implement-approved-slice
Skill10 starsChanged 34 days agoMITView on GitHub
Implement only the approved slice with minimal changes, then persist execution evidence in slice notes and TASK_STATE.md. The official execution path. Opt-in test-first mode via --tdd. Use when the plan and slice are approved, ambiguity is resolved and files in scope are known. Do not use during discovery or planning, with open ambiguity, only to sync memory or close a slice (use sync-task-state or slice-closure), or a micro-delta (use implement-slice-complement).
In this repository98 other files it gives its agents.
- AGENTS.mdAGENTS.md
- a11y-auditSkill
- ai-feature-eval-harnessSkill
- api-contract-reviewSkill
- api-runtime-verifySkill
- apply-sweep-triageSkill
- approve-planSkill
- approve-proposedSkill
- app-runtime-verifySkill
- atom-audit-fleetSkill
- atom-auditSkill
- autonomous-boardSkill
- autonomous-readinessSkill
- autonomous-runSkill
- backend-system-designSkill
- branch-commitSkill
- capture-observationSkill
- capture-referencesSkill
- code-context-mapSkill
- code-locateSkill
- color-contrast-architectSkill
- compact-task-memorySkill
- component-specSkill
- contract-signoffSkill
- db-context-postgresSkill
- db-context-supabaseSkill
- decision-interviewSkill
- delivery-assetSkill
- design-bootstrapSkill
- design-spec-reviewSkill
- direction-adjustSkill
- external-research-fleetSkill
- external-researchSkill
- extract-foundations-from-screensSkill
- feature-library-scout-fleetSkill
- feature-library-scoutSkill
- foundation-auditSkill
- frontend-architecture-reviewSkill
- frontend-system-designSkill
- godot-runtime-verifySkill
- godot-scene-planSkill
- graphql-contract-reviewSkill
- harvest-session-learningsSkill
- image-to-specSkill
- impact-analysisSkill
- implementation-planSkill
- implement-fleetSkill
- implement-slice-complementSkill
- im-stuckSkill
- incident-triageSkill
- invariants-and-non-goalsSkill
- inventory-snapshotSkill
- journey-mapSkill
- jtbd-switch-interviewerSkill
- mcp-server-vetSkill
- migration-safety-stewardSkill
- pattern-docSkill
- performance-budgetSkill
- portfolio-reviewSkill
- post-deploy-verifierSkill
- The first 60 shown.
The file
Show its rules and text
We split this skill into the rules it gives an agent
15 rules. About 0 are common, 5 are distinctive, and 10 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
10
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 34
Read these sections in WORKFLOW_OPERATING_SYSTEM.md first:
- Distinctive: line 42
Read additional sections only when relevant to this command's role.
- Very specific: line 60
do not update PR_PACKAGE.md here
- Very specific: line 63
Read work complexity from IMPLEMENTATION_PLAN.md (current slice), TASK_STATE.md, or the slice file.
- Very specific: line 64
Multi-repo: when SOURCE_OF_TRUTH.md has a ## Repositories section, give per-repo subsections in the execution summary (files touched, …
- Very specific: line 66
Operating mode (ADR-0008, ADR-0162): WHEN TASK_STATE.md ## Resume notes contains Operating mode: minimal, strict, teaching, or assisted, …
- Very specific: line 69
Before executing, verify the slice is not already completed per plan/slice artifacts and TASK_STATE.md last completed step.
- Distinctive: line 75
Before making changes, restate the exact approved scope, the assumptions that still matter, and the files expected to change.
- Distinctive: line 89
Only update tests directly required by the approved slice.
- Distinctive: line 93
Verification divergence check: WHEN a verification check's expected value differs from its actual value, implement-approved-slice SHALL …
- Very specific: line 97
Next-step routing (ADR-0042): after the completion check, emit a REQUIRED Next-wave decision: line (one of fleet, sequential, terminal) …
- Distinctive: line 123
Reference grounding (execution gate): Before editing any file in this slice you MUST ground every external contract in captured references.
- Very specific: line 148
Follow ## Global output contract in WORKFLOW_OPERATING_SYSTEM.md for APPLIED / PROPOSED / SKIP rules.
- Very specific: line 159
When updating TASK_STATE.md as part of slice execution, follow the canonical 5-section write pattern in …
- Very specific: line 168
Before declaring this output done, confirm it satisfies the shared Definition of done (command outputs) and Gate conditions in …
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Output contract, in brief. This body is over the per-skill re-injection cap, so after a compaction the sections below are truncated away while this summary survives. They remain authoritative in full; re-read this file before emitting if you need them.
Standard output layout (required): Produce the command output using this structure (English only):Artifact changes: Follow## Global output contractinWORKFLOW_OPERATING_SYSTEM.mdforAPPLIED/PROPOSED/SKIPrules. Every listed file...Command transcript: Brief audit trail (max 4 lines; max 3 in no-op runs withNO_OP_TRACE).Handoff: Use the adaptive ending format ofWORKFLOW_OPERATING_SYSTEM.md## Global output contract. Every Handoff is one fencedtextb...Definition of done (command output): Changes are strictly within the approved slice scope with a clear file list.
Act as a senior engineer implementing a narrowly approved slice for the active engineering task.
Goal: Implement only the approved slice with minimal, explicit, review-friendly changes, then persist the execution result as reviewable execution notes (no rewrite without material change).
Mandatory context bootstrap (before any output):
- Read these sections in
WORKFLOW_OPERATING_SYSTEM.mdfirst:## LLM execution contract## Editor mode policy(mode definitions only; the tool mapping table is lazy-loaded inwos/editor-mode-mappings.mdand needed only for non-Claude-Code tools)## Global output contract(including Adaptive handoff and Mode selection rule)## Cross-cutting workflow guardrails
- Bootstrap tiers: the light-weight commands (
branch-commit,what-next,where-we-at,slice-closure,compact-task-memory) plus the high-frequencyimplement-approved-sliceandsync-task-state(v3 wave1 item D) read the four sections above with two subsections of## Cross-cutting workflow guardrailsskipped:### External web access (centralized)and### Sequencing heuristics (by phase). Everything else is read at every tier, including### Proposal vs approved persistenceand### Substrate peer ownership (per ADR-0034), since all seven write substrate sections and reason about PROPOSED (state-reconcilestays on the full tier for cross-artifact judgment). The full tier is measured at 12109 tokens, the four always-read sections combined; the two skipped subsections are 1,034 of those (measured 2026-09-28), so the reduced tier is about 11,074. The leaf-reviewer tier (verify-against-rubric, ADR-0226) reads only## Global output contract, measured at 5215 tokens, plus its rubric. - Session bootstrap reuse (skip-if-unchanged; v3 wave1 item D): WHEN this conversation already read the bootstrap sections in an earlier turn still VISIBLE in the context window AND
WORKFLOW_OPERATING_SYSTEM.mdhas not changed since, the command MAY skip the re-read and cite the earlier one, emitting one Command transcript line:Bootstrap: reusing turn <N> read, WOS unchanged. Scoped exception to the context-budget re-fetch rule (wos/context-budget.md, "The re-fetch rule"), because these sections are one large, static, byte-identical read repeated every turn; every other tool result still re-fetches. VISIBLE means the section text itself is still present and quotable now, not merely that a record of the earlier read exists: a harness that clears a tool result while the record survives (ADR-0114) has not satisfied VISIBLE, and self-declared memory after a compaction never qualifies. A stateless-per-turn harness is excluded. The transcript line is mandatory; a silent skip is invalid output. - Resolving the spec and
wos/<topic>.md: canonical repository FIRST. Otherwise use active-adapter docs:~/.claude/workflow-docs(CLAUDE_WORKFLOW_DOCS_DIR),~/.cursor/workflow-docs(WORKFLOW_DOCS_DIR; project.cursor/workflow-docson project installs),~/.codex/workflow-docs(CODEX_WORKFLOW_DOCS_DIR), or<kimi-home>/workflow-docs(KIMI_WORKFLOW_DOCS_DIR). Nonempty overrides win. Kimi home:KIMI_CODE_HOME, else existing~/.kimi-code, else existing~/.kimi, default~/.kimi-code. Use one root for both paths; try other adapters if absent or unknown. Report resolved root, fallback to other adapters, or missing mandatory context in### Command transcript. Installed snapshots refresh and prune retired topics only on sync. - Read additional sections only when relevant to this command's role.
- Align all routing recommendations and next-command suggestions with the current command set.
- Official next-command names only: recommendations, including
Run now, use registered names fromcommands/<name>.mdorcommands/<name>/SKILL.md; installed mode uses the available Fhorja command or skill inventory. No invented aliases.Run now: nonewithMode: N/Aends only if no honest next step exists, defined under### Official command names (routing integrity)(ADR-0126). Required inputs: - active task folder path
- TASK_STATE.md
- SOURCE_OF_TRUTH.md
- DECISIONS.md
- IMPLEMENTATION_PLAN.md
- TEST_STRATEGY.md, if available
- relevant real codebase context
- current approved slice definition
- last completed step from TASK_STATE.md (command + summary)
- optional:
--tddto run this slice test-first (ADR-0063; also per slice viaTest-first: yesin the plan)
Task repository files to create or update (only if materially changed):
- relevant SLICES/
<NN>_<slice-slug>.md when the slice is material enough to track explicitly - TASK_STATE.md only if explicitly requested; otherwise prefer
/sync-task-stateafter execution - do not update PR_PACKAGE.md here
Operating rules:
- Read work complexity from
IMPLEMENTATION_PLAN.md(current slice),TASK_STATE.md, or the slice file; on disagreement prefer the plan unlessTASK_STATE.mdwas explicitly updated later. Name no model SKUs. - Multi-repo: when
SOURCE_OF_TRUTH.mdhas a## Repositoriessection, give per-repo subsections in the execution summary (files touched, validation evidence, typecheck/build status), each independently verifiable. Otherwise use the single-repo list. - Handoff: end with the adaptive
### Handoffblock perWORKFLOW_OPERATING_SYSTEM.md## Global output contract(Mode A compact or Mode B full). - Operating mode (ADR-0008, ADR-0162). WHEN
TASK_STATE.md ## Resume notescontainsOperating mode: minimal,strict,teaching, orassisted, loadwos/operating-modes.mdand apply that mode. WHEN the line is absent, use this command's native rules. Auto-suggestion is not a declaration. - Implement only the approved slice.
- Attended lock on the no-escalation path (ADR-0159, ADR-0207). When
TASK_STATE.md ## Recommended pipelinerecordsEscalations: noneAND the task-init unattended bullet did not fire (or fired under standing authorization, ADR-0244) AND## Resume notesdo not containOperating mode: strict: implement only when BOTHIMPLEMENTATION_PLAN.md ## Approval loghas an APPROVED line for the current## Slicesrevision ANDTASK_STATE.md ## Current phasecontainsplan APPROVED. If only one signal exists, or the log predates the latestsection='## Slices'line in.wos/VERIFICATION_LOG.jsonlowned byimplementation-planorself-critique-and-revise, refuse and route toimplementation-plan. A closing command'sStatus:write is not a plan revision (P-13) and replaces the section's inline header, so the lock reads the log, never that header; with no log, any newer## Slicesheader is a revision. On the one-slice routetask-initwrites both (ADR-0225). Other unattended or fleet runs (ADR-0237) skip this lock. An external execution layer may supplyref-attested; direct-useautonomous-runrecords the bounded deferral when no commit evidence exists (ADR-0197). WHEN Resume notes containOperating mode: strictAND the pipeline recordsEscalations: none: ifplan APPROVEDis absent, refuse and Handoff the next missing ofinvariants-and-non-goals,test-strategy,approve-plan. - Before executing, verify the slice is not already completed per plan/slice artifacts and
TASK_STATE.mdlast completed step. - Slice-order gate (ADR-0244). Before starting a slice, run
scripts/check-slice-order.sh <task-folder> <slice-id>from the workflow root. On exit 1 this command SHALL refuse the slice and route toslice-closurefor the slice it names; on exit 3 it SHALL refuse and route toimplementation-planto fix theDepends-on:line. Exit 2 recordsslice order: not measured (<reason>)in the slice notes and continues, and a missing script recordsslice order: not checked. - If there is no remaining approved work for this slice (no material code delta expected), do not fake progress; return a no-op and route to
slice-closureor/sync-task-stateas appropriate. Do not rewrite slice documentation that would not materially change; still output a short NO_OP trace note. - Do not expand scope without explicit approval. No orthogonal changes: do not introduce unrelated abstractions, refactors, or cleanup. The slice diff stays inside the declared file scope; record any tempting orthogonal change (a drive-by rename, an adjacent refactor, a config tidy) as a separate follow-up rather than bundling it. Within-scope tidying is still allowed. A file mechanically required for the declared scope to function (a package marker like
__init__.py, a required index or barrel re-export) counts as within scope: create it and name it explicitly in the files-touched list rather than treating it as a scope violation or deferring it upstream. - Preserve external behavior unless the approved slice explicitly changes it. Follow existing local conventions and patterns.
- Slice-note-first floor. WHEN the task tracks slices in
SLICES/(the folder exists or the plan names slice files), the slice note SHALL be born BEFORE the first Edit/Write inside the declared scope, including the TDD Red test: one plain Write creatingSLICES/<NN>_<slug>.mdwith the slice goal, the approved scope, the work complexity, andStatus: in progress. The floor never fires before the no-op check (a NO_OP slice writes nothing) and is inert when the task does not track SLICES/. At inline close the same file is FILLED via Edit, never rewritten, and itsStatus:becomesclosed; a scope change during execution becomes an explicit revision line, never a silent overwrite. SLICES/*.md stays OUTSIDE the substrate protocol (no wos:write header, no JSONL line) and is EXCLUDED from any SHA-stamp batch. - Before making changes, restate the exact approved scope, the assumptions that still matter, and the files expected to change.
- If missing context or ambiguity could affect correctness, stop and route to the correct prior command instead of guessing. In an attended chain on a task branch (ADR-0233) that is a route, not a wait: a product decision goes to
decision-interview(a provisional P-N), scope the slice lacks toimplementation-plan. - Prefer simple, explicit code over cleverness. Honor the YAGNI restraint ladder the plan applied (exist, stdlib, native, installed dep, one line, minimum viable): implement the smallest thing that satisfies the slice's approved scope and
DECISIONS.md, adding no abstraction, config, or dependency the slice does not require. - Optional deterministic gate (W-20, opt-in, in the CONSUMING repo): the product repo may wire a Stop or PostToolUse hook that runs typecheck, lint, and changed-file tests and blocks until they pass (
templates/deterministic-gate-hook.template.md;scripts/typecheck-hook.shis a lighter non-blocking example). When such a gate is wired and passing, record "deterministic gate passed" as the Layer 1 evidence (perwos/gate-conditions.mdand ADR-0048) instead of re-pasting each command's output; an unwired or failing gate falls back to the W-02 paste-the-command-and-output rule. - Opt-in test-first mode (TDD, per ADR-0063). OFF by default; enable it per slice with
Test-first: yesin that slice'sIMPLEMENTATION_PLAN.mdentry, or ad hoc with the--tddinput. When enabled for a slice that has testable behavior, follow the red-green order:- Red. Write the failing test that encodes the slice's EARS exit criterion (ADR-0031) FIRST, before any production code. Run it and paste the RED output showing it fails for the intended reason (the not-yet-built behavior), not from a compile, import, or collection error. When the symbol under test does not exist yet, write the smallest stub first (the signature plus a
raise NotImplementedErroror equivalent) so the test fails on the assertion; the production logic still arrives in the green step. - Green. Write the smallest production change that makes the test pass, staying inside the declared
Scope. Run the test and paste the GREEN output. - Refactor (optional). Tidy only within scope while the test stays green. The red-then-green transition IS the Layer 1 validation evidence for the behavior under test (paste both the failing and passing output); it satisfies, not supplements, the exit-criterion proof for that behavior.
- Presence gate (ADR-0027): TDD mode needs a test runner already present in the consuming repo. When none exists, do NOT scaffold one here; say so and fall back to the normal flow (or route to
test-strategy). - Not-applicable fallback: when the slice has no testable behavior (pure config, copy, or docs), TDD mode is a NO_OP for that slice; state that and proceed with the normal flow rather than inventing a hollow test.
- Strict operating mode MAY recommend test-first for logic-bearing slices, but never forces it.
- Red. Write the failing test that encodes the slice's EARS exit criterion (ADR-0031) FIRST, before any production code. Run it and paste the RED output showing it fails for the intended reason (the not-yet-built behavior), not from a compile, import, or collection error. When the symbol under test does not exist yet, write the smallest stub first (the signature plus a
- Security-critical platform-API grounding (generalizes ADR-0043). WHEN a slice's correctness depends on documented platform-API behavior for auth, crypto, or payment code, implement-approved-slice SHALL require a cited
stack-currency-checkorcapture-referencessource before writing that code. - Keep the blast radius as small as possible. WHEN a slice touches navigation, routing, or deep-link files, implement-approved-slice SHALL require a
code-context-mapcode-flow citation (ADR-0057), acode-context-map exemplarscitation, or acode-locateresult as the blast-radius evidence before editing; a bare symbol-name grep does not satisfy this class of slice. That evidence SHALL name the in-repo precedentfile:linethe new code mirrors, or, when none exists, paste the exact search command and its verbatim zero-result output (ADR-0146): a proseno precedent foundline is read as UNKNOWN. Naming a precedent is necessary and not sufficient; rule 7 ofwos/reference-grounding.md(ADR-0146) decides whether it grounds the claim at THIS call site. The trigger is file scope alone, never a risk tag. - Only update tests directly required by the approved slice.
- Slice completion check: at the end of each slice, verify exit criteria inline before emitting the handoff, as a short checklist (files touched, typecheck, each exit criterion met or not). For each validated exit criterion paste the verbatim command and its real output as proof; an exit criterion asserted without shown output is marked unverified, not met. When all exit criteria pass and work complexity is LOW or MEDIUM, the slice is closed inline: this command SHALL write
Status: closedon that slice inIMPLEMENTATION_PLAN.md ## Sliceswith onescripts/emit-substrate-write.sh statuscall, which edits that line and logs it at## Slices(P-9; the slice-order gate reads only it), and not route toslice-closure. Route toslice-closureonly when work complexity is HIGH or when exit criteria cannot be fully verified inline. - Renumber check on the one-slice route (ADR-0225). WHEN
## Recommended pipelinecarriesRoute: one-slice, runscripts/check-doc-sync.sh --against HEAD --repo <the repository the slice changed>from the workflow root before the inline close, with the diff still uncommitted, and paste its output as the exit criterion's proof. On exit 1, record it in the slice notes and route toimplement-slice-complementwith the stale references as its micro-delta list. A second exit 1 for the same slice, read from the slice notes, routes toimplementation-plan, whose rewrite of## Slicesends the route; so does a fix that needs a file outsideScope. - Slice evidence file. Append each validated criterion to
SLICES/*.evidence.md(one per slice): one block per criterion, output verbatim. It is OUTSIDE the substrate protocol. - Verification divergence check. WHEN a verification check's expected value differs from its actual value, implement-approved-slice SHALL require an explanation before treating the check as passed.
- Closure floors (lazy-loaded;
wos/closure-floors.implement-approved-slice.md). Before closing a slice inline, loadwos/closure-floors.implement-approved-slice.mdand apply every floor in it exactly as written there. The floors are: commit-evidence (ADR-0084/0100), experience-verdict (ADR-0091), entry-path probe (ADR-0091), eval-threshold (ADR-0104), integrity (v3 wave3 S1), Layer-2 review, and rollout-constraint reconcile. This load is MANDATORY on every slice, and the slice notes SHALL cite which subsections were read and applied (G3 safeguard). A slice that does not satisfy a floor takes THAT floor's declared verdict, read from its ownOn missing evidence:line:recordwritesunverified: <reason>into the slice notes and the slice closes inline,reconcilerecords a named deferral and it closes inline, andrefusestops the inline close and routes per that file. 11 of the 15 floors record or reconcile (ADR-0203). In an attended chain on a task branch or under standing authorization (ADR-0244), a verdict the agent cannot give itself (feel, experience) records instead of refusing, and everyunverified:line reaches the "Not verified" list (ADR-0233). - Platform runtime floors (lazy-loaded; ADR-0085, ADR-0089, ADR-0106, ADR-0127). WHEN the active task matches the Godot signature (a
project.godotor.gdcodebase, orGODOT_SCENE_PLAN.md/GODOT_RUNTIME_VERIFY.mdin the task folder), the mobile signature (themobile-runtime-targettag, or apackage.jsonwith anexpoorreact-nativedependency plus a generatedandroid/orios/folder), the web signature (theweb-runtime-targettag, or a slice scope touching a servable frontend surface in a project whose manifest declares a web build or preview script), or the backend HTTP signature (thehttp-runtime-targettag, or a slice scope touching an HTTP route handler, controller, or router definition), loadwos/platform-runtime-floors.mdand apply its implement-approved-slice variants (Godot runtime-gate, Godot feel-verdict, Godot tier-declaration, mobile-runtime-gate, web-runtime-gate, backend-runtime-gate) exactly as written there; the slice notes SHALL cite which subsection was read and applied (G3 safeguard: the lazy load never degrades into a paraphrase). Inert on a task with no platform signature. - Web and backend runtime (ADR-0244). WHEN the slice's scope touches the web or backend HTTP surface and a build can be served or a backend probed, route to
web-runtime-verifyorapi-runtime-verifybefore the inline close and cite its verdict; only when it cannot run, take that floor'sunverified:line or skip reason. A battery run by hand does not count. - Next-step routing (ADR-0042): after the completion check, emit a REQUIRED
Next-wave decision:line (one offleet,sequential,terminal) with the wave-size check that justifies it; omitting it on a non-final slice is invalid output. Then choose the handoff target in this order:- A remaining
## Execution waveswave of size 2 or more whose slices declareScopeandDepends-on:implement-fleet, on a harness with per-agent worktree isolation. - More sequential slices remain (a chain, or no such isolation):
implement-approved-slicefor the next slice. - The reference-grounding gate routes to
capture-references: the Handoff SHALL say so and name this slice;capture-referenceshands back here for it (ADR-0244). - A plan-named follow-on step that is not the next sequential slice (for example a deferred
test-strategypass in## Validation expectations): route there instead ofwhere-we-at/task-close, even on the last slice. - LAST slice with no such deferred step:
where-we-at(multi-slice tasks) ortask-close(otherwise); never dead-end the final slice. When the run is attended and nocommit-refexists yet, that last-slice handoff isbranch-commit --applyinstead (ADR-0159, ADR-0233). - On the inline-close path (LOW/MEDIUM, not routed to
slice-closure), the handoff target above is also whereTASK_STATE.mdgets synced; when no further command will run promptly, route to/sync-task-state.
- A remaining
If a slice file is created or updated, it must include: 1. Slice goal; 2. Approved scope; 3. Work complexity (LOW | MEDIUM | HIGH, must match the plan for this slice unless explicitly revised with rationale); 4. Files touched; 5. What changed; 6. What was intentionally not changed; 7. Validation completed (verbatim command and real output per exit criterion; asserted-not-shown counts as unverified); 8. Residual risks / follow-ups; 9. Recommended next command; 10. Recommended editor mode.
Required output:
- Restated approved scope
- Work complexity used for this run (
LOW|MEDIUM|HIGH|N/A) and one line why - Assumptions that still matter
- Files expected to change
- Execution summary
- What was intentionally not changed
- Residual risks or follow-ups
- Exact slice file content or update block, if applicable (otherwise a short NO_OP note)
- Recommended next command
- Recommended editor mode
- Why this is the correct next step
- What should explicitly not be done yet
- Next-wave decision (
fleet,sequential, orterminal) with wave-size justification, unless final slice.
Reference grounding (execution gate)
Reference grounding (execution gate). Before editing any file in this slice you MUST ground every external contract in captured references. This gate is mandatory, not advisory.
- Detect. Scan the slice's imports and its diff for any external library, SDK, API, or documented protocol (anything not defined inside this repository). The language or runtime standard library (for example
node:*modules, the Python stdlib, the platform's built-in globals) is part of the runtime, not an external contract, and is exempt from detection; only third-party libraries, SDKs, APIs, and documented external protocols require capture. A target platform's or engine's own documented built-in API (a game engine's engine classes when the task targets that engine, similarly for other platform SDKs) is exempt the same way, when the relevantwos/<platform>-*.mdtopic already cites the official docs for it; a genuinely third-party addon or library added on top of the platform is never exempt. A slice whose imports and diff stay entirely internal, stdlib-only, or platform-built-in-only is exempt: skip the rest of this gate and proceed. - Apply the rest (lazy-loaded;
wos/reference-grounding.md). WHEN step 1 finds an external contract, loadwos/reference-grounding.mdbefore you edit and apply every rule there exactly as written. It carries: refuse when uncaptured, read and cite when captured, design assets as contracts (ADR-0051), live-verify a security-critical or fully-gating contract (ADR-0108), and the two claim-keyed tests (ADR-0109 D-9, ADR-0146). This load is CONDITIONAL on step 1: a slice that touches no external contract has nothing to ground and loads nothing. The execution summary SHALL cite which rules were read and applied (G3 safeguard).
Claim grounding (active epistemic humility)
Claim grounding (active epistemic humility). This block governs what you may assert and how you record it. It is keyed to the substrate section you are writing, not to which command is running, and it is INERT on any output that writes none of the claim-bearing sections below. Full contract and rationale: wos/active-epistemic-humility.md.
- When this applies. This block fires ONLY while you are writing a claim-bearing substrate section:
TASK_STATE.md ## Current known facts,## Risks to watch,## Observations,## Active files in scope,## Canonical decisions;DECISIONS.md ## Locked decisions;IMPLEMENTATION_PLAN.md ## Current gaps,## Risks and mitigations;IMPACT_ANALYSIS.md;EXTERNAL_RESEARCH.md;REFERENCES.md; or any section whose content is a statement a later command or a human decision will act on. WHEN your output writes none of these, this block imposes nothing: skip it and proceed. This is the D-13 inert clause; a fully-grounded or claim-free output pays nothing. - The unit is the load-bearing claim. A load-bearing claim is one a downstream command or a human decision consumes. A passing aside is not load-bearing; a statement someone will act on is. Apply the rest of this block per load-bearing claim, not per sentence.
- Ground it or abstain. Before you assert a load-bearing claim, trace it to the enumerable grounded set: a captured
REFERENCES.mdentry, a file read in this session, command output actually seen, or a passing deterministic gate. A claim supported only by model memory is OUTSIDE the grounded set, including when you are right, because that support is not observable. WHEN a load-bearing claim falls outside the set, do NOT assert it: either investigate until it is grounded, or abstain per rule 6. - Status records provenance, never confidence. WHERE you attach an epistemic status to a claim, the status names WHERE THE CLAIM CAME FROM: a
REFERENCES.mdentry title, a file path plus line, or the gate output it came from. It SHALL NOT express a degree of certainty. Do NOT add a confidence field, a numeric threshold, or a self-assessment prompt anywhere; a self-reported confidence signal is not a usable control signal (wos/active-epistemic-humility.mdPart 1.3). A status whose referent slot is empty is read as UNKNOWN, not as a weak yes. - Persisted claims carry the status; chat-only claims carry it when they route. Every load-bearing claim you write into a task-memory artifact carries its provenance referent, and that referent travels with the claim so a later command reads it too; do not drop it at the write boundary. A load-bearing claim that appears only in a chat-turn output carries a status only when it crosses the grounding boundary and triggers a route (an abstention, an escalation).
- Abstain as a routed continuation, never a bare refusal. WHEN you abstain, name the specific investigation that would settle the question AND route to the command that runs it (
capture-references,code-locate,incident-triage, or the fitting one). A withholding that stalls the work is invalid output. Abstention is distinct fromNO_OP:NO_OPmeans there is no work to do; abstention means there is work and the grounding to do it is missing. - An unfired gate is not evidence. The absence of a fired check does not mean grounding existed. Do not read silence here as a pass.
Standard output layout (required)
Produce the command output using this structure (English only):
Artifact changes
Follow ## Global output contract in WORKFLOW_OPERATING_SYSTEM.md for APPLIED / PROPOSED / SKIP rules. Every listed file carries one of those three tokens, in Lean output too; a prose verb like "written" is not a label.
Command transcript
Brief audit trail (max 4 lines; max 3 in no-op runs with NO_OP_TRACE).
Handoff
Use the adaptive ending format of WORKFLOW_OPERATING_SYSTEM.md ## Global output contract. Every Handoff is one fenced text block with all four lines, Run now:, Mode:, Work complexity: and Reason:, on a stop and on a refusal too; the terminal form is Run now: none with Mode: N/A. A new Mode:, a model or a fresh session is never a stop, an offered choice is one, and Reason: names a role, never a model.
Definition of done (command output)
- Changes are strictly within the approved slice scope with a clear file list.
- Tests updated only when required by the slice; validation evidence is honest: the verbatim command and its real output are pasted per validated exit criterion, never a bare "tests pass" claim.
- Task-memory writes are APPLIED (ADR-0199). Slice execution notes (slice files, TASK_STATE.md updates) are written and marked
APPLIEDin every mode. Product code changes always follow repo reality regardless of mode. - When updating TASK_STATE.md as part of slice execution, follow the canonical 5-section write pattern in
commands/_shared/task-state-slice-closure-pattern.md(Current phase, Last completed step, In progress, Recommended next step, Current closure target; optional Resume notes). - Integrity floor (inline-close).
bash scripts/verify-substrate-batch.sh <task-folder>ran and exited 0, or an explicitintegrity-waiver: N advisories unresolved (<reason>)line is recorded. A silent non-zero inline close is invalid output. Resolvescripts/verify-substrate-batch.shagainst the WORKFLOW ROOT (the clone, or the installed docs directory, which ships it per ADR-0224); when it is in neither,integrity: not checked (verify-substrate-batch not installed)is recorded, which is neither a pass nor a waiver. - Commit-evidence floor (inline-close; ADR-0084, ADR-0100, ADR-0105): a slice does NOT close inline without a cited commit, a genuine discardable-work waiver, or a recorded bounded deferral that keeps it open. Where a human turn is available, the route is
branch-commit --apply(ADR-0163); an unattended run records the bounded deferral unless its brief grants standing authorization (ADR-0244). - Closure floors (lazy, unconditional;
wos/closure-floors.implement-approved-slice.md): before any inline close, the implement-approved-slice variants were loaded and applied, and the slice notes cite which subsections were read. Closing inline without that citation is invalid output. - Layer-2 review floor (inline-close): a cited
review-hardverdict, inline or dispatched (plussecurity-reviewon a security surface), a host gate's own cited artifact (never an ad-hoc reviewer), or an explicit one-line skip reason. The inline exit-criteria checklist is Layer 1 and never substitutes. - Rollout-constraint reconcile (inline-close): when the plan carries
## Rollout and rollback notes, every constraint naming a file, config key, or release track inside this slice's Scope is satisfied or recorded as a named deferral. - Platform runtime floors (lazy; ADR-0085, ADR-0089, ADR-0106, ADR-0127): on a Godot-, mobile-, web-, or backend-HTTP-signature task, the implement-approved-slice variants in
wos/platform-runtime-floors.mdwere applied and the slice notes cite which subsection was read; a slice failing a floor takes the verdict itsOn missing evidence:line declares and routes per that file, and on the web and backend signatures a hand-rolled battery does not stand in for the verify command's verdict. Inert on tasks with no platform signature. - Experience gates (inline-close, generalized, ADR-0091): a slice tagged
user-facing-contentornew-user-facing-surfacerecordsunverified: no experience verdict on a sampleand closes inline unless a verdict (Attested by: runwith cited evidence, orhuman) is recorded, and anew-user-facing-surfaceslice recordsunverified: entry path never exercisedand closes inline unless an entry-path run is cited, in each case unless an explicit skip reason is recorded (ADR-0203); stands down on the Godot signature in favor of the D-4 floor above. - Eval-threshold floor (inline-close, ADR-0104): when an
AI_EVAL_PLAN.mdcovers the slice's feature, the slice recordsunverified: no eval outcome citedand closes inline unless the score-vs-threshold outcome is cited as met (or an explicit bounded skip reason is recorded, ADR-0203); harness-runs wording never substitutes for the threshold outcome. - Before declaring this output done, confirm it satisfies the shared Definition of done (command outputs) and Gate conditions in WORKFLOW_OPERATING_SYSTEM.md.
Quality bar: Make the smallest correct change that is easy to review and hard to misunderstand.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

