Multi-Agent Software Development: From Requirements to Testing and Delivery
A practical workflow for non-professional developers using AI agents to build software. Learn how to finalize specifications, define project constraints, implement and review modules, design specification-based tests, and complete manual checks while retaining human control over key decisions.
1. Moving Beyond One-Off AI Coding
Many people use AI coding tools in a familiar cycle: describe a requirement, accept some code, run it, and paste any errors back into the tool. This can work for small scripts. Once modules grow beyond a few hundred lines, however, recurring problems often emerge: inconsistent interfaces, overlooked edge cases, and duplicate implementations of the same feature.
The underlying problem is that requirements have not been captured in a testable document, and implementation lacks an independent review step.
The workflow described here is intended for non-professional developers. Multiple agents first collaborate to finalize a specification. Development then proceeds module by module, with cross-review and automated testing for each module. Finally, a human performs additional tests and identifies interface issues for correction.
The goal is to turn “writing code” into a series of deliverables that can be checked and verified.
2. Separate Roles and Cross-Check Results
The workflow uses three roles:
- Requirements owner: The user, who defines goals, confirms trade-offs, and makes final decisions.
- Author: The agent responsible for drafting specifications and writing code.
- Reviewer: The agent responsible for challenging the author’s output and proposing changes.
Having two agents review each other’s work can be more effective than relying on one agent to check itself. Models tend to reinforce judgments they have already made. Using a different model as the reviewer—or running the same model in an independent context—can help reduce this confirmation bias.
Each stage also needs a clear completion criterion: neither side raises further substantive issues, or any remaining disagreements are documented and resolved by the requirements owner. Without such a criterion, discussions can continue indefinitely.
3. Stage One: Finalize the Specification
The specification is the reference for every subsequent stage. At a minimum, it should include:
- Goals and non-goals: What the project will and explicitly will not do.
- Module boundaries: Each module’s responsibilities, inputs, and outputs.
- Interface definitions: Function or API names, parameter types, return values, and error conditions.
- Data structures: Field meanings, allowed values, and storage methods.
- Acceptance criteria: A pass-or-fail outcome for each requirement.
For example, a module entry might look like this:
### Module: User Login- Responsibility: Validate account credentials and issue an access token.- Inputs: username (string, 3–32 characters), password (string).- Outputs: Return token (string) on success; return error code AUTH_FAILED on failure.- Acceptance criterion: Lock an account for 10 minutes after five consecutive incorrect password attempts.
The author drafts the document, the reviewer questions it item by item, and the author revises it. This cycle continues until the specification is finalized.
More specific documentation leaves less room for conflicting interpretations during implementation. Anything left unclear in the specification is likely to be filled in incorrectly in the code.
4. Stage Two: Define Project Constraints and Develop by Module
Before coding begins, create a project constraints file that gives the author a persistent set of rules to follow in each conversation. It generally includes:
- Language versions and the technology stack, as defined in the specification.
- Directory structure and naming conventions.
- Prohibited changes, such as modifying finalized interfaces or introducing unapproved dependencies.
- Check commands that must run after each change.
For example:
1. Follow the interface definitions in the specification. Submit a change description before modifying an interface.2. Place each module in its own directory. Modules may interact only through public interfaces.3. Add every new dependency to the dependency list and explain its purpose.4. Run the test command before each commit. Do not proceed to the next module if tests fail.
Module boundaries should follow a few principles:
- Each module has a single responsibility.
- Dependencies flow in one direction, avoiding circular references.
- Each module can be tested independently.
- Each module is small enough to review in full in one pass.
Implement lower-level modules before higher-level modules so that the interfaces required by dependent modules are already stable.
5. Stage Three: Review Each Module
After a module is complete, the reviewer checks its code against the specification. Review findings can be grouped into three severity levels:
- Critical: Security vulnerabilities, risks of data loss, or explicit conflicts with the specification.
- Moderate: Missing edge cases or incomplete error handling.
- Suggestions: Improvements to naming, readability, duplicate code, and similar concerns.
The author responds to each finding, implements accepted changes, and explains any rejected recommendations. The two sides repeat this process until they reach a clear conclusion on every finding.
Keep the review records so that defects can later be traced back to how they were identified and addressed.
Non-professional developers do not need to understand every line of code. They do need to understand the risks described in review conclusions and assess whether the author’s objections are reasonable. If the agents remain deadlocked, the requirements owner should make the decision.
6. Stage Four: Agree on an Automated Test Plan
The author and reviewer should also discuss and finalize the test plan. It should define:
- Which modules and execution paths are covered.
- How unit tests cover function-level logic and integration tests cover interactions between modules.
- How test data is constructed and whether external services need to be mocked.
- Pass criteria, such as all core paths passing and no failures in critical test cases.
Test cases should come from the specification’s acceptance criteria, not from the implementation itself. If the implementer derives tests solely from the code’s logic, those tests may prove only that the code does what it was written to do—not that it satisfies the specification.
Using the login lockout rule above, a test might look like this:
def test_account_locked_after_five_failures(auth_service):for _ in range(5):auth_service.login("alice", "wrong-password")result = auth_service.login("alice", "correct-password")assert result.error_code == "AUTH_FAILED"
This example illustrates the test structure only. Actual interface names and return structures must match the specification.
7. Stage Five: Add Manual Testing and Fix UI Defects
Automated tests are effective at checking logic, but their coverage of layout, interaction, and visual details is limited. Manual testing should focus on:
- Whether pages display correctly at different window sizes.
- Whether form messages, button states, and loading feedback behave as expected.
- Unusual interaction paths, such as performing actions out of order or clicking repeatedly.
- Display problems such as truncated text, misaligned elements, and insufficient color contrast.
For each issue, create a defect report describing the observed behavior, reproduction steps, and expected result. Give this report to the author for correction.
After a fix, rerun the relevant automated tests to check that correcting one issue has not broken other functionality.
8. Common Workflow Risks
Documentation and Code Drift Apart
An interface changes during implementation, but the specification is not updated.
Response: Make documentation updates a required part of every change.
Review Discussions Become Repetitive
The agents keep revisiting the same disagreement without making progress.
Response: Set a maximum number of review rounds. Escalate unresolved issues to the requirements owner once that limit is reached.
Tests Mirror the Implementation
Tests written entirely from the implementation can reproduce its assumptions and hide its mistakes.
Response: Base tests on the specification’s acceptance criteria.
Review Findings Receive Too Much Trust
The reviewer can also be wrong.
Response: Manually spot-check critical conclusions involving security, money, or data.
9. Conclusion
This workflow keeps final decision-making with the requirements owner while agents handle repetitive drafting, coding, checking, and recordkeeping.
For non-professional developers, the priority is to understand the specification, review conclusions, and test results well enough to make informed trade-offs. The process can be scaled to fit the project, but three principles should remain: define the specification first, use cross-review, and keep tests independent of the implementation.
