# ═══════════════════════════════════════════════════════════════════════════════ # CHANDRA — Enterprise AI Cloud Operations Platform # Environment Configuration (.env.example) # ═══════════════════════════════════════════════════════════════════════════════ # Copy this file to .env and fill in your values. # cp .env.example .env # ═══════════════════════════════════════════════════════════════════════════════ # ── REQUIRED: AWS Credentials ───────────────────────────────────────────────── AWS_DEFAULT_REGION=us-east-1 AWS_ACCESS_KEY_ID=YOUR_AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY=YOUR_AWS_SECRET_ACCESS_KEY # ── REQUIRED: Database ──────────────────────────────────────────────────────── # PostgreSQL connection string (Docker: docker compose up -d postgres) # Default: postgresql+psycopg://chandra:chandra@localhost:5434/chandra POSTGRES_URL=postgresql+psycopg://chandra:chandra@localhost:5434/chandra DATABASE_URL=${POSTGRES_URL} # ── REQUIRED: Jira Integration ──────────────────────────────────────────────── JIRA_SERVER=https://your-domain.atlassian.net JIRA_EMAIL=your-email@example.com JIRA_API_TOKEN=YOUR_JIRA_API_TOKEN # ── OPTIONAL: Slack Integration ─────────────────────────────────────────────── # Create a Slack app at https://api.slack.com/apps, enable Events API # Set Request URL to: https://your-host/webhooks/slack # SLACK_WEBHOOK_URL= # SLACK_BOT_TOKEN= # ── OPTIONAL: Microsoft Teams Integration ───────────────────────────────────── # Use Power Automate HTTP action, POST to: https://your-host/webhooks/teams # TEAMS_WEBHOOK_URL= # ── OPTIONAL: Email Agent ──────────────────────────────────────────────────── # POST to: https://your-host/webhooks/email # EMAIL_WEBHOOK_URL= # ── OPTIONAL: Webhook Security ──────────────────────────────────────────────── # CHANDRA_WEBHOOK_TOKEN=your-secret-token # ── REQUIRED: AWS Resources ─────────────────────────────────────────────────── SYNTHETIC_ACCOUNT_ID=YOUR_SYNTHETIC_ACCOUNT_ID SNS_TOPIC_ARN=arn:aws:sns:us-east-1:YOUR_ACCOUNT:chandra-escalation-critical # ── REQUIRED: Frontend / API URL ────────────────────────────────────────────── # For local development: http://localhost:6001 # For Docker: http://backend:6001 # For production: https://your-domain.com/api/backend NEXT_PUBLIC_API_URL=http://localhost:6001 FRONTEND_URL=http://localhost:3000 # ── OPTIONAL: Auto-approve (development only) ───────────────────────────────── # CHANDRA_AUTO_APPROVE=1 # ═══════════════════════════════════════════════════════════════════════════════ # LLM Provider Configuration # ═══════════════════════════════════════════════════════════════════════════════ # LLM provider backend. One of: # bedrock — Amazon Bedrock (default, production) # vllm — Local vLLM server (development, air-gapped) # openai — Any OpenAI-compatible endpoint (Together, Groq, etc.) # ollama — Local Ollama daemon LLM_PROVIDER=bedrock # Model name for the active provider # Bedrock: anthropic.claude-sonnet-4-5-20250929-v1:0 # vLLM: google/gemma-4-12B-it-qat-w4a16-ct # OpenAI: Qwen/Qwen2.5-32B-Coder-Instruct # Ollama: qwen2.5-coder:32b LLM_MODEL=anthropic.claude-sonnet-4-5-20250929-v1:0 # Sampling temperature (0.0 = deterministic for code generation) LLM_TEMPERATURE=0.0 # ── Bedrock (default) ──────────────────────────────────────────────────────── BEDROCK_MODEL_ID=anthropic.claude-sonnet-4-5-20250929-v1:0 # ── vLLM (local) — set LLM_PROVIDER=vllm to use ────────────────────────────── # Start vLLM with: # vllm serve google/gemma-4-12B-it-qat-w4a16-ct \ # --max-model-len 16384 \ # --enable-prefix-caching \ # --gpu-memory-utilization 0.90 \ # --host 0.0.0.0 \ # --port 8000 # # The model google/gemma-4-12B-it-qat-w4a16-ct is already QAT 4-bit quantized. # No additional quantization implementation is required — the model name suffix # (qat-w4a16) indicates Quantization-Aware Training with 4-bit weights. # vLLM serves the quantized weights directly from the HuggingFace checkpoint. # VLLM_API_BASE=http://localhost:8000/v1 # VLLM_MODEL=google/gemma-4-12B-it-qat-w4a16-ct # VLLM_API_KEY=not-needed # ── OpenAI-compatible (fallback) ────────────────────────────────────────────── # OPENAI_API_BASE=http://localhost:8000/v1 # OPENAI_API_KEY=not-needed # OPENAI_MODEL_NAME=google/gemma-4-12B-it-qat-w4a16-ct # ── Ollama ─────────────────────────────────────────────────────────────────── # OLLAMA_HOST=http://localhost:11434 # OLLAMA_MODEL=qwen2.5-coder:32b # ═══════════════════════════════════════════════════════════════════════════════ # Execution Agent Settings # ═══════════════════════════════════════════════════════════════════════════════ # Enforce typed ExecutionPlan pipeline (validated plan + deterministic executor) # CHANDRA_TYPED_EXECUTION=false # Agent decoding knobs (deterministic by default) CHANDRA_AGENT_TEMPERATURE=0.0 CHANDRA_AGENT_TOP_P=1.0 # Max output tokens. LEAVE UNSET for vLLM to use full context (context_len - prompt). # CHANDRA_AGENT_MAX_TOKENS= # Structured output method # json_schema — vLLM guided decoding (works for any model, no --tool-call-parser needed) # function_calling — Tool-use path (default for Bedrock/Claude) # json_mode — JSON mode (OpenAI-compatible) CHANDRA_STRUCTURED_OUTPUT_METHOD=json_schema # ── Token Budget Caps (for local LLM with 16K context) ────────────────────── # ~4 chars per token. Local models have limited context (16K), so cap sections. # Bedrock is exempt (full context). Adjust when vLLM --max-model-len increases. CHANDRA_TF_DOCS_MAX_CHARS=8000 CHANDRA_AWS_CTX_MAX_CHARS=6000 CHANDRA_MEMORY_MAX_CHARS=3000 CHANDRA_AGENT_MAX_INPUT_CHARS=30000 # ═══════════════════════════════════════════════════════════════════════════════ # Observability & Tracing (OPTIONAL) # ═══════════════════════════════════════════════════════════════════════════════ # LangSmith (LangChain tracing) # LANGCHAIN_TRACING_V2=true # LANGCHAIN_ENDPOINT=https://api.smith.langchain.com # LANGCHAIN_API_KEY=ls__your-key-here # LANGCHAIN_PROJECT=chandra # LangFuse (open-source LLM observability) # LANGFUSE_PUBLIC_KEY=pk-lf-xxxxx # LANGFUSE_SECRET_KEY=sk-lf-xxxxx # LANGFUSE_HOST=https://cloud.langfuse.com # AgentOps (AI agent monitoring) # AGENTOPS_API_KEY=your-agentops-key # ═══════════════════════════════════════════════════════════════════════════════ # Logging # ═══════════════════════════════════════════════════════════════════════════════ # LOG_LEVEL=INFO # DEBUG, INFO, WARNING, ERROR # UVICORN_LOG_LEVEL=info