npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@purmemo.ai/converters

v0.3.0

Published

Platform converters for AMP — parse ChatGPT, Claude, Gemini, Cursor, Perplexity, Grok, Mistral, and GitHub Copilot exports into AMP format

Readme

@purmemo.ai/converters

Platform converters for AMP (AI Memory Protocol) — parse ChatGPT, Claude, Gemini, Cursor, Perplexity, Grok, Mistral, and GitHub Copilot exports into portable AMP format.

Install

npm install @purmemo.ai/converters

Platform Support

| Platform | Converter | Export Path | |----------|-----------|-------------| | ChatGPT | convertChatGPTExport | Settings → Data Controls → Export Data | | Claude | convertClaudeExport | Settings → Export Data | | Gemini | convertGeminiExport | Google Takeout (converter ready — awaiting Google chat export support) | | Cursor | convertCursorDBRows | Auto-extracted from local SQLite DB | | Perplexity | convertPerplexityExport | Settings → Data Controls → Download My Data | | Grok | convertGrokExport | accounts.x.ai → Download account data | | Mistral Le Chat | convertMistralExport | Settings → Export | | GitHub Copilot Chat | convertGitHubCopilotExport | VS Code: Command Palette → "Chat: Export Chat..." | | Poe | 🔜 coming | GDPR email request to [email protected] | | Amazon Q | 🔜 coming | CLI: ~/.aws/amazonq/history/ | | Character.ai | 🔜 coming | Profile → Settings → Account → Export |

Usage

import {
  convertChatGPTExport,
  convertClaudeExport,
  convertGeminiExport,
  convertCursorDBRows,
  convertPerplexityExport,
  convertGrokExport,
  convertMistralExport,
  convertGitHubCopilotExport,
} from '@purmemo.ai/converters'
import { readFileSync } from 'fs'

// ChatGPT
const chatgpt = convertChatGPTExport(JSON.parse(readFileSync('conversations.json', 'utf-8')))

// Claude
const claude = convertClaudeExport(JSON.parse(readFileSync('conversations.json', 'utf-8')))

// Perplexity
const perplexity = convertPerplexityExport(JSON.parse(readFileSync('perplexity-export.json', 'utf-8')))

// Grok
const grok = convertGrokExport(JSON.parse(readFileSync('prod-grok-backend.json', 'utf-8')))

// Mistral
const mistral = convertMistralExport(JSON.parse(readFileSync('mistral-export.json', 'utf-8')))

// GitHub Copilot Chat (single session or array of sessions)
const copilot = convertGitHubCopilotExport(JSON.parse(readFileSync('copilot-session.json', 'utf-8')))

All converters return an AMPExport object:

{
  amp_version: "0.1",
  exported_at: "2026-03-08T00:00:00.000Z",
  platform: "chatgpt",
  conversation_count: 42,
  conversations: [
    {
      id: "...",
      title: "...",
      platform: "chatgpt",
      messages: [
        {
          id: "...",
          role: "user",       // "user" | "assistant" | "system" | "tool"
          content: "...",
          platform: "chatgpt",
          timestamp: "2026-03-08T00:00:00.000Z",
          model: "gpt-4o",
          parent_id: null,
          sources: null,      // AMPSource[] for Perplexity/Grok citations
          metadata: {}
        }
      ],
      created_at: "...",
      updated_at: "...",
      source_format: "chatgpt-export-v1",
      amp_version: "0.1"
    }
  ]
}

Utilities

Shared normalization helpers — useful when building custom converters:

import { normalizeRole, normalizeTimestamp } from '@purmemo.ai/converters'

// Maps platform-specific role strings to AMP roles
normalizeRole('human')       // → "user"   (Claude)
normalizeRole('grok')        // → "assistant" (Grok)
normalizeRole('model')       // → "assistant" (Gemini)
normalizeRole('userPrompt')  // → "user"   (M365 Copilot)
normalizeRole('CHATBOT')     // → "assistant" (Cohere)

// Handles ISO 8601, Unix seconds, Unix ms, BSON $date.$numberLong
normalizeTimestamp(1741348800)                           // Unix seconds → ISO
normalizeTimestamp(1741348800000)                        // Unix ms → ISO
normalizeTimestamp({ $date: { $numberLong: "1741348800000" } })  // BSON → ISO
normalizeTimestamp("2026-03-08T00:00:00Z")              // pass-through
normalizeTimestamp(null)                                 // → null

Citations / Sources

Perplexity and Grok include web search citations. These are preserved in the sources field on assistant messages:

{
  role: "assistant",
  content: "AMP is the AI Memory Protocol...",
  sources: [
    {
      url: "https://github.com/purmemo-ai/purmemo-amp",
      title: "purmemo-amp",
      snippet: "The open protocol for AI conversation portability."
    }
  ]
}

Community

  • Discord — get help, discuss the spec, share your conversions
  • GitHub Issues — bug reports and feature requests

Links

Apache 2.0 — by pūrmemo