Import your chat exports from ChatGPT, Claude, Grok, Claude Code, and Cursor. Generate vector embeddings locally with sentence-transformers. Expose everything via an MCP server that any AI tool can query.
Local-first AI memory archive. Import ChatGPT, Claude, and Grok exports, generate semantic embeddings, and search via MCP server. Zero cloud, zero cost.
Estrelas
68
Ferramentas
—
Disponibilidade
—
Open core: The local pipeline (import, embed, summarize, search, MCP server) is free and AGPL-licensed. Cloud sync and hosted MCP are on the roadmap at mychatarchive.com.
Why MyChatArchive
Your archive, searchable. Drop your ChatGPT, Claude, or Grok exports into the import folder, or let MyChatArchive auto-discover Claude Code and Cursor sessions from your machine. Full transcripts, local embeddings, MCP server. No cloud required.
Lossless
Full message transcripts, not extracted summaries. You can always search the original.
Local-first
Single SQLite file. Embeddings run on your machine. Core needs no API keys.
Developer-native
Auto-discovers Claude Code sessions and Cursor conversations from your local machine on day one.
MCP server
Claude Desktop, Cursor, Claude Code, and any MCP client can search your archive.
Quick Start
git clone https://github.com/1ch1n/mychatarchive.git
cd mychatarchive
pip install .
# 1. Set up (creates drop folder, configures auto-discovery)
mychatarchive init
# 2. Import everything in one command
# Auto-discovers Claude Code + Cursor, scans your drop folder
mychatarchive sync
# 3. (Optional) Generate thread summaries for richer context retrieval
# Needs an API key: set OPENROUTER_API_KEY or ANTHROPIC_API_KEY
mychatarchive summarize
# 4. Generate local embeddings
mychatarchive embed
# 5. Start the MCP server
mychatarchive serve
Then connect from Claude Desktop or Cursor: run mychatarchive mcp-config and add the output to your client config. That's it.
What You Get
Once the MCP server is running, any connected AI tool can call:
Tool
What it does
search_brain
Semantic search by meaning across all conversations
search_recent
Recent conversations and captured thoughts by time range
get_context
Full context bundle for a topic: related threads, LLM summaries, thoughts
capture_thought
Save a thought or note with auto-embedding for future retrieval
get_profile
Snapshot of your recent focus areas, thread summaries, and thoughts
get_current_datetime
Current UTC datetime, injected into every tool response
All search tools support filtering by platform, time range (hours_back, since), and thread group. Sort by relevance or recency.
Example: Ask Claude "What did I decide about the database architecture last month?" and it searches your actual conversation history semantically.
Installation
From source (recommended for now)
git clone https://github.com/1ch1n/mychatarchive.git
cd mychatarchive
pip install .
Development install
pip install -e ".[dev]"
Requirements
Python 3.10+
~500MB disk for the embedding model (downloaded once, runs locally)
No API keys needed for: sync, embed, search, serve
summarize uses an LLM API for thread summaries (optional but recommended for get_profile)
The Pipeline
Full workflow:
mychatarchive sync # import from all sources
mychatarchive summarize # LLM thread summaries (optional, needs API key)
mychatarchive embed # generate vector embeddings locally
mychatarchive serve # start MCP server
Shortcut:
mychatarchive sync --embed # sync + embed in one shot
mychatarchive serve
The pipeline is incremental. Re-run sync any time -- SHA1 dedup means it's always safe. New messages get embedded on the next embed run without --force.
Sync
mychatarchive sync # import from all sources
mychatarchive sync --embed # sync + generate embeddings in one shot
sync imports in three layers:
Auto-discovery -- Claude Code sessions (~/.claude/projects/) and Cursor conversations from local databases. Enabled by default, toggleable in init.
Drop folder -- anything in ~/.mychatarchive/imports/. Drop your ChatGPT, Claude, or Grok export JSON here; format is auto-detected. Subdirectories scanned recursively.
Named sources -- custom paths or NAS shares you've configured with mychatarchive sources add.
All three deduplicate into the same archive via SHA1 hashing.
Note: Auto-discovery covers Claude Code (the terminal agent) and Cursor. Claude web, mobile, and desktop app conversations require a manual export from Anthropic's settings -- drop the file in your imports folder and run sync.
Summarize
Generate LLM thread summaries for richer context retrieval and the get_profile MCP tool.
mychatarchive summarize # default model via OpenRouter
mychatarchive summarize --model gpt-4o-mini # specify model
mychatarchive summarize --key sk-... # pass API key inline
mychatarchive summarize --limit 50 # process first 50 threads (for testing)
Summaries are stored in SQLite, embedded into their own vector index, and surfaced by get_context and get_profile. Without summaries, get_profile falls back to recent message chunks.
API key: Set OPENROUTER_API_KEY (default) or ANTHROPIC_API_KEY, or pass --key inline.
Thread Groups
Organize threads into named groups for scoped search and context retrieval. Useful when your archive mixes personal conversations, coding work, and project threads -- you can scope search to exactly what's relevant.
# Create groups
mychatarchive groups create jarvis --description "Daily personal chats"
mychatarchive groups create coding --description "Dev work and technical threads"
# Browse threads to find IDs
mychatarchive groups show jarvis
# Add threads
mychatarchive groups add jarvis <thread_id> <thread_id>
# Scope search to a group
mychatarchive search "what did I decide" --group jarvis
# In MCP tools: search_brain(query="...", group="jarvis")
The group filter works on search_brain, get_context, get_profile, and the search CLI.
Sensitivity Levels
Years of chat history contain things an agent should not surface on any random turn -- sensitive work, personal matters, private notes. Classify threads into three levels and the archive enforces them in the data access layer:
Level
Behavior
public
Default. Returned by every search and MCP tool.
private
Returned only when a caller explicitly opts in (include_private on MCP tools, --include-private on the CLI).
sealed
Never returned by the MCP server, under any circumstances. CLI-only, and only with an explicit --include-sealed flag.
# See where you stand
mychatarchive classify --list
# Classify one thread (applies immediately)
mychatarchive classify --thread <id> --level private
# Bulk-classify by keyword -- previews first, applies only with --confirm
mychatarchive classify --query "project-x" --level sealed
mychatarchive classify --query "project-x" --level sealed --confirm
# Bulk-classify old threads (last message before a date)
mychatarchive classify --before 2022-01-01 --level private --confirm
# Search honors levels
mychatarchive search "query" # public only
mychatarchive search "query" --include-private
mychatarchive search "query" --include-sealed # prints a warning
Details worth knowing:
Enforcement lives in the data access layer, not in tool handlers. A retrieval call that doesn't name a scope fails closed to public -- including third-party integrations that use mychatarchive.db directly.
Bulk classification is thread-scoped: one matching message classifies the whole conversation, which is how sensitivity works in practice.
mychatarchive summarize (the one command that sends content to an external LLM API) summarizes public threads only by default; --include-private opts in, and sealed threads never leave the machine.
Re-running sync on a classified thread is safe: newly imported messages inherit the thread's level before anything can read them.
Existing archives migrate automatically on first use -- every row defaults to public, and a verified backup (*.pre-v3-*.backup.sqlite) is written next to the database before the schema changes.
Sealed content is hidden, not encrypted: the text still exists in the SQLite file, its FTS index, and its vectors. Protect the file itself with filesystem permissions. Encryption at rest is a possible future addition.
Default mode is semantic (vector search). Supports: --mode keyword for FTS, --platform for source filter, --hours / --since for time filter, --sort time for newest-first, --group for group filter.
Export
mychatarchive export archive.json # full structured export
mychatarchive export archive.csv # spreadsheet-friendly
mychatarchive export archive.db # full SQLite copy with embeddings
mychatarchive export chatgpt.json --platform chatgpt
mychatarchive export everything.json --include-thoughts
The principle: anything that runs on your machine is free. Anything that requires infrastructure is paid.
Licensing: Local and self-hosted use is free under AGPL-3.0. Commercial use or offering MyChatArchive as a hosted service requires a commercial license. Contact [email protected] for commercial licensing.
Local-first AI memory archive. Import ChatGPT, Claude, and Grok exports, generate semantic embeddings, and search via MCP server. Zero cloud, zero cost.
Ainda não há lista de ferramentas. Servidores remotos recebem uma após a primeira verificação de saúde.
Perguntas frequentes
Perguntas
Como instalo Mychatarchive?
Copie nesta página a configuração stdio para Cursor, Claude Desktop, Claude Code ou VS Code. Ela usa a instalação do publicador, não um proxy do PlugMCP.
Mychatarchive precisa de uma chave de API?
Este registro não lista nenhuma variável de ambiente obrigatória.
Qual transporte Mychatarchive usa?
Mychatarchive roda localmente via stdio.
Quando Mychatarchive foi verificado pela última vez?
Última verificação: 2026-10-26. Local-first AI memory archive. Import ChatGPT, Claude, and Grok exports, generate semantic embeddings, and search via MCP server. Zero cloud, zero cost.