Fork Notice: This project is an extended fork of karpathy/llm-council, the original "vibe coded" weekend project by Andrej Karpathy. This version adds multiple council modes, cloud deployment, streaming, authentication, and other features.
A multi-LLM deliberation system where AI models collaborate, debate, and peer-review each other's responses to provide more thoughtful answers than any single model alone.
Instead of asking a question to a single AI, LLM Council sends your query to multiple leading models simultaneously. The models then review and rank each other's work (anonymously, to prevent favoritism), and a "Chairman" model synthesizes everything into a final response.
This approach provides:
- Multiple perspectives on complex questions
- Peer review to catch errors and blind spots
- Transparency into how different models think
- Higher quality synthesis from collective intelligence
LLM Council supports several deliberation modes:
| Mode | Description |
|---|---|
| Synthesized | Full 3-stage process: responses → peer review → chairman synthesis |
| Independent | See all model responses side-by-side without synthesis |
| Debate | Multi-round discussion where models respond to each other's arguments |
| Adversarial | Three models answer while a Devil's Advocate challenges everything |
| Socratic | The council asks YOU probing questions to clarify your thinking |
| Scenario Planning | Models generate best/worst/likely scenarios and debate probabilities |
For the synthesized mode, here's what happens when you submit a query:
-
Stage 1: Individual Responses — Your query goes to all council models independently. Each response is shown in tabs so you can inspect them.
-
Stage 2: Peer Review — Each model reviews and ranks the others' responses. Identities are anonymized (Response A, B, C...) so models can't play favorites.
-
Stage 3: Final Synthesis — The Chairman model compiles all responses and rankings into a unified final answer.
Customize the council's expertise with domain-specific configurations:
- General Purpose — Balanced advice for any topic
- Business Strategy — Market analysis, competitive strategy, growth decisions
- Code Review — Architecture, bugs, performance, security analysis
- Creative Writing — Narrative, style, character development
- Personal Productivity — Habits, systems, work-life balance
- Research Analysis — Evidence evaluation, methodology, synthesis
Enable specialist roles to have each model take a different perspective:
- The Optimist — Focuses on opportunities and upside potential
- The Skeptic — Identifies risks and plays devil's advocate
- The Pragmatist — Considers real-world constraints and feasibility
- The Innovator — Suggests unconventional, creative solutions
- Backend: FastAPI (Python 3.10+), async httpx, OpenRouter API
- Frontend: React + Vite, react-markdown for rendering
- Database: Supabase (PostgreSQL)
- Deployment: Vercel (serverless)
- LLM Access: OpenRouter (supports 100+ models)
Note on Streaming: The app supports real-time streaming where model responses appear as they complete (hot loading with skeleton tabs). This works when running locally, but Vercel's Python runtime buffers responses, so production shows all results at once. For true streaming in production, deploy the backend to Railway, Render, or Fly.io.
- Python 3.10+
- Node.js 18+
- OpenRouter API key
- Supabase account (for persistence)
git clone https://github.com/alexclowe/aicouncil.git
cd aicouncil
# Backend dependencies
pip install -r requirements.txt
# Frontend dependencies
cd frontend && npm install && cd ..Create a .env file in the project root:
# Required: OpenRouter API key
OPENROUTER_API_KEY=sk-or-v1-your-key-here
# Required: Supabase configuration
SUPABASE_URL=https://your-project.supabase.co
SUPABASE_SERVICE_ROLE_KEY=your-service-role-key
# Required for production: API password
COUNCIL_API_PASSWORD=your-secure-password
# Optional: CORS origins (comma-separated)
CORS_ORIGINS=http://localhost:5173,https://your-app.vercel.appRun the schema in your Supabase SQL Editor:
# The schema is in supabase/schema.sqlOption A: Use the start script
./start.shOption B: Run manually
Terminal 1 (Backend):
python -m backend.mainTerminal 2 (Frontend):
cd frontend && npm run devOpen http://localhost:5173 in your browser.
See DEPLOYMENT.md for detailed instructions on deploying to Vercel with Supabase.
Edit backend/config.py to customize the council:
DEFAULT_COUNCIL_MODELS = [
"openai/gpt-5.2",
"anthropic/claude-opus-4.5",
"google/gemini-3-pro-preview",
"x-ai/grok-4",
]
DEFAULT_CHAIRMAN_MODEL = "anthropic/claude-opus-4.5"You can use any model available on OpenRouter.
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ Frontend │────▶│ FastAPI │────▶│ OpenRouter │
│ (React/Vite) │ │ (Backend) │ │ (LLM APIs) │
└─────────────────┘ └────────┬────────┘ └─────────────────┘
│
▼
┌─────────────────┐
│ Supabase │
│ (PostgreSQL) │
└─────────────────┘
This project is forked from karpathy/llm-council by Andrej Karpathy, who created the original concept and implementation as a weekend "vibe coding" project. The original was inspired by reading books together with LLMs — seeing multiple AI perspectives side-by-side while exploring complex topics.
This fork adds:
- Multiple council modes (Debate, Adversarial, Socratic, Scenario Planning)
- Domain-specific council types and specialist roles
- Supabase database for persistence
- Vercel serverless deployment
- Streaming responses with real-time UI updates
- Password authentication
- Conversation archiving
- Mid-session message injection
MIT License - see LICENSE for details.
