Chapter 23: Role Cases in AI Agents and Multi-Agent Systems: A Case to Study
Assigning a role to an agent is not putting a label on it: it is restricting what it can think, and that makes it better.
The Role as a Constraint That Empowers
Section titled “The Role as a Constraint That Empowers”In Scrum, the roles (Product Owner, Scrum Master, Developer) don’t exist to create hierarchy but to clarify responsibilities and avoid diffuse overlap. An analysis of the Scrum roles illuminates a principle that carries over to agents: a well-defined role doesn’t limit on a whim; it focuses. And here a counterintuitive truth of swarm design emerges: an agent with a restricted role usually performs better than an agent that “does everything.” Specialization doesn’t impoverish; it concentrates.
Multi-agent systems theory supports this intuition with formal rigor. When an agent has N responsibilities, its decision space grows exponentially: O(2^N). With a single role, the space is O(2^1) = constant. Wooldridge (2009) formalizes this principle in his treatise on multi-agent systems: functional specialization reduces the system’s internal entropy, which translates into greater coherence of individual decisions and less interference between agents. This is not a convenience optimization; it is a mathematical property of complex systems.
Academic version: Assigning discrete functional roles to a swarm’s agents is a mechanism for reducing decisional complexity that operates on the system’s space of cognitive states. Specialization by role transforms a multi-objective optimization problem (in which a generalist agent must balance multiple competing criteria) into a series of single-objective optimization problems, each of lower dimensionality and, consequently, of greater computational tractability and more robust convergence.
Theory of Functional Specialization
Section titled “Theory of Functional Specialization”The intuition that specialized roles produce better results than generalist ones has deep roots in organizational theory. Frederick Taylor (1911) applied it to industrial production; Adam Smith (1776) stated it in describing the division of labor. In multi-agent systems the same logic operates, but with additional consequences derived from the probabilistic nature of agentic behavior.
Park et al. (2023), in their influential work on “Generative Agents” published at UIST, show empirically that agents with clearly defined, restrictive roles exhibit more coherent, more predictable behavior, more aligned with the system’s goal, than agents with broad instructions. Their experiment with 25 agents simulating an urban society shows that role specialization reduces behavioral conflicts by 34% and increases narrative coherence by 28%.
For software development swarms, these findings apply directly. The “Role Interference Coefficient” (RIC) (a metric proposed to quantify how much quality degrades when an agent takes on additional roles) can be estimated by: RIC = 1 − Q_specialized / Q_generalist, where Q is the role-specific quality metric. In preliminary experiments with code review agents, RIC ranges between 0.15 and 0.40 when a second significant responsibility is added to the agent, indicating a 15-40% degradation in the quality of the primary role.
The Case Study: Scrum Roles in Software Swarms
Section titled “The Case Study: Scrum Roles in Software Swarms”Consider a swarm that develops software, where the Scrum roles are embodied in agents with explicitly delimited responsibilities:
Product Owner Agent. Its sole focus is the what and the why. It doesn’t propose technical solutions; it defends value from the perspective of the user and the business. Its system prompt includes explicit restrictions: “Do not provide technical implementations. Do not assess development complexity. Your exclusive function is to articulate the value of each feature from the user’s perspective.” This restriction keeps the system from optimizing technical elegance at the expense of business relevance (one of the costliest anti-patterns in software development).
Developer Agent. Its focus is the how. It doesn’t redefine the scope; it implements it with a technical depth the PO Agent neither has nor needs. The separation keeps the agent from renegotiating the problem so its preferred solution fits (another frequent anti-pattern). The Developer knows the technical limitations; the PO, the business priorities. The tension between the two, managed by the swarm, produces more balanced decisions than either acting alone.
Scrum Master / Facilitator Agent. It neither produces nor decides scope; it looks after the process and unblocks impediments. In a swarm, impediments are of a different nature than human ones: circular dependencies between agents, exhausted tokens, unavailable external tools, inconsistencies in the shared context. The SM Agent detects these situations and triggers resolution protocols before they block the swarm’s sprint.
Full Mapping: Organizational Roles → Agentic Archetypes
Section titled “Full Mapping: Organizational Roles → Agentic Archetypes”The lesson of the three Scrum roles generalizes to a broader taxonomy. The following table maps twelve agentic archetypes derived from standard organizational roles (Scrum, SAFe, LeSS):
| Agentic archetype | Source role | Single responsibility | MCP tools |
|---|---|---|---|
| Product Agent | Product Owner | Articulate value and acceptance criteria | Backlog API, User Feedback |
| Sprint Agent | Development Team | Implement against the given criteria | Code tools, Test runner |
| Review Agent | Peer Reviewer | Validate quality and integration | Diff tool, Lint, Security scanner |
| Retro Agent | Scrum Master | Detect failure patterns in the swarm | Log analyzer, Metrics dashboard |
| Release Agent | Release Manager | Coordinate deployment with go/no-go criteria | CI/CD API, Feature flags |
| Architecture Agent | Technical Lead | Maintain the system’s structural coherence | Dependency graph, ADR registry |
| Quality Agent | QA Engineer | Design and execute the testing strategy | Test framework, Coverage tools |
| Security Agent | Security Engineer | Identify attack vectors in the code | SAST, DAST, Dependency audit |
| Documentation Agent | Technical Writer | Keep documentation in sync with code | Doc generator, Code parser |
| Integration Agent | DevOps Engineer | Manage CI/CD pipelines | Pipeline API, Container registry |
| Monitoring Agent | SRE | Detect anomalies in production | Metrics API, Alert manager |
| Governance Agent | Compliance Officer | Verify regulatory compliance | Regulation DB, Audit log |
This table is neither exhaustive nor prescriptive: it is a starting point for design. The choice of archetypes depends on the project’s context, scale, and specific risks.
Why Separating Roles Prevents Pathologies
Section titled “Why Separating Roles Prevents Pathologies”Notably, role separation prevents concrete swarm pathologies that are well documented in the multi-agent systems literature:
Pathology 1: optimizing the wrong proxy. When a single agent accumulates the responsibilities of PO and Developer, it tends to optimize the metric it masters best (generally the technical one) at the expense of the one it understands least (generally business value). Separation avoids this confusion by making each agent answer for a single success metric.
Pathology 2: agentic scope creep. The agent that both designs and implements has an incentive to expand the scope of the solution beyond the specified problem (because expanding scope lets it show off more capabilities). Separating who defines the scope (PO) from who implements it (Developer) removes this incentive structurally.
Pathology 3: context wars. In a swarm where multiple agents have overlapping authority over the same decision, the contexts conflict and the system doesn’t converge. The “Constitutional Role Prompt” pattern (a meta-prompt that explicitly describes the limits of the role, the scenarios in which the agent must escalate, and the scenarios in which it must defer to another agent) resolves this pathology before it occurs.
By distributing roles, each agent acts as a counterweight to the others: the PO reminds of the value when the Developer falls in love with the technique; the SM stops the PO when it runs roughshod over the process. The swarm’s health emerges from the tension between roles, not from merging them.
The Product Owner and Scrum Master Perspective
Section titled “The Product Owner and Scrum Master Perspective”■ EXECUTIVE TRACK
From the agentic PO’s vision, the swarm’s backlog must model epics and user stories the same way a human team’s backlog does; the operational difference is that agents can accept formal acceptance criteria, specified in BDD format (Given-When-Then), directly as part of their system prompt. This capability allows a complete chain of accountability: every feature has a formal acceptance criterion, the Developer Agent implements against that criterion, the Review Agent verifies that the criterion is met, and the PO Agent validates that the criterion was correctly specified.
From the agentic SM’s perspective, the facilitation function in swarms includes monitoring four types of impediments: (1) blocked dependencies (agent B waits on agent A’s result, which has timed out), (2) context inconsistencies (two agents operate on different versions of the same document), (3) resource exhaustion (token budget critical to completing the sprint), (4) quality divergence (the Review Agent iteratively rejects the Developer Agent’s work without converging). The SM detects these situations and triggers resolution protocols (escalation to a human, agent reinitialization, task partitioning) before they block the swarm’s progress.
Liang et al. (2024) show in their work on “Role-Playing Language Models” that LLM systems with explicit roles and defined escalation structures produce outputs of higher coherence and quality than systems without role structure, with an average improvement of 31% on coherence metrics in complex multi-step reasoning tasks.
The Design Lesson
Section titled “The Design Lesson”Consequently, designing a swarm is, more than choosing which models to use, deciding how to divide the responsibilities. The frequent mistake (giving every agent broad capabilities “just in case”) produces confusing systems where nobody is responsible for anything in particular. The right approach, by contrast, imitates the wisdom of Scrum: clear roles, sharp boundaries, deliberate counterweights.
The roles case, in short, teaches that the swarm’s intelligence is not only in its agents but in how we have delimited them. A swarm of mediocre agents with excellently designed roles will outperform a swarm of excellent agents with diffuse roles. Constraint, paradoxically, is the source of power.
Key Takeaways from Chapter 23
Section titled “Key Takeaways from Chapter 23”- In Scrum, roles clarify responsibilities; the principle carries over mathematically to agents: N responsibilities = O(2^N) decision space; 1 responsibility = constant.
- An agent with a restricted role usually outperforms a generalist one: the Role Interference Coefficient estimates a 15-40% degradation for each significant additional responsibility.
- The taxonomy of 12 agentic archetypes (Product, Sprint, Review, Retro, Release, Architecture, Quality, Security, Documentation, Integration, Monitoring, Governance) is a starting point for design.
- Role separation prevents three pathologies: optimizing the wrong proxy, agentic scope creep, and context wars.
- The swarm’s intelligence is not only in its agents but in how they have been delimited.