agent-continuity
H-13 long-running agent harness continuity per §26 v1.11. When a CL exceeds a single agent context window, the initializer agent writes a continuation artifact at `.claude-tdd-pro/agent-continuations/<session_id>.json` and the incremental successor agent reads it at startup to resume from `next_action` without losing the §2.15 workflow state envelope.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-09
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- agent-continuity
- description
- H-13 long-running agent harness continuity per §26 v1.11. When a CL exceeds a single agent context window, the initializer agent writes a continuation artifact at `.claude-tdd-pro/agent-continuations/<session_id>.json` and the incremental successor agent reads it at startup to resume from `next_action` without losing the §2.15 workflow state envelope.
03 SKILL.md 正文
agent-continuity — H-13 / v1.11 §26
Architecture §11 H-13: "Long-running agent harness continuity (§2.27).
When a single CL exceeds an agent's context window, the harness writes
a continuation artifact at
.claude-tdd-pro/agent-continuations/<session_id>.json."
Schema (§2.27 verbatim)
{
"parent_session_id": "<id>",
"parent_cl_id": "<id>",
"current_phase": "<phase-id>",
"completed_steps": [
{ "step_id": "<id>", "completed_at": "<iso>", "summary": "<text>" }
],
"pending_steps": [
{ "step_id": "<id>", "queued_at": "<iso>", "prerequisite_ids": ["<id>"] }
],
"context_summary": "<= 500 char",
"last_tool_calls": [
"<= 10 entries"
],
"next_action": { "action": "<text>", "rationale": "<text>" }
}
Substrate
commands/agent-continuity.sh provides three subcommands:
--write— initializer writes the artifact at session boundary--read— successor reads + validates the parent_session_id--purge-stale— TTL purge (24h since last write; per §2.27)
Invariants
- Parent session must be active.
--readvalidates thatparent_session_idreferences an envelope in.claude-tdd-pro/workflow-state.json(§2.15). Stale parent → refuse. - No contract-relaxation. Resumption preserves §2.23 lock-section ownership, §2.7 source-folder ownership, and §2.25 vocabulary fidelity. The artifact is a context-window-crossing mechanism, not an escape hatch.
- 24-hour TTL. Stale artifacts are stale state, not historical
record. Purge daily via
--purge-stale --now <iso>.
Cross-references
- §2.27 — the contract surface
- §2.15 — workflow state envelope (the
_resumableblock) - §2.23 — concurrent CL contract (continuation does not bypass)
- W-3 — workflow state machine (consumer of resumed envelope)
- §2.8 — provenance manifest (artifact citation in
models_usedblock)
04 同仓库更多 Skills
test-first-extract
Use when the user asks to EXTRACT or RELOCATE existing code into its own file, module, or component ("extract X", "split out Y", "pull Z into its own file", "decompose god-file"). NOT for net-new features (use tdd-feature-build) or behavior changes (use fix-bug). Enforces the 9-step extraction with isolated unit tests + integration regression tests as a two-tier safety net.
tdd-feature-build
Use when the user describes a NEW feature to add ("add X to Y", "implement Z", "build a feature that…", "make it possible to…"). Enforces TDD — failing test first, minimum code to pass, refactor. Refuses to ship code without a test that demonstrably catches its absence. Does NOT trigger on bug fixes (use bug-fix-discipline) or refactors (use test-first-extract). Will ask 1-3 clarifying questions before writing any code; safe to delegate from /feature command.
sync
Multi-machine git-backed sync of local TDD Pro state via the `tdd-pro-sync` branch. Use when operators run claude-tdd-pro on more than one machine and want their FAILURE-LOG, decisions, audit checkpoints, workflow state, operator-curated URL registries, operator/community trees, and paywalled attestations to follow them between hosts.
strict-component-tests
Use when writing or reviewing test files. Enforces strict assertions that actually catch regressions (getByRole, exact counts, jest-dom matchers) in contrast to permissive tests (queryAllByText length > 0) that pass against broken UIs. References QUALITY-BAR.md for the canonical strictness rules.
spec
暂无简介
spec-first
Use when the user describes a non-trivial feature or system that should be specified in writing before any code is written. Pattern from Geoffrey Huntley's "Ralph" loop, OpenSpec, intent-driven.dev, and Kent Beck's "augmented coding" framing — specs+tests are the durable artifact, code is the disposable one. Produces a Markdown spec document that the user reviews; only after approval does any code get written (typically via tdd-feature-build or /feature).