- skills/gt-usage/references/commands.md: add POST /repos/{owner}/{repo}/issues/<issue-index>/times recipe for lock-free duration logging
- skills/implement-slice/SKILL.md & references/handoff-contracts.md: record started_at=$(date +%s) at Step 4 (Ready -> Work in Progress) and log elapsed seconds at Step 7 (Work in Progress -> Review), avoiding Gitea's single-user stopwatch/start lock
- tests/fixtures/test_skills_behavioral_contracts.py: assert lock-free POST .../times tracking in gt-usage and implement-slice
6.3 KiB
6.3 KiB
name, description
| name | description |
|---|---|
| implement-slice | Orchestrates end-to-end delivery of a Gitea issue or vertical feature slice across delegated implementation and QA subagents, checkpoint commits, static review, and pull request packaging. Never edits implementation code or self-certifies QA. Not for decomposing epics into issues (use gitea-plan) or executing a single already-delegated worker task (use tdd and git-manager). |
Implement Slice
Use when
- Delivering an approved Gitea issue or bounded feature slice end to end via coordinated subagents.
- Coordinating multi-task checkpoints, pre-committed QA rubrics, and final review gates.
- Not for decomposing raw epics into milestones and issues: use
gitea-plan. - Not inside an already-delegated implementation worker task: follow the assigned worker contract (
tdd,git-manager) without re-invokingimplement-slice.
Steps
- Preflight branch check, readiness audit, and
Backlog -> Ready. Check session mode perprofile/AGENTS.md. Classify working tree per handoff-contracts (CLEAN_BASE,ADOPTABLE_DIFF,CONFLICTING_STATE,WRONG_BASE). Stop on conflicts. Read target Gitea issue/milestone/board state viagt issue,gt milestone, direction docs (ARCHITECTURE.md,ROADMAP.md,docs/designs/*.md,AGENTS.md), andgit status --short. Reconcile issue acceptance criteria against currentHEAD(handing off toreconcile-docsif canonical design docs drifted during upstream slices, or updating the Gitea issue after owner approval) and, when--dry-runis not active, move the issue cardBacklog -> Readyon the project board. Hand off togitea-planif tracking issues must be created first. - Select orchestration topology (
complexity x risk). Combine planning size with assurance risk per orchestration-tiers. Keep pure-orchestrator invariants: retain plan, status, commit SHAs, QA dispositions, blockers; never edit implementation files, repair Git via code edits, self-certify QA, or ingest full test logs unless resolving a failure. - Lock Planned Workflow and pre-committed rubrics. Formulate the Planned Workflow using the Canonical Node Schema (5-tuples:
node_id,claim,method,executor,pass_condition), decomposing multi-module slices into bottom-up vertical per-submoduleRed -> Greentasks rather than horizontal "all tests first, all code second" batching per orchestration-tiers. Project a dynamic Mermaid diagram deriving directly from node IDs with visible rework edges. If--dry-runis active, halt after displaying the plan (enforce 0 file changes, 0 commits, 0 remote calls). Hard gate: pause for human approval. - Move card
Ready -> Work in Progress, start slice clock, and delegate. Once the human approves Step 3, move the issue cardReady -> Work in Progresson the project board and recordstarted_at=$(date +%s)per handoff-contracts. Govern branch/worktree lifecycle throughgit-managerper orchestration-tiers. Dispatch worker subagent(s) with the Implementation Assignment in handoff-contracts. Never run concurrent workers in the same working tree. Update the runtime Execution Record table as nodes change state. - Audit worker reports and run rubric QA. Verify worker reports via read-only Git checks. Spawn read-only QA subagents running
verify-sliceagainst pre-committed rubrics. Update Execution Record with concrete evidence (SHA, exit codes). - Triage outcomes and route rework. Classify failures using handoff-contracts: route code defects to existing worker via
send_message; record justified rubric amendments if criteria change. Loop Steps 4-6 until all nodes pass. - Enforce final-HEAD evidence, log elapsed time, move card
Work in Progress -> Review, and integrate. Confirmcode-review(Ready) andverify-slicematch the exact finalHEADand base, log elapsed issue time (POST .../issues/<index>/times) and move the issue cardWork in Progress -> Reviewon the project board per handoff-contracts. Present the Execution Deviation Report (skipped/added checks, rework iterations, scope drift; if scope drift evolved a contract indocs/designs/*.mdorARCHITECTURE.md, prompt to runreconcile-docsbefore the next slice). Integrate per orchestration-tiers Policy Matrix: fast-forward merge (and move cardReview -> Completed) if repoAGENTS.mdpermits and user approves, else hand off togitea-pr.
Your call
- Session mode: decide whether to switch from
learningtodeliverybefore autonomous delegation. - Planned workflow and rubrics: approve task breakdown, node 5-tuples, assurance tier, and QA rubrics before workers spawn.
- Rubric amendments, live-infra, and trade-offs: approve rubric criteria changes, authorize
live-infrachecks, and adjudicate review conflicts. - Integration authorization: authorize direct merge to main or PR creation and merge.
Done when
- All slice checkpoints are committed on a clean target branch,
code-review(Ready) andverify-slicematch the same finalHEAD, the Execution Deviation Report is recorded, and the branch is integrated per policy.
Hands off to
gitea-plan: when goals or epics require milestone and issue decomposition before slice execution.git-manager: to create/integrate slice branches and worktrees, commit worker checkpoints, or stop on conflicts.tdd: inside workers for seam-level red-green development, or standalone test hardening (Suggested Next Step: /tdd <test-path>).verify-slice: inside QA subagents for pre-committed chunk and final-HEADruntime verification.code-review: for final-slice 4-axis static and strategic alignment inspection.diagnose: when an unexpected failure requires evidence-first root-cause investigation.gitea-pr: when policy or remote CI mandates a PR and final-HEADpackets are ready (Suggested Next Step: /gitea-pr #<issue>).reconcile-docs: when design specs drifted (Suggested Next Step: /reconcile-docs); on--dry-runor post-merge next slice, emitSuggested Next Step: /implement-slice #<issue>.