context-handoff
Use when writing or resuming a bounded repository handoff across agent sessions or hosts, including checking saved task state for staleness.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when writing or resuming a bounded repository handoff across agent sessions or hosts, including checking saved task state for staleness.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Use when creating or editing a plugin for a multi-host GitHub Copilot / APM / Claude Code marketplace — required manifests, the plugin.json ⇆ apm.yml mirroring rule, portable env-var and install conventions, component layout, and the catalog entry.
Use when every unit of a corpus must be accounted for rather than merely searched — auditing a document set, log archive, or file tree with provable coverage and gaps split into truly absent versus undecidable.
Use when searching source code: text/regex (ripgrep), structural/AST patterns (ast-grep, semgrep), symbol definitions/references/callers (LSP, GNU Global, ctags), when/why code changed (git history), structural rewrites (comby), or size/complexity (tokei, scc).
Use when searching non-code corpora: query JSON/YAML/config (jq, yq, gron), tabular data files (duckdb, sqlite-utils), or content inside PDFs/Office/archives (rga, pandoc, pdftotext).
Use when deciding WHERE a piece of guidance should live — always-on memory (CLAUDE.md / AGENTS.md), a path-scoped rule, an on-demand skill, a subagent, an MCP server, or a deterministic hook — and how to keep the always-on budget small.
Use for semantic search over a markdown corpus when keywords aren't enough (you know the meaning, not the exact words), or hybrid semantic plus lexical search when both meaning and exact terms matter. Index once, then query.
| name | context-handoff |
| description | Use when writing or resuming a bounded repository handoff across agent sessions or hosts, including checking saved task state for staleness. |
| license | MIT |
| metadata | {"author":"Mark Beacom","version":"0.2.0"} |
| allowed-tools | Read Grep Glob Bash Write |
Create a small, explicit bridge between sessions rather than trying to preserve an entire transcript. Capture only the task state another agent needs to make the next correct move, then bind every claim to repository provenance and verification state.
Treat the handoff as an exchange artifact, not as native session persistence.
Do not imply that it restores hidden reasoning, tool state, model memory, or the
original runtime. Do not automatically ingest it into RAG or durable memory.
When a user separately requests historical retention, validate freshness first,
then use the memory plugin's explicit /archive-handoff workflow. The archived
copy remains historical evidence, not authoritative current task state.
Resolve the destination in this order:
CONTEXT_KIT_HANDOFF_PATH when set..context-kit/handoff.md relative to the repository root.Resolve relative override paths from the repository root. Allow an absolute
override only when it was explicitly configured. Keep the default inside the
repository so it can move with the worktree when desired; let each repository
decide whether .context-kit/ belongs in version control.
Prefer /write-handoff where plugin commands are available. Otherwise apply
the same flow manually:
verify-before-trust to claims that affect the next agent's behavior.
Delegate a larger claim set to the verifier subagent instead of inventing a
parallel verification taxonomy.handoff-compiler subagent to compile the gathered inputs. Keep that
subagent read-only; let the main agent persist its returned Markdown.references/handoff-contract.md and templates/handoff.md.scripts/validate-handoff.py and fix every structural error before
considering the handoff complete.Keep each section concise. Use - None. rather than omitting an empty category.
Never convert assumptions into verified facts merely to make the artifact look
complete.
Prefer /resume-handoff where available. Before acting on any saved state:
verify-before-trust or the verifier subagent.Never silently trust a structurally valid artifact. Structure proves only that the fields exist; freshness and evidence determine whether the content remains usable.
file:line evidence, or — for a result actually
observed — the observation source plus its artifact pointer. A bare command
name is not evidence.not run or blocked
explicitly where applicable.unable-to-check with the observation that would settle it, or cite an
observation actually collected through runtime-evidence.PreCompact, SessionEnd, or SessionStart hooks to this handoff
workflow. Manual commands are the source of authority. Optional lifecycle
capture belongs to the separate memory plugin and cannot change handoff
authority.references/handoff-contract.md — exact schema, limits, and section rules.references/resume-safety.md — mismatch and staleness decision table.templates/handoff.md — canonical artifact template.../../scripts/validate-handoff.py — deterministic artifact validator.