Skip to content
Microsoft Certified: Multi-Agent AI Solutions Expert (AI-500) Exam Prep

Lesson 5 of 10 · 14 min

x
5/10

Domain 2: Develop Multi-Agent Solutions in Azure (Part 3 of 4)

This lesson covers 4 exam topics: Tool Errors, Fallbacks and Result Validation, Multi-Agent Orchestration Patterns, Human-in-the-Loop Processes, Caching Strategies for Agents. Each topic has a short video, then the notes: key facts, exam traps and what to check in the official docs.

1. Tool Errors, Fallbacks and Result Validation

Video lesson: AI-500 18/39: Tool Errors, Fallbacks and Result Validation

Central question: What happens when a tool fails or returns bad data?

Facts (verified and design guidance)

  • Foundry process evaluators measure tool call success (no technical errors), tool input accuracy, tool selection and tool output utilization.
  • Agent Framework middleware is the natural place for error handling, retry logic and graceful degradation; function-calling middleware can inspect and modify tool inputs and outputs.
  • Guardrails can scan tool responses (preview) for risks such as indirect prompt injection.

Design guidance

  • Classify errors: transient (retry with backoff and limits), invalid input (ask the model to correct arguments), permanent (fall back to another tool or a person).
  • Validate tool results against a schema and business rules (ranges, required fields, freshness) before the agent uses them; return structured errors the model can reason about.
  • Use circuit breakers and timeouts so one failing tool can't stall a workflow.

Exam traps

  • Unlimited retries on a failing tool.
  • Passing raw tool errors or untrusted tool text straight to users.
  • Trusting tool output without validation.

2. Multi-Agent Orchestration Patterns

Video lesson: AI-500 19/39: Multi-Agent Orchestration Patterns

Central question: Which orchestration pattern fits the problem?

Facts

Agent Framework patternTopologyUse
SequentialPipelineOrdered steps, each building on the last
ConcurrentFan-out, aggregateIndependent perspectives in parallel
HandoffMesh, no orchestratorTransfer full control to the right specialist
Group chatStar, orchestrator picks speakerIterative refinement with shared context
MagenticManager plans and delegatesComplex open-ended tasks
  • Handoff vs agent-as-tools: in handoff, the receiving agent takes full ownership and context; in agent-as-tools, a primary agent keeps responsibility and calls others as tools (orchestrator-subagent).
  • Group chat speaker selection: round-robin, prompt-based or custom; Magentic adds a planning manager (based on Magentic-One) and supports human plan review.
  • Orchestrations support HITL through tool approval and request info.

Design guidance

  • Map study-guide names: hub-and-spoke = group chat or orchestrator-subagent; parallel = concurrent; peer-to-peer = handoff.

Exam traps

  • Magentic for a simple fixed pipeline. Use sequential.
  • Handoff when the main agent must keep ownership. Use agent-as-tools.
  • Sequential for independent analyses. Use concurrent.

3. Human-in-the-Loop Processes

Video lesson: AI-500 20/39: Human-in-the-Loop Processes

Central question: How do people approve, override and handle edge cases?

Facts

  • Agent Framework: approval-required function tools; workflow RequestPort for human input; Magentic plan review.
  • Foundry MCP tool require_approval returns an approval request; your app sends an approval response before the call runs.
  • Long-running hosted agents (preview) can suspend a multi-turn task and resume on the same task_id when a person replies, surviving restarts; the wait can last minutes to days.
  • The Durable Extension lets agents pause for human input or external events without consuming compute or tokens while waiting.

Design guidance

  • Approval UX: show the proposed action, inputs and impact; allow approve, reject or edit (override); log who decided.
  • Route low-confidence or policy edge cases to a person; set timeouts and escalation for unanswered approvals.

Exam traps

  • Holding a request open while waiting for a person.
  • Approval for every action (fatigue). Reserve it for high-risk actions.
  • No audit trail of approvals.

4. Caching Strategies for Agents

Video lesson: AI-500 21/39: Caching Strategies for Agents

Central question: Which cache: prompt, semantic or response?

Facts

CacheWhereHits when
Prompt cachingModel serviceIdentical prompt prefix (at least 1,024 tokens)
Semantic cachingAPI Management (llm-semantic-cache-lookup/store) with Azure Managed Redis + RediSearch and an embeddings deploymentSimilar prompts within a score threshold
Response cachingYour app or gatewayExact repeat requests (design guidance)
  • Prompt caching discounts cached input tokens on Standard deployments and up to 100% on Provisioned; put static content (instructions, tools, documents) first.
  • On GPT-5.6 and later: prompt_cache_key improves matching (beyond about 15 requests per minute per key-prefix, spread across keys); explicit cache breakpoints; cache writes can be charged.
  • Semantic cache vary-by (for example subscription ID) partitions the cache; RediSearch can be enabled only when creating the Redis cache.

Exam traps

  • Variable content at the start of the prompt, breaking prefix caching.
  • Semantic cache shared across tenants without vary-by.
  • Adding RediSearch to an existing cache. Only at creation.

References

  1. AI-500 study guide — checked Oct 22, 2026
  2. Agent evaluators — checked Oct 22, 2026
  3. Middleware exception handling — checked Oct 22, 2026
  4. Guardrails overview — checked Oct 22, 2026
  5. Orchestrations overview — checked Oct 22, 2026
  6. Handoff — checked Oct 22, 2026
  7. Group chat — checked Oct 22, 2026
  8. Magentic — checked Oct 22, 2026
  9. Workflows HITL — checked Oct 22, 2026
  10. Tool approval — checked Oct 22, 2026
  11. Add HITL approval (hosted) — checked Oct 22, 2026
  12. Durable Extension — checked Oct 22, 2026
  13. Prompt caching — checked Oct 22, 2026
  14. Semantic caching in API Management — checked Oct 22, 2026

Check your understanding

  • Measure whether tool calls errored?Show answer

    Answer

    Tool call success evaluator.
  • Specialist takes over the conversation?Show answer

    Answer

    Handoff.
  • Pause days for a manager's approval?Show answer

    Answer

    Durable/long-running pause and resume.
  • Reuse long identical instructions cheaply?Show answer

    Answer

    Prompt caching.
  • Central retry logic?Show answer

    Answer

    Middleware.
Previous

Progress is saved in this browser.

Next Lesson