← ClaudeAtlas

chat-historylisted

Search, inspect, and export Claude Code, Cursor, and Codex conversation history. Use when the user asks about past conversations, wants to find a previous session, needs to search chat history, wants a summary of what they worked on, or asks to resume a session. Also use when the user says "what did I work on", "find that conversation where I...", "show me my recent sessions", or "search my history for...".
ay-bh/chat-history · ★ 12 · AI & Automation · score 79
Install: claude install-skill ay-bh/chat-history
# chat-history Search, inspect, and export Claude Code, Cursor, and Codex conversation history. The short alias `ch` works identically. If the command is not found: `cargo install chat-history`. ## When to use - User asks about past conversations or sessions - User wants to find something they discussed before - User needs a summary of recent work / accomplishments - User wants to resume or export a previous session ## Process **Keyword question** ("find that conversation where I..."): 1. `chat-history search "<query>" --compact` — one line per conversation: short id, date, source, directory, `#ordinal` of the best match (`-` for a title or first-prompt match), title, then `— Role: excerpt` and `(also #a #b)` for its other matches. Role is `You` (the person), `Assistant` or `Tool` (command output or file contents). BM25 searches metadata and transcripts together. Use `--json` instead only when a script parses the results: each hit then carries `session_id`, `score`, `snippet`, `role`, `ordinal`, `timestamp`, `tools`, `files`, and `additional_matches` with the same message fields. 2. Shortlist by title and excerpt (see "Choosing the best hit"). 3. Read the hit in context, not the whole transcript: `chat-history view <id> --plain --around <ordinal>` (2 messages each side; `-C N` to widen, `--max-chars 1500` to cap long messages), or `--around` one of the `also` ordinals. A title/prompt match has no ordinal — use `inspect` for those. `view --json` gives the same selection