LLM Council

April 23, 2026 · View on GitHub

A variant of the LLM Council pattern tuned for policy ideation on local-governance challenges. The user supplies a problem statement describing a policy challenge facing a city, town, or municipality; a council of six domain-specialist advisors examines it from distinct policy lenses; a Chairman synthesises the perspectives into a structured Policy Ideation Report.

Based on karpathy/llm-council, adapted to use a single LLM with six policy-specialist system prompts rather than multiple model providers.

How It Works

The user submits a policy problem statement (e.g. "Our downtown has lost 30% of retail tenants in three years — what should the city do?"). The council deliberates in three stages and returns a synthesised report.

Council members

LensFocus
Urban PlannerLand use, zoning, transport, public space, density
Municipal Fiscal OfficerBudget envelope, revenue mechanisms, capital vs operating cost
Community & Equity AdvocateDistributional impact, vulnerable populations, participation
Legal & Regulatory AnalystStatutory authority, pre-emption, procurement, implementing instruments
Service Delivery PractitionerImplementability, staffing, workflows, frontline friction
Policy Innovation & Comparative ScholarEvidence from other municipalities, unconventional instruments

Three-stage pipeline

  1. Stage 1 — Councillor Perspectives. Each councillor examines the problem through their lens and proposes ideas, options, and considerations independently.
  2. Stage 2 — Peer Review. Each councillor sees the other responses anonymised and ranks them for usefulness and rigour.
  3. Stage 3 — Chairman Synthesis. The Chairman produces a structured Policy Ideation Report: restated problem, consolidated catalogue of ideas with attribution, cross-cutting themes, tensions and trade-offs, a shortlist of promising directions, and open questions.

Digest Outputs

After deliberation, you can generate two digest formats:

  • PDF Report -- A formatted Typst document with all stages, rankings, and the final Policy Ideation Report
  • Briefing Podcast -- An LLM-written briefing script converted to audio via Microsoft Edge TTS, summarising the council's ideas for a commuting municipal official

Setup

1. Install Dependencies

Requires uv for Python and Node.js for the frontend.

uv sync
cd frontend && npm install && cd ..

2. Configure API Key

Create a .env file in the project root:

OPENROUTER_API_KEY=sk-or-v1-...

Get your API key at openrouter.ai.

3. Configure Model (Optional)

Set the base model and chairman model via environment variables in .env:

COUNCIL_MODEL=anthropic/claude-sonnet-4.5
CHAIRMAN_MODEL=anthropic/claude-sonnet-4.5

Or edit backend/config.py to customise the council lenses for a more specific policy domain (e.g. add a Public Health Officer lens for health-policy work, or a Climate & Resilience lens for environmental policy).

4. Optional: Install Typst and Edge TTS

For PDF report generation:

# Install Typst (see https://github.com/typst/typst)
cargo install typst-cli
# or via package manager

For podcast audio generation:

pip install edge-tts

Running

./start.sh

Or manually:

# Terminal 1 - Backend
uv run python -m backend.main

# Terminal 2 - Frontend
cd frontend && npm run dev

Open http://localhost:5173 in your browser.

Tech Stack

  • Backend: FastAPI, async httpx, OpenRouter API
  • Frontend: React + Vite, react-markdown
  • PDF Generation: Typst
  • Audio Generation: Microsoft Edge TTS (edge-tts)
  • Storage: JSON files in data/conversations/

Attribution

Based on karpathy/llm-council by Andrej Karpathy.