Can AI Agents Produce Better Answers by Disagreeing With Each Other?
What happens when AI agents do not simply agree with one another, but solve independently, challenge assumptions, compare evidence, and make uncertainty visible? This is the engineering experiment behind Assembly.
Project: Assembly on GitHub
Author: Anubhab Das
Project status: Experimental; actively under development
Status snapshot used in this article: 17 November 2026
A large language model can give you a confident answer that is completely wrong. The difficult part is that, on the screen, a confident wrong answer can look almost identical to a confident correct one.
You can ask another model, repeat the question, or verify every claim yourself. But those steps are manual. They also do not guarantee that the second answer is independent of the first or that either answer has been checked against useful evidence.
That observation led me to build Assembly, an experimental multi-agent AI workspace. Instead of relying on one model response, Assembly explores a structured workflow: multiple agents attempt a problem independently, their answers are compared, disagreements can trigger research or debate, and a final response is assembled with the remaining uncertainty made explicit.
The important word here is explores. Assembly is an engineering experiment, not a proven method for making AI answers more accurate. Its orchestration, routing, consensus, and debate components have been implemented and tested offline, but live reliability and answer-quality improvements have not yet been established.
This article explains why I started the project, how its architecture works, what has been implemented, and what still needs to be tested.
Why build a multi-agent workspace?
A single model response has a few limitations that become especially visible when the task is complex:
- A single answer offers no independent check. The user sees one result, but not which alternatives were considered or where the model was uncertain.
- Models can disagree. Different model families—and even different runs of the same model—may produce different answers. Comparing them manually takes time.
- An incorrect premise can carry forward. Follow-up questions in the same conversation may inherit the original mistake instead of challenging it.
- More model calls create more operational complexity. Each provider has its own authentication, quota, latency, and failure behaviour.
Assembly is an attempt to make some of that process explicit.
The core idea is straightforward: let agents work independently before exposing them to one another's conclusions. Then compare their positions and evidence. When a meaningful disagreement remains, use another stage—such as research, debate, or an adversarial check—to investigate it. Finally, produce a synthesis that does not hide unresolved uncertainty.
This approach is related to research on self-consistency, model ensembles, and multi-agent debate. However, existing research also contains important caveats: self-correction without external feedback can be unreliable, and debate does not improve every task or every baseline. Assembly therefore treats the value of multi-agent orchestration as an open question.
What is Assembly?
Assembly is a time-bounded, bring-your-own-key (BYOK) AI workspace. A user supplies their own provider credentials, chooses a time budget, and submits a problem. The system then plans the work and selects a temporary team of agents from the configured model catalog.
The agents can take different roles, including:
- Solver: independently works on the submitted problem.
- Researcher: searches for and gathers supporting information.
- Critic: looks for errors, unsupported claims, and weaknesses.
- Planner: proposes the task strategy and agent roles.
- Synthesizer: combines the work into a final response.
The intended output is not merely a merged answer. Assembly is designed to retain structured information such as each agent's position, confidence, evidence, supporting or disagreeing agents, and remaining uncertainty.
The current time-budget options are 3, 5, 10, and 15 minutes. These limits are intended to keep a run bounded and to make the system account for available model capacity before work begins.
Assembly is not presented as a production-ready decision system. It should not be the sole basis for medical, legal, financial, security-critical, or emergency decisions.
How the architecture is organised
Assembly uses a browser-based frontend and a Python backend, with the orchestration engine coordinating the AI workflow.
1. Frontend: Next.js, React, and TypeScript
The frontend is a static-export Next.js application built with React and TypeScript, with Tailwind CSS for styling. It handles provider-key configuration, settings, time-budget selection, run controls, progress updates, and results.
The web workspace keeps user-side information—such as settings, usage, and run history—in browser storage. IndexedDB is the primary storage layer, with localStorage as a fallback. The application also uses a typed API client so that request and event payloads have a defined contract.
2. Backend: Python and FastAPI
The backend is built with FastAPI. It exposes endpoints for the model catalog, preflight checks, provider-key testing, run execution, event streaming, and cancellation.
Validation is performed on the server as well as the client. For example, attachment validation on the server is authoritative; a client-side check is not treated as a security boundary.
3. Orchestration engine
This is the core of Assembly. It handles planning, capacity checks, temporary team formation, model routing, independent solving, consensus scoring, debate, adversarial checks, and synthesis.
Agents return structured outputs rather than only free-form text. The consensus engine then considers several signals:
- Agreement or disagreement between agents
- The confidence reported by agents
- The quality and relevance of evidence
- Contradictions between responses
- How much new information appears in later rounds
The resulting consensus score is a heuristic. It is not a calibrated probability that the final answer is correct.
4. Model-provider adapters and routing
Provider adapters sit behind a common interface. A family-aware router selects configured models for different roles while considering available keys and quota information.
Provider and model identifiers, family classifications, role information, and quota metadata are maintained in a central models.yaml catalog rather than being duplicated throughout the application.
Adapters have been written for several providers, including Gemini, Groq, OpenRouter, and Hugging Face. Cerebras was considered during early development but was unusable on one test account. Mock and replay providers are also available so that the default test suite can run without making live provider calls.
Why route by model family rather than provider? Two different providers may expose the same underlying model. Treating those as independent perspectives could create a misleading impression of diversity. Family-aware routing is intended to reduce that risk, although genuine independence between model families has not yet been measured.
5. Research and retrieval
When a run needs external information, the research module can search and fetch bounded static-page content. Tavily is the primary search service. The fallback path may use Wikipedia, arXiv, Semantic Scholar, or DuckDuckGo.
Retrieved content is sanitized and treated as untrusted evidence before it is included in a prompt. A citation manager deduplicates sources so that the final answer can include the sources actually used.
6. Progress streaming
Run progress is delivered to the browser using Server-Sent Events (SSE). The frontend can display agent activity, consensus changes, disagreements, and the final response. Cancellation is handled through a separate API endpoint.
SSE replaced an earlier WebSocket-based prototype because the run-progress flow is primarily one-way: the backend sends updates to the browser, while cancellation can be handled separately.
What happens during a run?
A typical Assembly run follows eight stages:
- Submission: The user submits a problem, chooses a time budget, and may attach supported files.
- Preflight: The backend checks the requested budget against configured models, available keys, and quota metadata. The intention is to identify an infeasible plan before a run starts.
- Planning: A planner classifies the task and proposes a strategy and set of roles.
- Agent selection: The router assigns models to roles, taking model families and available keys into account.
- Independent solving: Agents attempt the problem without seeing one another's first-pass answers.
- Comparison: The consensus engine compares positions, evidence, confidence, contradictions, and new information.
- Challenge and research: If important disagreements or evidence gaps remain, the system can run debate, research, or an adversarial check. It then scores the responses again.
- Synthesis: The synthesizer assembles the final answer, including sources and uncertainty where possible.
The run is bounded by its time budget. It may also end because of cancellation, provider failure, or other stopping conditions. The design aims to avoid debate rounds that add no value: a round should resolve a disagreement, add evidence, correct an error, or materially change the assessment. If the deadline arrives while agreement is weak, the remaining uncertainty should be reported rather than concealed.
A key part of the workflow is the adversarial check. When agents appear to agree too early, one agent can be asked to assume that the consensus is wrong and search for the strongest counterargument. This is a design mechanism, not proof that premature agreement will always be detected.
Engineering lessons from building the pipeline
Multi-agent orchestration introduces failure modes beyond those found in a single chat request. During development, several concrete issues surfaced:
- Model output did not always contain clean JSON, so a more tolerant brace-tracking extractor was introduced.
- Agents sometimes returned identifiers that did not belong to the current team. The pipeline was changed to provide valid identifiers and remove invalid ones.
- Debate context could grow rapidly across rounds. Output compression was added to limit context growth, with the trade-off that compression can discard useful details.
- Failed calls could accidentally reinsert an earlier answer, making an agent appear to repeat itself. Failed outputs were tagged to prevent them from being treated as fresh responses.
- Token usage was not initially aggregated into the budget controller and needed to be accounted for.
- A later audit found a nested helper being used before its definition, causing runs with attachments to fail.
These fixes are part of the development history, not a claim that every failure mode has been eliminated. They illustrate why a pipeline involving multiple providers, structured outputs, retries, and iterative reasoning needs extensive testing.
Technology stack
The current stack is deliberately practical for a small, local-first project:
| Area | Technology |
|---|---|
| Frontend | Next.js, React, TypeScript, Tailwind CSS |
| Backend | Python, FastAPI |
| Local database | SQLite, SQLAlchemy, Alembic migrations |
| Desktop shell | Tauri |
| API communication | REST and Server-Sent Events (SSE) |
| AI integration | Multiple LLM providers behind a common adapter interface |
| Testing | pytest, Vitest, Playwright |
SQLite is used for local and planned desktop execution, where a database server would add unnecessary setup. The hosted backend is designed not to persist run questions, answers, or provider keys in a server database. Earlier plans involving PostgreSQL and Redis were dropped from the current demo scope.
The desktop direction is a Windows application using Tauri with the Python backend bundled as a local sidecar. Tauri provides a lightweight desktop shell, but the sidecar, installer, and credential-store integration still require work.
BYOK, privacy, and security: what users should know
Assembly uses a bring-your-own-key model because free-tier quotas are generally tied to individual provider accounts. Instead of relying on one shared operator key, users configure their own provider credentials.
That design avoids a shared project credential, but it makes key handling especially important. The current implementation has limitations that should be understood before using real keys.
Browser key storage
In the hosted web experience, provider keys are stored in the browser's IndexedDB, with localStorage as a fallback. They are stored as readable values: they are not encrypted at rest and are not protected by an operating-system credential vault. JavaScript running on the same origin could potentially read them, including injected JavaScript in an XSS incident.
The browser sends keys to the backend over HTTPS for preflight, key-test, and run requests. Under the documented request behaviour, preflight and run requests send all saved provider keys regardless of which models are selected; run requests can also send a saved Tavily key. A key-test request sends only the key being tested.
The backend is designed to use keys transiently and not write them to a database or disk. Request handling avoids logging raw request bodies, and a masking filter is used to scrub key-like values. However, hosting providers may maintain their own network or operational logs outside the application's control.
Desktop key storage
The desktop version is intended to use the Windows credential store. A Windows Credential Manager adapter exists in the repository, but the current settings flow still uses the WebView browser vault. OS credential-store use is therefore only partially implemented; it is not yet the primary save path.
Third-party services and prompt injection
Model providers receive the information needed to fulfil requests, and their own terms and privacy practices apply. During research, the user's full question may be sent as a search query to the configured search provider or fallback service. Attachment bodies are not used to form search queries.
Search results, fetched pages, and uploaded files are untrusted inputs. They may contain indirect prompt-injection instructions intended to manipulate a model. Assembly applies structural mitigations: retrieved text is sanitized and marked as untrusted evidence; attachment content is escaped, size-limited, and marked untrusted; fetching is bounded; and attachment bodies are not intended to appear in logs, events, database rows, or error text.
These measures reduce exposure but do not eliminate prompt injection. The project has not yet completed a systematic adversarial evaluation of injection robustness. A malicious claim could also be repeated or amplified as it passes from one agent to another.
Assembly should not be described as end-to-end encrypted, and the current key-storage design should not be treated as a guarantee of privacy or security.
Current development status
The distinction between implemented code and validated behaviour matters. The following status reflects the project's progress snapshot dated 17 November 2026; it may change as development continues.
| Component | Status |
|---|---|
| Multi-agent orchestration engine | Implemented and offline-tested |
| Family-aware model routing | Implemented |
| Consensus evaluation | Implemented and unit-tested |
| Debate and adversarial check | Implemented and unit-tested |
| Local web workspace | Implemented for local execution |
| Hosted web experience | Public introduction and setup flow; live execution release validation remains outstanding |
| Windows desktop application | Tauri shell and packaging groundwork; integration incomplete |
| Automated testing | Backend and frontend test coverage in place |
| Live operational reliability | Not yet established |
| Comparative benchmarking | Evaluation framework exists; experiments are pending |
The same progress snapshot reports:
- Backend: 684 tests — 683 passed and 1 skipped
- Frontend unit tests: 153 tests across 23 suites
- Playwright end-to-end tests: 22
- ESLint: clean output at the time of the snapshot
These are test-suite results, not evidence that the complete system works reliably with live providers. Mock and replay providers make offline testing possible, but they cannot establish real-world provider reliability, quota stability, or answer quality.
What has not been proven yet?
There are several open questions at the centre of the project:
- Does Assembly improve answer quality? No valid comparative benchmark results are available yet. It has not been shown to outperform the best single free model or a simple majority-vote baseline.
- Does model-family diversity reduce correlated errors? The router uses model-family metadata, but actual independence between families has not been measured.
- Does the consensus score mean anything predictive? The score combines agreement, confidence, evidence, contradictions, and new information. Its correlation with correctness has not been established.
- How reliable are live provider runs? Authentication failures, rate limits, timeouts, and provider changes are covered by mocked tests, but live failure rates over time have not been measured.
- How robust is the system to prompt injection? The current mitigations have not been validated through a systematic adversarial test programme.
- What does a run cost in time and calls? Performance under load, failure rates by time tier, and cost per run still need measurement.
These are not minor details. They determine whether the central idea is useful in practice.
How I plan to evaluate Assembly
The current evaluation plan compares three approaches:
- The best available single free model
- A simple majority vote across three models
- Assembly, evaluated by time-budget tier
The question set is intended to cover mathematics and science, reasoning, coding, and research-style tasks. Answers that can be checked automatically will use automatic grading; other answers will use blinded rubric-based evaluation. If an LLM judge is used, its known biases will need to be controlled for.
The benchmark table remains empty because there are no valid experimental results to report. I would rather publish no result than present synthetic or incomplete data as evidence of an improvement.
What's next?
The next stages of development follow directly from those gaps:
- Run the benchmark against the planned baselines and publish the methodology and results, including negative results.
- Rehearse live runs with real provider keys and establish reliability across providers and quotas.
- Finish the Windows desktop integration, installer testing, and Credential Manager-based key storage.
- Strengthen security with a formal threat model and adversarial prompt-injection tests.
- Evaluate whether the consensus score correlates with correctness and compare it with alternative aggregation methods.
- Make debate and disagreement easier to inspect through a more transparent timeline.
- Expand provider and model support through the catalog, and consider local models as a privacy-oriented option.
- Continue improving tests, accessibility, documentation, and scoped starter issues for contributors.
Final thoughts
Assembly starts with a modest premise: one model response does not provide an independent check. A structured group of agents might make disagreements, evidence gaps, and uncertainty easier to inspect.
The project turns that premise into a working engineering pipeline: planning, family-aware model selection, independent solving, consensus scoring, debate, adversarial checking, and synthesis. It combines a Next.js frontend, a FastAPI backend, multiple provider adapters, and a BYOK approach designed around user-supplied model access.
There is meaningful implementation work in place, and the offline test suite covers important parts of the system. But the central hypothesis remains untested. Live operational reliability has not been established, comparative benchmark results do not yet exist, and the hosted execution and Windows desktop paths still need completion.
That is why I want to keep the project's limitations visible. If multi-agent orchestration helps, the benchmark should show where and by how much. If it does not, that is worth reporting too.
Explore the project: github.com/anubhab7105/Assembly
Assembly is open source under the Apache License 2.0. Contributions around reliability, testing, accessibility, security, and documentation are welcome.
Further reading
The original technical article relates Assembly to the following research and technical work. The bibliographic details below are carried over from the working article and should be checked against the original publications before being used in formal academic work.
- Wang et al., Self-Consistency Improves Chain of Thought Reasoning in Language Models (2022), arXiv:2203.11171.
- Du et al., Improving Factuality and Reasoning in Language Models through Multiagent Debate (2023), arXiv:2305.14325.
- Liang et al., Encouraging Divergent Thinking in Large Language Models through Multi-Agent Debate (2023), arXiv:2305.19118.
- Jiang et al., LLM-Blender: Ensembling Large Language Models with Pairwise Ranking and Generative Fusion (2023), arXiv:2306.02561.
- Wang et al., Mixture-of-Agents Enhances Large Language Model Capabilities (2024), arXiv:2406.04692.
- Huang et al., Large Language Models Cannot Self-Correct Reasoning Yet (2023), arXiv:2310.01798.
- Smit et al., Should we be going MAD? A Look at Multi-Agent Debate Strategies for LLMs (2023), arXiv:2311.17371.
- Greshake et al., Not What You've Signed Up For: Compromising Real-World LLM-Integrated Applications with Indirect Prompt Injection (2023), arXiv:2302.12173.
- OWASP, Top 10 for Large Language Model Applications.