Repository navigation
Expand file tree
/
Copy path.env.example
More file actions
153 lines (134 loc) · 5.48 KB
/
Copy path.env.example
File metadata and controls
153 lines (134 loc) · 5.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
# ContextMine Environment Configuration
# API settings
APP_MODE=development
DEBUG=true
API_HOST=0.0.0.0
API_PORT=8000
# Ephemeral repository analysis (required in production)
SANDBOX_API_URL=
SANDBOX_API_KEY=
SANDBOX_ANALYZER_SNAPSHOT=
SANDBOX_ANALYSIS_TIMEOUT_SECONDS=3600
SANDBOX_RESULT_MAX_BYTES=67108864
SANDBOX_ARTIFACT_MAX_BYTES=1073741824
# CodeCharta visualization host port used by Docker Compose and the Vite dev proxy
CODECHARTA_PORT=9001
# Optional full Vite proxy target; overrides the URL derived from CODECHARTA_PORT
# VITE_CODECHARTA_URL=http://localhost:9001
# Database
# For local development with Docker Compose:
DATABASE_URL=postgresql+asyncpg://contextmine:contextmine@localhost:5432/contextmine
# Optional: postgres container architecture (default in compose: linux/amd64)
# POSTGRES_PLATFORM=linux/amd64
# For running inside Docker network:
# DATABASE_URL=postgresql+asyncpg://contextmine:contextmine@postgres:5432/contextmine
# Twin Evolution Cockpit
# Enables the Evolution tab and backend endpoints
TWIN_EVOLUTION_VIEW_ENABLED=true
# Fixed analysis window in days (v1 default)
TWIN_EVOLUTION_WINDOW_DAYS=365
# GitHub OAuth (required for authentication)
# Create a GitHub OAuth App at: https://github.com/settings/developers
# Set Authorization callback URL to: http://localhost:8000/api/auth/callback
# (Both admin UI and MCP clients use this single callback URL)
GITHUB_CLIENT_ID=your_github_client_id
GITHUB_CLIENT_SECRET=your_github_client_secret
# Public URL for OAuth callbacks (must match GitHub OAuth App settings)
PUBLIC_BASE_URL=http://localhost:8000
# Security keys (generate secure random values for production!)
# Generate with: python -c "import secrets; print(secrets.token_urlsafe(32))"
SESSION_SECRET=dev-session-secret-change-in-production
TOKEN_ENCRYPTION_KEY=dev-encryption-key-change-in-production
# MCP Security
# Comma-separated list of allowed origins for MCP endpoint
# Empty = allow all origins (dev mode only!)
# Example: MCP_ALLOWED_ORIGINS=https://claude.ai,https://your-app.com
MCP_ALLOWED_ORIGINS=
# Comma-separated browser origins for API CORS
CORS_ALLOWED_ORIGINS=http://localhost:8000
# MCP OAuth base URL (for OAuth callbacks)
# Must match where your server is accessible
MCP_OAUTH_BASE_URL=http://localhost:8000
# Set to false for deterministic indexing and FTS-only retrieval without
# external embedding or LLM calls.
MODEL_CALLS_ENABLED=true
# Model providers (at least one is required when model calls are enabled)
# OPENAI_API_KEY=sk-...
# ANTHROPIC_API_KEY=sk-ant-...
# GEMINI_API_KEY=...
# Default models
# DEFAULT_EMBEDDING_MODEL=openai:text-embedding-3-small
# DEFAULT_LLM_PROVIDER=openai
# DEFAULT_LLM_MODEL=gpt-5-mini
# OPENAI_LLM_MODEL=gpt-5-mini
# ANTHROPIC_LLM_MODEL=claude-sonnet-4-5-20250929
# GEMINI_LLM_MODEL=gemini-2.0-flash
# Local models via Ollama; embeddings stay on OpenAI/Gemini.
# SEMANTIC_EXTRACTION_LLM_PROVIDER=ollama runs only semantic entity extraction
# locally (with a prompt tuned for qwen3-coder); everything else keeps
# DEFAULT_LLM_PROVIDER.
# SEMANTIC_EXTRACTION_LLM_PROVIDER=
# SEMANTIC_EXTRACTION_LLM_MODEL=
# Semantic extraction commits every batch and resumes unfinished chunks on the
# next run; MAX_CHUNKS caps the chunks per run (0 = all).
# SEMANTIC_EXTRACTION_MAX_CHUNKS=0
# SEMANTIC_EXTRACTION_BATCH_SIZE=25
# SEMANTIC_EXTRACTION_CONCURRENCY=1
# OLLAMA_BASE_URL=http://localhost:11434
# OLLAMA_LLM_MODEL=qwen3-coder:30b
# OLLAMA_NUM_CTX=8192
# Research Agent (advanced code investigation)
# Artifact storage: 'memory' or 'file'
ARTIFACT_STORE=memory
# Directory for file-backed artifact store
ARTIFACT_DIR=.mcp_artifacts
# Artifact TTL in minutes
ARTIFACT_TTL_MINUTES=60
# Maximum number of research runs to keep
ARTIFACT_MAX_RUNS=100
# Model for research agent reasoning
RESEARCH_MODEL=claude-sonnet-4-5-20250929
# Max tokens per research agent LLM call
RESEARCH_MAX_TOKENS=4096
# Default maximum steps for research agent
RESEARCH_BUDGET_STEPS=10
# Prefect orchestration
PREFECT_API_URL=http://localhost:4200/api
PREFECT_WORK_POOL_NAME=contextmine-process
PREFECT_SYNC_DEPLOYMENT=sync_single_source/default
PREFECT_DUE_INTERVAL_SECONDS=60
PREFECT_WORKER_LIMIT=2
# Native TypeScript protocol logs: INFO (default) or DEBUG
LSP_PROTOCOL_LOG_LEVEL=INFO
# SCIP Polyglot Indexing
# Comma-separated list of languages to index
SCIP_LANGUAGES=python,typescript,javascript,java,php
# Dependency installation mode: auto, always, never
SCIP_INSTALL_DEPS_MODE=auto
# Indexing timeouts per language (seconds)
SCIP_TIMEOUT_PYTHON=300
SCIP_TIMEOUT_TYPESCRIPT=600
SCIP_TIMEOUT_JAVA=900
SCIP_TIMEOUT_PHP=300
# Node.js memory limit for TS/JS/Python indexers (MB)
SCIP_NODE_MEMORY_MB=4096
# Continue indexing if individual projects fail
SCIP_BEST_EFFORT=true
# Fail sync when a detected supported language has no indexed files
SCIP_REQUIRE_LANGUAGE_COVERAGE=true
# OpenTelemetry (optional - disabled by default)
# Enable distributed tracing, metrics, and log correlation
OTEL_ENABLED=false
# Service name (will be suffixed with -api, -worker)
OTEL_SERVICE_NAME=contextmine
# OTLP exporter endpoint (gRPC or HTTP)
# Examples: http://localhost:4317 (gRPC), http://localhost:4318/v1/traces (HTTP)
OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317
# Protocol: 'grpc' or 'http/protobuf'
OTEL_EXPORTER_OTLP_PROTOCOL=grpc
# Trace sampling: always_on, always_off, traceidratio, parentbased_traceidratio
OTEL_TRACES_SAMPLER=parentbased_traceidratio
# Sampling ratio (0.0-1.0, e.g., 0.1 for 10% sampling)
OTEL_TRACES_SAMPLER_ARG=1.0
# Minimum log level to export: DEBUG, INFO, WARNING, ERROR
OTEL_LOG_LEVEL=INFO