liveBook · Manning

Chapter 8: Multi-agent systems

What you will learn in chapter 8 of Building Reliable AI Systems

The introduction explains why a customer request spanning images, products, and policies calls for coordinated specialist agents rather than isolated tools or one overloaded model.

After this chapter you will be able to

What it builds on

Section by section

Introduction

The introduction explains why a customer request spanning images, products, and policies calls for coordinated specialist agents rather than isolated tools or one overloaded model.

Key terms: multipart request, MCP tools, response coordination, multi-agent architecture, specialized agents, intelligent orchestrator, coordination layer, context window

8.1 Multi-agent systems

This section introduces the shift from individual AI capabilities to orchestrating them in multi-agent systems for complex conversations.

8.1.1 Why multi-agent architecture matters

The section uses a shopping request to show why specialized, coordinated agents can handle mixed customer needs better than one agent trying to do everything.

Key terms: Product search, Policy knowledge, Conversation coordination, monolithic agent problem, multi-agent solution, SearchAgent, PolicyAgent, Coordinator

8.1.2 Introducing LangGraph: The multi-agent framework

Introduces LangGraph as a multi-agent framework and defines the shared state, workflow structure, and coordination capabilities it provides.

Key terms: State, Nodes, Edges, Conditional edges, Cycle management, Error handling, Observability

8.1.3 Building intelligent agent coordination

This section explains how semantic intent analysis and conditional routing coordinate agents for different user queries.

Key terms: intelligent coordination, semantic understanding, function calling, conditional routing, LangGraph

8.1.4 Real-world example: ShopBot multi-agent system

ShopBot illustrates how a shopping assistant can coordinate specialized product-search and policy-answering agents, ground answers in company knowledge, and assign models according to task difficulty.

Key terms: SearchAgent, product search, MCP, QAAgent, RAG, business policies, grounded, LangGraph, orchestration, intent analysis

8.1.5 Running your multi-agent system

8.1.6 Adding vision: Image-based product search with VisionAgent

This section shows how ShopBot handles a product query that combines an image with text by turning the image into a caption and reusing its existing search workflow.

Key terms: multimodal query, captioning model, SearchAgent, AgentResponse, VisionAgent, captioning step, preprocessing step

8.1.7 What you built and why it matters

Summarizes ShopBot’s coordinated multi-agent architecture and explains why specialized agents are easier to extend and maintain than a monolithic system.

Key terms: LangGraph orchestrator, specialized agents, state management, synthesis step, modularity, scalability, reliability, maintainability, degrades gracefully

8.2 Testing multi-agent workflows

This section explains why multi-agent systems need end-to-end workflow tests and identifies five categories for checking their reliability and user experience.

Key terms: end-to-end tests, orchestration layer, state flows, integration points, blended queries, ambiguous intent, agent failure, state flow, regression testing

8.2.1 Category 1: Blended queries and multimodal interactions

This subsection explains what blended-query tests check when users combine visual input, text, and follow-up questions.

Key terms: blended query tests, orchestrator, specialized agents, critical context

8.2.2 Category 2: Ambiguous intent and robust routing decisions

This subsection explains what ambiguous-intent tests should check in a multi-agent system’s routing decisions.

Key terms: ambiguous queries, orchestrator, routing logic

8.2.3 Category 3: Agent failure and resilience verification

This section explains why multi-agent workflows should be tested for helpful responses when individual agents or infrastructure components fail.

Key terms: agent failure tests, resilience testing, degrading gracefully

8.2.4 Category 4: State flow and information preservation across the workflow

This section explains why multi-agent workflows need state flow tests to ensure user requirements survive every handoff.

Key terms: shared state, state flow tests, information preservation

8.2.5 Regression: Moving forward without breaking what worked

This section recommends rerunning multi-agent workflow tests as the system changes and adding a test for every discovered bug.

Key terms: regression, old flows, safety net

8.3 Alternative framework: CrewAI

Introduces CrewAI as a team-oriented alternative to LangGraph for building multi-agent systems.

Key terms: LangGraph, CrewAI, state, routing, roles, goals

8.3.1 LangGraph vs. CrewAI: Different philosophies

This section contrasts LangGraph’s explicit workflow design with CrewAI’s role-based agent collaboration and explains the control-versus-convenience tradeoff.

Key terms: LangGraph, CrewAI, states, nodes, and edges, roles, goals, and backstories, routing logic

8.3.2 ShopBot with CrewAI

The section outlines the steps for rebuilding a simplified ShopBot with CrewAI.

Key terms: ShopBot, CrewAI, tools, agents, tasks, crew

8.3.3 When to use which multi-agent framework

This section explains how workflow complexity, team preferences, and desired control guide the choice between LangGraph and CrewAI.

Key terms: LangGraph, CrewAI, explicit graph structure, cycles, role-based approach

8.3.4 The framework landscape

This section surveys other multi-agent frameworks and argues that choosing a tool matters less than understanding reusable coordination patterns.

Key terms: mental model, requirements, framework, intent analysis, agent specialization, state management, error handling, response synthesis, AutoGen, Agency Swarm

8.4 Summary

Where this is used later

Concepts explained in this chapter

← Chapter 7: Tool integration and MCP Chapter 9: Evaluation and performance for LLMs and agents →

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.