cross-agent-handoff

Transfer context between AI agent sessions with structured handoff protocols, state serialization, and decision log preservation. Covers multi-agent coordination, context compression, and continuity patterns. Triggers on agent handoff, session transfer, or multi-agent continuity requests.

Best use case

cross-agent-handoff is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Transfer context between AI agent sessions with structured handoff protocols, state serialization, and decision log preservation. Covers multi-agent coordination, context compression, and continuity patterns. Triggers on agent handoff, session transfer, or multi-agent continuity requests.

Teams using cross-agent-handoff should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/cross-agent-handoff/SKILL.md --create-dirs "https://raw.githubusercontent.com/organvm-iv-taxis/a-i--skills/main/distributions/claude/skills/cross-agent-handoff/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/cross-agent-handoff/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How cross-agent-handoff Compares

Feature / Agentcross-agent-handoffStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Transfer context between AI agent sessions with structured handoff protocols, state serialization, and decision log preservation. Covers multi-agent coordination, context compression, and continuity patterns. Triggers on agent handoff, session transfer, or multi-agent continuity requests.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Cross-Agent Handoff

Transfer work between agent sessions without losing context, decisions, or progress.

## The Handoff Problem

When an agent session ends (context limit, task change, timeout), work must continue. Without a structured handoff, the next agent:

- Re-explores already-understood code
- Re-makes already-decided decisions
- Contradicts previous agent's approach
- Misses critical constraints discovered earlier

## Handoff Document Structure

```markdown
# Agent Handoff: {task-name}

**From:** Session {id} | **Date:** {date} | **Phase:** {current-phase}

## Current State
{What exists right now — files created, branches, test status}

## Completed Work
{What was accomplished, with evidence}
- [x] Created skills/development/python-packaging-patterns/SKILL.md
- [x] Created skills/development/cli-tool-design/SKILL.md
- [ ] Wave 1 skills (not started)

## Key Decisions
{Decisions made and WHY — so next agent doesn't re-litigate}
| Decision | Rationale |
|----------|-----------|
| Used governance_norm_group: repo-hygiene for packaging skills | Packaging is infrastructure hygiene, not quality-gate |
| Put data-backup-patterns in development/ not security/ | It's an engineering pattern, security-baseline applies via norm_group |

## Critical Context
{Non-obvious information the next agent needs}
- The ecosystem.yaml shows 130+ skills target, currently at 101
- Governance metadata format: governance_phases, governance_norm_group, organ_affinity, triggers, complements
- Bundle skills use `includes:` field listing constituent skill names

## Next Actions
{Exactly what to do next, no ambiguity}
1. Create Wave 1 skills: fastapi-patterns, database-migration-patterns, ...
2. After all waves: run refresh_skill_collections.py
3. Then validate with validate_skills.py --collection example --unique

## Risks & Warnings
{Things that could go wrong}
- Skill name must match directory name exactly
- .build/ artifacts must be refreshed after skill changes
- 16GB RAM constraint: max 4-6 concurrent agents
```

## Context Compression

### Summarization Levels

| Level | Token Budget | Content |
|-------|-------------|---------|
| **Full** | Unlimited | Complete handoff document |
| **Standard** | ~2000 tokens | State + Decisions + Next Actions |
| **Minimal** | ~500 tokens | Current state + Next action only |
| **Emergency** | ~100 tokens | "Continue from step X of plan Y" |

### Compression Strategy

```python
def compress_handoff(handoff: dict, target_tokens: int) -> str:
    if target_tokens > 2000:
        return format_full_handoff(handoff)
    elif target_tokens > 500:
        return format_standard_handoff(handoff)
    elif target_tokens > 100:
        return f"""
Continue {handoff['task']}. Phase: {handoff['phase']}.
Completed: {', '.join(handoff['completed'][:5])}.
Next: {handoff['next_actions'][0]}.
Key constraint: {handoff['constraints'][0]}.
"""
    else:
        return f"Continue {handoff['task']} from step {handoff['next_step']}. Plan: {handoff['plan_path']}"
```

## Multi-Agent Coordination

### Parallel Agent Handoff

When multiple agents work simultaneously:

```yaml
coordination:
  task: "Skill Fortification Campaign"
  agents:
    - id: agent-a
      scope: "Stream A: Engineering Infrastructure"
      owns: [skills/development/*-patterns/]
      status: in_progress

    - id: agent-b
      scope: "Stream B: Governance & Process"
      owns: [skills/tools/*, skills/documentation/*]
      status: in_progress

  shared_state:
    completed_skills: ["A1", "A2", "A3"]
    pending_skills: ["A4", "A5", "A6"]

  conflict_zones:
    - path: .build/skills-registry.json
      rule: "Only one agent refreshes at a time"
    - path: ecosystem.yaml
      rule: "Coordinate updates"
```

### Conflict Prevention

```python
OWNERSHIP_RULES = {
    "exclusive": "Only one agent modifies this path",
    "append_only": "Multiple agents can add, none can modify existing",
    "coordinator_only": "Only the coordinator agent modifies this",
}

def check_conflict(agent_id: str, file_path: str, agents: list[dict]) -> bool:
    for agent in agents:
        if agent["id"] != agent_id and file_path in agent.get("owns", []):
            return True  # Conflict
    return False
```

## Handoff Triggers

| Trigger | Action |
|---------|--------|
| Context window 80% full | Start compression, prepare handoff |
| Task phase complete | Write handoff document at phase boundary |
| Error threshold exceeded | Handoff with error log and attempted fixes |
| Time limit approaching | Save state and produce next-actions list |
| Explicit user request | Full handoff with all context |

## Recovery Patterns

### From Incomplete Handoff

```markdown
## Recovery Protocol

1. Read the last handoff document
2. Verify current file system state matches "Current State"
3. If mismatch: investigate git log for changes since handoff
4. Re-verify key decisions still hold
5. Continue from "Next Actions"
```

### From Missing Handoff

```markdown
## Cold Start Protocol

1. Read the plan file (.claude/plans/*)
2. Check git log for recent session activity
3. Inventory what exists vs what the plan requires
4. Infer current progress from file existence
5. Ask user to confirm before continuing
```

## Anti-Patterns

- **No handoff document** — Every session that might continue must produce one
- **Handoff without decisions** — Raw state is useless without rationale
- **Over-compressed context** — Better to have a verbose handoff than lose critical context
- **Handoff to file only** — Also summarize in conversation so user has visibility
- **No conflict zones** — Parallel agents will corrupt shared state without coordination
- **Assuming continuous context** — Always verify state at session start

Related Skills

taxonomy-modeling-design

5
from organvm-iv-taxis/a-i--skills

Phase 2 of the pentaphase structural-overhaul protocol. Classifies entities, standardizes attributes, establishes relationships, and designs the access framework. Use when the user invokes phase 2 of an overhaul, asks to "design the taxonomy" or "model the structure", or has completed a landscape audit and is ready to redesign. Consumes phase-1-landscape-report.md; produces phase-2-taxonomy-model.md.

systemic-ingestion-normalization

5
from organvm-iv-taxis/a-i--skills

Phase 4 of the pentaphase structural-overhaul protocol. Purges redundancies, enriches and aligns legacy entities to the new schema, executes phased ingestion into the new environment, and audits integrity. Use when the user invokes phase 4 of an overhaul, asks to "migrate the data" or "ingest into the new system", or has a configured environment ready to accept legacy entities. Consumes phase-3-environment-spec.md; produces phase-4-ingestion-report.md.

system-environment-configuration

5
from organvm-iv-taxis/a-i--skills

Phase 3 of the pentaphase structural-overhaul protocol. Translates the taxonomy model into objective technical criteria, evaluates candidate mechanisms or frameworks, instantiates the chosen architecture, and programs validation rules. Use when the user invokes phase 3 of an overhaul, asks to "select a system" or "configure the environment", or has a taxonomy model and is ready to choose technology. Consumes phase-2-taxonomy-model.md; produces phase-3-environment-spec.md.

pentaphase-orchestrator

5
from organvm-iv-taxis/a-i--skills

Threads the full five-phase structural-overhaul protocol — landscape discovery, taxonomy design, environment configuration, systemic ingestion, governance evolution — for any substrate the user names. Use when the user requests a structural overhaul, system redesign, or end-to-end restructuring of a documentation system, asset registry, code monorepo, knowledge base, or operational workflow; or when they explicitly invoke the pentaphase methodology. Coordinates handoffs between phase-skills and seats validation gates between phases.

landscape-discovery-audit

5
from organvm-iv-taxis/a-i--skills

Phase 1 of the pentaphase structural-overhaul protocol. Inventories assets, maps current flow, identifies friction, and defines value metrics for any substrate. Use when the user invokes phase 1 of an overhaul, requests a baseline audit, asks to "discover the landscape" of a system, or wants to understand current state before redesigning. Produces phase-1-landscape-report.md.

governance-evolution-protocol

5
from organvm-iv-taxis/a-i--skills

Phase 5 of the pentaphase structural-overhaul protocol. Codifies operational protocols, onboards the ecosystem of participants, programs behavior monitoring, and establishes an iteration cadence so the substrate evolves rather than calcifies. Use when the user invokes phase 5 of an overhaul, asks to "establish governance" or "lock in the protocols", or has completed ingestion and is ready to declare the substrate operational. Consumes phase-4-ingestion-report.md; produces phase-5-governance-charter.md, which closes the protocol.

dimension-surfacing

5
from organvm-iv-taxis/a-i--skills

Surfaces the parallel domain dimensions implicit in a dense or minimal prompt. Use when a user prompt is small on the surface but plainly implies multiple independent domains needing different expertise; when explicitly invoked by the coliseum-orchestrator skill as Phase 1; or when the user asks "what dimensions does this prompt encode" or "what axes does this break into." Produces a named dimension set where each dimension is independently executable and not a paraphrase of another.

coliseum-dispatch

5
from organvm-iv-taxis/a-i--skills

Dispatches a composed set of assignment envelopes to domain-expert subagents in parallel, in a single message with multiple Agent tool calls. Enforces the no-pingpong gate via the pingpong-detector agent before any dispatch fires. Use when invoked by the coliseum-orchestrator as Phase 3; when envelopes are already composed and the next step is parallel execution; or when the user asks to "fan out" or "dispatch in parallel." Produces a dispatch log capturing what was sent, when, and where returns land.

assignment-composition

5
from organvm-iv-taxis/a-i--skills

Wraps each surfaced dimension as a self-contained 9-section autonomous-work-assignment envelope — scope, context, success criteria, allowed tools, return format, handoff — all the recipient subagent needs to execute without coming back. Use when invoked by coliseum-orchestrator as Phase 2; when dimensions are named and the next step is to make each independently dispatchable; or when the user asks "compose this as an assignment." The no-pingpong gate validates each envelope before dispatch.

workspace-autopsy-governance

5
from organvm-iv-taxis/a-i--skills

Conducts a full automated autopsy of the current workspace directory to map files, identifies structural issues, proposes a restructuring plan (the signal), and establishes unified governance using templates. Use this skill when a user asks to map, restructure, reorganize, or apply new governance to an existing messy repository.

workshop-presentation-design

5
from organvm-iv-taxis/a-i--skills

Design engaging workshops, conference talks, and educational presentations. Covers learning objectives, activity design, slide craft, and facilitation techniques. Triggers on workshop design, presentation prep, talk structure, or training session requests.

webhook-integration-patterns

5
from organvm-iv-taxis/a-i--skills

Designs reliable webhook systems with proper delivery guarantees, retry logic, signature verification, and idempotent processing for event-driven integrations.