# OpenAI API Configuration # Get your API key from: https://platform.openai.com/api-keys OPENAI_API_KEY=your_openai_api_key_here # OpenRouter API Configuration (Alternative to OpenAI) # Get your API key from: https://openrouter.ai/keys OPENROUTER_API_KEY=your_openrouter_api_key_here # Reddit API Configuration # REQUIRED: Get credentials from: https://www.reddit.com/prefs/apps REDDIT_CLIENT_ID=your_reddit_client_id_here REDDIT_CLIENT_SECRET=your_reddit_client_secret_here REDDIT_USERNAME=your_reddit_username_here REDDIT_PASSWORD=your_reddit_password_here REDDIT_USER_AGENT=your_user_agent_string_here # Format: "app_name/version by your_username" # Mem0 Memory Configuration (Optional) # Get your API key from: https://app.mem0.ai/dashboard/api-keys # MEM0_API_KEY=your_mem0_api_key_here # Model Configuration (Optional) # MODEL_NAME=openai/gpt-4o # Default model # MODEL_NAME=anthropic/claude-3.5-sonnet # Alternative via OpenRouter # MODEL_NAME=openai/gpt-oss-120b:free # Free model via OpenRouter # Optional: Phoenix Telemetry Configuration # If you're running Phoenix for observability, set the endpoint # Otherwise, telemetry errors will be logged but won't affect functionality # PHOENIX_COLLECTOR_ENDPOINT=http://phoenix:6006/v1/traces # Optional: Debug Mode # DEBUG=true # Enable debug logging # Instructions: # 1. Copy this file to .env: cp .env.example .env # 2. Choose either OpenAI or OpenRouter and add your API key # 3. Add all required Reddit API credentials # 4. (Optional) Add Mem0 API key for memory features # 5. (Optional) Configure Phoenix endpoint for observability # 6. (Optional) Set DEBUG=true for detailed logging # Reddit API Setup Instructions: # 1. Go to https://www.reddit.com/prefs/apps # 2. Click "create app" or "create another app" # 3. Fill in: # - Name: Your app name (e.g., "RedditPostGenerator") # - App type: Select "script" # - Description: "AI-powered Reddit post generator" # - About url: Leave blank or add your GitHub URL # - Redirect uri: http://localhost:8080 # 4. Click "create app" # 5. Copy: # - client_id: The string under the app name # - client_secret: The secret key # 6. Use your Reddit account credentials for username/password # Note: The agent follows lazy initialization - it will only fail at runtime # if required API keys are missing but needed for the requested operation.