PolyHedra / .env.example
yf176
fix(llm): honor configured OpenRouter model
0dca9a4
Raw History Blame Contribute Delete
4.21 kB
# Polyhedra Configuration Example
# Copy this file to .env and fill in your values
# =============================================================================
# LLM Provider Configuration (for v2.1 Literature Review Generation)
# =============================================================================
# Choose ONE provider
# Option 1: Google Gemini (Recommended for v3.0)
# Get your key at: https://aistudio.google.com/apikey
GEMINI_API_KEY=
# Option 2: Anthropic Claude
# Get your key at: https://console.anthropic.com/
# ANTHROPIC_API_KEY=sk-ant-api03-your-key-here
# Option 3: OpenAI GPT
# Get your key at: https://platform.openai.com/api-keys
# OPENAI_API_KEY=sk-your-key-here
# Option 4: OpenRouter
# Get your key at: https://openrouter.ai/settings/keys
# OPENROUTER_API_KEY=sk-or-your-key-here
# =============================================================================
# LLM Settings (Optional)
# =============================================================================
# Provider selection (default: anthropic)
# Uncomment to override:
POLYHEDRA_LLM_PROVIDER=gemini
# Model selection (optional, uses provider's default if not set)
# Gemini options: gemini-2.0-flash, gemini-2.0-flash-lite, gemini-1.5-pro, gemini-1.5-flash
# Anthropic options: claude-3-5-sonnet-20241022, claude-3-opus-20240229
# OpenAI options: gpt-4o, gpt-4-turbo, gpt-4
# OpenRouter example: apodex/apodex-1.1-mini:free
# POLYHEDRA_LLM_MODEL=gemini-2.0-flash
# OpenRouter configuration example:
# POLYHEDRA_LLM_PROVIDER=openrouter
# POLYHEDRA_LLM_MODEL=apodex/apodex-1.1-mini:free
# POLYHEDRA_SITE_URL=https://your-space.hf.space
# =============================================================================
# Cost Management (Optional)
# =============================================================================
# Maximum cost per single operation (default: $1.00)
# Polyhedra will block operations exceeding this limit
POLYHEDRA_MAX_COST=1.00
# =============================================================================
# Semantic Scholar API (Optional)
# =============================================================================
# API key for increased rate limits (optional, works without it)
# Get your key at: https://www.semanticscholar.org/product/api
# SEMANTIC_SCHOLAR_API_KEY=your-key-here
# =============================================================================
# Slack Integration (v3.0 — required only for the FastAPI/Slack server)
# =============================================================================
# Bot OAuth token — from your Slack app's "OAuth & Permissions" page
# SLACK_BOT_TOKEN=xoxb-your-token-here
# Signing secret — from your Slack app's "Basic Information" page
# SLACK_SIGNING_SECRET=your-signing-secret-here
# =============================================================================
# Finnhub — Market Data (v4.0 quant team / paper trading)
# =============================================================================
# Required for /poly quant, /poly portfolio, /poly trade, /poly watchlist
# Free tier: 60 API calls/minute — get your key at: https://finnhub.io/dashboard
# FINNHUB_API_KEY=your-key-here
# Seed watchlist (optional, comma-separated tickers)
# Users can also manage the watchlist live via /poly watchlist add <TICKER>
# POLYHEDRA_QUANT_WATCHLIST=AAPL,MSFT,NVDA,GOOGL
# =============================================================================
# Usage Notes
# =============================================================================
# v2.0 Features (NO API KEY REQUIRED):
# - search_papers
# - get_paper
# - query_similar_papers
# - index_papers
# - add_citation
# - get_citations
# - save_file
# - get_context
# - init_project
# - get_project_status
# v2.1 Features (REQUIRE LLM API KEY):
# - generate_literature_review
# - estimate_review_cost
# Typical Costs (with Anthropic Claude Sonnet):
# - Brief review (50 papers): $0.08-0.12
# - Standard review (50 papers): $0.12-0.20
# - Comprehensive review (50 papers): $0.20-0.35
# For more information:
# - Setup guide: docs/SETUP.md
# - API reference: docs/API.md
# - User guide: docs/USER_GUIDE.md