Skip to content

Configuration

Context Chain is configured through ckg.config.json in the project root. See ckg.config.example.json for a starting point.

Example

json
{
  "project": "my-project",
  "ai": { "provider": "claude-cli" },
  "analysis": {
    "summaryWords": 30,
    "contentWords": 150
  },
  "repos": [
    {
      "name": "my-service",
      "path": "/absolute/path/to/repo",
      "type": "backend",
      "cpgFile": "data/my-service.json",
      "packages": ["@myorg/shared"]
    }
  ]
}

Top-Level Fields

project

Type: stringRequired

A name for this Context Chain project.

ai

Type: objectRequired

FieldTypeDescription
providerstring"claude-cli" (subscription, no cost) or "anthropic-api" (direct API).
apiKeystringRequired if provider is anthropic-api. Can also be set in the Dashboard.
modelstringModel to use with anthropic-api. Defaults to claude-sonnet-4-20250514.

TIP

claude-cli uses claude -p from your Claude Max subscription — no API costs and doesn't eat your daytime quota. Recommended for most users.

analysis

Type: object — Optional

FieldTypeDefaultDescription
summaryWordsnumber30Target word count for decision summaries
contentWordsnumber150Target word count for full decision content

Repo Configuration

repos

Type: arrayRequired

FieldTypeRequiredDescription
namestringYesRepository identifier.
pathstringYesAbsolute path to the repo on your machine.
typestringNoLabel: "frontend", "backend", "shared-lib", "infra". Informational only.
cpgFilestringYesRelative path for Joern CPG JSON output.
languagestringNoPrimary language: "javascript", "typescript", "python", "java".
srcDirstringNoSubdirectory containing source code (e.g., "src").
packagesstring[]NoNPM package names this repo publishes. Used for cross-repo dependency detection.
skipEdgeFunctionsbooleanNoSkip small utility functions during analysis. Reduces noise for large repos.

Environment Variables

VariableDefaultDescription
CKG_MEMGRAPH_PORT7687Memgraph bolt protocol port
DASHBOARD_PORT3001Dashboard web server port

Useful for the dogfooding setup where you run two isolated instances.

WARNING

ckg.config.json contains machine-specific absolute paths. Add it to .gitignore.

Released under the Apache 2.0 License.