Configuration
All Code Insights configuration files, data paths, and local storage locations. Covers config.json, sync state, device ID, and the SQLite database.
File locations
All Code Insights data lives in ~/.code-insights/:
| File | Purpose |
|---|---|
~/.code-insights/data.db | SQLite database (sessions, insights, messages) |
~/.code-insights/config.json | CLI configuration |
~/.code-insights/sync-state.json | Incremental sync state (file modification times) |
~/.code-insights/device-id | Stable device identifier |
config.json
Created by code-insights init. Example:
{
"sourcePaths": {
"claudeCode": "/Users/you/.claude/projects",
"cursor": "/Users/you/Library/Application Support/Cursor/User/globalStorage"
}
}Viewing config
code-insights configShows sync paths, dashboard port, LLM provider, and telemetry status.
LLM settings
LLM provider settings (provider, model, API key, base URL) are stored in config.json under the dashboard.llm key. Configure via CLI or the dashboard Settings page:
# Interactive wizard
code-insights config llm
# Non-interactive
code-insights config llm --provider openai --model gpt-4o --api-key sk-...
# View current config
code-insights config llm --showSupported providers: OpenAI, Anthropic, Google Gemini, Ollama (local, no API key needed).
Telemetry
Anonymous, opt-in telemetry collects command name, success/failure, CLI version, OS, and session count bucket. No filenames, project names, session content, API keys, or personal info is ever collected.
code-insights telemetry status # View what's collected
code-insights telemetry opt-out # Disable
code-insights telemetry opt-in # Re-enable
code-insights config set telemetry false # AlternativeEnvironment variable overrides: CODE_INSIGHTS_TELEMETRY_DISABLED=1 or DO_NOT_TRACK=1.
Resetting
To delete all local data:
code-insights reset --confirmThis deletes data.db, sync-state.json, and device-id. The config.json is preserved.
To delete everything including config:
rm -rf ~/.code-insights