katas-human-handoff-protocol

Escalates agent tasks to humans with a typed, self-contained JSON handoff payload.

Updated Jun 28, 2026
One-click install
npx skills add https://github.com/JaviMontano/claude-plugins --skill katas-human-handoff-protocol-javimontano
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: katas-human-handoff-protocol
Source: https://github.com/JaviMontano/claude-plugins/tree/main/plugins/claude-native-toolkit/skills/katas-human-handoff-protocol
Command: npx skills add https://github.com/JaviMontano/claude-plugins --skill katas-human-handoff-protocol-javimontano

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? When an AI agent hits a policy limit, an irreversible action, or an unresolvable data conflict, continuing to chat or dumping a raw transcript on a human operator wastes time and creates ambiguity. This Skill defines a strict escalation protocol: the agent calls escalate_to_human, stops generating prose, and emits a typed payload the operator can act on immediately. ## Core Features & Use Cases - Escalation Preconditions: Detects the three canonical triggers for handoff — limit exceeded, irreversible action, and data conflict — rather than escalating on generic uncertainty. - Typed Handoff Payload: Emits a fixed five-field JSON payload (customer_id, issue_summary, actions_taken, escalation_reason, recommended_action) that is fully self-contained. - End-State Loop Termination: Treats the handoff as the end of the agent loop, enforceable via a PostToolUse hook that closes the session after escalation. - Use Case: A customer requests a USD 2,400 refund but the agent's tier-2 limit is USD 1,000. The agent detects the limit breach, calls escalate_to_human with the complete case payload, and terminates the loop instead of continuing the conversation. ## Quick Start Escalate this refund case to a human operator using the typed handoff payload because the amount exceeds the agent's policy limit.

Frequently Asked Questions about katas-human-handoff-protocol

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I escalate an agent task to a human with a structured payload?▼

Detect the escalation precondition, then call the escalate_to_human tool with five fixed fields: customer_id, issue_summary, actions_taken, escalation_reason, and recommended_action. Stop generating prose immediately after the tool call so the loop ends.

When should an AI agent hand off to a human operator?▼

Handoff is triggered by three preconditions: a policy limit is exceeded (such as a refund above the agent's tier), the requested action is irreversible, or there is a data conflict the agent cannot arbitrate. Generic uncertainty is not a valid trigger.

What fields should a human handoff payload contain?▼

The payload contains exactly five fields: customer_id, issue_summary, actions_taken, escalation_reason, and recommended_action. It must be self-contained so the operator can decide without reading the prior conversation.

How do I stop an agent from continuing after escalation?▼

Treat the handoff as an end-state, not a pause. A PostToolUse hook can terminate the session after escalate_to_human succeeds, preventing any additional prose or tool calls until a human resolves the case.

Why is sending a raw transcript to a human operator a bad pattern?▼

A raw transcript forces the operator to read the entire conversation and reconstruct context under pressure. A typed, self-contained payload delivers an actionable case with the reason and recommended action, reducing resolution time and ambiguity.