In this clip we unpack a powerful pattern used in modern agent systems: dedicated research sub-agents. Instead of the main agent calling a search tool directly, it delegates to a focused research agent that runs many searches (often in parallel), filters noise, condenses findings, and returns a clean report back to the main agent.
The result? Sharper context, less clutter, better answers. This is context engineering in action.
What you’ll learn
The delegation pattern: Main agent → research sub-agent → summarized report.
Why it works: Sub-agents see only the current task, so their context is laser-focused.
Cleaner inputs for the main agent: It gets the distilled report—not every noisy intermediate result.
Parallel search → single brief: Run wide, then compress into a tight artifact the main agent can use.
When to use it: Deep research, due diligence, competitive analysis, literature sweeps, market scans.
Known trade-offs: The main agent loses visibility into “how” results were gathered unless you record artifacts or attach citations.
Architecture at a glance
Task framing: Main agent creates a research brief (objective, scope, constraints, deliverable format).
Sub-agent execution: Research agent runs searches, clusters sources, extracts signals, takes notes.
Synthesis: Research agent produces a structured report (key findings, evidence, gaps, next steps).
Handoff: Report returns to the main agent as a single tool result or file reference for the next decision.
Best practices (copy/paste into your system prompt or spec)
Define the brief: topic, must-answer questions, inclusion/exclusion rules, time window, regions, required citations.
Require artifacts: notes.jsonl, sources.csv, report.md—so you don’t lose traceability.
Scoring & filtering: prefer primary sources; rank by credibility, recency, corroboration.
Structure the output: Summary → Evidence → Contradictions → Risks → Open Questions → References.
Budget & limits: cap queries, pages fetched, and tokens; allow the sub-agent to request an extension with reasons.
Citations: enforce URL + title + date for each claim; flag unverified statements.
Common pitfalls & fixes
Pitfall: Main agent asks vague questions → weak research.
Fix: Template the brief with explicit questions and acceptance criteria.
Pitfall: Sub-agent returns a wall of text.
Fix: Mandate a schema or headings; reject responses that omit sources.
Pitfall: Lost transparency.
Fix: Always return an appendix with search trails and discarded leads.
Pitfall: Redundant searches.
Fix: De-dupe by domain/title; cache recent queries and reuse notes.
Minimal research brief template
Goal: What decision will this research inform?
Scope: Topic, timeframe, geography, depth.
Must answer: 3–5 concrete questions.
Deliverable: Markdown report with sections + references.
Constraints: Time/budget limits, allowed sources, language.
Definition of done: Rubric (e.g., ≥8 credible sources, conflicting views addressed, risks listed).
Информация по комментариям в разработке