Two agents on two sessions. Generator proposes a patch; reviewer holds
veto via permission.request. Same wire contract as a single agent
asking a human.
Two-agent code review is glued together with sidecars: generator writes a PR, CI runs a "reviewer" model, results posted as a comment. The reviewer can't say "deny: rewrite this hunk and try again" without manual loop wiring.
let lease = request_apply(&generator, ticket_id, &patch).await;
match lease {
Err(ARCPError::PermissionDenied { detail }) => prior_denial = Some(detail),
Ok(_) => return Ok(()), // applied
Err(e) => return Err(e.into()),
}Idempotency key per (ticket, diff) lets identical patches dedupe at
the runtime — re-proposing the same diff returns the prior verdict.
permission.requestwith structuredreasonand a tightrequested_lease_seconds— §15.4.permission.grant/permission.denywith typedcode— §15.4.idempotency_keyfor retry-safe re-asks — §6.4.
main.rs— generator side proposes; reviewer loop on a second session responds.agents.rs—propose+reviewLLM stubs.
- Three reviewers, majority-grant.
- A
permission.requestwithmin_reviewers: 2carried inextensions. - Promote the deny into structured feedback the generator parses.