gentle-pi 2.1.2 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +70 -12
- package/assets/agents/gentle-ai-worker.md +7 -3
- package/assets/agents/jd-fix-agent.md +1 -1
- package/assets/agents/jd-judge-a.md +3 -1
- package/assets/agents/jd-judge-b.md +3 -1
- package/assets/agents/review-readability.md +4 -1
- package/assets/agents/review-reliability.md +4 -1
- package/assets/agents/review-resilience.md +4 -1
- package/assets/agents/review-risk.md +4 -1
- package/assets/agents/sdd-apply.md +6 -1
- package/assets/agents/sdd-archive.md +6 -1
- package/assets/agents/sdd-design.md +6 -1
- package/assets/agents/sdd-explore.md +6 -2
- package/assets/agents/sdd-init.md +10 -2
- package/assets/agents/sdd-onboard.md +6 -1
- package/assets/agents/sdd-proposal.md +6 -1
- package/assets/agents/sdd-spec.md +6 -1
- package/assets/agents/sdd-status.md +6 -1
- package/assets/agents/sdd-sync.md +6 -1
- package/assets/agents/sdd-tasks.md +6 -1
- package/assets/agents/sdd-verify.md +6 -1
- package/assets/chains/4r-review.chain.md +2 -0
- package/assets/chains/sdd-full.chain.md +1 -1
- package/assets/chains/sdd-plan.chain.md +1 -1
- package/assets/chains/sdd-verify.chain.md +1 -1
- package/assets/orchestrator-delegation.md +246 -67
- package/assets/orchestrator.md +7 -14
- package/assets/sdd-orchestrator-workflow.md +154 -9
- package/assets/support/sdd-status-contract.md +19 -1
- package/contracts/review-integration/v1/fixtures/consent.fixture.json +3 -3
- package/contracts/review-integration/v1/fixtures/start-v2.fixture.json +19 -28
- package/contracts/review-integration/v1/fixtures/start.fixture.json +1 -10
- package/contracts/review-integration/v1/fixtures/status-v2.fixture.json +12 -21
- package/contracts/review-integration/v1/schemas/correction-plan-request.schema.json +49 -0
- package/contracts/review-integration/v1/schemas/operation.schema.json +76 -0
- package/contracts/review-integration/v1/schemas/repair.schema.json +39 -0
- package/contracts/review-integration/v1/schemas/status-v2.schema.json +4 -2
- package/contracts/review-integration/v1/schemas/status.schema.json +4 -2
- package/contracts/review-integration/v2/fixtures/consent.fixture.json +1 -1
- package/contracts/review-integration/v2/fixtures/start.fixture.json +1 -10
- package/contracts/review-integration/v2/fixtures/status.fixture.json +1 -10
- package/contracts/review-integration/v2/schemas/failure.schema.json +5 -1
- package/contracts/review-integration/v2/schemas/operation.schema.json +6 -1
- package/contracts/review-integration/v2/schemas/repair.schema.json +4 -2
- package/contracts/review-integration/v2/schemas/start.schema.json +5 -2
- package/contracts/review-integration/v2/schemas/status.schema.json +4 -2
- package/contracts/review-provider-contract-mirror/provider-contract.lock.json +30 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/README.md +12 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/manifest.json +65 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/schemas/lens.schema.json +16 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/schemas/refuter.schema.json +1 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/schemas/targeted-validator.schema.json +1 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/vectors/lens.json +1 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/vectors/refuter.json +1 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/bundle/vectors/targeted-validator.json +1 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/generated/provider-capabilities.baseline.json +15 -0
- package/contracts/review-provider-contract-mirror/v1.1.0/generated/provider-roles.baseline.json +42 -0
- package/docs/native-authority-architecture.md +5 -5
- package/docs/review-integration.md +22 -2
- package/extensions/gentle-ai.ts +1595 -201
- package/extensions/sdd-init.ts +19 -6
- package/extensions/skill-registry.ts +10 -2
- package/extensions/startup-banner.ts +10 -4
- package/lib/gentle-ai-binary.ts +173 -2
- package/lib/git-commit-transaction.ts +77 -17
- package/lib/native-review-cli.ts +528 -65
- package/lib/provider-contract-bundle.ts +704 -0
- package/lib/review-candidate-view.ts +527 -18
- package/lib/review-compact-contract.ts +59 -248
- package/lib/review-host-relay.ts +436 -0
- package/lib/review-integration-v2.ts +537 -36
- package/lib/review-relay-contract.ts +16 -0
- package/lib/sdd-preflight.ts +53 -1
- package/package.json +5 -2
- package/runtime/gentle-ai-binary.mjs +173 -2
- package/runtime/git-commit-transaction.mjs +75 -15
- package/runtime/native-review-cli.mjs +524 -61
- package/runtime/review-integration-v2.mjs +536 -35
- package/runtime/review-relay-contract.mjs +17 -0
- package/scripts/build-git-commit-transaction-runner.mjs +1 -0
- package/scripts/check-provider-contract.mjs +138 -0
- package/scripts/gentle-ai-installer.mjs +23 -13
- package/scripts/maintainer/provider-relay-matrix.mjs +219 -0
- package/scripts/mirror-provider-contract.mjs +143 -0
- package/scripts/test-packed-runner.mjs +16 -2
- package/scripts/verify-package-files.mjs +110 -33
- package/skills/_shared/review-ledger-contract.md +4 -6
- package/skills/gentle-ai/SKILL.md +4 -4
- package/skills/issue-creation/SKILL.md +94 -168
- package/skills/judgment-day/SKILL.md +7 -1
- package/skills/judgment-day/references/prompts-and-formats.md +2 -0
- package/skills/rdd-defect-workflow/SKILL.md +54 -0
- package/tests/background-subagents.test.ts +771 -0
- package/tests/crosslane/cross-lane.mjs +1169 -0
- package/tests/delegated-key-learnings-contract.test.ts +238 -0
- package/tests/fixtures/devbinary/capabilities-v2.1.derived.json +331 -0
- package/tests/fixtures/devbinary/capabilities-v2.2.captured.json +340 -0
- package/tests/fixtures/devbinary/consent-v3.captured.json +37 -0
- package/tests/fixtures/devbinary/failure-v2-capture-evidence.captured.json +16 -0
- package/tests/fixtures/devbinary/result-artifact-v2-path.captured.json +12 -0
- package/tests/fixtures/devbinary/result-artifact-v2.captured.json +12 -0
- package/tests/fixtures/devbinary/start-v3-consent-declined.captured.json +19 -0
- package/tests/fixtures/devbinary/start-v3-consent-granted.captured.json +109 -0
- package/tests/fixtures/devbinary/status-v5-capture-result-submission.captured.json +184 -0
- package/tests/fixtures/devbinary/status-v5-repository-context.captured.json +138 -0
- package/tests/fixtures/devbinary/status-v5.captured.json +88 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/README.md +12 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/manifest.json +65 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/schemas/lens.schema.json +16 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/schemas/refuter.schema.json +1 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/schemas/targeted-validator.schema.json +1 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/vectors/lens.json +1 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/vectors/refuter.json +1 -0
- package/tests/fixtures/provider-contract-bundle/v1.1.0/vectors/targeted-validator.json +1 -0
- package/tests/gentle-ai-binary.test.ts +1 -1
- package/tests/gentle-ai-dev-binary-surfacing.test.ts +195 -0
- package/tests/gentle-ai-dev-binary.test.ts +336 -0
- package/tests/gentle-ai-installer.test.ts +46 -46
- package/tests/git-commit-transaction.test.ts +229 -1
- package/tests/maintainer/provider-relay.maintest.ts +265 -0
- package/tests/native-review-capability-contract.test.ts +48 -2
- package/tests/native-review-cli.test.ts +56 -0
- package/tests/native-review-consent.test.ts +164 -3
- package/tests/native-review-parity-runtime.test.ts +37 -0
- package/tests/native-review-parity.test.ts +218 -15
- package/tests/native-sdd-attempt-authority.test.ts +235 -0
- package/tests/orchestrator-budget.test.ts +30 -5
- package/tests/package-manifest.test.ts +98 -72
- package/tests/provider-contract-bundle.test.ts +385 -0
- package/tests/provider-contract-mirror.test.ts +206 -0
- package/tests/provider-defect-handoff.test.ts +355 -0
- package/tests/review-actor-tool-deny.test.ts +12 -13
- package/tests/review-candidate-view.test.ts +489 -9
- package/tests/review-compact-contract.test.ts +52 -119
- package/tests/review-controller-native-recovery.test.ts +643 -47
- package/tests/review-controller-native-routing.test.ts +1667 -222
- package/tests/review-controller-workspace-root.test.ts +17 -2
- package/tests/review-corrected-finalize-binding.test.ts +175 -0
- package/tests/review-dispatch-hydration-gap.test.ts +197 -0
- package/tests/review-host-relay-routing.test.ts +317 -0
- package/tests/review-host-relay.test.ts +520 -0
- package/tests/review-integration-v2-forward.test.ts +631 -0
- package/tests/review-integration-v2.test.ts +114 -0
- package/tests/review-ledger-contract.test.ts +12 -28
- package/tests/review-recovered-lineage-routing.test.ts +246 -0
- package/tests/review-relay-transport-agent.test.ts +249 -0
- package/tests/runtime-harness.mjs +242 -14
- package/tests/sdd-agent-tools.test.ts +18 -33
- package/tests/skill-collision-prefixes.test.ts +1 -0
- package/tests/skill-registry.test.ts +50 -1
- package/tests/verify-package-files.test.ts +62 -0
- package/assets/agents/review-refuter.md +0 -40
- package/assets/agents/review-validator.md +0 -23
- package/lib/native-review-remediation.ts +0 -49
- package/lib/review-compact.ts +0 -947
- package/lib/review-refuter-adapter.ts +0 -129
- package/lib/review-runtime-contract.ts +0 -68
- package/prompts/gcl.md +0 -54
- package/prompts/gis.md +0 -25
- package/prompts/gpr.md +0 -41
- package/prompts/gwr.md +0 -31
- package/tests/fixtures/native-review-cli/v2.1.2/bind-sdd.json +0 -25
- package/tests/fixtures/native-review-cli/v2.1.2/finalize.json +0 -8
- package/tests/fixtures/native-review-cli/v2.1.2/sdd-status-engram.json +0 -139
- package/tests/fixtures/native-review-cli/v2.1.2/sdd-status.json +0 -200
- package/tests/fixtures/native-review-cli/v2.1.2/start.json +0 -12
- package/tests/fixtures/native-review-cli/v2.1.2/validate-allow.json +0 -24
- package/tests/fixtures/native-review-cli/v2.1.2/validate-deny-empty-context.json +0 -20
- package/tests/fixtures/native-review-cli/v2.1.2/validate-deny.json +0 -28
- package/tests/review-compact.test.ts +0 -243
- package/tests/review-refuter-adapter.test.ts +0 -89
package/README.md
CHANGED
|
@@ -58,7 +58,7 @@ Most coding-agent sessions fail for operational reasons, not model reasons:
|
|
|
58
58
|
| **Skill creation workflow** | Provides the `gentle-ai-skill-creator`/`gentle-ai-skill-improver` skills, `/skill-creation` prompt, and packaged style guide for LLM-first skills. |
|
|
59
59
|
| **Delivery skills** | Includes issue-first PRs, chained PRs, work-unit commits, cognitive docs, comment writing, and Judgment Day review. |
|
|
60
60
|
| **Bounded native review** | Freezes one candidate, dispatches only controller-selected lenses, records native authority, and reuses the same content-bound receipt at delivery gates. |
|
|
61
|
-
| **Verified native runtime** | Provisions the exact package-local Gentle AI v2.
|
|
61
|
+
| **Verified native runtime** | Provisions the exact package-local Gentle AI v2.4.0 runtime: signed archives on Darwin/Linux and a Go SumDB-verified source build on Windows x64/arm64. It validates package-local integrity and rejects PATH, global, sibling, symlink, and mode fallbacks. |
|
|
62
62
|
| **Runtime safety** | Blocks destructive shell commands, asks for confirmation for sensitive operations, and blocks direct read/write/edit access to sensitive paths. |
|
|
63
63
|
|
|
64
64
|
## Install
|
|
@@ -79,7 +79,7 @@ pi install npm:gentle-pi@0.14.0
|
|
|
79
79
|
pi install npm:gentle-pi@latest
|
|
80
80
|
```
|
|
81
81
|
|
|
82
|
-
The latest RDD package installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned signed archives with archive and executable SHA-256 verification. Windows x64 and arm64 build the exact `v2.
|
|
82
|
+
The latest RDD package installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned signed archives with archive and executable SHA-256 verification. Windows x64 and arm64 build the exact `v2.4.0` source tag with a local Go 1.25.10+ toolchain, a sealed Go environment, `GOTOOLCHAIN=local`, and `GOSUMDB=sum.golang.org`; it does not download Go automatically. Windows provenance is Go-toolchain plus SumDB evidence and postinstall tamper detection, **not** Authenticode or protection against a malicious joint binary-and-manifest replacement. Package-private locks coordinate cooperative concurrent or crashed installers; their tombstones fail closed. A malicious same-user process with write access to package-private `node_modules` is outside that protocol because it can already replace package code, binary, or manifest, and portable Node has no pathname-delete CAS. It never uses `PATH` or a global `gentle-ai` installation. For development or offline installs only, set `GENTLE_PI_SKIP_GENTLE_AI_INSTALL=1`; native review operations then fail closed with an actionable `package-local-binary-missing` error until the package is reinstalled normally.
|
|
83
83
|
|
|
84
84
|
Recommended companion packages:
|
|
85
85
|
|
|
@@ -107,9 +107,10 @@ pi
|
|
|
107
107
|
/gentle:status Check package, SDD assets, OpenSpec, and global model config.
|
|
108
108
|
/gentle:doctor Run read-only diagnostics for SDD assets, config, tools, and guards.
|
|
109
109
|
/gentle:sdd-preflight Run or reuse the session SDD preflight explicitly.
|
|
110
|
-
/sdd-init Create or refresh openspec/config.yaml.
|
|
110
|
+
/sdd-init Create or refresh openspec/config.yaml (openspec/both stores only).
|
|
111
111
|
/gentle:models Assign global model/effort routing to SDD/custom agents.
|
|
112
112
|
/gentle:persona Switch between gentleman and neutral persona modes.
|
|
113
|
+
/gentle:background-subagents Show or set the managed background-subagents policy, with its deciding source.
|
|
113
114
|
/gentle:banner Configure startup rose, text logo, and color preset.
|
|
114
115
|
/gentle:commit-status Inspect an unresolved durable commit transaction.
|
|
115
116
|
/gentle:commit-abort Abandon safe recovery state without changing HEAD or the index.
|
|
@@ -165,13 +166,13 @@ parent git/status + clarify → bind ordinary snapshot/route → one worker writ
|
|
|
165
166
|
|
|
166
167
|
Review lenses are controller-selected transaction actors, not lifecycle hooks. `scout`/`context-builder` save parent context by compressing broad exploration. `worker` preserves a single writer thread. Commit, push, PR, and release validate receipts with zero actors.
|
|
167
168
|
|
|
168
|
-
Review actors are dispatched only through parent `subagent_run` calls in `mode: "task"`. Before execution, the controller verifies every entry, content hash, mode, root, and index in one selected immutable candidate tree per requested lens, then appends one bounded controller-owned block containing only the Git-derived base-to-candidate changed scope.
|
|
169
|
+
Review actors are dispatched only through parent `subagent_run` calls in `mode: "task"`. Before execution, the controller verifies every entry, content hash, mode, root, and index in one selected immutable candidate tree per requested lens, then appends one bounded controller-owned block containing only the Git-derived base-to-candidate changed scope. Readable scopes group paths by exact candidate mode and list deletions explicitly. Larger scopes use a canonical gzip/base64url manifest plus SHA-256; the read-only `gentle_review_scope` actor tool validates and paginates every changed path without traversing the ambient or full candidate tree. Oversized compressed transport, decompressed manifests, or response pages fail closed. Mixed batches, unselected/missing/stale views, user-supplied candidate-view text, unsafe paths, and non-task dispatches also fail closed; review actors retain no shell or mutation tools.
|
|
169
170
|
|
|
170
171
|
### Review authority recovery and reset safety
|
|
171
172
|
|
|
172
173
|
Legacy pre-graph authority is never migrated. `gentle_review inspect` reports an exact repository-bound destructive reset challenge for legacy corruption; after that fresh interactive authorization, RESET and RECOVER_LOCK route to the audited native `gentle-ai review reclaim` operation and RECOVER routes to native `gentle-ai review recover`, so every destructive transition is executed and audited by the native authority store. Native inputs the request did not carry return a `native-input-required` envelope instead of being invented. Existing graph-v1 ordinary lineages remain readable and gate-validatable but are read-only; Judgment Day remains mutable on graph-v1.
|
|
173
174
|
|
|
174
|
-
`gentle_review abandon`, `quarantine-legacy`, and `reconcile-authority` remain explicit v2.1.11 maintenance routes. Pi derives and displays the published
|
|
175
|
+
`gentle_review abandon`, `quarantine-legacy`, and `reconcile-authority` remain explicit v2.1.11 maintenance routes. Pi derives and displays the published nine-line `gentle-ai.review-abandon-authorization/v2` binding only for a caller-specified compact lineage, revision, snapshot identity, and discarded-work summary (captured lens results, findings presence, evidence-record presence); the native CLI re-derives non-terminal compact-v2 eligibility and the exact discarded work before accepting it. Legacy quarantine accepts only `historical findings freeze changed unrelated transaction state` with disposition `quarantine-malformed-freeze-event` and uses its exact eight-line binding. Both require fresh interactive approval and fail closed headlessly.
|
|
175
176
|
|
|
176
177
|
`gentle_review reconcile-authority` accepts one predecessor lineage and revision, one successor lineage and revision, an actor, and a reason. Pi derives the exact seven-line `gentle-ai.review-reconcile-authorization/v1` binding, or appends exactly `anomalies=unchanged_target,malformed_recovery_authorization` for the published dual anomaly in that order. Native code re-derives every anomaly; malformed bindings, changed revisions, unavailable native support, cancellation, and native refusal fail closed through typed envelopes.
|
|
177
178
|
|
|
@@ -253,15 +254,15 @@ flowchart TD
|
|
|
253
254
|
|
|
254
255
|
Lifecycle gates never launch review actors. They rederive Git and publication targets, validate the existing receipt, and authorize one exact command. Any target drift, stale evidence, malformed authority, or unprovable state blocks delivery instead of silently reopening review.
|
|
255
256
|
|
|
256
|
-
Native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v2.
|
|
257
|
+
Native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v2.4.0 executable, independently hashes it, then negotiates `gentle-ai.review-integration/v2` outside the repository. Capabilities are cached by that executable digest. Every START, target status, FINALIZE, validate, and BIND-SDD request passes the same contract identifier. Negotiated envelopes decode exactly against the vendored schemas; `recover` routes only the provider-selected `action_disposition`, and optional additions require a future compatible schema/minor that the provider explicitly advertises and the consumer negotiates.
|
|
257
258
|
|
|
258
|
-
|
|
259
|
+
Contract `/v2` replaces the Base64 `candidate_diff` reviewer transport of `/v1` with immutable `base_tree`/`candidate_tree` plus an ordered `changed_path_manifest` and never an inline patch. `gentle-pi` negotiates `/v2` only, with no dual-lane fallback; the cutover landed as one atomic commit against gentle-ai v2.2.2 (tracked by the `migrate-review-integration-v2` change), and the `/v1` schemas stay packaged because the `/v2` schemas `$ref` into their fragments. This provider contract version is unrelated to Pi's own internal "compact-v2" review-authority naming used below — the shared digit is coincidental, not a version pairing.
|
|
259
260
|
|
|
260
261
|
Target status owns `current_target`, `unrelated`, `ambiguous`, and `corrupted` applicability and returns one native action. Pi does not reconstruct ordinary authority from provider-private files or choose a lineage from repository-wide history. Restart recovery rebuilds only the derived candidate view from the native Git/content projection, including intended-untracked paths, symlinks, and immutable gitlink identities. Native failure envelopes retain their exact mutation outcome, replayability, required inputs, request digest, and next action. After an unknown or lost mutating result, Pi calls target status before any replay decision and returns only the provider-declared action.
|
|
261
262
|
|
|
262
263
|
Direct authorized `git commit` commands use a durable recovery record under the Git common directory. The package runs the effective pre-commit hook once, captures the post-hook index, performs final native validation against that tree, suppresses only the already-completed pre-commit hook while preserving message/post hooks through proxies, and proves `HEAD^{tree}` before the tool result succeeds. Any unresolved, interrupted, failed, or mismatched transaction blocks push, PR, and release. Recovery never resets HEAD or the index automatically.
|
|
263
264
|
|
|
264
|
-
Once the pinned gentle-ai runtime (currently v2.
|
|
265
|
+
Once the pinned gentle-ai runtime (currently v2.4.0) has written review authority, rollback MUST preserve every native store and receipt and MUST NOT run a downgraded binary against that repository. Disable the Pi route or roll forward to a compatible authority-aware release instead; deleting authority data or reinstalling an older binary is not a rollback path.
|
|
265
266
|
|
|
266
267
|
### FINALIZE wrapper input
|
|
267
268
|
|
|
@@ -334,7 +335,7 @@ SDD completion adds no review or Judgment Day pass.
|
|
|
334
335
|
|
|
335
336
|
Review operations, validation, and SDD perform no push, PR creation, release, or publication. The separate durable commit runner may create exactly one local commit only after final native pre-commit validation and post-commit tree proof.
|
|
336
337
|
|
|
337
|
-
`review-refuter`
|
|
338
|
+
Adversarial review roles (the refuter and the targeted validator) are never Pi-authored: the provider renders self-contained `review.capture-refuter` / `review.capture-validation` vectors and Go runs its own locked-down `pi` process on them. Package agent assets remain a package-managed isolated installation. Project and user overrides may shadow a package asset; `gentle-pi` preserves those definitions and does not claim their effective permissions are package-compliant.
|
|
338
339
|
|
|
339
340
|
## SDD/OpenSpec flow
|
|
340
341
|
|
|
@@ -594,11 +595,12 @@ Legacy string entries are still accepted and treated as `model`-only config.
|
|
|
594
595
|
| `/gentle:doctor` | Runs read-only diagnostics for SDD assets, model/persona config, memory tools, and safety guards. |
|
|
595
596
|
| `/gentle:models` | Opens global model + effort assignment UI. Press `x` to export and `r` to restore saved routing. |
|
|
596
597
|
| `/gentle:persona` | Switches global persona mode, with project override support. |
|
|
598
|
+
| `/gentle:background-subagents` | Shows or sets the managed background-subagents policy (`status\|enable\|disable`), naming the source that decided it. |
|
|
597
599
|
| `/gentle:banner` | Configures startup banner rose, text logo, and color preset. |
|
|
598
600
|
| `/gentle:toggle-rose` | Toggles the startup rose. |
|
|
599
601
|
| `/gentle:toggle-text-logo` | Toggles the startup text logo. |
|
|
600
602
|
| `/gentle:banner-color` | Selects a startup banner color preset. |
|
|
601
|
-
| `/sdd-init` | Initializes or refreshes `openspec/config.yaml
|
|
603
|
+
| `/sdd-init` | Initializes or refreshes `openspec/config.yaml` (openspec/both stores only). |
|
|
602
604
|
| `/gentle:install-sdd` | Repairs missing global SDD runtime assets without overwriting files. |
|
|
603
605
|
| `/gentle:install-sdd --force` | Force-refreshes installed global SDD assets. |
|
|
604
606
|
| `/skill-registry:refresh` | Regenerates `.atl/skill-registry.md`. |
|
|
@@ -606,6 +608,29 @@ Legacy string entries are still accepted and treated as `model`-only config.
|
|
|
606
608
|
|
|
607
609
|
Package-owned global SDD runtime assets are also refreshed automatically on session start when `gentle-pi` changes. Project-local `.pi/agents` and `.pi/chains` remain manual overrides and are never overwritten by startup refresh.
|
|
608
610
|
|
|
611
|
+
### Background subagents policy
|
|
612
|
+
|
|
613
|
+
Background delegation is off unless you turn it on. The policy is user-owned: only an explicit `/gentle:background-subagents enable` or `disable` writes it, and Pi automation never toggles it.
|
|
614
|
+
|
|
615
|
+
```text
|
|
616
|
+
/gentle:background-subagents Report the effective policy, the deciding source, and the resolved capability.
|
|
617
|
+
/gentle:background-subagents enable Write "on" to the global file.
|
|
618
|
+
/gentle:background-subagents disable Write "off" to the global file.
|
|
619
|
+
```
|
|
620
|
+
|
|
621
|
+
Four sources can decide the policy, and the first hit wins:
|
|
622
|
+
|
|
623
|
+
| Priority | Source | Notes |
|
|
624
|
+
| -------- | ------------------------------------------------- | ------------------------------------------------------------ |
|
|
625
|
+
| 1 | `<cwd>/.pi/gentle-ai/background-subagents.json` | Project file. Outranks everything, including a global write. |
|
|
626
|
+
| 2 | `<configHome>/background-subagents.json` | Global file, written by `enable`/`disable`. `configHome` honors `GENTLE_PI_CONFIG_HOME` and defaults to `~/.pi/gentle-ai`. |
|
|
627
|
+
| 3 | `GENTLE_PI_BACKGROUND_SUBAGENTS` | Exactly `on` or `off`. Any other value is ignored. |
|
|
628
|
+
| 4 | Built-in default | `off`. |
|
|
629
|
+
|
|
630
|
+
Both files use the strict shape `{"schema":"gentle-pi.background-subagents/v1","policy":"on"}`. A file that is present but malformed fails closed to `off` and is **not** skipped in favor of a lower-priority source, so a typo in the project file disables background subagents rather than silently handing the decision to the global file. The command reports that case as a warning instead of an ordinary `off`.
|
|
631
|
+
|
|
632
|
+
Because the project file outranks the global one, `enable` still writes the global file but reports plainly when a project file keeps the effective policy unchanged. The resolved capability (`ready` or `absent`) reports whether `subagent_run` is actually callable in this session; a policy of `on` with capability `absent` means the subagents package is not installed.
|
|
633
|
+
|
|
609
634
|
Startup banner settings are global and default to the current pink rose + text logo. Supported color presets are `pink`, `cyan`, `yellow`, and `green`.
|
|
610
635
|
|
|
611
636
|
Startup flag:
|
|
@@ -666,12 +691,16 @@ Memory contract for SDD delegation:
|
|
|
666
691
|
| `extensions/startup-banner.ts` | Shows and configures the startup intro, color presets, compact runtime panel, and collaboration credit. |
|
|
667
692
|
| `extensions/sdd-init.ts` | Registers `/sdd-init` for OpenSpec initialization. |
|
|
668
693
|
| `extensions/skill-registry.ts` | Maintains `.atl/skill-registry.md` from project/user skills and closes file watchers on shutdown. |
|
|
669
|
-
| `assets/orchestrator.md` | Parent-session orchestration contract.
|
|
694
|
+
| `assets/orchestrator.md` | Parent-session orchestration contract (always-on core). |
|
|
695
|
+
| `assets/orchestrator-delegation.md` | Lazy-loaded delegation/routing/review detail, including the mirrored gentle-ai canon. |
|
|
696
|
+
| `assets/orchestrator-memory.md` | Lazy-loaded SDD memory phase table, artifact keys, and lifecycle rule. |
|
|
697
|
+
| `assets/orchestrator-skills.md` | Lazy-loaded skill registry fallback semantics and intent-driven skill discovery. |
|
|
698
|
+
| `assets/sdd-orchestrator-workflow.md` | Lazy-loaded SDD workflow surface for the parent orchestrator. |
|
|
670
699
|
| `assets/agents/` | SDD agents installed as global Pi runtime assets. |
|
|
671
700
|
| `assets/chains/` | SDD chains installed as global Pi runtime assets. |
|
|
672
701
|
| `assets/support/` | Strict TDD support docs for apply/verify phases. |
|
|
673
702
|
| `skills/` | Gentle AI delivery and collaboration skills. |
|
|
674
|
-
| `prompts/` |
|
|
703
|
+
| `prompts/` | The `/skill-creation` prompt template. |
|
|
675
704
|
| `docs/skill-style-guide.md` | Normative style guide used by the packaged skill creation/improvement skills. |
|
|
676
705
|
| `docs/native-authority-architecture.md` | Post-U8 ownership boundary, reproducible slimming metrics, Windows evidence, exact #191 seam, and the `review-integration/v1`→`v2` migration status, including the "compact-v2" naming disambiguation. |
|
|
677
706
|
| `docs/review-integration.md` | Negotiated provider/consumer contract and the current Gentle Pi adoption boundary. |
|
|
@@ -695,6 +724,35 @@ node --experimental-strip-types --check extensions/startup-banner.ts
|
|
|
695
724
|
npm pack --dry-run
|
|
696
725
|
```
|
|
697
726
|
|
|
727
|
+
### Running the cross-lane battery
|
|
728
|
+
|
|
729
|
+
The cross-lane battery (`tests/crosslane/cross-lane.mjs`) validates the adapter against a real `gentle-ai` binary, end to end and out of CI on purpose. The pinned decoder lane only ever sees vendored fixtures, so new envelope schemas and full controller sequencing are never driven through a live lifecycle before merge; the battery closes that gap.
|
|
730
|
+
|
|
731
|
+
```bash
|
|
732
|
+
pnpm test:cross-lane # requires the dev-binary override
|
|
733
|
+
pnpm test:cross-lane --with-model # adds the real Go-owned pi reviewer run (model spend)
|
|
734
|
+
```
|
|
735
|
+
|
|
736
|
+
What it checks, against live scratch repositories:
|
|
737
|
+
|
|
738
|
+
- a low-risk lifecycle from START to a `pre-commit` gate allow;
|
|
739
|
+
- the medium-risk `consent/v3` granted round-trip through the direct decoder lane;
|
|
740
|
+
- controller sequencing: at every step the client's decoded offered next step must equal the native transition, including that correction evidence is collected before targeted validation is ever offered, through a full correction lifecycle to an approved receipt;
|
|
741
|
+
- the audited abandon end to end, asserting the adapter builds the exact nine-line `gentle-ai.review-abandon-authorization/v2` discarded-work binding and the native gate commits the quarantine record;
|
|
742
|
+
- forward-decoder freshness: every live envelope captured from the binary must decode without unknown-key rejection, the early warning that gentle-ai main grew a field gentle-pi lacks;
|
|
743
|
+
- with `--with-model`, one real locked-down `pi` reviewer run captured through the native transport.
|
|
744
|
+
|
|
745
|
+
Prerequisites:
|
|
746
|
+
|
|
747
|
+
- A real `gentle-ai` binary selected through the dev-binary override; there is no PATH or pinned-binary fallback, and the battery refuses to run without one. Either export `GENTLE_PI_GENTLE_AI_DEV_BINARY=<absolute path>` for the session, or register a persistent override with `/gentle:dev-binary <absolute path>` (stored at `~/.pi/gentle-ai/dev-binary.json` with schema `gentle-pi.dev-binary/v1`; the environment variable takes precedence over the registration, and the binary is re-validated and re-hashed on every resolution). Any real build works: an installed release binary or a locally built gentle-ai main.
|
|
748
|
+
- A Git checkout or worktree of this repository. The battery is a contributor tool wired to the repository layout and is excluded from `pnpm test` and CI by construction; run it from the repo, not from an installed Pi package.
|
|
749
|
+
|
|
750
|
+
The battery creates throwaway scratch repositories under the OS temp directory and never touches the enclosing repository. The default run spends no model tokens; `--with-model` launches one real reviewer model run and costs model spend.
|
|
751
|
+
|
|
752
|
+
It prints one PASS/FAIL/SKIP row per check plus a note, and exits non-zero when any check fails. Checks blocked by a known upstream class are reported with a `known-red` prefix instead of being hidden.
|
|
753
|
+
|
|
754
|
+
Running this battery against new gentle-ai builds (release candidates or main) and reporting red checks is a valuable contribution. The sibling provider-side battery lives at `scripts/cross-lane-battery.sh` in [Gentleman-Programming/gentle-ai](https://github.com/Gentleman-Programming/gentle-ai).
|
|
755
|
+
|
|
698
756
|
Publish npm through GitHub Actions only:
|
|
699
757
|
|
|
700
758
|
```bash
|
|
@@ -20,10 +20,10 @@ Use this agent only for scoped implementation work that is too large for the par
|
|
|
20
20
|
Before repository work:
|
|
21
21
|
|
|
22
22
|
1. Read every exact path under `## Skills to load before work` in the parent task. Do not rediscover the skill registry.
|
|
23
|
-
2. Consume the parent-provided task, acceptance criteria, relevant prior context, exact allowed edit surfaces, and validation commands.
|
|
23
|
+
2. Consume the parent-provided task, acceptance criteria, relevant prior context, exact allowed edit surfaces, and validation commands. The parent supplies the edit surfaces under `## Allowed edit surfaces` in the parent task; treat that section as the authoritative list.
|
|
24
24
|
3. Inspect the working tree and preserve pre-existing changes. Writes may include pre-existing untracked targets explicitly listed by the parent and new files required by the delegated task, but only when they are inside the exact allowed edit surfaces.
|
|
25
25
|
4. Preserve every unrelated tracked or untracked file. Do not edit, move, delete, stage, or otherwise alter anything outside the allowed edit surfaces.
|
|
26
|
-
5. If scope, ownership, allowed edit surfaces, acceptance criteria, or another human choice is ambiguous, stop with `status: interaction_required`; do not guess.
|
|
26
|
+
5. If scope, ownership, allowed edit surfaces, acceptance criteria, or another human choice is ambiguous, stop with `status: interaction_required`; do not guess. Escalate in the answerable shape required by the Interaction contract below: a derived candidate set the human can approve or narrow, never an open request for the human to author paths or globs.
|
|
27
27
|
|
|
28
28
|
Do not read persistent memory for context. The parent selects and forwards relevant observations.
|
|
29
29
|
|
|
@@ -67,6 +67,10 @@ Run focused tests first. Broad suites, builds, formatters, or linters may run on
|
|
|
67
67
|
|
|
68
68
|
When any human input is required, stop editing and return the full schema in the Return contract with `status: interaction_required` and the nested `interaction_required` payload completed. Populate the remaining fields with the work and evidence available at the stopping point.
|
|
69
69
|
|
|
70
|
+
Every interaction must be answerable from the payload alone. State the concrete choices in `options` as a closed set the human can approve, decline, or select from, and never ask the human to author paths, globs, identifiers, or commands as free text.
|
|
71
|
+
|
|
72
|
+
When the missing input is the allowed edit surface, derive the candidate set before stopping: put the exact repository-relative paths the delegated task would touch in `options`, and ask the human to approve that list or name which entries to drop. Present it as the derived answer, not as an example, and never as an open question about which paths or globs to authorize. If the delegated task gives no basis for even a candidate list, say that plainly in `reason` and name the missing evidence in `unblock_response`.
|
|
73
|
+
|
|
70
74
|
Do not return `blocked` for a human decision and do not invent a second interaction shape.
|
|
71
75
|
|
|
72
76
|
## Return contract
|
|
@@ -92,7 +96,7 @@ skill_resolution: paths-injected | paths-invalid | none
|
|
|
92
96
|
interaction_required: <include only when status is interaction_required>
|
|
93
97
|
question: <same deterministic interaction question>
|
|
94
98
|
reason: <same deterministic blocking reason>
|
|
95
|
-
options: <same
|
|
99
|
+
options: <same closed set of concrete choices; for a missing edit surface, the derived candidate paths>
|
|
96
100
|
unblock_response: <same exact context needed to continue>
|
|
97
101
|
```
|
|
98
102
|
|
|
@@ -5,7 +5,7 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
9
|
- bash
|
|
10
10
|
---
|
|
11
11
|
|
|
@@ -34,6 +34,8 @@ Initial discovery and scoped re-judgment are separate modes.
|
|
|
34
34
|
|
|
35
35
|
During initial discovery, run exactly once against the supplied `initial_review_tree` and return candidate rows only.
|
|
36
36
|
|
|
37
|
+
Sweep budget: run one exhaustive read-only sweep, then stop — at most two sweeps for a full-4R-scale target (hot auth/update/security/payments paths, or more than 400 changed lines). There is no loop-until-dry mechanism; the sweep budget is the entire discovery pass.
|
|
38
|
+
|
|
37
39
|
During initial discovery, do not persist state, mutate claims, launch actors, request fixes, validate fixes, or deliver anything.
|
|
38
40
|
|
|
39
41
|
On controller-requested scoped re-judgment, receive only requested frozen IDs, their exact hash-bound rows, and the fix diff.
|
|
@@ -5,7 +5,7 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
9
|
- bash
|
|
10
10
|
---
|
|
11
11
|
|
|
@@ -34,6 +34,8 @@ Initial discovery and scoped re-judgment are separate modes.
|
|
|
34
34
|
|
|
35
35
|
During initial discovery, run exactly once against the supplied `initial_review_tree` and return candidate rows only.
|
|
36
36
|
|
|
37
|
+
Sweep budget: run one exhaustive read-only sweep, then stop — at most two sweeps for a full-4R-scale target (hot auth/update/security/payments paths, or more than 400 changed lines). There is no loop-until-dry mechanism; the sweep budget is the entire discovery pass.
|
|
38
|
+
|
|
37
39
|
During initial discovery, do not persist state, mutate claims, launch actors, request fixes, validate fixes, or deliver anything.
|
|
38
40
|
|
|
39
41
|
On controller-requested scoped re-judgment, receive only requested frozen IDs, their exact hash-bound rows, and the fix diff.
|
|
@@ -5,9 +5,12 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
|
+
- gentle_review_scope
|
|
9
10
|
---
|
|
10
11
|
|
|
12
|
+
> Manual/compat-lane only: the provider host-relay capture path never loads this agent definition; native lens capture materializes the Go-issued opaque prompt through the gentle-pi host relay.
|
|
13
|
+
|
|
11
14
|
You are **R2 Readability**, a read-only reviewer. Find clarity problems; do not fix them.
|
|
12
15
|
|
|
13
16
|
Rule sources: ai-course-2 slides `05-code-smells.md`, `06-safe-refactoring.md`, `07-advanced-refactoring.md`, `08-tech-debt.md`, `22-docs-as-code.md`, `25-executive-summary.md`.
|
|
@@ -5,9 +5,12 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
|
+
- gentle_review_scope
|
|
9
10
|
---
|
|
10
11
|
|
|
12
|
+
> Manual/compat-lane only: the provider host-relay capture path never loads this agent definition; native lens capture materializes the Go-issued opaque prompt through the gentle-pi host relay.
|
|
13
|
+
|
|
11
14
|
You are **R3 Reliability**, a read-only reviewer. Find test and behavior risks; do not fix them.
|
|
12
15
|
|
|
13
16
|
Rule sources: ai-course-2 slides `01-testing-setup.md`, `02-tdd-implementation.md`, `03-integration-testing.md`, `04-e2e-testing.md`, `10-strategic-coverage.md`, `11-playwright-visibility.md`, `12-quality-gates-husky.md`, `23-apis-components.md`.
|
|
@@ -5,9 +5,12 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
|
+
- gentle_review_scope
|
|
9
10
|
---
|
|
10
11
|
|
|
12
|
+
> Manual/compat-lane only: the provider host-relay capture path never loads this agent definition; native lens capture materializes the Go-issued opaque prompt through the gentle-pi host relay.
|
|
13
|
+
|
|
11
14
|
You are **R4 Resilience**, a read-only reviewer. Find operational failure risks; do not fix them.
|
|
12
15
|
|
|
13
16
|
Rule sources: ai-course-2 slides `09-essential-metrics.md`, `13-observability-strategy.md`, `14-sentry-implementation.md`, `15-sentry-errors.md`, `16-sentry-performance.md`, `17-sentry-alertas.md`, `29-performance-percibida.md`.
|
|
@@ -5,9 +5,12 @@ tools:
|
|
|
5
5
|
- "*": false
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
|
+
- gentle_review_scope
|
|
9
10
|
---
|
|
10
11
|
|
|
12
|
+
> Manual/compat-lane only: the provider host-relay capture path never loads this agent definition; native lens capture materializes the Go-issued opaque prompt through the gentle-pi host relay.
|
|
13
|
+
|
|
11
14
|
You are **R1 Risk**, a read-only reviewer. Find security risks; do not fix them.
|
|
12
15
|
|
|
13
16
|
Rule sources: ai-course-2 slides `18-env-secrets.md`, `19-web-security.md`, `20-auth-tokens.md`, `21-owasp-top10.md`.
|
|
@@ -4,7 +4,7 @@ description: Implement SDD tasks with strict TDD evidence and review workload gu
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- edit
|
|
9
9
|
- write
|
|
10
10
|
- bash
|
|
@@ -146,3 +146,8 @@ Rules:
|
|
|
146
146
|
- Before returning, re-read the persisted tasks artifact and ensure completed tasks are visibly marked `- [x]`; internal todos are not completion evidence.
|
|
147
147
|
|
|
148
148
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
## Key Learnings Closing
|
|
152
|
+
|
|
153
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Archive a verified SDD change into OpenSpec source specs.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- bash
|
|
@@ -200,3 +200,8 @@ Include:
|
|
|
200
200
|
- Do NOT launch child subagents. Parent/orchestrator owns delegation.
|
|
201
201
|
|
|
202
202
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
## Key Learnings Closing
|
|
206
|
+
|
|
207
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Design the technical approach for an SDD change.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- mem_search
|
|
@@ -38,3 +38,8 @@ Persist this phase's artifact to the active backend before returning (mandatory)
|
|
|
38
38
|
- `none`: return the design inline.
|
|
39
39
|
|
|
40
40
|
Never claim persistence you did not perform.
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
## Key Learnings Closing
|
|
44
|
+
|
|
45
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,10 +4,9 @@ description: Explore an SDD change idea before proposal.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- edit
|
|
9
9
|
- write
|
|
10
|
-
- webfetch
|
|
11
10
|
- mem_save
|
|
12
11
|
---
|
|
13
12
|
|
|
@@ -37,3 +36,8 @@ Persist this phase's artifact to the active backend before returning (mandatory)
|
|
|
37
36
|
- `none`: return the exploration inline.
|
|
38
37
|
|
|
39
38
|
Never claim persistence you did not perform.
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
## Key Learnings Closing
|
|
42
|
+
|
|
43
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -5,7 +5,7 @@ model: openai-codex/gpt-5.3-codex
|
|
|
5
5
|
tools:
|
|
6
6
|
- read
|
|
7
7
|
- grep
|
|
8
|
-
-
|
|
8
|
+
- find
|
|
9
9
|
- write
|
|
10
10
|
- edit
|
|
11
11
|
- bash
|
|
@@ -24,21 +24,29 @@ Use your assigned executor/phase skill for this SDD phase. For project/user skil
|
|
|
24
24
|
If skill paths are missing, explicit fallback loading is allowed only as degraded self-healing. Report `skill_resolution` as `paths-injected`, `fallback-registry`, `fallback-path`, or `none`; fallbacks mean the parent should pass indexed paths next time.
|
|
25
25
|
|
|
26
26
|
- Inspect the project stack, test runner, conventions, and existing docs.
|
|
27
|
-
- If `openspec/config.yaml` is missing, create it automatically with project context, `strict_tdd`, phase rules, and testing runner details.
|
|
27
|
+
- If the artifact store is `openspec` or `both` and `openspec/config.yaml` is missing, create it automatically with project context, `strict_tdd`, phase rules, and testing runner details. If the artifact store is `engram` or `none`, do not create `openspec/` files.
|
|
28
28
|
- If `openspec/config.yaml` already exists, read it, summarize the current SDD/testing configuration, and do not block the caller. Update only safe derived context when explicitly necessary; never destructively rewrite user-maintained SDD configuration.
|
|
29
29
|
- Ensure `.atl/skill-registry.md` exists when skill registry data is available, or report that it is missing.
|
|
30
30
|
- Do NOT launch child subagents. Parent/orchestrator owns delegation.
|
|
31
31
|
- Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
32
|
+
|
|
32
33
|
## Memory Contract
|
|
33
34
|
|
|
34
35
|
Read any existing project context directly from the active backend before bootstrapping; do not wait for the parent to inline it. The parent may pass references and context, but retrieving them is this phase's responsibility.
|
|
35
36
|
|
|
36
37
|
Inputs to read (`engram`/`both`: use the injected Engram memory read tools for the topic key, then fetch the full observation; `openspec`: read the file under `openspec/`):
|
|
38
|
+
|
|
37
39
|
- Existing project context (if re-initializing): `sdd-init/{project}`
|
|
38
40
|
|
|
39
41
|
Persist this phase's artifact to the active backend before returning (mandatory):
|
|
42
|
+
|
|
40
43
|
- `engram`/`both`: call the injected Engram save tool with title and `topic_key` `"sdd-init/{project}"`, `type: "architecture"`, `project` from context, and `capture_prompt: false` when the tool schema supports it (omit the field if an older schema rejects it).
|
|
41
44
|
- `openspec`: write the project context file under `openspec/`.
|
|
42
45
|
- `none`: return the project context inline.
|
|
43
46
|
|
|
44
47
|
Never claim persistence you did not perform.
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
## Key Learnings Closing
|
|
51
|
+
|
|
52
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Guide a user through a complete SDD cycle on a small real project c
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- bash
|
|
@@ -41,3 +41,8 @@ Persist each demonstrated artifact to the active backend before moving on (manda
|
|
|
41
41
|
- `none`: walk through the artifacts inline.
|
|
42
42
|
|
|
43
43
|
Never claim persistence you did not perform.
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
## Key Learnings Closing
|
|
47
|
+
|
|
48
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Write an SDD proposal for an approved change idea.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- mem_search
|
|
@@ -51,3 +51,8 @@ Persist this phase's artifact to the active backend before returning (mandatory)
|
|
|
51
51
|
- `none`: return the proposal inline.
|
|
52
52
|
|
|
53
53
|
Never claim persistence you did not perform.
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
## Key Learnings Closing
|
|
57
|
+
|
|
58
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Write SDD delta specs with requirements and scenarios.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- mem_search
|
|
@@ -181,3 +181,8 @@ Archive will copy this new domain spec into `openspec/specs/{domain}/spec.md`.
|
|
|
181
181
|
- Do NOT launch child subagents. Parent/orchestrator owns delegation.
|
|
182
182
|
|
|
183
183
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
184
|
+
|
|
185
|
+
|
|
186
|
+
## Key Learnings Closing
|
|
187
|
+
|
|
188
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Show read-only structured SDD status for an active change.
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- bash
|
|
9
9
|
- mem_search
|
|
10
10
|
- mem_get_observation
|
|
@@ -113,3 +113,8 @@ If parent context reports `workspace-planning` and no `allowedEditRoots`, mark a
|
|
|
113
113
|
## Output
|
|
114
114
|
|
|
115
115
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution. Include the structured status block in `artifacts` or `executive_summary`.
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
## Key Learnings Closing
|
|
119
|
+
|
|
120
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Sync verified SDD delta specs into OpenSpec canonical specs without
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- bash
|
|
@@ -135,3 +135,8 @@ Include:
|
|
|
135
135
|
- Apply `rules.sync` from `openspec/config.yaml` when present.
|
|
136
136
|
|
|
137
137
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
## Key Learnings Closing
|
|
141
|
+
|
|
142
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Break SDD design/specs into implementation tasks with review worklo
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- write
|
|
9
9
|
- edit
|
|
10
10
|
- mem_search
|
|
@@ -98,3 +98,8 @@ Use `implementation` for RED/GREEN/TRIANGULATE/REFACTOR, code, tests, and apply-
|
|
|
98
98
|
- Do NOT launch child subagents. Parent/orchestrator owns delegation.
|
|
99
99
|
|
|
100
100
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
## Key Learnings Closing
|
|
104
|
+
|
|
105
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -4,7 +4,7 @@ description: Verify implementation against SDD specs, tasks, strict TDD evidence
|
|
|
4
4
|
tools:
|
|
5
5
|
- read
|
|
6
6
|
- grep
|
|
7
|
-
-
|
|
7
|
+
- find
|
|
8
8
|
- bash
|
|
9
9
|
- write
|
|
10
10
|
- edit
|
|
@@ -117,3 +117,8 @@ Write `openspec/changes/{change}/verify-report.md` with:
|
|
|
117
117
|
Do NOT launch child subagents. Parent/orchestrator owns delegation. Do NOT fix issues; report them.
|
|
118
118
|
|
|
119
119
|
Return the standard phase envelope with status, executive_summary, artifacts, next_recommended, risks, and skill_resolution.
|
|
120
|
+
|
|
121
|
+
|
|
122
|
+
## Key Learnings Closing
|
|
123
|
+
|
|
124
|
+
Close your final report text with a `## Key Learnings` block (no trailing colon). Use 1–5 numbered items, each a standalone factual sentence of at least 20 characters and at least 4 words. This applies to final report text only — not intermediate tool output or saved artifact content. The Engram memory provider automatically extracts and persists these items as passive capture; you do not parse the block or invoke passive-capture tools yourself. Omit the block when there is genuinely no reusable learning; no filler or speculation. This closing block is separate from explicit `mem_save` artifact/decision persistence.
|
|
@@ -3,6 +3,8 @@ name: 4r-review
|
|
|
3
3
|
description: One-shot lens-only 4R discovery against a supplied initial review tree; the controller owns all authority.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
> Manual/compat-lane only: the provider host-relay capture path never loads this chain; it exists solely for explicit manual 4R invocation.
|
|
7
|
+
|
|
6
8
|
## review-risk
|
|
7
9
|
|
|
8
10
|
output: review-risk-report.md
|
|
@@ -13,7 +13,7 @@ output: init.md
|
|
|
13
13
|
outputMode: file-only
|
|
14
14
|
progress: true
|
|
15
15
|
|
|
16
|
-
Initialize SDD context for {task} before any planning or implementation. If `openspec/config.yaml` is missing, inspect the project and create it automatically. If
|
|
16
|
+
Initialize SDD context for {task} before any planning or implementation. If the artifact store is `openspec` or `both` and `openspec/config.yaml` is missing, inspect the project and create it automatically. If the artifact store is `engram` or `none`, skip OpenSpec file creation. If `openspec/config.yaml` already exists, read it, refresh only safe derived context when appropriate, and report the current SDD/testing configuration without blocking the chain.
|
|
17
17
|
|
|
18
18
|
## sdd-explore
|
|
19
19
|
|
|
@@ -13,7 +13,7 @@ output: init.md
|
|
|
13
13
|
outputMode: file-only
|
|
14
14
|
progress: true
|
|
15
15
|
|
|
16
|
-
Initialize SDD context for {task} before planning. If `openspec/config.yaml` is missing, inspect the project and create it automatically. If
|
|
16
|
+
Initialize SDD context for {task} before planning. If the artifact store is `openspec` or `both` and `openspec/config.yaml` is missing, inspect the project and create it automatically. If the artifact store is `engram` or `none`, skip OpenSpec file creation. If `openspec/config.yaml` already exists, read it and report the current SDD/testing configuration without blocking the chain.
|
|
17
17
|
|
|
18
18
|
## sdd-proposal
|
|
19
19
|
|