Your server's intelligent companion powered by cutting-edge AI models
Installation • Features • Commands • Models • Troubleshooting • Documentation
🤖 Gideon - AI Assistant for Discord
🌟 Overview
Gideon transforms your Discord server into an AI-powered hub, connecting members to state-of-the-art language and image models. With Gideon, users can have intelligent conversations, generate creative images, analyze visual content, summarize news feeds, manage URLs, play AI-powered trivia games, and organize discussions through an intuitive thread system.
✨ Features
🧠 Intelligence
- Multiple AI Models - Access OpenAI, Anthropic Claude, Google Gemini, and more through OpenRouter
-
Conversation Memory - Natural conversations with context across messages
- Natural Language Intent Detection - Simply @mention Gideon with natural language to automatically execute commands without needing to remember slash command syntax. The AI understands your intent and routes to the appropriate feature:
- Reminders: “@Gideon remind me to check the server logs tomorrow at 3pm”
- Image Generation: “@Gideon draw a sunset over mountains with vibrant colors”
- Web Search: “@Gideon what are the current best games on Xbox Game Pass”
- Conversation: Any other @mention automatically engages in natural conversation
- Web Search - Search the web for current information through conversational AI responses or natural language (@mention)
- Image Analysis - Upload and analyze images with vision-capable AI models
- Image Generation - Create stunning visuals using the unified
/dreamcommand or natural language @mentions (e.g., “@Gideon draw a futuristic cityscape”). Supports multiple backend providers (AI Horde, Cloudflare Worker, OpenAI DALL-E, ComfyUI, OpenRouter)
🎮 Entertainment
- AI-Powered Trivia - Play interactive trivia games with questions generated dynamically by AI
- Solo Mode: Test your knowledge in a personal trivia session
- Competitive Mode: Race against other players for the highest score
- Dynamic Categories: Ask questions about ANY topic - the AI generates questions on-demand
- Smart Scoring: Earn points based on difficulty, speed, and answer streaks
- Achievements: Unlock badges for milestones like perfect games, speed records, and win streaks
- Leaderboards: Compete on daily, weekly, monthly, and all-time rankings
- Natural Gameplay: Just type your answer directly in the thread - no complex commands needed!
🧵 Organization
- Conversation Threads - Create dedicated topics with independent histories using Discord’s native threads
- Auto-Responses - Bot automatically responds to all messages in AI threads
- Dynamic URL Summarization - Instantly extracts and distills key information from any shared webpage, providing concise, up-to-date summaries directly in your chat.
🛠️ Customization
- Model Switching - Change AI models on-the-fly with simple commands
- Channel Personalities - Set different system prompts per channel
- Admin Controls - Comprehensive configuration options for server admins
🚀 Installation
There are two ways to install and run Gideon: using Docker (recommended for ease of deployment and management) or directly with Python.
Prerequisites
For both methods:
- Git installed
- Discord bot token with Message Content Intent enabled (Discord Developer Portal)
- OpenRouter API key (OpenRouter.ai)
- AI Horde API key (optional, for
/imaginecommand - AI Horde) - Cloudflare Worker URL & API Key (optional, for
/dreamcommand and Adventure scene visualization - requires self-setup, see Cloudflare Worker Configuration)
For Docker Installation:
- Docker installed
- Docker Compose installed (usually included with Docker Desktop)
For Python Installation:
- Python 3.8+
Docker Installation (Recommended)
- Clone the Repository:
git clone https://github.com/eoko-dev/gideon cd gideon - Configure Environment:
- Copy the example environment file:
cp .env.example .env - Edit the
.envfile with your actual API keys and tokens (DISCORD_TOKEN,OPENROUTER_API_KEY, etc.). LeaveDATA_DIRECTORYblank or commented out when using Docker Compose with the provided configuration, as the volume mount handles data persistence.
- Copy the example environment file:
- Build the Docker Image:
- Build the image using the included Dockerfile. This command builds the image and tags it as
gideon-bot:latest.docker build -t gideon-bot:latest . - (Optional) If you plan to distribute the image or use a registry like Docker Hub or GHCR, you would tag and push the image here.
- Build the image using the included Dockerfile. This command builds the image and tags it as
- Configure Docker Compose:
- Open the
docker-compose.ymlfile. - Verify the
volumessection. The defaultdocker-compose.ymlis set up to use a bind mount. It maps a directory from your host machine to the/app/datadirectory inside the container. ```yamlExample docker-compose.yml volume section:
volumes: # This maps a host directory to the container’s data directory
- ./gideon_data:/app/data # Example: Creates ‘gideon_data’ in the current directory ```
- Important: Ensure the host path part (
./gideon_datain the example) points to a location where Docker has permission to create/write files. Using a relative path like./gideon_datawill create the directory within yourgideonproject folder. - (Optional) If you pushed your image to a registry in step 3, update the
image:line to point to your registry image (e.g.,image: your-dockerhub-username/gideon:latestorimage: ghcr.io/your-github-username/gideon:latest). Otherwise, leave it asimage: gideon-bot:latestto use the locally built image.
- Open the
- Run the Container:
- Start the bot using Docker Compose in detached mode (runs in the background):
docker-compose up -d - To view logs:
docker-compose logs -f - To stop the bot:
docker-compose down
- Start the bot using Docker Compose in detached mode (runs in the background):
Python Installation
# Clone and enter repository (if not already done)
# git clone https://github.com/eoko-dev/gideon
# cd gideon
# Set up environment and dependencies
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
pip install -r requirements.txt
# Configure bot
cp .env.example .env
# Edit .env with your Discord token, OpenRouter API key, AI Horde API key,
# AND set the DATA_DIRECTORY to an absolute path where the bot can write data.
# Example: DATA_DIRECTORY=/home/user/gideon_data
# If DATA_DIRECTORY is not set, data (including the SQLite database file, typically 'gideon.db')
# will be stored in a 'data' subdirectory within the project.
# Launch
python3 -m src
Discord Configuration
- Create an application at Discord Developer Portal
- Under “Bot” tab:
- Enable “Message Content Intent”
- Copy your bot token for the
.envfile
- Generate invite URL in “OAuth2 > URL Generator”:
- Scopes:
bot,applications.commands - Permissions: Send Messages, Read Message History, Embed Links, Use Slash Commands, Manage Threads (for
/threadcommands)
- Scopes:
Intent Detection Configuration (Optional)
Gideon’s intent detection feature allows users to interact naturally with the bot through @mentions instead of slash commands. This feature is enabled by default.
Environment Variables (in .env):
INTENT_DISCOVERY=true- Enable/disable intent detection (default: true)INTENT_DETECTION_MODEL=anthropic/claude-3.5-haiku- Model used for intent classification (default: Claude 3.5 Haiku)INTENT_CONFIDENCE_THRESHOLD=0.7- Minimum confidence score (0.0-1.0) to trigger intent routing (default: 0.7)
How It Works: When you @mention Gideon, the bot uses AI to analyze your message and determine your intent:
- High confidence (≥0.7): Routes to the appropriate handler (reminder, image generation, or search)
- Low confidence (<0.7): Falls back to normal conversation
- Search intent: Requires OpenRouter provider. If another provider is active, falls back to conversation with a notification
Supported Intents:
- Reminder: Schedule notifications for future events
- Image Generation: Create images from text descriptions
- Search: Fetch current information from the web (OpenRouter only)
- Conversation: General chat and questions
Cloudflare Worker Configuration (Optional)
⚠️ IMPORTANT: Setting up and deploying the Cloudflare Worker is the responsibility of the end user. Gideon does not provide support for configuring or troubleshooting Cloudflare Workers.
If you want to use the /dream command for generating images or enable scene visualization in Adventure mode:
- Create and deploy your own Cloudflare Worker that can generate images (e.g., using Cloudflare’s AI platform or another service).
- The worker should accept a JSON payload with at least a
promptfield and return image data. - Set the
CLOUDFLARE_WORKER_URLin your.envfile to your worker’s URL. - Optionally set
CLOUDFLARE_API_KEYif your worker requires authentication (e.g., via a header likeAuthorization: Bearer YOUR_KEY).
An example Cloudflare worker that has been tested with Gideon can be found here: flux1-cloudflare-worker
Example /dream output
ComfyUI Configuration (Optional)
ComfyUI is a powerful node-based UI for Stable Diffusion and other AI image generation models. Gideon supports ComfyUI as an image generation provider, giving you access to advanced workflows and custom models.
Prerequisites:
- ComfyUI installed and running (local or remote)
- Download from: ComfyUI GitHub
- Requires Python 3.10+, CUDA-compatible GPU recommended
Setup Steps:
- Install ComfyUI:
# Clone and setup ComfyUI git clone https://github.com/comfyanonymous/ComfyUI cd ComfyUI pip install -r requirements.txt # Download at least one checkpoint model to ComfyUI/models/checkpoints/ # Example: Stable Diffusion 1.5, SDXL, FLUX, etc. - Start ComfyUI Server:
# Local (default port 8188) python main.py # Or specify host/port python main.py --listen 0.0.0.0 --port 8188 - Configure Gideon:
- Edit your
.envfile and add:COMFYUI_URL=http://127.0.0.1:8188 # Or your remote URL - Restart the bot
- Edit your
- Activate ComfyUI Provider:
/dream manage set_provider provider:comfyui /dream manage comfyui_test # Verify connection
Advanced Features:
- Model Selection: Use
/dream manage comfyui_modelsto list available checkpoint models, then configure with/dream manage configure comfyui - Custom Workflows: Load custom ComfyUI workflow JSONs via
/dream manage comfyui_workflowfor advanced generation (FLUX, SDXL, LoRA support) - Parameter Control: Configure default size, steps, and model via
/dream manage configure comfyui
Admin Commands:
/dream manage comfyui_test- Test server connection and view system stats/dream manage comfyui_models- List available checkpoint models/dream manage configure comfyui- Set default size, steps, and model/dream manage comfyui_workflow- Load custom workflow JSON or reset to default
🤖 Commands
Tip: Use
/helpin Discord to browse all commands with an interactive menu. Admin commands are automatically hidden from regular users.
General Commands
| Command | Description |
|---|---|
/help |
View all commands with interactive category navigation |
/chat |
Start a conversation with the AI (supports image uploads for vision models) |
/search |
Search the web for current information using the AI |
/reset |
Clear the conversation history for the current channel |
/summarize |
Summarize the current conversation history |
/memory |
Show conversation statistics (message count, history window) |
Thread Commands
Gideon leverages Discord’s native thread system to organize conversations and create dedicated AI chat spaces.
| Command | Description |
|---|---|
/thread new |
Create a new AI conversation thread |
/thread message |
Send a message to a specific thread |
/thread list |
View all active AI threads in the channel |
/thread delete |
Remove an AI thread and its history |
/thread rename |
Change the name of an AI thread |
/thread show |
View thread configuration settings |
/thread model |
Set the AI model for this thread |
/thread system |
Set the system prompt for this thread |
Trivia Commands
Play AI-generated trivia games with dynamic questions on any topic you choose.
| Command | Description |
|---|---|
/trivia start |
Start a new trivia game (solo or competitive mode) |
/trivia stop |
End the current trivia game |
/trivia stats [user] |
View your trivia statistics or another player's stats |
/trivia leaderboard [timeframe] |
View server rankings (daily/weekly/monthly/all-time) |
/trivia achievements |
Display your earned achievement badges |
How to Play:
- Use
/trivia startand choose your mode (solo/competitive), category, and difficulty - The bot creates a dedicated thread and posts questions
- Simply type your answer in the thread (A, B, C, D, or the full answer text)
- Earn points based on speed and accuracy - build streaks for bonus multipliers!
- Complete all questions to see final results and unlock achievements
Settings Commands (Admin)
Manage global bot configuration settings.
| Command | Description |
|---|---|
/settings show |
View all current global settings |
/settings model |
Set global AI model (format: provider/model) |
/settings system |
Set global system prompt |
/settings provider |
Set global AI provider (openrouter/openai) |
/settings memory |
Set message history limit |
/settings window |
Set time window for history (hours) |
/settings restore |
Reset all settings to defaults |
Channel Commands (Admin)
Configure channel-specific overrides for AI behavior.
| Command | Description |
|---|---|
/channel show |
View current channel settings |
/channel model |
Set AI model for this channel |
/channel system |
Set system prompt for this channel |
/channel provider |
Set AI provider for this channel |
/channel reset |
Clear all channel overrides |
/channel list |
List all channels with custom settings |
Admin Commands
Administrative tools and diagnostics (Admin/Owner only).
| Command | Description |
|---|---|
/admin sync |
Sync slash commands with Discord (Owner only) |
/admin debug |
Show debug information |
/admin state |
Display database state information |
/admin diagnostic |
Run system diagnostics |
/admin vision_models |
List all vision-capable AI models |
Configuration Commands (Deprecated)
These commands are deprecated and will be removed in a future update. Please use the new grouped commands above.
| Command | Description | Permissions |
|---|---|---|
/setmodel |
Change the default AI model for the server | Admin |
/model |
View or change the current model for the channel/thread | All Users |
/setsystem |
Customize the default AI personality (system prompt) | Admin |
/setchannelmodel |
Set the AI model for the current channel | Admin |
/setchannelsystem |
Set the system prompt for the current channel | Admin |
/setmemory |
Set the message history limit (max messages) | Admin |
/setwindow |
Set the time window for memory (in hours) | Admin |
Image Commands
Gideon uses a unified command for image generation with support for multiple backend providers (AI Horde, Cloudflare, OpenAI, ComfyUI, OpenRouter).
| Command | Description | Permissions |
|---|---|---|
/dream |
Generate an image using the currently configured AI backend. | All Users |
/dream_manage set_provider |
Set the active image generation provider. | Admin |
/dream_manage view_config |
View the current active provider and configuration. | Admin |
/dream_manage configure ai_horde |
Configure AI Horde defaults (model, size, steps). | Admin |
/dream_manage configure cloudflare |
Configure Cloudflare defaults (size, steps, seed). | Admin |
/dream_manage configure openai |
Configure OpenAI/DALL-E defaults (model, quality, style). | Admin |
/dream_manage configure comfyui |
Configure ComfyUI defaults (model, size, steps). | Admin |
/dream_manage configure openrouter |
Configure OpenRouter defaults (model, aspect ratio, image size). | Admin |
/dream_manage comfyui_models |
List available ComfyUI checkpoint models. | Admin |
/dream_manage comfyui_test |
Test ComfyUI server connection. | Admin |
/dream_manage comfyui_workflow |
Set a custom ComfyUI workflow (JSON). | Admin |
📚 Supported Models
Text Models (via OpenRouter)
- OpenAI: GPT-4o, GPT-4o-mini, GPT-4 Turbo, etc.
- Anthropic: Claude 3.7 Sonnet, Claude 3 Opus, Claude 3 Haiku, etc.
- Google: Gemini 2.0 Flash, Gemini Pro 1.5, etc.
- Meta: Llama 3 70B, 8B, etc.
- Mistral: Mistral Large, Mixtral 8x22B, etc.
- Perplexity: Sonar Large, Sonar Small
- And many more! Check OpenRouter.ai for the full list.
Image Models
Via AI Horde
- Stable Diffusion: SD 2.1, SDXL, and various fine-tuned community models.
- Check
/hordemodelsfor currently available options.
Via Cloudflare Worker (requires self-setup)
- Custom model implementation - Your Cloudflare Worker can integrate any image generation model you choose (e.g., Stable Diffusion via Cloudflare’s platform).
Via OpenRouter
- Google Gemini: Gemini 2.5 Flash Image, Gemini 3 Pro Image Preview
- OpenAI: GPT-5 Image, GPT-5 Image Mini
❓ Troubleshooting
- Connection Issues: Run
/admin diagnosticto check network connectivity to Discord and APIs. - Missing Commands: Ensure the bot has
applications.commandsscope and necessary permissions (Send Messages, Read History, Embed Links, Manage Threads). Try re-inviting if needed. Use/admin sync(owner only) as a last resort. - Model Problems: Some models require OpenRouter credits - check your account balance. Ensure the model ID used is correct. Use
/settings showto view current model configuration. - State Issues: Check logs for errors related to database operations. Ensure the
DATA_DIRECTORY(Python) or Docker volume mount is writable and contains thegideon_state.dbfile. The bot automatically saves state to the database periodically and on shutdown. - Image Generation Issues: If
/dreamfails, try simpler prompts, different models, or smaller dimensions. Check provider configuration with/dream manage view_config. Verify API keys in.env. - Cloudflare Worker Issues: Verify your
CLOUDFLARE_WORKER_URLandCLOUDFLARE_API_KEYin.envare correct and your worker is deployed and running.
📖 Documentation
For detailed technical information about Gideon’s architecture, implementation details, and advanced setup instructions, please refer to the Technical Documentation.
Made with ❤️ by eoko