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

@myndboostersai/ai-history

v1.1.4

Published

Export your Cursor, Claude Code, Copilot Chat and Gemini history to Markdown + JSONL

Readme

AI History

Export your Cursor, Claude Code, GitHub Copilot Chat, and Gemini CLI history to Markdown + JSONL.

These tools have been quietly writing your chat history to disk for months. This pulls it back out — retroactively, from sessions that already happened — and normalizes all four into one format.

Read-only. It never modifies your editor's data.


Install & run

No clone, no build, no compiler:

npx @myndboostersai/ai-history list

To install it permanently:

npm i -g @myndboostersai/ai-history
ai-history list

Requires Node 22.5+.

It uses Node's built-in SQLite, so there is no native build step — it installs in seconds with zero dependencies. Verified working even with --ignore-scripts --omit=optional.

On Node < 22.5 it falls back to the optional better-sqlite3, which does need a C++ toolchain. Upgrading Node is easier.


Usage

1. See what history you have

ai-history list
Found history for 26 project(s):

    2442 turns  /Users/you/code/payments-api
               claude_code:2442
     529 turns  /Users/you/code/console-ui
               copilot_chat:529  gemini:171
     ...

Run this first — it tells you which projects have history before you export anything.

2. Export it

# Chats for the project you're standing in  ->  ./.history
cd ~/code/my-app && ai-history

# A specific project
ai-history --project ~/code/my-app

# Everything, anywhere
ai-history --all --out ~/all-chats

# One agent only
ai-history --project ~/code/my-app --agent cursor

| Flag | Meaning | |---|---| | list | Show which projects have history (writes nothing) | | --all | Every project, not just the current folder | | --project <path> / -p | A specific folder | | --out <dir> / -o | Where to write (default ./.history) | | --agent <name> / -a | cursor | claude_code | copilot_chat | gemini. Repeatable. | | --help / -h | Usage |


Output

.history/
  cursor/2026-07-10_<session>.md      # human-readable
  cursor/2026-07-10_<session>.jsonl   # machine-readable, full fidelity
  claude_code/...
  copilot_chat/...
  gemini/...

Each JSONL line is one turn:

{
  "agent": "cursor",
  "sessionId": "...",
  "projectPath": "/Users/you/code/my-app",
  "timestamp": "2026-07-10T10:00:00.000Z",
  "role": "user",
  "text": "Fix the login bug",      // ONLY human prompts / assistant prose
  "contextFiles": ["src/auth.ts"],  // files attached at prompt time
  "toolCalls": [...],               // what the agent invoked
  "toolResults": [...],             // what came back — never mixed into `text`
  "filesTouched": ["src/auth.ts"],
  "model": "composer-2.5"           // which model actually answered
}

text is guaranteed free of tool output. A 1000-line file read can never masquerade as something you typed — that lives in toolResults. So pulling out every real prompt you ever wrote is one line:

cat .history/**/*.jsonl | jq -r 'select(.role=="user" and (.text|length>0)) | .text'

Or see which models actually answered you, across every tool:

$ cat .history/**/*.jsonl | jq -r '.model' | sort | uniq -c | sort -rn
   1352 gpt-5.3-codex
   1346 claude-opus-4-8
    890 gemini-3-flash-preview
    540 claude-haiku-4.5
    448 claude-sonnet-5
    ...

The .md files truncate long tool output for readability; the .jsonl always has it whole.


Where it reads from

| Agent | Location | |---|---| | Claude Code | ~/.claude/projects/ (all platforms) | | Gemini CLI | ~/.gemini/tmp/ (all platforms) | | Cursor | macOS ~/Library/Application Support/Cursor/UserLinux ~/.config/Cursor/UserWindows %APPDATA%\Cursor\User | | Copilot Chat | same as Cursor, with Code in place of Cursor |

Using Gemini or Claude as the model inside Cursor doesn't need a separate adapter — those chats are stored by Cursor, so the Cursor adapter already captures them. The gemini agent is the standalone Gemini CLI.


Status

All four adapters are validated against real data on Linux:

| Agent | Verified | |---|---| | Claude Code | ✅ 3,557 turns | | Copilot Chat | ✅ 2,867 turns | | Gemini CLI | ✅ 890 turns | | Cursor | ✅ 59 turns |

⚠️ macOS and Windows are not yet proven. The platform paths are unit-tested but have never run on a real Mac or Windows machine. Every on-disk format in this project turned out to differ from its documentation, so treat those platforms as unverified until someone actually runs it. If you're on one, please try ai-history list and report back.

Not covered: Continue.dev, Cline/Roo, Aider, Windsurf.


Also a VS Code / Cursor extension

The same core powers an editor command. Build it and press F5, then run "AI History: Export Chat History" from the command palette. The CLI is usually easier — the extension exports everything it can find rather than scoping to a folder.


Docs

Development

npm install
npm test        # 86 tests
npm run typecheck
npm run build   # CLI + VS Code extension