# ───────────────────────────────────────────────────────────────────────────── # LLM-Auto-Trader — example environment file. # Copy this to `.env` and fill in the values you need. Anything not set falls # back to the safe defaults documented in the README. # ───────────────────────────────────────────────────────────────────────────── # === Bot mode ──────────────────────────────────────────────────────────────── # `paper` simulates trades; `live` places real orders. Start with paper. BOT_MODE=paper # === Exchange ──────────────────────────────────────────────────────────────── # Any CCXT exchange id: binance, bybit, okx, mexc, gate, kucoinfutures, ... EXCHANGE_NAME=binance # Required for live trading. Not needed for paper mode. EXCHANGE_API_KEY= EXCHANGE_API_SECRET= # Optional: market type (swap | future | spot), quote currency, fee/margin overrides. # EXCHANGE_MARKET_TYPE=swap # EXCHANGE_QUOTE_CCY=USDT # EXCHANGE_MAKER_FEE=0.0002 # EXCHANGE_TAKER_FEE=0.0004 # EXCHANGE_MAINT_MARGIN=0.004 # Comma-separated extra exchanges used only for cross-exchange data # (price triangulation, funding-rate comparison). No keys needed. DATA_EXCHANGES=binance,bybit,okx # === LLM ───────────────────────────────────────────────────────────────────── # Provider: anthropic | openai | google | openai-compat LLM_PROVIDER=anthropic # One key for whichever provider you chose. The legacy ANTHROPIC_API_KEY, # OPENAI_API_KEY, GOOGLE_API_KEY env vars are also honored. LLM_API_KEY= # Default model. Override per provider: # anthropic: claude-opus-4-7, claude-sonnet-4-6, claude-haiku-4-5 # openai: gpt-4.1, gpt-4.1-mini, o4-mini # google: gemini-2.5-pro, gemini-2.5-flash # openai-compat: anything your local server serves LLM_MODEL=claude-opus-4-7 # Only for openai-compat (Ollama default shown). # LLM_BASE_URL=http://localhost:11434/v1 # Anthropic-only: extended thinking + 1M context beta. Set false to save tokens. LLM_EXTENDED_THINKING=true LLM_THINKING_BUDGET=8000 LLM_LONG_CONTEXT=true # Output cap, sampling temperature. LLM_MAX_OUTPUT_TOKENS=2048 LLM_TEMPERATURE=0.0 # Hard budget stops. The bot stops calling the LLM if these are hit. LLM_DAILY_BUDGET_USD=5.00 LLM_MONTHLY_BUDGET_USD=100.0 # Manual price overrides ($/M tokens). Leave at 0 to use the provider's # built-in pricing table. Useful if you have negotiated tiers or a custom proxy. # LLM_INPUT_PRICE_PER_M=0 # LLM_CACHED_INPUT_PRICE_PER_M=0 # LLM_OUTPUT_PRICE_PER_M=0 # === Scheduling ────────────────────────────────────────────────────────────── # daily | hourly | adaptive | "*/30 * * * *" (5-field cron) REBALANCE_CADENCE=adaptive # === Telegram (optional) ───────────────────────────────────────────────────── # Empty = silent. Both required to enable. TELEGRAM_BOT_TOKEN= TELEGRAM_CHAT_ID= # === Optional data feeds ───────────────────────────────────────────────────── # News + sentiment APIs. RSS feeds work without keys; these are upgrades. CRYPTOPANIC_API_KEY= NEWSDATA_API_KEY= GNEWS_API_KEY= # === Storage & logs ────────────────────────────────────────────────────────── DB_PATH=data/trading_bot.db LOG_LEVEL=INFO LOG_DIR=logs