Skip to content

Config File

The contextkit.config.yaml file configures your ContextKit project. It lives at the root of your project directory.

# Directory containing your context files
context_dir: context
# Database connections for introspection, enrichment, and verification
data_sources:
default:
adapter: duckdb
path: ./warehouse.duckdb
production:
adapter: postgres
connection: postgres://user:pass@host:5432/analytics

Path to the directory containing your metadata files. Defaults to context.

Named database connections. Each source requires an adapter field plus adapter-specific configuration:

AdapterRequired Fields
duckdbpath — path to .duckdb file
postgresconnection — PostgreSQL connection URI
mysqlconnection — MySQL connection URI
mssqlconnection — SQL Server connection URI
sqlitepath — path to .sqlite or .sqlite3 file
snowflakeaccount, username, password, database, schema (optional: warehouse, role)
bigqueryproject, dataset (optional: keyFilename)
clickhousehost (optional: port)
databricksserverHostname, httpPath, token
data_sources:
# DuckDB
warehouse:
adapter: duckdb
path: ./warehouse.duckdb
# PostgreSQL / Neon / Supabase
production:
adapter: postgres
connection: postgres://user:pass@host:5432/analytics
# MySQL
mysql_db:
adapter: mysql
connection: mysql://user:pass@host:3306/mydb
# Snowflake
snowflake_dwh:
adapter: snowflake
account: xy12345.us-east-1
username: analyst
password: ${SNOWFLAKE_PASSWORD}
database: ANALYTICS
schema: PUBLIC
warehouse: COMPUTE_WH
# BigQuery
bq:
adapter: bigquery
project: my-gcp-project
dataset: analytics

Optional configuration for the static documentation site:

FieldDefaultDescription
titleContextKitSite title shown in navigation
base_path.Base path for asset URLs

Many CLI commands accept --source <name> to specify which data source to use:

Terminal window
context introspect --source default
context enrich --target silver --apply --source production
context verify --source default

If you only have one source named default, commands use it automatically.

The context setup wizard auto-detects databases from:

  1. Existing contextkit.config.yaml
  2. Environment variables (DATABASE_URL, POSTGRES_URL, etc.)
  3. MCP server configs from 5 IDEs:
    • Claude Code.claude/mcp.json
    • Cursor~/.cursor/mcp.json
    • VS Code.vscode/mcp.json and VS Code settings
    • Windsurf~/.windsurf/mcp.json
    • Claude Desktop~/Library/Application Support/Claude/claude_desktop_config.json
  4. Database files in the current directory (.duckdb, .sqlite, .db)