Every AI conversation ends somewhere — quota runs out, the context window fills, you switch tools, or you just come back tomorrow. AnyLLM snapshots what happened and hands it to whatever comes next.
It ships as two surfaces that share one idea:
| Surface | Carries context between | Where it lives | |
|---|---|---|---|
| 🧩 | Browser Extension | Claude.ai, ChatGPT, Gemini | src/ (this repo root) |
| ⌨️ | CLI (anyllm-ctx) |
Claude Code, Codex, Agy, Kiro, Kilocode, OpenCode, Cursor | cli/ |
Demo: https://anyllm.vercel.app/
anycapsule/
├── src/ # Browser extension source (Manifest V3)
│ ├── adapters/ # adapter.js — PlatformAdapter base + Claude/ChatGPT/Gemini adapters
│ ├── components/ # Injected UI: side panel, banners, toolbars
│ ├── services/ # Context extraction, pinboard, highlights, delete, handoff, storage
│ ├── background.js # Service worker — message routing, side panel behavior
│ ├── content.js # Content script entry point
│ └── sidepanel.html/js/css # Side panel UI (opens on toolbar icon click)
├── manifest.json # Extension manifest (Manifest V3)
├── vite.config.js # Build config (vite-plugin-web-extension)
├── cli/ # Python CLI package — "Git for LLM context" for coding agents
│ ├── src/anyllm/ # ingestors, distiller, merger, composer, injectors, integrations
│ ├── tests/
│ └── README.md # Full CLI documentation
├── landing/ # Static marketing page (no build step)
└── docs/ # Design notes / working docs
A Manifest V3 extension that works inside the conversation itself — no server, no account.
Clicking the toolbar icon opens a Chrome side panel (not a popup dropdown) that stays docked next to the page. Pins, highlights, and extracted context are rendered natively inside that panel — nothing is injected as a floating overlay on top of the conversation.
Features
- Extract Context — scans the thread for decisions, next steps, code blocks, and topics, then condenses it into a structured summary, shown in the side panel's Context tab.
- Context Handoff — turns that extraction into a ready-to-paste briefing, right there in the panel. Copy to clipboard or send it straight into a new Claude/ChatGPT/Gemini tab.
- Pins — pin any message from its hover toolbar; the pinned list, with unpin, lives in the side panel's Pins tab (not a floating panel on the page).
- Highlights — select text and mark it yellow, green, or red; anchored to the DOM via relative XPath so it survives reloads. The list of highlights, with remove, lives in the side panel's Highlights tab.
- Soft Delete & Bulk Mode — hide messages from view locally (never mutates the actual conversation), toggle visibility, or bulk-select and clear several at once, from the side panel's Tools tab.
- Local-first storage — everything lives in
chrome.storageon your machine.
Supported platforms: claude.ai, chat.openai.com / chatgpt.com, gemini.google.com.
sidepanel.js ──message──▶ content.js ──▶ services/adapter.js (DOM in, structured messages out)
│ └─▶ services/* (contextExtractor, pinService,
│ highlightService, deleteService,
│ handoffService, storage)
│ └─▶ components/* (messageToolbar, highlightToolbar,
│ HandoffBanner)
└──reads/writes chrome.storage directly for pins & highlights (no DOM dependency)
background.js ── service worker: side panel behavior, install lifecycle, cross-tab handoff delivery
src/services/adapter.js holds the shared PlatformAdapter base class plus ClaudeAdapter, ChatGPTAdapter, and GeminiAdapter — one file, one interface (getMessageElements(), extractMessageData(), getConversationId(), etc.). Services never touch the DOM directly for data — they consume whatever the adapter returns, so adding a new platform means adding one class in that file, not touching every feature.
The side panel is its own extension page — it can't reach into the host page's DOM directly. It reads/writes pins and highlights straight from chrome.storage (pure data, no DOM needed) and relays anything that does need the live page — extracting context, removing a highlight span, toggling deleted messages — to content.js via chrome.tabs.sendMessage. chrome.storage.onChanged keeps the panel and the in-page toolbar in sync in both directions.
npm install
npm run dev # vite build --watchThen in Chrome: chrome://extensions → enable Developer mode → Load unpacked → select dist/. Click the AnyLLM toolbar icon on Claude.ai, ChatGPT, or Gemini to open the side panel.
npm run build # one-off production build
npm run zip # build + zip dist/ for distributionA Python CLI that snapshots a dying coding session and primes the next model in 30 seconds — as a slash command inside your agent.
pip install anyllm-ctx
cd your-project
anyllm install # detects installed AI coding CLIs, wires up slash commands in all of them/anyllm-pack ← Claude Code, Kiro, OpenCode, Kilocode
$anyllm-pack ← Codex
anyllm-pack ← type as a plain message in Antigravity / Agy
Pipeline: Ingestor → Distiller → Merger → Composer → Adapter. Every pack merges into a rolling .anyllm/current.md instead of overwriting it, with decisions classified CONFIRMED / STALE / ORPHANED across sessions.
Full command reference, config, and storage layout: cli/README.md.
landing/index.html + landing/styles.css — static, no build step, no dependencies. Open the file directly or serve the folder to preview.
- Extension: Node + Vite (
package.jsonat repo root). Path aliases@services/*,@adapters/*,@components/*are configured injsconfig.json. - CLI: Python 3.10+, Poetry-based build (
cli/pyproject.toml). Run tests withpytestfromcli/.
MIT.
