NetaHa/LLM-debate-arena
0
Debate Bots App
A Gradio-based web application that facilitates AI-powered debates between different language models. Two AI models (affirmative and negative sides) engage in a structured debate on a given topic, with a third AI model serving as the judge to evaluate and score the debate, according to pre-defined scoring criteria.
Tech Stack
Python | OpenAI Client | Prompt Engineering | State management for multi-turn conversations | Gradio
Features
- Multi-Model Support: Supports OpenAI, Anthropic Claude, and Grok models
- Structured Debate Format: 6-turn debate with constructive speeches, rebuttals, and closing statements
- Real-time Streaming: Watch debates unfold in real-time with streaming responses
- AI Judge: Automated evaluation by an AI judge that scores both teams on multiple criteria
- Interactive UI: Built with Gradio for an intuitive web interface
- Pre-configured Examples: Try out example debates with different model combinations
Debate Structure
The debate follows a structured format with 6 turns:
- Affirmative - Constructive Speech
- Negative - Constructive Speech
- Affirmative - Rebuttal
- Negative - Rebuttal
- Affirmative - Closing Speech
- Negative - Closing Speech
After all turns are complete, a judge model evaluates the debate and scores each team on:
- Organization and Clarity (1-4)
- Use of arguments (1-4)
- Use of examples and facts (1-4)
- Use of rebuttal (1-4)
- Presentation style (1-4)
How it works?
- Choose a debate topic (or use one of the pre-configured examples)
- Select model for each role: affirmative, negative, and judge (GPT, Claude, or Grok)
- Click "Start Debate" to start the first speech, and then "Next Turn" to proceed through the debate
- Watch as the models debate in real-time, with responses streaming in as they're generated
- After all 6 turns are complete, the final click on "Next Turn" will call the judge to evaluate the debate and declare a winner
Supported Models
Currently for cost reasons the supported models are:
- GPT:
gpt-5-nano(OpenAI) - Claude:
claude-haiku-4-5(Anthropic) - Grok:
grok-4-fast-reasoning(xAI)
but any models compatible with the OpenAI client can be easily added.
Dependencies
openai>=1.30.0- OpenAI Python client librarygradio>=4.0.0- Web UI frameworkpython-dotenv>=1.0.0- Environment variable management
Notes
- The application uses streaming to provide real-time updates, with a 50ms delay per chunk for better readability
- The debate format can be customized by modifying the
turnsandspeechesarrays in the code
