Skip to content

GH-600 · Domain 5: Orchestrate multi-agent coordination · 18% of the exam

Task 5.3: Detect and respond to multi-agent failures and degraded behavior

Spotting failed, partial or stalled agent runs, responding when coordination degrades, and recovering with rollback and human review.

Study it

  • Failed, partial and stalled agent runs, and recovery with rollback and human review

    Lesson coming

Sample questions

Try each one before opening the answer. Every option is explained, with the GitHub documentation page that proves it.

Question 1 · choose 1

In an SDK app, a specialist sub-agent occasionally errors out, and users just see the main response stop making sense. What does GitHub recommend the app do?

  1. ARely on the runtime, which retries failed sub-agents automatically until they succeed
  2. BWait for subagent.deselected, which only fires when a sub-agent fails
  3. CSet infer: false on the specialist so it can never fail
  4. DListen for subagent.failed and retry, show the error, or fall back to the parent agent
Show the answer and why
  • ARely on the runtime, which retries failed sub-agents automatically until they succeed

    Incorrect

    Handling failures is the app's job; GitHub tells you to listen for subagent.failed.

  • BWait for subagent.deselected, which only fires when a sub-agent fails

    Incorrect

    deselected means the runtime switched away from the sub-agent; failures arrive as subagent.failed.

  • CSet infer: false on the specialist so it can never fail

    Incorrect

    infer controls automatic selection; it has nothing to do with failures.

  • DListen for subagent.failed and retry, show the error, or fall back to the parent agent

    Correct

    Sub-agents can fail, and the app should handle subagent.failed events.

Sub-agents can fail, so GitHub's best practice is to listen for subagent.failed events, which carry the agent name and error, and handle them in your application: show the error in the UI, retry, or fall back to the parent agent. Other lifecycle events are subagent.selected, started, completed and deselected.

Question 2 · choose 1

In a fleet run, one sub-agent can't finish its todo because a required credential is missing. The team wants the orchestrator to see this clearly instead of the todo silently staying in progress. What does fleet's coordination model call for?

  1. AThe sub-agent sets the todo's status to blocked and records why
  2. BThe sub-agent marks the todo done so the run can finish
  3. CThe sub-agent deletes the todo so others don't pick it up
  4. DThe sub-agent claims another ready todo and leaves this one in progress
Show the answer and why
  • AThe sub-agent sets the todo's status to blocked and records why

    Correct

    A sub-agent that can't proceed sets status = 'blocked' and includes the reason.

  • BThe sub-agent marks the todo done so the run can finish

    Incorrect

    done is for completed work; marking it done hides the failure.

  • CThe sub-agent deletes the todo so others don't pick it up

    Incorrect

    Todos stay in the shared state; blocked records the problem.

  • DThe sub-agent claims another ready todo and leaves this one in progress

    Incorrect

    Leaving the stuck todo in progress hides the problem from the orchestrator; blocked with a reason shows it.

Fleet mode coordinates through explicit todo state shared with the orchestrator. A sub-agent that can't proceed sets its todo's status to blocked and includes the reason, so the orchestrator can see what is ready, running, complete or blocked.

Question 3 · choose 1

In autopilot mode, what does Copilot CLI do if the model stops working without signalling that the task is complete?

  1. AIt injects a message nudging the model to continue or mark the task complete
  2. BIt ends the session and reports success
  3. CIt rolls back the changes made so far
  4. DIt asks the user to approve stopping
Show the answer and why
  • AIt injects a message nudging the model to continue or mark the task complete

    Correct

    The CLI tracks task_complete in autopilot and nudges the model when the loop ends without it.

  • BIt ends the session and reports success

    Incorrect

    The CLI nudges the model rather than treating the stop as success.

  • CIt rolls back the changes made so far

    Incorrect

    Nothing is rolled back; the model is nudged to continue.

  • DIt asks the user to approve stopping

    Incorrect

    In autopilot there is no prompt; the CLI injects a nudge.

In autopilot mode the CLI tracks whether the model has called task_complete. If the tool-use loop ends without it, the CLI injects a synthetic user message telling the model it hasn't marked the task complete and should keep working, which restarts the loop. In interactive mode there is no such nudge.

Question 4 · choose 1

Under Copilot cloud agent, which reasons does a sessionEnd hook typically receive?

  1. Aabort or user_exit
  2. Bapproved or rejected
  3. Cmerged or closed
  4. Dcomplete, error or timeout
Show the answer and why
  • Aabort or user_exit

    Incorrect

    These aren't expected, because there is no user.

  • Bapproved or rejected

    Incorrect

    Those aren't sessionEnd reasons.

  • Cmerged or closed

    Incorrect

    Those describe pull requests, not sessions.

  • Dcomplete, error or timeout

    Correct

    With no user present, these are the reasons expected under cloud agent.

Under cloud agent, sessionEnd fires once per job. Its reason is typically "complete", "error" or "timeout"; "abort" and "user_exit" are not expected because there is no user. Use it to clean up or report how a job ended.

Question 5 · choose 1

What happens if a response is in progress when a Copilot CLI session reaches its AI credit limit?

  1. AThe response is cut off immediately, at the exact credit where the limit is reached
  2. BThe response is rolled back
  3. CThe response completes, so usage can slightly exceed the limit
  4. DThe limit doubles automatically
Show the answer and why
  • AThe response is cut off immediately, at the exact credit where the limit is reached

    Incorrect

    Limits are soft, so the response completes.

  • BThe response is rolled back

    Incorrect

    Nothing is rolled back; the session stops after the response.

  • CThe response completes, so usage can slightly exceed the limit

    Correct

    Session limits are soft; an in-progress response finishes before the session stops.

  • DThe limit doubles automatically

    Incorrect

    You are prompted to reset it in interactive mode.

An AI credit session limit caps what Copilot can spend in a session; each credit is $0.01. Limits are soft: a response in progress completes, so usage may slightly exceed the limit, and limits must be at least 30 credits. In interactive mode you are prompted to reset the limit.

Question 6 · choose 1

A script runs copilot -p with an AI credit session limit set on the command line. What happens when the limit is reached?

  1. AIt pauses for someone to raise the limit
  2. BThe run ends
  3. CIt switches to a cheaper model
  4. DIt ignores the limit for the rest of the task
Show the answer and why
  • AIt pauses for someone to raise the limit

    Incorrect

    Prompting to reset happens in interactive mode.

  • BThe run ends

    Correct

    In non-interactive mode the run ends when the limit is reached.

  • CIt switches to a cheaper model

    Incorrect

    There is no automatic model switch.

  • DIt ignores the limit for the rest of the task

    Incorrect

    The limit stops the run.

When an AI credit session limit is reached, the agent stops cleanly and tells you. In interactive mode you are prompted to raise the limit with /limits set and continue; in non-interactive mode, the run ends.

Practise domain 5 →Practise all domains →