# DraftStudio environment # Copy this file to .env and fill in real values. NEVER commit .env. # --- Groq (primary provider; OpenAI-compatible, fast open-weight inference) --- # Key: https://console.groq.com/keys GROQ_API_KEY=your-groq-api-key-here GROQ_BASE_URL=https://api.groq.com/openai/v1 # Models for every agent call. Primary: Groq openai/gpt-oss-120b, the same primary the n8n workflow uses on # Intake, Research, Draft and Dispatch. The fallback (harness only) takes over for the rest of a run when the # primary's daily token quota is exhausted. Change models here, not in code or configs. GROQ_PRIMARY_MODEL=openai/gpt-oss-120b GROQ_FALLBACK_MODEL=qwen/qwen3.8-27b # --- OpenRouter (second provider; the harness moves the rest of a run here when Groq is unreachable or blocked) --- # Key: https://openrouter.ai/keys. Model IDs look like provider/model. OPENROUTER_API_KEY=your-openrouter-api-key-here OPENROUTER_BASE_URL=https://openrouter.ai/api/v1 # Model the Python harness uses after the switch (required for that fallback). OPENROUTER_PRIMARY_MODEL=openai/gpt-oss-120b # n8n does not read this file: the workflow hard-codes its model IDs on the nodes (see the n8n design # doc). The values below record what the workflow uses; changing them changes nothing there. # Fallback of Intake, Research, Draft and Dispatch (their primary is the Groq model above). OPENROUTER_FALLBACK_MODEL=openai/gpt-oss-20b # ReviewAgent judge: primary on OpenRouter (a different model family from the drafter) ... OPENROUTER_REVIEW_MODEL=qwen/qwen3-235b-a22b-2507 # ... and its fallback, a Groq model (node "Groq Fallback Review"), so the reviewer also has two providers. OPENROUTER_REVIEW_FALLBACK_MODEL=llama-3.3-70b-versatile # --- Web search for ResearchAgent (Tavily) --- # Key: https://app.tavily.com. Without a real key, research fails soft: no findings, and the gaps say why. TAVILY_API_KEY=your-tavily-api-key-here # Optional override; defaults to the URL below. # TAVILY_BASE_URL=https://api.tavily.com/search # --- Alternative providers (future use) --- ANTHROPIC_API_KEY=your-anthropic-api-key-here OPENAI_API_KEY=your-openai-api-key-here # --- n8n (workflow automation; read by n8n-mcp via .mcp.json) --- # Host-published port of the n8n container (it listens on 5678 inside). N8N_API_URL=http://localhost:5555 # Create in n8n: Settings -> n8n API. N8N_API_KEY=your-n8n-api-key-here # Header Auth secret for the n8n Webhook node (credential "DraftStudio Webhook", header X-API-Key). N8N_WEBHOOK_API_KEY=your-webhook-secret-here # --- Telegram (DraftStudio bot; create one with @BotFather) --- # n8n keeps the token in its own credential store; these two are for reference and scripts only. # TELEGRAM_ALLOWED_CHAT_ID enforces nothing by itself: put the same id in the Telegram Trigger's # "Restrict to Chat IDs" field (the committed workflow holds a placeholder and rejects everyone # until you do), otherwise anyone who finds the bot can spend your LLM quota. TELEGRAM_BOT_TOKEN=your-telegram-bot-token-here TELEGRAM_ALLOWED_CHAT_ID=your-telegram-chat-id-here # --- Notion --- # No key needed: connected through the Notion MCP server with OAuth.