231 lines
8.7 KiB
Plaintext
231 lines
8.7 KiB
Plaintext
# Honcho Environment Variables Template
|
|
# Copy this file to .env and fill in the appropriate values
|
|
#
|
|
# Required variables are marked with (REQUIRED)
|
|
# Optional variables have default values and can be left commented out
|
|
|
|
# =============================================================================
|
|
# Application Settings
|
|
# =============================================================================
|
|
LOG_LEVEL=INFO
|
|
# SESSION_OBSERVERS_LIMIT=10
|
|
# GET_CONTEXT_MAX_TOKENS=100000
|
|
# MAX_FILE_SIZE=5242880 # Bytes
|
|
# MAX_MESSAGE_SIZE=25000 # Characters
|
|
|
|
# Embedding settings
|
|
# EMBED_MESSAGES=true
|
|
# MAX_EMBEDDING_TOKENS=8192
|
|
# MAX_EMBEDDING_TOKENS_PER_REQUEST=300000
|
|
|
|
# LANGFUSE_HOST=
|
|
# LANGFUSE_PUBLIC_KEY=
|
|
|
|
# COLLECT_METRICS_LOCAL=false
|
|
# LOCAL_METRICS_FILE=metrics.jsonl
|
|
|
|
# NAMESPACE="honcho"
|
|
|
|
# =============================================================================
|
|
# Database Settings (REQUIRED)
|
|
# =============================================================================
|
|
# Connection URI for PostgreSQL database with pgvector support
|
|
# Must use postgresql+psycopg prefix for SQLAlchemy compatibility
|
|
DB_CONNECTION_URI=postgresql+psycopg://testuser:testpwd@localhost:5432/honcho
|
|
|
|
# Optional database settings
|
|
# DB_SCHEMA=public
|
|
# DB_POOL_CLASS=default
|
|
# DB_POOL_SIZE=10
|
|
# DB_MAX_OVERFLOW=20
|
|
# DB_POOL_TIMEOUT=30
|
|
# DB_POOL_RECYCLE=300
|
|
# DB_POOL_PRE_PING=true
|
|
# DB_POOL_USE_LIFO=true
|
|
# DB_SQL_DEBUG=false
|
|
# DB_TRACING=false
|
|
|
|
# =============================================================================
|
|
# Authentication Settings
|
|
# =============================================================================
|
|
# Whether to enable authentication (set to true for production)
|
|
AUTH_USE_AUTH=false
|
|
|
|
# JWT secret key (REQUIRED if AUTH_USE_AUTH=true)
|
|
# Generate with: python scripts/generate_jwt_secret.py
|
|
# AUTH_JWT_SECRET=your-secret-key-here
|
|
|
|
# =============================================================================
|
|
# LLM API Keys (REQUIRED for full functionality)
|
|
# =============================================================================
|
|
# OpenAI API key for embeddings
|
|
LLM_OPENAI_API_KEY=your-openai-api-key-here
|
|
|
|
# Anthropic API key for dialectic and deriver functionality
|
|
LLM_ANTHROPIC_API_KEY=your-anthropic-api-key-here
|
|
|
|
# Google API key for summarization (if using Gemini)
|
|
# LLM_GEMINI_API_KEY=your-google-api-key-here
|
|
|
|
# Groq API key for query generation (if using Groq)
|
|
# LLM_GROQ_API_KEY=your-groq-api-key-here
|
|
|
|
# Base URL for OpenAI Compatible Requests if you want to use a different provider
|
|
# LLM_OPENAI_COMPATIBLE_BASE_URL=
|
|
# LLM_OPENAI_COMPATIBLE_API_KEY=
|
|
|
|
# Separate vLLM endpoint (for local models)
|
|
# LLM_VLLM_API_KEY=
|
|
# LLM_VLLM_BASE_URL=
|
|
|
|
# =============================================================================
|
|
# LLM Configuration
|
|
# =============================================================================
|
|
# Global LLM settings
|
|
# LLM_DEFAULT_MAX_TOKENS=2500
|
|
# LLM_EMBEDDING_PROVIDER=openai
|
|
# LLM_MAX_TOOL_OUTPUT_CHARS=30000 # Max chars for tool output (~7500 tokens)
|
|
# LLM_MAX_MESSAGE_CONTENT_CHARS=2000 # Max chars per message in tool results
|
|
|
|
# =============================================================================
|
|
# Deriver (Background Worker) Settings
|
|
# =============================================================================
|
|
# DERIVER_ENABLED=true
|
|
# DERIVER_WORKERS=1
|
|
# DERIVER_POLLING_SLEEP_INTERVAL_SECONDS=1.0
|
|
# DERIVER_STALE_SESSION_TIMEOUT_MINUTES=5
|
|
# DERIVER_QUEUE_ERROR_RETENTION_SECONDS=2592000 # 30 days
|
|
# DERIVER_PROVIDER=google
|
|
# DERIVER_MODEL=gemini-2.5-flash-lite
|
|
# DERIVER_DEDUPLICATE=true
|
|
# DERIVER_MAX_OUTPUT_TOKENS=4096
|
|
# DERIVER_THINKING_BUDGET_TOKENS=1024
|
|
# DERIVER_LOG_OBSERVATIONS=false
|
|
# DERIVER_WORKING_REPRESENTATION_MAX_OBSERVATIONS=100
|
|
# DERIVER_REPRESENTATION_BATCH_MAX_TOKENS=4096
|
|
# DERIVER_BACKUP_PROVIDER=
|
|
# DERIVER_BACKUP_MODEL=
|
|
|
|
# =============================================================================
|
|
# Peer Card Configuration
|
|
# =============================================================================
|
|
# PEER_CARD_ENABLED=true
|
|
|
|
# =============================================================================
|
|
# Dialectic Settings
|
|
# =============================================================================
|
|
# Global dialectic settings
|
|
# DIALECTIC_MAX_OUTPUT_TOKENS=8192
|
|
# DIALECTIC_MAX_INPUT_TOKENS=100000
|
|
# DIALECTIC_HISTORY_TOKEN_LIMIT=8192
|
|
# DIALECTIC_SESSION_HISTORY_MAX_TOKENS=16384
|
|
|
|
# Per-level settings (reasoning_level parameter in API)
|
|
# Each level can have its own provider, model, thinking budget, and tool iterations
|
|
|
|
# Minimal level
|
|
# DIALECTIC_LEVELS__minimal__PROVIDER=google
|
|
# DIALECTIC_LEVELS__minimal__MODEL=gemini-2.5-flash-lite
|
|
# DIALECTIC_LEVELS__minimal__THINKING_BUDGET_TOKENS=0
|
|
# DIALECTIC_LEVELS__minimal__MAX_TOOL_ITERATIONS=2
|
|
|
|
# Low level
|
|
# DIALECTIC_LEVELS__low__PROVIDER=google
|
|
# DIALECTIC_LEVELS__low__MODEL=gemini-3-flash
|
|
# DIALECTIC_LEVELS__low__THINKING_BUDGET_TOKENS=0
|
|
# DIALECTIC_LEVELS__low__MAX_TOOL_ITERATIONS=5
|
|
|
|
# Medium level
|
|
# DIALECTIC_LEVELS__medium__PROVIDER=anthropic
|
|
# DIALECTIC_LEVELS__medium__MODEL=claude-haiku-4-5
|
|
# DIALECTIC_LEVELS__medium__THINKING_BUDGET_TOKENS=512
|
|
# DIALECTIC_LEVELS__medium__MAX_TOOL_ITERATIONS=4
|
|
|
|
# High level
|
|
# DIALECTIC_LEVELS__high__PROVIDER=anthropic
|
|
# DIALECTIC_LEVELS__high__MODEL=claude-opus-4-5
|
|
# DIALECTIC_LEVELS__high__THINKING_BUDGET_TOKENS=0
|
|
# DIALECTIC_LEVELS__high__MAX_TOOL_ITERATIONS=4
|
|
|
|
# Max level
|
|
# DIALECTIC_LEVELS__max__PROVIDER=anthropic
|
|
# DIALECTIC_LEVELS__max__MODEL=claude-opus-4-5
|
|
# DIALECTIC_LEVELS__max__THINKING_BUDGET_TOKENS=512
|
|
# DIALECTIC_LEVELS__max__MAX_TOOL_ITERATIONS=10
|
|
# Optional backup per level (must set both or neither):
|
|
# DIALECTIC_LEVELS__max__BACKUP_PROVIDER=google
|
|
# DIALECTIC_LEVELS__max__BACKUP_MODEL=gemini-2.5-pro
|
|
|
|
# =============================================================================
|
|
# Summary Settings
|
|
# =============================================================================
|
|
# SUMMARY_ENABLED=true
|
|
# SUMMARY_MESSAGES_PER_SHORT_SUMMARY=20
|
|
# SUMMARY_MESSAGES_PER_LONG_SUMMARY=60
|
|
# SUMMARY_PROVIDER=google
|
|
# SUMMARY_MODEL=gemini-2.5-flash
|
|
# SUMMARY_MAX_TOKENS_SHORT=1000
|
|
# SUMMARY_MAX_TOKENS_LONG=4000
|
|
# SUMMARY_THINKING_BUDGET_TOKENS=512
|
|
# SUMMARY_BACKUP_PROVIDER=
|
|
# SUMMARY_BACKUP_MODEL=
|
|
|
|
# =============================================================================
|
|
# Dream Settings
|
|
# =============================================================================
|
|
# DREAM_ENABLED=true
|
|
# DREAM_DOCUMENT_THRESHOLD=50
|
|
# DREAM_IDLE_TIMEOUT_MINUTES=60
|
|
# DREAM_MIN_HOURS_BETWEEN_DREAMS=8
|
|
# DREAM_ENABLED_TYPES=["omni"]
|
|
# DREAM_PROVIDER=anthropic
|
|
# DREAM_MODEL=claude-haiku-4-5
|
|
# DREAM_MAX_OUTPUT_TOKENS=4000
|
|
# DREAM_THINKING_BUDGET_TOKENS=2048
|
|
# DREAM_MAX_TOOL_ITERATIONS=8
|
|
# DREAM_HISTORY_TOKEN_LIMIT=8192
|
|
# DREAM_BACKUP_PROVIDER=
|
|
# DREAM_BACKUP_MODEL=
|
|
|
|
# Dream Surprisal Settings (Tree-based observation sampling for targeted reasoning)
|
|
# DREAM_SURPRISAL__ENABLED=true
|
|
# DREAM_SURPRISAL__TREE_TYPE=kdtree # Options: kdtree, balltree, rptree, covertree, lsh, graph, prototype
|
|
# DREAM_SURPRISAL__TREE_K=5 # Number of neighbors for kNN-based trees
|
|
# DREAM_SURPRISAL__SAMPLING_STRATEGY=recent # Options: recent, random, all
|
|
# DREAM_SURPRISAL__SAMPLE_SIZE=200 # Number of observations to sample for tree building
|
|
# DREAM_SURPRISAL__TOP_PERCENT_SURPRISAL=0.10 # Top percentage of observations (0.10 = top 10%)
|
|
# DREAM_SURPRISAL__MIN_HIGH_SURPRISAL_FOR_REPLACE=10 # Hybrid mode: min observations to replace standard questions
|
|
# DREAM_SURPRISAL__INCLUDE_LEVELS=["explicit","deductive"] # Observation levels to include
|
|
|
|
# =============================================================================
|
|
# Webhook Settings
|
|
# =============================================================================
|
|
# WEBHOOK_SECRET=
|
|
# WEBHOOK_MAX_WORKSPACE_LIMIT=10
|
|
|
|
# =============================================================================
|
|
# Monitoring and Observability (Optional)
|
|
# =============================================================================
|
|
# Sentry error tracking
|
|
# SENTRY_ENABLED=false
|
|
# SENTRY_DSN=your-sentry-dsn-here
|
|
# SENTRY_RELEASE=your-release-semver
|
|
# SENTRY_ENVIRONMENT=development
|
|
# SENTRY_TRACES_SAMPLE_RATE=0.1
|
|
# SENTRY_PROFILES_SAMPLE_RATE=0.1
|
|
|
|
# =============================================================================
|
|
# Metrics (Optional)
|
|
# =============================================================================
|
|
# METRICS_ENABLED=false
|
|
# METRICS_NAMESPACE=honcho # Inherits from NAMESPACE if not set
|
|
|
|
# =============================================================================
|
|
# Cache
|
|
# =============================================================================
|
|
# CACHE_ENABLED=false
|
|
# CACHE_URL="redis://localhost:6379/0?suppress=false"
|
|
# CACHE_NAMESPACE="honcho" # Inherits from NAMESPACE if not set
|
|
# CACHE_DEFAULT_TTL_SECONDS=300
|
|
# CACHE_DEFAULT_LOCK_TTL_SECONDS=5
|