Skip to content

roundtablelabs/crucible-community

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

12 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Crucible Logo

πŸ”₯ Crucible Community Edition

Decision Intelligence Platform

License Docker Python TypeScript

Quick Start β€’ Documentation β€’ Contributing β€’ License


🎯 What is Crucible?

Crucible is an advanced AI debate engine that orchestrates multiple AI "knights" (expert personas) to analyze complex topics from diverse perspectives. Watch as AI experts debate, challenge each other, and converge on nuanced insightsβ€”all in real-time.

Why Crucible?

  • πŸ€– Multi-Agent Intelligence: Multiple AI personas with distinct expertise debate your questions
  • ⚑ Real-Time Streaming: Watch debates unfold live with streaming responses
  • πŸ“Š Executive Briefs: Generate comprehensive PDF decision briefs from debates
  • 🏰 Prebuilt Knights: Access to a library of expert AI personas
  • πŸ”’ Self-Hosted: Full control over your data and infrastructure
  • πŸ”‘ BYOK Model: Bring your own API keysβ€”no vendor lock-in

Perfect For

  • Power Users who want to self-host and customize
  • Enterprises requiring internal deployment and data control
  • Developers who want to extend and contribute
  • Researchers exploring multi-agent AI systems
  • Decision Makers who need comprehensive analysis from multiple perspectives

✨ Features

Feature Description
🎭 Multi-Agent Debates Orchestrate debates between multiple AI personas with distinct expertise
πŸ“‘ Live Streaming Real-time debate sessions with streaming responses and live updates
πŸ“„ PDF Briefs Generate comprehensive executive decision briefs from completed debates
🏰 Prebuilt Knights Library of expert AI personas ready to use
πŸ”„ Phase-Based Workflow Research β†’ Position Cards β†’ Challenges β†’ Rebuttals β†’ Convergence
πŸ” Self-Hosted Full control over your data, infrastructure, and deployment
πŸ”‘ BYOK Model Bring your own API keysβ€”support for OpenAI, Anthropic, OpenRouter, and more
🎨 Customizable Branding, configuration, and extensible architecture
🐳 Docker Ready One-command deployment with Docker Compose
⚑ Fast Setup Get running in 3 stepsβ€”no complex configuration needed

πŸš€ Quick Start

Get Crucible running in 3 simple steps!

Prerequisites

  • 🐳 Docker 20.10+ and Docker Compose v2+ (or docker-compose v1.29+)
  • 🐍 Python 3.11+ (only needed for automatic secret generation on first run)
    • The wrapper scripts use Python to generate secure secrets
    • After .env is created, Python is no longer needed
    • Install from https://python.org if missing
  • πŸ’Ύ 4GB RAM minimum, 8GB recommended
  • πŸ”Œ Ports available: 3000 (frontend), 8000 (API)
    • Check with: lsof -i :3000 (Linux/macOS) or netstat -ano | findstr :3000 (Windows)

πŸ’‘ Tip: API keys are optional during setupβ€”you can configure them later in the Settings page after login.

Installation (3 Steps)

Estimated time: 5-10 minutes (depending on internet speed for Docker image downloads)

1️⃣ Clone the Repository

Time: ~30 seconds

git clone https://github.com/roundtable-labs/crucible-community.git
cd crucible-community

2️⃣ Start Services

What are wrapper scripts? The wrapper scripts (docker-compose.sh, docker-compose.ps1, docker-compose.bat) are convenience scripts included in this repository that:

  • βœ… Automatically generate secure secrets (if .env doesn't exist)
  • βœ… Start all Docker services with one command
  • βœ… Display your login credentials after setup

Why use them? They eliminate manual configurationβ€”just run one command and everything is set up!

Estimated time: 2-5 minutes (depending on internet speed for Docker image downloads)

What happens:

  1. Script checks if .env file exists
  2. If missing, generates secure secrets (requires Python)
  3. Starts 6 Docker containers (PostgreSQL, Redis, API, Worker, Beat, Frontend)
  4. Displays login credentials in terminal
  5. Services take 30-60 seconds to fully start

Expected output: You'll see Docker pulling images, starting containers, and then your login credentials.

Linux/macOS:

./docker-compose.sh up -d

Windows PowerShell (Recommended):

# Open PowerShell (not Command Prompt)
.\docker-compose.ps1 up -d

Windows Command Prompt:

# Open Command Prompt (cmd.exe)
.\docker-compose.bat up -d

Windows with WSL2:

# If using WSL2, you can use the Linux script
./docker-compose.sh up -d

⚠️ Windows Users:

  • Always use .\ prefix when running scripts
  • Do NOT use docker-compose.sh on Windows (unless using WSL2)
  • Use .ps1 (PowerShell) or .bat (Command Prompt) instead
  • PowerShell is recommended for better error messages

3️⃣ Access Crucible

  1. Wait for services to start (30-60 seconds)

    • Verify: docker compose ps - all services should show "healthy" or "running"
  2. Open http://localhost:3000 in your browser

  3. Find your login credentials:

    • Default email: admin@community.local
    • Password: Look in your terminal output for a section that says:
      ==================================================
      IMPORTANT: Save your credentials!
      ==================================================
      
      Your secure credentials have been generated:
        - Authentication password: [YOUR_PASSWORD_HERE]
      
    • The password is the value shown after "Authentication password:"
  4. Can't find the password? It's also saved in your .env file:

    # Linux/macOS
    grep ROUNDTABLE_COMMUNITY_AUTH_PASSWORD .env
    
    # Windows PowerShell
    Select-String "ROUNDTABLE_COMMUNITY_AUTH_PASSWORD" .env

❓ Having trouble? See the Troubleshooting section below for common issues and solutions.

4️⃣ Verify Installation (Optional but Recommended)

Check all services are running:

docker compose ps

All 6 services should show "healthy" or "running" status.

Test the API:

If services aren't healthy:

  • Check logs: docker compose logs -f
  • See Troubleshooting section for common issues

πŸ“‹ First Install Output

When you run the setup for the first time, you'll see output like this in your terminal:

==================================================
IMPORTANT: Save your credentials!
==================================================

Your secure credentials have been generated:
  - Authentication password: [Login Password]
  - Database user: [Database Username]
  - Database password: [Database Password]
  - Redis password: [Redis Password]

⚠️  These values are saved in: .env
   Keep this file secure and never commit it to version control!

Important: Save your authentication password - you'll need it to log in!

πŸŽ‰ That's It!

The wrapper scripts automatically:

  • βœ… Generate .env file with secure secrets (if missing)
  • βœ… Start all Docker services (PostgreSQL, Redis, API, Worker, Frontend)
  • βœ… Display your login credentials
  • βœ… No manual configuration needed!

What's Next?

  1. βœ… Log in at http://localhost:3000 using the credentials from your terminal
  2. βš™οΈ Configure API keys in Settings (optional - you can add them later)
  3. πŸš€ Start creating your first debate session!

πŸ’‘ Pro Tip: The wrapper scripts work exactly like docker-composeβ€”they accept all the same arguments (up, down, logs, ps, etc.).

πŸ—οΈ Architecture

When you run the installation, Crucible creates:

Docker Services

Service Description Port
🐘 postgres PostgreSQL 15 database 5432 (internal)
πŸ”΄ redis Redis 7 cache and session storage 6379 (internal)
πŸš€ api FastAPI backend service 8000
βš™οΈ worker Celery worker for background tasks -
⏰ beat Celery beat scheduler -
🎨 frontend Next.js frontend application 3000

Data Persistence

  • πŸ“¦ Docker volumes (data persists between restarts):
    • postgres_data - Database files
    • artifacts - Generated PDFs and documents

Configuration

  • βš™οΈ .env - Environment variables with auto-generated secrets

Environment Variables Reference

Auto-Generated (Required)

These are automatically generated by the setup scripts. You don't need to set them manually.

Variable Purpose Generated Value
API_KEY_ENCRYPTION_KEY Encrypts user API keys stored in database 32-character URL-safe token
ROUNDTABLE_JWT_SECRET JWT token signing for authentication 48-character URL-safe token
ROUNDTABLE_JWT_REFRESH_SECRET JWT refresh token signing 48-character URL-safe token
ROUNDTABLE_COMMUNITY_AUTH_PASSWORD Login password for admin@community.local 16-character URL-safe token
POSTGRES_USER PostgreSQL database username 12-character alphanumeric
POSTGRES_PASSWORD PostgreSQL database password 24-character URL-safe token
REDIS_PASSWORD Redis authentication password 32-character URL-safe token

Optional (User-Provided)

These can be set in .env or configured later in the UI Settings page.

Variable Purpose Notes
ROUNDTABLE_OPENROUTER_API_KEY OpenRouter API key for LLM access Can be set in UI Settings after login
ROUNDTABLE_EDEN_AI_API_KEY Eden AI API key for AI research features Optional, can be set in UI Settings
ROUNDTABLE_ENABLE_RATE_LIMITING Enable rate limiting for LLM API calls Default: true. Set to false in .env to disable
ROUNDTABLE_LLM_RATE_LIMIT_TPM Rate limit in tokens per minute Default: 100000. Adjust in .env if needed
ROUNDTABLE_LLM_RATE_LIMIT_WINDOW_SECONDS Rate limit time window in seconds Default: 60. Adjust in .env if needed

Security Note: For production deployments, consider hashing the password using:

cd service && python -m scripts.hash_password <your-password>

Then update ROUNDTABLE_COMMUNITY_AUTH_PASSWORD in .env with the generated hash.

Common Operations

View Logs

# All services
docker compose logs -f

# Specific service
docker compose logs -f api
docker compose logs -f frontend

Stop Services

docker compose down

Update to Latest Version

# Pull latest images and restart
docker compose pull && docker compose up -d

Check Service Status

# Verify all services are running
docker compose ps

Reset Everything (WARNING: Deletes All Data)

# Stop and remove all containers, volumes, and networks
docker compose down -v

Backup Data

# Backup PostgreSQL database
# Replace YOUR_POSTGRES_USER with the value from your .env file
docker compose exec postgres pg_dump -U YOUR_POSTGRES_USER roundtable > backup.sql

# Or use the environment variable directly (if available in shell)
docker compose exec -e PGPASSWORD="$POSTGRES_PASSWORD" postgres pg_dump -U "$POSTGRES_USER" roundtable > backup.sql

# Backup .env file (contains encryption keys!)
cp .env .env.backup

Customization (For Power Users)

Change the Default Password

  1. Generate a password hash:

    cd service && python -m scripts.hash_password <your-new-password>
  2. Update .env file:

    ROUNDTABLE_COMMUNITY_AUTH_PASSWORD=<generated-hash>
  3. Restart services:

    docker compose restart api

Use Custom Domain / HTTPS

  1. Update ROUNDTABLE_CORS_ORIGINS in .env:

    ROUNDTABLE_CORS_ORIGINS=https://yourdomain.com
  2. Update NEXT_PUBLIC_API_URL in docker-compose.prod.yml or frontend environment:

    NEXT_PUBLIC_API_URL=https://api.yourdomain.com/api
  3. Use a reverse proxy (nginx, Traefik, etc.) to handle SSL/TLS termination.

Connect External PostgreSQL/Redis

  1. Update connection strings in .env file (replace placeholders with your actual values):

    # Replace user, pass, and external-host with your PostgreSQL credentials
    ROUNDTABLE_DATABASE_URL=postgresql+asyncpg://user:pass@external-host:5432/roundtable
    
    # Replace password and external-host with your Redis credentials
    ROUNDTABLE_REDIS_URL=redis://:password@external-host:6379/0
  2. Edit docker-compose.prod.yml and remove or comment out the postgres and redis service definitions (since you're using external services).

  3. Ensure external databases are accessible and initialized (run python -m scripts.init_community_db manually if needed).

Manual Secret Generation

If you prefer to generate secrets manually instead of using wrapper scripts:

Option 1: Using setup scripts (generates secrets and starts services):

# Linux/macOS
./scripts/setup.sh

# Windows PowerShell
.\scripts\setup.ps1

Option 2: Generate secrets only, then start services manually:

# Generate .env file with secrets
python3 scripts/generate_secrets.py  # or python on Windows

# Then use regular docker-compose
docker compose -f docker-compose.prod.yml up -d

Production vs Development

Production (Default - Recommended)

Uses pre-built images from GitHub Container Registry. Faster startup, no local builds required.

File: docker-compose.prod.yml

Usage:

# Wrapper scripts automatically use production compose file
./docker-compose.sh up -d

Development

Builds from source code. Use this if you're contributing or need to modify the codebase.

File: docker-compose.yml

Usage:

# Build and run from source
docker compose up -d --build

Note: The wrapper scripts (docker-compose.sh, docker-compose.ps1, docker-compose.bat) automatically use the production compose file. For development, use docker compose directly with docker-compose.yml.

Troubleshooting

"Python not found" Error

  • Install Python 3.8+ from https://python.org
  • Ensure python or python3 is in your PATH
  • Restart your terminal after installing

"Docker not found" Error

  • Install Docker Desktop from https://docker.com
  • Ensure Docker is running
  • Restart your terminal after installing

Windows: Script Asks Which Application to Open

  • Don't use .sh files on Windows!
  • Use .\docker-compose.ps1 (PowerShell) or .\docker-compose.bat (Command Prompt)

Services Won't Start

  1. Check Docker is running: docker ps
  2. Check logs: docker compose logs
  3. Verify .env file exists: ls -la .env (Linux/macOS) or dir .env (Windows)
  4. Try regenerating secrets: Delete .env and run ./docker-compose.sh up -d again (or .\docker-compose.ps1 up -d on Windows)

Database "does not exist" Error

If you see an error like FATAL: database "username" does not exist:

  1. This usually means there's an old PostgreSQL volume with conflicting data
  2. Solution: Remove the old volume and restart:
    docker compose down -v
    docker compose up -d
    This will delete all data and start fresh. Make sure to backup your .env file first!
  1. Check services are running: docker compose ps
  2. Check frontend logs: docker compose logs frontend
  3. Verify port 3000 is not in use by another application
  4. Try accessing http://localhost:8000/docs to verify API is running

Forgot Password

  1. Check .env file for ROUNDTABLE_COMMUNITY_AUTH_PASSWORD
  2. If password is hashed, you'll need to reset it (see "Change the Default Password" section)
  3. Or delete .env and regenerate (WARNING: This makes existing encrypted API keys unreadable!)

Security Notes

  • Never commit .env to version control - It contains sensitive secrets
  • Backup your .env file - If lost, encrypted API keys become unrecoverable
  • Save your password - Displayed during setup, also stored in .env file
  • For production: Hash passwords using python -m scripts.hash_password <password>
  • Keep encryption keys secure - If API_KEY_ENCRYPTION_KEY changes, users must re-enter their API keys

API Usage Responsibility

This software uses a "Bring Your Own Key" (BYOK) model. You are responsible for:

  • Obtaining and managing your own API keys
  • All costs associated with API usage
  • Complying with API provider terms of service

Roundtable Labs is NOT liable for API costs or provider issues.

See NOTICE.md for complete disclaimers.

Documentation

Getting Started

Deployment

Configuration

API

Additional Resources

Note: For development documentation, API reference, and detailed deployment guides, see internal_dev_docs/ folder.

🀝 Contributing

We welcome contributions! Crucible is open source and built by the community.

How to Contribute

  1. πŸ“– Read our Contributing Guidelines
  2. πŸ” Check existing Issues and Pull Requests
  3. 🍴 Fork the repository and create a feature branch
  4. βœ… Sign our Contributor License Agreement (CLA)
  5. πŸ’» Make your changes and add tests
  6. πŸ“ Submit a Pull Request

Resources

Development Setup

For local development, use docker-compose.yml to build from source:

docker compose up -d --build

See Development Setup Guide for detailed instructions.

License

This project is licensed under the AGPL-3.0 (GNU Affero General Public License v3.0) - see the LICENSE file for details.

Proprietary Content

Note: While the source code is licensed under AGPL-3.0, certain content (knight prompts, personas) is proprietary. See PROMPTS_LICENSE.md for details.

πŸ’Ό Commercial Version

Looking for enterprise features, support, SLA guarantees, or managed hosting?

Visit Roundtable Labs for:

  • 🏒 Enterprise features and support
  • πŸ“ž Dedicated support and SLA
  • ☁️ Managed hosting options
  • πŸ” Advanced security features
  • πŸš€ Priority updates and new features

πŸ“ž Support & Community


Built with ❀️ by Roundtable Labs

Copyright Β© 2026 Roundtable Labs Pty Ltd

License