FAQ
Frequently asked questions about Code Insights — installation, privacy, supported tools, costs, and troubleshooting.
Code Insights is a free, open-source CLI tool that parses AI coding sessions from multiple tools into a local knowledge base. Here are the most common questions.
What is Code Insights?
Code Insights is an open-source CLI and embedded dashboard that analyzes your AI coding sessions. It parses session history from Claude Code, Cursor, Codex CLI, Copilot CLI, and VS Code Copilot Chat, stores everything in a local SQLite database, and provides terminal analytics plus a browser-based dashboard with optional LLM-powered insights.
Which AI coding tools does Code Insights support?
Code Insights supports five tools out of the box:
- Claude Code — parses JSONL session files from
~/.claude/projects/ - Cursor — reads the SQLite state database (
state.vscdb) - Codex CLI — parses rollout JSONL files from
~/.codex/sessions/ - Copilot CLI — reads event JSONL files from
~/.copilot/session-state/ - VS Code Copilot Chat — reads chat session data from VS Code's storage
All supported tools are auto-detected. No per-tool configuration needed. See the Multi-Source Setup guide for platform-specific details.
Is my data sent to the cloud?
No. Code Insights is fully local-first. All session data is stored in a SQLite database on your machine at ~/.code-insights/data.db. There are no accounts, no cloud services, and no data ever leaves your device.
The only optional network activity is if you configure LLM-powered insights — in that case, session content is sent to your chosen LLM provider (OpenAI, Anthropic, Gemini, or Ollama/llama.cpp for fully local inference).
How do I install Code Insights?
npm install -g @code-insights/cli
code-insightsThat's it. Running code-insights syncs your sessions and opens the dashboard automatically. No configuration files, API keys, or cloud accounts needed. See the Installation and Quick Start guides for details.
Is Code Insights free?
Yes. Code Insights is free and open-source under the MIT license. The entire stack — CLI, embedded dashboard, and Hono server — is available on GitHub.
How does Code Insights track AI coding costs?
The code-insights stats cost command shows cost breakdowns by project and model. Cost data is calculated from token usage in your session files. You can filter by time period (--period 7d|30d|90d|all), project, or source tool.
The dashboard also shows cost analytics on the Analytics page with visual charts. See Terminal Analytics for all stats subcommands.
What insights can Code Insights extract?
When you run analysis on a session, Code Insights uses your configured LLM to extract structured insights across several types:
- Decisions — architectural and design choices made during the session
- Learnings — new knowledge gained or patterns discovered
- Techniques — specific coding approaches or tool usage patterns
- Summaries — concise overviews of what happened in the session
- Prompt Quality — five-dimension scores (0–100) with deficit and strength findings
- Friction points — per-session friction categorized across 9 types (e.g.,
knowledge-gap,stale-assumptions,scope-creep) with attribution (user-actionable,ai-capability, orenvironmental) - Effective patterns — per-session effective behaviors categorized across 8 types (e.g.,
structured-planning,systematic-debugging) with driver attribution - Facets — extracted per-session metadata (outcome satisfaction, iteration count, course corrections) used by the Reflect pipeline for cross-session synthesis
Insights are stored locally and searchable in the dashboard. See Insights & Analysis and the Reflect & Patterns guide for details.
How do I use Reflect to get cross-session patterns?
Run code-insights reflect to generate a weekly synthesis of your friction points, effective patterns, and CLAUDE.md rule suggestions. The default is the current ISO week:
code-insights reflect # current week
code-insights reflect --week 2026-W10 # specific weekReflect requires the dashboard server to be running (code-insights dashboard) and an LLM configured in Settings. If your sessions don't have facets yet, run code-insights reflect backfill first to extract them. See the Reflect & Patterns guide for the full workflow.
How do I sync sessions from Cursor?
Cursor sessions are auto-detected. Run code-insights sync and the CLI will find Cursor's state.vscdb database in the platform-specific location (macOS, Linux, or Windows). To sync only Cursor sessions, use code-insights sync --source cursor.
How do I sync sessions from Claude Code?
Claude Code sessions are auto-detected from ~/.claude/projects/. Run code-insights sync to process all session files. Use code-insights sync --source claude-code to sync only Claude Code sessions.
How do I sync sessions from VS Code Copilot Chat?
VS Code Copilot Chat sessions are auto-detected from VS Code's workspaceStorage/ directory. Run code-insights sync and the CLI finds chat session files automatically. Use code-insights sync --source copilot to sync only VS Code Copilot Chat sessions.
How do I export my insights?
There are two ways to export. For a single session, open the session detail panel and click the download icon to export as Markdown, Obsidian, or Notion format. For AI-powered synthesis across sessions, open the Export page — it uses your configured LLM to compile deduplicated, prioritized knowledge in 4 formats (Agent Rules, Knowledge Brief, Obsidian, Notion) at 3 depth levels. See Analytics & Export for details.
Can I use Code Insights without an LLM API key?
Yes. LLM analysis is optional. Without an API key, you still get full session syncing, browsing, search, cost tracking, terminal analytics, and the dashboard. The only feature that requires an LLM is the "Analyze" button for extracting insights.
For fully local LLM inference, you can use Ollama or llama.cpp — no API key or cloud service needed. We recommend Gemma 4 12B as a strong local model. See the Local LLM Setup guide.
Where is my data stored?
All data lives in ~/.code-insights/:
| File | Purpose |
|---|---|
data.db | SQLite database with all sessions, messages, and insights |
config.json | Configuration (source tools, preferences) |
sync-state.json | Tracks which files have been synced |
device-id | Anonymous device identifier |
To delete everything: code-insights reset --confirm or rm -rf ~/.code-insights.