Back/Claude
Advanced

Build iOS Apps with a Dueling AI Agent Workflow

Give one Claude Code session the builder role and another the reviewer role. The builder writes a plan on a feature branch, the reviewer challenges architecture and security, and the builder incorporates that feedback before the app is tested in Xcode.

Build iOS Apps with a Dueling AI Agent Workflow

Daniel opens Bob the Builder and Ray the Reviewer, passes a retention plan between them, incorporates the reviewer's edge cases, and then tests the approved feature in Xcode.

Before you start

What you need

  • An iOS project in Git
  • Claude Code in two terminal tabs
  • A written feature brief or plan
  • Xcode with a simulator or test device

What you’ll make

A feature branch implemented from a reviewed plan, with the reviewer's architectural, security, and edge case feedback incorporated before Xcode testing.

Tools used

Step by step

The workflow

Follow the sequence once, then adapt the prompts, checks, and handoffs to your own setup.

5 steps

Step01

Create Your AI Engineering Team

Open two Claude Code tabs. Configure the builder to plan first, work in modules, document decisions, and use a feature branch. Configure the reviewer to focus on platform constraints, security, architecture, member trust, and quality, with permission to disagree.

Example prompt
Builder instructions: plan before coding, work in small modules, keep project documentation current, use a feature branch, and summarize decisions and checks.

Reviewer instructions: review the builder's plans and code for iOS platform constraints, security, architecture, member trust, and quality. Identify concrete risks and required changes. Do not agree without explaining why the design is sound.

Keep the two chats open side-by-side in your terminal to easily manage the handoff between them.

Step02

Assign a Task to Bob the Builder

Give the builder the feature brief or reference its Markdown file. Ask for an implementation plan that names the branch, files, data flow, platform constraints, and how the feature will be tested in Xcode.

Step03

Initiate Code Review with Ray

Send the complete plan to the reviewer. Ask for findings tied to architecture, security, known iOS limitations, cost, and edge cases, then read the response before passing it back.

Example prompt
Review the attached implementation plan. Check its architecture, iOS background and Live Activity constraints, security and privacy, cost, failure states, migration needs, and test coverage. Return required changes first, then optional improvements, with a reason for each finding.

[latest builder plan]

This manual copy-paste step is crucial. It forces you to read the plan and the feedback, helping you learn and catch potential issues yourself.

Step04

Get Approval and Start Building

Pass the reviewer's findings to the builder and have it revise the plan and implement the agreed changes on the feature branch. If the two recommendations conflict, make the product or cost decision and record it in the plan.

Step05

Integrate and Test in Xcode

Open the branch in Xcode, clean and build the project, then run the feature in the simulator and on a device when its behavior depends on notifications, background execution, or Live Activities. Send concrete failures back to the builder and rerun the same test.

Always work in separate branches for new features to avoid merge conflicts with your main codebase.

What good looks like

  • The builder creates a plan before editing code.
  • The reviewer identifies concrete risks or confirms why the plan is sound.
  • Implementation happens on a feature branch.
  • The app builds and the feature works in the simulator or on device.

Build your next product with ChatPRD

Turn an idea into a PRD, user stories, and a plan.

Try ChatPRD free

After the steps

Runbook notes

How to recover when the loop fails and where human judgment helps.

Recover

If it goes sideways

The reviewer agrees with every plan
Give the reviewer explicit product constraints and known platform limits, and require concrete findings tied to the proposed design.
The two sessions review different versions of the plan
Save the current plan to a Markdown file or paste the full latest version with the reviewer comments when handing work back.
The builder edits main directly
Create a feature branch before implementation and confirm the current branch in the builder session.
The code looks plausible but fails in Xcode
Give the builder the exact compiler, simulator, or device error and keep the fix on the same feature branch. Repeat the failing action after rebuilding.

Start shipping
better products.

Join 100,000+ product managers who use ChatPRD to write better docs, align teams faster, and build products users love.

Free to start
No credit card
SOC 2 certified
Enterprise ready