Aggregator
Agents contribute specialized outputs that are collected and synthesized by an aggregator agent into a single, well-formatted result.
Overview
Reach for this pattern when multiple agents (or tools) produce complementary information and you want a unified summary. Executive briefings, dashboards, and cross-team status reports are common fits.
Demo Scenario: Daily Briefing Synthesizer
This runnable example assembles a morning briefing by combining three specialists using gllm-pipeline for orchestration:
Time & calendar agent – pulls the current time and today's events
Weather agent – reports the local forecast
Synthesizer agent – stitches everything together into a friendly briefing
Specialists run in parallel for faster execution, and their outputs are merged and passed to the synthesizer. Each specialist uses a mock tool that returns static values so the demo works out of the box; swap the tools for real integrations to connect to live data.
Diagram
Implementation Steps
Create specialist agents with tools
Build pipeline: parallel specialists → merge → synthesize
Run the pipeline
Full implementation: See
aggregator/main.pyfor complete code with State definition and helper functions.AgentComponent: See the Agent as Component guide for details on the
.to_component()pattern.
How to Run
From the gl-aip/examples/multi-agent-system-patterns directory in the GL SDK Cookbook:
Ensure your .env contains:
Output
Notes
This example uses gllm-pipeline for orchestrating the multi-agent workflow with parallel execution.
Replace the mock tool scripts under
aggregator/tools/with real integrations to connect to live systems.Add more specialists (finance, news, incidents) by adding more branches to the
parallel()step.Combine this pattern with a router or scheduler for automated briefings.
To install gllm-pipeline:
uv add gllm-pipeline-binary==0.4.13(compatible with aip_agents and langgraph <0.3.x)
Related Documentation
Agents guide — Configure agent instructions and manage lifecycles.
Tools guide — Upload Python tools and reference their IDs.
Automation & scripting — Schedule or orchestrate the aggregator run in CI.
Security & privacy — Apply PII masking or output-sharing policies when aggregating data.
Last updated
Was this helpful?