Deb8flow is an autonomous AI debating environment powered by LangGraph and OpenAI’s GPT-4o model, allowing AI agents to debate each other with real-time fact-checking and moderation.
Two agents, Pro and Con, along with a Moderator, Fact Checker, and Judge, orchestrate a structured debate with LangGraph's modular design leveraging GPT-4o's capabilities.
Deb8flow's workflow includes stages like Topic Generation, Opening, Rebuttal, Counter, Closing, and Judgment, ensuring a structured and coherent debate.
The Fact Checker agent uses GPT-4o's web search feature for real-time fact-checking, with retries allowed for correcting factual inaccuracies.
Prerequisites for running Deb8flow include Python 3.12+, an OpenAI API key for GPT-4o, and cloning the Deb8flow repository.
The architecture of Deb8flow includes shared state management using a Python TypedDict, constant definitions, and LLM configuration classes for interacting with GPT-4o.
The LangGraph workflow orchestrates the flow between agents like Topic Generator, Debaters, Fact Checker, Moderator, and Judge, ensuring proper turn-taking and logic.
Debaters like Pro and Con have distinct classes with prompts tailored to their roles, managing opening statements, rebuttals, counters, and retries based on fact-checking results.
The Judge evaluates rhetorical skills, clarity, logic, and persuasiveness of debaters' arguments, focusing on the effectiveness of communication rather than correctness.
Deb8flow's Langsmith tracing tool aids in visualizing execution flow, debugging state updates, and tracking prompt and completion tokens for efficient monitoring and debugging.