gentle-pi 3.7.0 → 4.0.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 +37 -6
- package/assets/agents/gentle-ai-explore.md +4 -4
- package/assets/agents/gentle-ai-verify.md +6 -4
- package/assets/agents/gentle-ai-worker.md +7 -9
- package/assets/orchestrator-delegation.md +40 -41
- package/assets/orchestrator-memory.md +1 -22
- package/assets/orchestrator-skills.md +1 -1
- package/assets/orchestrator.md +12 -24
- package/assets/support/strict-tdd-verify.md +4 -266
- package/assets/support/strict-tdd.md +8 -360
- package/bin/gentle-shell.mjs +254 -29
- package/docs/delegated-verification.md +26 -1
- package/docs/gentle-agents-activity.md +24 -0
- package/docs/gentle-shell.md +92 -28
- package/docs/native-authority-architecture.md +2 -2
- package/docs/prompt-history.md +280 -0
- package/docs/readme-reference.md +112 -206
- package/docs/telemetry.md +1 -1
- package/docs/yolo-mode.md +86 -0
- package/extensions/child-context.ts +26 -0
- package/extensions/child-safety.ts +23 -0
- package/extensions/gentle-agents.ts +429 -262
- package/extensions/gentle-ai.ts +781 -683
- package/extensions/gentle-shell.ts +1375 -88
- package/extensions/gentle-stats.ts +101 -0
- package/extensions/gentle-todo.ts +18 -7
- package/extensions/history/atomic-write.ts +38 -0
- package/extensions/history/hide-prompts.ts +183 -0
- package/extensions/history/index.ts +1419 -0
- package/extensions/history/load-shared-history.ts +39 -0
- package/extensions/history/selector-helpers.ts +538 -0
- package/extensions/history/session-scan.ts +233 -0
- package/extensions/history/store.ts +1119 -0
- package/extensions/nan-provider.ts +6 -0
- package/extensions/quiet-tools.ts +179 -87
- package/extensions/resume-hint.ts +60 -0
- package/extensions/skill-registry.ts +16 -12
- package/extensions/startup-banner.ts +60 -31
- package/lib/agent-assets.ts +604 -0
- package/lib/agent-profile-pin.ts +12 -0
- package/lib/agents-message-delivery.ts +181 -0
- package/lib/agents-protocol.ts +60 -0
- package/lib/agents-runner.ts +96 -98
- package/lib/agents-view.ts +26 -3
- package/lib/agents-widget.ts +16 -9
- package/lib/append-system-prompt.ts +21 -0
- package/lib/bounded-writer-admission.ts +147 -0
- package/lib/card-style-policy.ts +60 -0
- package/lib/child-context-files.ts +166 -0
- package/lib/codemode-renderer.ts +185 -0
- package/lib/command-palette-catalog.ts +3 -9
- package/lib/command-palette.ts +25 -14
- package/lib/destructive-command-guard.ts +144 -0
- package/lib/gentle-ai-elapsed-store.ts +87 -0
- package/lib/gentle-ai-renderer.ts +196 -39
- package/lib/gentle-shell-launcher.ts +24 -13
- package/lib/gentle-shell-resume-hint.ts +176 -0
- package/lib/history-capture-policy.ts +95 -0
- package/lib/model-routing-authority.ts +5 -1
- package/lib/nan-provider.ts +227 -0
- package/lib/native-review-cli.ts +49 -108
- package/lib/odd-phase-inference.ts +231 -0
- package/lib/odd-phase.ts +141 -0
- package/lib/overlay-repaint.ts +26 -0
- package/lib/pi-tui-keys.ts +53 -0
- package/lib/review-candidate-view-owner.ts +67 -17
- package/lib/review-candidate-view.ts +112 -25
- package/lib/review-reminder-receipt.ts +48 -8
- package/lib/review-risk-assessment.ts +156 -11
- package/lib/review-sidebar-state.ts +223 -0
- package/lib/selection-engine.ts +515 -0
- package/lib/session-messaging-grants.ts +135 -0
- package/lib/session-worktree-registry.ts +14 -2
- package/lib/shell-bar.ts +179 -24
- package/lib/shell-card.ts +287 -18
- package/lib/shell-changes-view.ts +2 -1
- package/lib/shell-prompt.ts +102 -6
- package/lib/shell-sidebar-layout.ts +78 -14
- package/lib/shell-sidebar.ts +15 -1
- package/lib/shell-todo.ts +23 -13
- package/lib/shell-usage-view.ts +9 -4
- package/lib/shell-usage.ts +66 -10
- package/lib/stats-collector.ts +381 -0
- package/lib/stats-view.ts +431 -0
- package/lib/theme-customization.ts +52 -0
- package/lib/vim-editor-adapter.ts +379 -0
- package/lib/vim-normal-engine.ts +154 -0
- package/lib/vim-operator-engine.ts +416 -0
- package/lib/vim-policy.ts +49 -0
- package/lib/vim-visual-engine.ts +107 -0
- package/lib/visual-customization-policy.ts +108 -0
- package/lib/visual-customize-view.ts +330 -0
- package/lib/visual-profiles.ts +228 -0
- package/lib/yolo-session-policy.ts +240 -0
- package/package.json +20 -8
- package/runtime/gentle-shell-launcher.mjs +23 -12
- package/runtime/gentle-shell-resume-hint.mjs +177 -0
- package/runtime/native-review-cli.mjs +49 -108
- package/runtime/review-risk-assessment.mjs +154 -9
- package/scripts/build-runtime-modules.mjs +1 -0
- package/scripts/gentle-ai-installer.mjs +14 -13
- package/scripts/mirror-odd-routing.mjs +2 -2
- package/scripts/run-test-suite.mjs +76 -0
- package/scripts/test-packed-runner.mjs +31 -14
- package/scripts/verify-package-files.mjs +11 -22
- package/skills/branch-pr/SKILL.md +24 -52
- package/skills/chained-pr/SKILL.md +31 -15
- package/skills/chained-pr/references/chaining-details.md +31 -20
- package/skills/gentle-ai/SKILL.md +9 -15
- package/skills/issue-creation/SKILL.md +8 -2
- package/skills/issue-creation/references/delegated-workflow-actions.md +19 -0
- package/skills/work-unit-commits/SKILL.md +4 -3
- package/tests/agent-profiles.test.ts +18 -0
- package/tests/agents-fake-child.ts +2 -2
- package/tests/agents-message-delivery.test.ts +106 -0
- package/tests/agents-protocol.test.ts +40 -0
- package/tests/agents-runner.test.ts +378 -89
- package/tests/agents-view-thread-identity.test.ts +169 -0
- package/tests/agents-view.test.ts +8 -2
- package/tests/agents-widget.test.ts +154 -15
- package/tests/append-system-prompt-route.test.ts +160 -0
- package/tests/append-system-prompt.test.ts +46 -0
- package/tests/artifact-language.test.ts +19 -213
- package/tests/ask-user-question.test.ts +44 -1
- package/tests/asset-installation-runtime.test.ts +5 -16
- package/tests/autonomous-guard.test.ts +69 -1
- package/tests/bounded-writer-admission.test.ts +95 -0
- package/tests/branch-pr-skill.test.ts +43 -0
- package/tests/card-style-policy.test.ts +55 -0
- package/tests/chained-pr-skill.test.ts +124 -0
- package/tests/child-context-files.test.ts +255 -0
- package/tests/child-safety.test.ts +82 -0
- package/tests/codemode-rendering.test.ts +491 -0
- package/tests/command-palette.test.ts +39 -3
- package/tests/delegated-key-learnings-contract.test.ts +0 -76
- package/tests/destructive-command-guard.test.ts +84 -0
- package/tests/devbinary/native-review-parity.devtest.ts +170 -2
- package/tests/devbinary/non-git-subagent-bootstrap.devtest.ts +193 -0
- package/tests/fixtures/stats/sessions/--work-alpha--/2026-09-28T10-00-00-000Z_aaa.jsonl +7 -0
- package/tests/fixtures/stats/sessions/--work-alpha--/2026-09-29T23-00-00-000Z_bbb.jsonl +3 -0
- package/tests/fixtures/stats/sessions/--work-alpha--/2026-09-30T08-00-00-000Z_ddd.jsonl +2 -0
- package/tests/fixtures/stats/sessions/--work-alpha--/2026-09-30T09-00-00-000Z_eee.jsonl +3 -0
- package/tests/fixtures/stats/sessions/--work-alpha--/run-1/session.jsonl +2 -0
- package/tests/fixtures/stats/sessions/--work-beta--/2026-09-01T12-00-00-000Z_ccc.jsonl +2 -0
- package/tests/fixtures/stats/user-pi/sessions/--work-alpha--/2026-09-28T10-00-00-000Z_aaa.jsonl +2 -0
- package/tests/fixtures/stats/user-pi/sessions/--work-alpha--/2026-09-29T23-00-00-000Z_bbb.jsonl +4 -0
- package/tests/fixtures/stats/user-pi/sessions/--work-gamma--/2026-09-20T09-00-00-000Z_fff.jsonl +3 -0
- package/tests/generic-agent-tools.test.ts +54 -0
- package/tests/gentle-agents.test.ts +1047 -252
- package/tests/gentle-ai-binary.test.ts +3 -3
- package/tests/gentle-ai-elapsed-store.test.ts +68 -0
- package/tests/gentle-ai-installer.test.ts +68 -54
- package/tests/gentle-ai-renderer.test.ts +487 -8
- package/tests/gentle-ai.test.ts +288 -65
- package/tests/gentle-card-text.ts +2 -1
- package/tests/gentle-shell-bin.test.ts +651 -114
- package/tests/gentle-shell-launcher.test.ts +99 -52
- package/tests/gentle-shell-resume-hint.test.ts +270 -0
- package/tests/gentle-shell.test.ts +3839 -187
- package/tests/gentle-stats.test.ts +152 -0
- package/tests/gentle-theme.test.ts +4 -1
- package/tests/gentle-todo.test.ts +80 -8
- package/tests/history-atomic-write.test.ts +57 -0
- package/tests/history-capture-policy.test.ts +102 -0
- package/tests/history-command-registration.test.ts +164 -0
- package/tests/history-dedupe-entries.test.ts +123 -0
- package/tests/history-delete-backfill.test.ts +190 -0
- package/tests/history-delete-confirm.test.ts +460 -0
- package/tests/history-dispatch.test.ts +180 -0
- package/tests/history-drain-hidden.test.ts +110 -0
- package/tests/history-drain-order.test.ts +98 -0
- package/tests/history-expanded-globals.test.ts +62 -0
- package/tests/history-gc.test.ts +832 -0
- package/tests/history-header-layout.test.ts +265 -0
- package/tests/history-hide-prompts.test.ts +275 -0
- package/tests/history-lazy-windowing.test.ts +508 -0
- package/tests/history-legacy-migrate-v2.test.ts +297 -0
- package/tests/history-load-shared-history.test.ts +53 -0
- package/tests/history-max-results-cap.test.ts +76 -0
- package/tests/history-multi-reader.test.ts +203 -0
- package/tests/history-off-path.test.ts +170 -0
- package/tests/history-openflow-integration.test.ts +173 -0
- package/tests/history-overlay-margin.test.ts +326 -0
- package/tests/history-preview-layout.test.ts +93 -0
- package/tests/history-registry.test.ts +143 -0
- package/tests/history-scope-delete.test.ts +411 -0
- package/tests/history-search-caret-keys.test.ts +142 -0
- package/tests/history-seed-bootstrap.test.ts +170 -0
- package/tests/history-seed-regen.test.ts +129 -0
- package/tests/history-selector-windowing.test.ts +94 -0
- package/tests/history-session-scan-directory.test.ts +87 -0
- package/tests/history-session-scan-extract.test.ts +583 -0
- package/tests/history-session-writer.test.ts +351 -0
- package/tests/history-store-paths.test.ts +79 -0
- package/tests/history-tombstone-exact.test.ts +139 -0
- package/tests/history-wheel-mouse.test.ts +242 -0
- package/tests/inprocess-reviewer.test.ts +29 -19
- package/tests/issue-creation-skill.test.ts +61 -0
- package/tests/model-routing-authority.test.ts +16 -0
- package/tests/nan-provider.test.ts +471 -0
- package/tests/native-review-capability-contract.test.ts +7 -1
- package/tests/native-review-cli.test.ts +6 -120
- package/tests/native-review-parity-runtime.test.ts +100 -3
- package/tests/odd-integration.test.ts +67 -0
- package/tests/odd-phase-inference.test.ts +213 -0
- package/tests/odd-phase-loader.test.ts +253 -0
- package/tests/odd-phase.test.ts +307 -0
- package/tests/odd-routing-canonical-ratchet.test.ts +11 -6
- package/tests/odd-routing-contract.test.ts +86 -35
- package/tests/orchestrator-budget.test.ts +14 -39
- package/tests/orchestrator-rdd-ownership.test.ts +3 -3
- package/tests/overlay-repaint.test.ts +74 -0
- package/tests/package-manifest.test.ts +252 -115
- package/tests/packed-runner-owned-path.test.ts +46 -0
- package/tests/persona-single-channel.test.ts +6 -6
- package/tests/provider-defect-handoff.test.ts +3 -11
- package/tests/quiet-bash-runtime.test.ts +76 -0
- package/tests/quiet-tool-rendering.test.ts +409 -184
- package/tests/rdd-aware-verification-contract.test.ts +76 -1
- package/tests/rdd-status-line.test.ts +9 -4
- package/tests/resume-hint-extension.test.ts +122 -0
- package/tests/review-agent-end-preflight.test.ts +176 -12
- package/tests/review-candidate-owner-retry.test.ts +22 -1
- package/tests/review-candidate-view.test.ts +298 -0
- package/tests/review-contract-prompt.test.ts +108 -43
- package/tests/review-controller-lock-status.test.ts +0 -1
- package/tests/review-controller-native-routing.test.ts +611 -5
- package/tests/review-controller-workspace-root.test.ts +163 -4
- package/tests/review-host-relay-routing.test.ts +338 -2
- package/tests/review-integration-v2-forward.test.ts +200 -0
- package/tests/review-ledger-contract.test.ts +10 -34
- package/tests/review-reminder-receipt.test.ts +47 -1
- package/tests/review-risk-assessment.test.ts +498 -6
- package/tests/review-sidebar-state.test.ts +402 -0
- package/tests/run-test-suite.test.ts +124 -0
- package/tests/runtime-harness.mjs +145 -786
- package/tests/runtime-metrics-children.test.ts +16 -23
- package/tests/selection-engine.test.ts +421 -0
- package/tests/session-messaging-grants.test.ts +255 -0
- package/tests/session-worktree-registry.test.ts +77 -0
- package/tests/shell-bar.test.ts +382 -1
- package/tests/shell-card.test.ts +353 -1
- package/tests/shell-changes-view.test.ts +52 -0
- package/tests/shell-prompt.test.ts +94 -2
- package/tests/shell-sidebar-layout.test.ts +325 -21
- package/tests/shell-sidebar-scroll-benchmark.test.ts +255 -0
- package/tests/shell-todo.test.ts +87 -1
- package/tests/shell-usage-view.test.ts +27 -0
- package/tests/shell-usage.test.ts +73 -0
- package/tests/skill-registry.test.ts +50 -1
- package/tests/startup-banner.test.ts +130 -2
- package/tests/stats-collector.test.ts +195 -0
- package/tests/stats-view.test.ts +202 -0
- package/tests/telemetry-trigger.test.ts +81 -20
- package/tests/theme-customization.test.ts +72 -0
- package/tests/vim-editor-adapter-host-resolution.test.ts +37 -0
- package/tests/vim-editor-adapter.test.ts +804 -0
- package/tests/vim-normal-engine.test.ts +101 -0
- package/tests/vim-operator-engine.test.ts +215 -0
- package/tests/vim-policy.test.ts +19 -0
- package/tests/vim-visual-engine.test.ts +52 -0
- package/tests/visual-customization-policy.test.ts +110 -0
- package/tests/visual-customize-view.test.ts +418 -0
- package/tests/visual-profiles.test.ts +87 -0
- package/tests/yolo-customize.test.ts +256 -0
- package/tests/yolo-mode-runtime.test.ts +161 -0
- package/tests/yolo-mode.test.ts +261 -0
- package/tests/yolo-session-policy.test.ts +59 -0
- package/themes/Gentle.json +2 -1
- package/themes/Gentleman-Cute.json +2 -1
- package/themes/Gentleman-Sexy.json +2 -1
- package/assets/agents/sdd-apply.md +0 -159
- package/assets/agents/sdd-archive.md +0 -228
- package/assets/agents/sdd-design.md +0 -49
- package/assets/agents/sdd-explore.md +0 -48
- package/assets/agents/sdd-init.md +0 -56
- package/assets/agents/sdd-onboard.md +0 -52
- package/assets/agents/sdd-proposal.md +0 -64
- package/assets/agents/sdd-remediate.md +0 -37
- package/assets/agents/sdd-research.md +0 -49
- package/assets/agents/sdd-spec.md +0 -192
- package/assets/agents/sdd-status.md +0 -54
- package/assets/agents/sdd-tasks.md +0 -108
- package/assets/agents/sdd-verify.md +0 -124
- package/assets/chains/sdd-full.chain.md +0 -83
- package/assets/chains/sdd-plan.chain.md +0 -56
- package/assets/chains/sdd-verify.chain.md +0 -43
- package/assets/sdd-orchestrator-workflow.md +0 -319
- package/assets/support/sdd-status-contract.md +0 -77
- package/docs/assets/diagrams/sdd-cycle.svg +0 -14
- package/extensions/sdd-init.ts +0 -816
- package/lib/openspec-deltas.ts +0 -156
- package/lib/sdd-preflight.ts +0 -1066
- package/lib/sdd-research-capabilities.ts +0 -94
- package/lib/sdd-status.ts +0 -26
- package/tests/fixtures/legacy/sdd-research-v2.5.0.md +0 -54
- package/tests/fixtures/native-review-cli/v2.1.3/bind-sdd.json +0 -25
- package/tests/fixtures/v0.10.7/assets/agents/sdd-apply.md +0 -132
- package/tests/openspec-deltas.test.ts +0 -209
- package/tests/sdd-agent-tools.test.ts +0 -156
- package/tests/sdd-archive-replay.test.ts +0 -82
- package/tests/sdd-classical-continuation.test.ts +0 -74
- package/tests/sdd-execution-routing-contract.test.ts +0 -44
- package/tests/sdd-managed-runtime-settlement.test.ts +0 -155
- package/tests/sdd-native-managed-uptake.test.ts +0 -243
- package/tests/sdd-no-attempts-contract.test.ts +0 -15
- package/tests/sdd-odd-integration.test.ts +0 -33
- package/tests/sdd-optional-research.test.ts +0 -124
- package/tests/sdd-planning-routing-contract.test.ts +0 -45
- package/tests/sdd-preflight-rpc-input.test.ts +0 -125
- package/tests/sdd-preflight.test.ts +0 -541
- package/tests/sdd-research-capabilities.test.ts +0 -114
- package/tests/sdd-research-live.test.ts +0 -241
- package/tests/sdd-selection-transport.test.ts +0 -653
- package/tests/sdd-status.test.ts +0 -9
- package/tests/sdd-task-truth.test.ts +0 -43
package/docs/readme-reference.md
CHANGED
|
@@ -1,17 +1,15 @@
|
|
|
1
1
|
# README technical reference
|
|
2
2
|
|
|
3
|
-
This reference preserves
|
|
3
|
+
This reference preserves detailed installation, configuration, ODD, runtime, and contributor material previously carried by the README. Start with the [README](../README.md) for the product overview; use this document when you need operational detail. Historical compatibility and authority passages remain reference material, not newly endorsed operator instructions.
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
## Organic Driven Development
|
|
7
7
|
|
|
8
|
-
Organic Driven Development (ODD) keeps explore → implement → proportionate checks as the
|
|
9
|
-
|
|
10
|
-
Choose SDD explicitly when you want separate proposal, spec, design, tasks, and verification artifacts. Its phases and handoffs add coordination; everyday work usually needs the intent and evidence, not that extra workflow. ODD keeps those in one document. Size, ambiguity, and risk alone never select SDD.
|
|
8
|
+
Organic Driven Development (ODD) keeps explore → implement → proportionate checks as the development workflow. For substantial authorized implementation, the parent automatically tracks feature progress after exploration, without asking for task-tracking or storage permission. Small, understood work creates no durable task artifact; investigation and proposal-only work stay read-only.
|
|
11
9
|
|
|
12
10
|
### The ODD protocol
|
|
13
11
|
|
|
14
|
-
ODD
|
|
12
|
+
ODD runs on every request, without the user asking for a workflow, a plan, or task tracking.
|
|
15
13
|
|
|
16
14
|
1. **Authorize** — read-only unless implementation is authorized; ask one clarification when intent is ambiguous.
|
|
17
15
|
2. **Explore** — read existing code and requirements first, proportionately to the request.
|
|
@@ -25,11 +23,19 @@ ODD is the predefined workflow: it runs by default on every request, without the
|
|
|
25
23
|
- **Recovery:** write local progress first and read back both copies; writes are not atomic. Unavailable Engram leaves an explicit pending mirror, not invented success or a block on unrelated safe work. Before implementation or resume, the parent reads full feature memory and the actual task file, reconciles code and evidence, and preserves conflicting versions. Pass the locator and relevant context; workers read the document before edits. The existing Todo UI is a projection, not another authority.
|
|
26
24
|
- **Task size:** about 400 authored changed lines (additions plus deletions) is advisory only, not a cap, acceptance criterion, automatic stop, forced split, or RDD trigger. Keep coherent behavior with tests and docs, explain natural overages, and continue under existing PR policy. Forward this instruction to workers; never remove whitespace, comments, or tests, minify, invent abstractions, or split artificially for cosmetic savings.
|
|
27
25
|
- **Delegation boundary:** the parent delegates implementation touching two or more non-trivial files; a second direct path alone is not a runtime refusal. The runtime cannot infer whether an edit is mechanical from write history. Validate consequential premises before building, reuse relevant sibling findings, run focused checks while iterating, then the applicable full suite at closure. This is effort guidance, not a hard token or line budget.
|
|
28
|
-
- **Research:** optional research addresses a named uncertainty. Establish problem, intended outcome, constraints, and current evidence; inspect code and adapt depth to consequence, not fixed questionnaires or rounds. The parent asks one focused product question only when needed, then waits; workers return gaps. Use available authorized documentation/web tools, prefer primary sources, and attribute claims to URLs/code locations. Distinguish facts, assumptions, contradictions, freshness, and gaps; return a recommendation, tradeoffs, open questions, and implementation implications. Forward these instructions to
|
|
26
|
+
- **Research:** optional research addresses a named uncertainty. Establish problem, intended outcome, constraints, and current evidence; inspect code and adapt depth to consequence, not fixed questionnaires or rounds. The parent asks one focused product question only when needed, then waits; workers return gaps. Use available authorized documentation/web tools, prefer primary sources, and attribute claims to URLs/code locations. Distinguish facts, assumptions, contradictions, freshness, and gaps; return a recommendation, tradeoffs, open questions, and implementation implications. Forward these instructions to a fresh general worker. Unavailable evidence pauses only unsafe dependent decisions. Research stays read-only; a brief proposal is needed only for a real decision.
|
|
29
27
|
- **Assumptions:** at most one scoped independent read-only challenge for a high-consequence unproven premise, including a small security-critical change. Deterministic failures need fixes, not debate. Native RDD claims stay with its refuter.
|
|
30
|
-
- **TDD:** resolve on/off from existing project/session configuration or explicit user choice; retain source and exact runner in the feature document when present and forward all three on every implementation delegation, refreshing on resume. Test presence does not enable TDD. Enabled requires observed RED before implementation → GREEN → REFACTOR; disabled still requires ordinary functional checks. Unknown/conflicting mode or a missing runner needs only the clarification affecting the next action, never invented precedence
|
|
28
|
+
- **TDD:** resolve on/off from existing project/session configuration or explicit user choice; retain source and exact runner in the feature document when present and forward all three on every implementation delegation, refreshing on resume. Test presence does not enable TDD. Enabled requires observed RED before implementation → GREEN → REFACTOR; disabled still requires ordinary functional checks. Unknown/conflicting mode or a missing runner needs only the clarification affecting the next action, never invented precedence or commands.
|
|
31
29
|
- **Checks:** functional checks run per task; a TODO checkbox never triggers a review cycle. The native review candidate is a work-unit commit or a PR slice, never a TODO checkbox and never the accumulated feature branch. After each work-unit commit, when RDD is enabled, assess it with `gentle_review` `{"operation":"assess"}` and `{"baseRef":"<last reviewed boundary>","committedOnly":true}`. Passive or low stays silent and the boundary advances. High, or an unavailable or failed assessment, reviews the commit itself right away at that base. Medium defers to the PR slice, the commits accumulated since the last reviewed boundary, bounded by the delivery budget of about 400 authored changed lines, and reviews at slice close. The first boundary is the branch point, and every reviewed boundary becomes the next base. Record the assessed tier and outcome per task: granted, declined, passive, deferred to slice, or unavailable. Existing risk, consent, and authority stay unchanged; never infer low risk from a failed assessment. Never skip an existing delivery gate.
|
|
32
|
-
- **Delivery:** at feature-document creation, forecast authored changed lines (additions plus deletions, generated files excluded) from the task list, and keep a running count from work-unit commits. Choose one delivery strategy per feature: `ask-on-risk` (default), `auto-chain`, `single-pr`, or `exception-ok`. When the forecast or running count exceeds about 400 authored changed lines, apply the chosen strategy before the next commit. `ask-on-risk` asks once
|
|
30
|
+
- **Delivery:** at feature-document creation, forecast authored changed lines (additions plus deletions, generated files excluded) from the task list, and keep a running count from work-unit commits. Choose one delivery strategy per feature: `ask-on-risk` (default), `auto-chain`, `single-pr`, or `exception-ok`. When the forecast or running count exceeds about 400 authored changed lines, apply the chosen strategy before the next commit. `ask-on-risk` asks once using the ordered oversized-delivery menu; `auto-chain` asks only for a missing chain strategy and slices automatically with a cached choice. When either chaining path needs a choice, offer exactly these three semantic outcomes:
|
|
31
|
+
|
|
32
|
+
1. **Feature/tracker branch chain** — `chain_strategy=feature-branch-chain`; integrate the feature after reviewing child slices.
|
|
33
|
+
2. **Verified default/main branch chain** — `chain_strategy=stacked-to-main`; land slices in order on the verified destination default branch, not an assumed name.
|
|
34
|
+
3. **One single PR — least recommended** — `delivery_strategy=single-pr`; review the entire oversized change together.
|
|
35
|
+
|
|
36
|
+
Generate the complete user-facing question and every option label, description, and recommendation marker in the active user's conversation language (English for an English user, Spanish for a Spanish user, etc.). Machine strategy tokens remain unchanged and untranslated. These English examples are illustrative and localizable, not mandatory copy.
|
|
37
|
+
|
|
38
|
+
The third choice overrides the pending chaining path: clear the chain choice as inapplicable and suppress later chain prompts. `single-pr` is not a `chain_strategy` token; do not automatically select `exception-ok`. Least recommended is scoped to the oversized menu: larger single PRs increase reviewer load, slow feedback, and couple rollback. A focused ≤400-line single PR remains reasonable. Follow the destination repository's documented contribution/size policy; `size:exception` is a Gentle-owned repository policy, not a universal label requirement. Do not request or add it for generic users unless the destination policy uses it; keep applicable maintainer acceptance and protected-label authorization gates. Single-PR output requires no tracker, child dependency diagram, or Chain Context. Choosing shape does not authorize push, PR creation, merge, or review-mode/consent changes. Cache both choices, and record slice boundaries (which commits each PR holds) in the feature document for chains, or the whole-PR scope for single PR. Resolve the `work-unit-commits` and `chained-pr` skills by registry name before planning or creating any PR.
|
|
33
39
|
|
|
34
40
|
```mermaid
|
|
35
41
|
flowchart TD
|
|
@@ -67,9 +73,13 @@ flowchart TD
|
|
|
67
73
|
T --> X
|
|
68
74
|
R --> X
|
|
69
75
|
X --> AG{Running authored lines over 400?}
|
|
70
|
-
AG -->|Yes| AH
|
|
76
|
+
AG -->|Yes| AH{Apply selected delivery strategy}
|
|
71
77
|
AG -->|No| Y[Deliver]
|
|
72
|
-
AH
|
|
78
|
+
AH -->|Chain selected| CH[Chained PR slice]
|
|
79
|
+
AH -->|Single PR selected| SP[Single PR; no chain artifacts]
|
|
80
|
+
CH --> DP[Destination policy and existing authorization gates]
|
|
81
|
+
SP --> DP
|
|
82
|
+
DP --> Y
|
|
73
83
|
Z[Resume] --> AA[Full feature memory and actual task file]
|
|
74
84
|
AA --> AB[Reconcile requirements, code, proof and conflicts]
|
|
75
85
|
AB --> TC
|
|
@@ -82,7 +92,7 @@ This is guidance through existing tools, not a new CLI, phase, state engine, or
|
|
|
82
92
|
- [Capabilities](#capability-reference)
|
|
83
93
|
- [Installation and release policy](#install)
|
|
84
94
|
- [ODD workflow and recovery](#organic-driven-development)
|
|
85
|
-
- [
|
|
95
|
+
- [Review architecture](#review-authority-architecture-reference-only)
|
|
86
96
|
- [Configuration, commands, skills, memory, and telemetry](#persona-modes)
|
|
87
97
|
- [Package contents and development](#package-contents)
|
|
88
98
|
|
|
@@ -92,21 +102,19 @@ This is guidance through existing tools, not a new CLI, phase, state engine, or
|
|
|
92
102
|
| ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
93
103
|
| **el Gentleman persona** | Makes Pi behave like a senior architect and teacher, not a generic chatbot. Spanish responses use Rioplatense voseo by default; neutral mode is saved globally with project overrides. |
|
|
94
104
|
| **Configurable startup intro** | Adds a rose/text-logo startup intro, compact runtime panel, color presets, and commands to hide or show the decorative parts. |
|
|
95
|
-
| **Work routing discipline** | ODD keeps small tasks inline and delegates context-heavy work.
|
|
96
|
-
| **SDD/OpenSpec assets** | Installs phase agents and chains for `init`, `onboard`, `explore`, `proposal`, `spec`, `design`, `tasks`, `apply`, optional `verify` and `archive`. |
|
|
97
|
-
| **Lazy SDD preflight** | Confirms SDD mode, artifact store, delivery strategy, and review budget on the first SDD invocation of every interactive session, including saved preferences; the parent transports the confirmed block to RPC SDD children. |
|
|
105
|
+
| **Work routing discipline** | ODD keeps small tasks inline and delegates context-heavy work. |
|
|
98
106
|
| **Subagent orchestration** | Keeps one parent session responsible while child agents explore, implement, test, or review with focused context. |
|
|
99
|
-
| **Strict TDD support** | TDD mode, source, and runner come from configuration or explicit choice in ODD
|
|
107
|
+
| **Strict TDD support** | TDD mode, source, and runner come from configuration or explicit choice in ODD. Enabled TDD requires observed evidence; a test command alone does not enable it. |
|
|
100
108
|
| **Closed choice prompts** | Per-option hover/click/wheel in fullscreen; keyboard selection in either TUI mode. |
|
|
101
109
|
| **Native pointer regions** | Compose hover, press, click, and wheel behavior around public TUI components. |
|
|
102
110
|
| **Agent overlay close control** | Adds a header close button that adapts to available width. |
|
|
103
111
|
| **Reviewer protection** | Surfaces review workload risk before a task turns into an oversized PR. |
|
|
104
|
-
| **Per-agent model assignment** | Pi-native modal for assigning stronger or cheaper models to
|
|
112
|
+
| **Per-agent model assignment** | Pi-native modal for assigning stronger or cheaper models to packaged and custom agents. |
|
|
105
113
|
| **Skill discovery registry** | Maintains `.atl/skill-registry.md` from project and user skills so review/comment/PR workflows do not silently miss the right skill. |
|
|
106
114
|
| **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. |
|
|
107
115
|
| **Delivery skills** | Includes issue-first PRs, chained PRs, work-unit commits, cognitive docs, comment writing, and Judgment Day review. |
|
|
108
116
|
| **Bounded native review** | Freezes one candidate, dispatches only controller-selected lenses, and records native authority. Review outcomes are informational; delivery follows ordinary repository policy. |
|
|
109
|
-
| **Verified native runtime** | The current source checkout provisions the exact package-local Gentle AI
|
|
117
|
+
| **Verified native runtime** | The current source checkout provisions the exact package-local Gentle AI v4.0.0 runtime: signed, SHA-256-pinned release 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. |
|
|
110
118
|
| **Runtime safety** | Blocks destructive shell commands, asks for confirmation for sensitive operations, and blocks direct read/write/edit access to sensitive paths. |
|
|
111
119
|
|
|
112
120
|
## Native pointer regions
|
|
@@ -131,7 +139,9 @@ Pointer input is fullscreen-only. Regions preserve a consuming child's native re
|
|
|
131
139
|
`Text`, activate on press or wheel, synthesize outside leave events, or alter terminal tracking.
|
|
132
140
|
Callers own keyboard policy, theme state, and business actions.
|
|
133
141
|
|
|
134
|
-
**
|
|
142
|
+
**Bash UI tradeoff:** `quiet-tools` leaves Bash execution and UI to Pi, preserving configured `shellPath` and shell prefixes. Bash no longer uses Gentle's quiet cards or direct-command lifecycle renderer; the six other quiet tool cards and codemode remain unchanged.
|
|
143
|
+
|
|
144
|
+
**Migration note:** Do not enable `pi-tool-cards` and `quiet-tools` together: Pi rejects duplicate `read`, `edit`, and `write` registrations. Disable or remove the standalone package during migration; gentle-pi does not change those package registrations or delete that repository. The global fullscreen setting described below is a separate install-time change.
|
|
135
145
|
|
|
136
146
|
## Install
|
|
137
147
|
|
|
@@ -161,31 +171,13 @@ This installs the current npm release; select an explicit version if you need a
|
|
|
161
171
|
|
|
162
172
|
### Source checkout
|
|
163
173
|
|
|
164
|
-
This checkout declares `gentle-pi` `
|
|
165
|
-
|
|
166
|
-
The native SDD status consumer accepts both the pinned producer's legacy
|
|
167
|
-
`apply`/`verify`/`remediate`/`archive` instruction record and the classical
|
|
168
|
-
`apply`/`verify`/`archive` record. It preserves the provider's instructions and
|
|
169
|
-
selected route; it does not fabricate a remediation phase for a newer producer.
|
|
170
|
-
Unknown or incomplete instruction records still fail closed.
|
|
171
|
-
|
|
172
|
-
The Pi runtime now uses native status exclusively for SDD and retires standalone
|
|
173
|
-
sync. The full chain follows completed apply to archive, where applicable delta
|
|
174
|
-
specs are composed; verification remains explicitly invokable. With the current
|
|
175
|
-
3.7.0 pin, native still requires verification and its emitted evidence requirements;
|
|
176
|
-
a plain practical PASS report does not satisfy that legacy native gate. Pi forwards
|
|
177
|
-
those exact instructions without overriding readiness or inventing legacy evidence.
|
|
178
|
-
Classical direct-archive behavior is compatibility-tested with an identified
|
|
179
|
-
upstream development build, not presented as a published fix or version bump.
|
|
180
|
-
The complete classical flow awaits a compatible published native version; this
|
|
181
|
-
change does not bump the pin. Ordinary attempt governance and research/planning simplification remain separate
|
|
182
|
-
work under [SDD parity #1051](https://github.com/Gentleman-Programming/gentle-shell/issues/1051).
|
|
174
|
+
This checkout declares `gentle-pi` `4.0.0` with a package-local Gentle AI `v4.0.0` pin. Checkout metadata alone is not proof of npm publication; verify the registry version and its release workflow.
|
|
183
175
|
|
|
184
176
|
### Pi compatibility
|
|
185
177
|
|
|
186
|
-
The current package requires Pi 0.
|
|
178
|
+
The current package requires Pi 0.99.1 or newer and Node >=22.19.0. Development tests resolve Pi through the open `>=1.0.0` development range. The private Vim editor adapter admits only the audited Pi `0.99.1`, `0.99.2`, and `1.0.0` releases; any other release keeps ordinary prompt editing until its editor is audited. Use the latest Pi release; gentle-pi does not update your installed Pi automatically. Children, including any `GENTLE_PI_AGENTS_PI` override, must emit `agent_settled`: `agent_end` records a run's output but is not completion because retries or queued continuations may follow.
|
|
187
179
|
|
|
188
|
-
The [`v2.6.0` release](https://github.com/Gentleman-Programming/gentle-shell/releases/tag/v2.6.0) added persistent registered worktrees and grouped `/gentle:changes` views; fuller workspace interaction details are in the [Gentle Shell reference](gentle-shell.md). It also adds named atomic `/gentle:profiles`,
|
|
180
|
+
The [`v2.6.0` release](https://github.com/Gentleman-Programming/gentle-shell/releases/tag/v2.6.0) added persistent registered worktrees and grouped `/gentle:changes` views; fuller workspace interaction details are in the [Gentle Shell reference](gentle-shell.md). It also adds named atomic `/gentle:profiles`, native review intended-untracked selection and provider continuations, and opt-in custom ask responses. Pi recognizes its global Git-managed package path; subsystems install with explicit recovery guidance when npm lifecycle work was skipped. Windows keeps child consoles hidden and fixes ownership mode; Gentle Todo keeps the next pending task visible when collapsed.
|
|
189
181
|
|
|
190
182
|
### Install-time fullscreen
|
|
191
183
|
|
|
@@ -204,9 +196,9 @@ Native RDD was introduced in `gentle-pi` `v0.15.0` on 2026-07-10 with bounded re
|
|
|
204
196
|
pi install npm:gentle-pi@3.5.1
|
|
205
197
|
```
|
|
206
198
|
|
|
207
|
-
RDD remains opt-in. Enable it only through an explicit user decision with `/gentle:review-mode enable`; `status` lets you inspect the mode without changing it.
|
|
199
|
+
RDD remains opt-in. Enable it only through an explicit user decision with `/gentle:review-mode enable`; `status` lets you inspect the mode without changing it. The `.git/gentle-ai/candidate-views` parent must sit on a filesystem that honors private POSIX modes (or equivalent Windows ACLs); WSL DrvFS mounts without metadata can reject START before lineage creation.
|
|
208
200
|
|
|
209
|
-
The source checkout's RDD integration installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned release assets with asset and executable SHA-256 verification (signed archives for source pin `
|
|
201
|
+
The source checkout's RDD integration installs Gentle AI only into its private `.gentle-ai/` directory. Darwin and Linux use pinned release assets with asset and executable SHA-256 verification (signed archives for source pin `v4.0.0`; raw prerelease binaries only under a prerelease pin). Windows x64 and arm64 build the exact `v4.0.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. To recover explicitly, if `GENTLE_PI_SKIP_GENTLE_AI_INSTALL` is set, remove or unset it before changing to the installed `gentle-pi` package directory. Then run `node scripts/install-gentle-ai.mjs`. This invokes the package-owned installer without relying on a global binary or npm configuration change. A missing binary can result from skipped lifecycle scripts, but does not prove that lifecycle scripts were disabled.
|
|
210
202
|
|
|
211
203
|
Recommended companion packages, into the standalone `gentle-shell` home:
|
|
212
204
|
|
|
@@ -236,7 +228,7 @@ Then start Pi in a project:
|
|
|
236
228
|
pi
|
|
237
229
|
```
|
|
238
230
|
|
|
239
|
-
`gentle-pi` installs delegation and review agents at startup.
|
|
231
|
+
`gentle-pi` installs delegation and review agents at startup. Substantial ODD work tracks progress in a project feature document; no separate workflow setup is required.
|
|
240
232
|
|
|
241
233
|
### Base references for review
|
|
242
234
|
|
|
@@ -317,7 +309,9 @@ gentle-ai's managed Pi stack always declares `npm:gentle-pi` itself in the home'
|
|
|
317
309
|
2. The bundled `@earendil-works/pi-coding-agent` resolved next to gentle-pi (`dist/bundle/cli.js`, run with the current `node`), when installed as its optional peer dependency.
|
|
318
310
|
3. `pi` on `PATH`.
|
|
319
311
|
|
|
320
|
-
|
|
312
|
+
Adjacent resolution uses Pi's public ESM entry, then verifies the canonical package root, package name and declared `pi` bin. Only a genuinely absent optional peer permits PATH fallback; an invalid installed package fails rather than silently selecting another runtime. Pi AI and TUI are optional `"*"` host peers, not runtime dependencies, so managed extensions use the host's classes and registries. The launcher still gates the actual runtime version before home bootstrap. This is a one-time baseline upgrade, not an auto-updater.
|
|
313
|
+
|
|
314
|
+
If none resolve, `gentle-shell` exits 1 naming all three options. Once a runtime is found, its `pi --version` must be at least `0.99.1` (the coding-agent peer minimum): an older version exits 1 naming the found and required versions, and unparsable `--version` output exits 1 naming the required minimum.
|
|
321
315
|
|
|
322
316
|
### Environment variables
|
|
323
317
|
|
|
@@ -381,14 +375,22 @@ gentle-pi's postinstall only writes the global `tuiMode: fullscreen` setting whe
|
|
|
381
375
|
|
|
382
376
|
Setting `GENTLE_SHELL_INTERACTIVE_HOST=1` on a `pi --mode rpc` process turns on two things a plain headless RPC host does not get: dialogs for `ask_user_question` and `ask_user_choice` (one `ctx.ui.select` prompt per question, looped for multiSelect), and Gentle Agents' helper activity pushed live through `setWidget`. A subagent child spawned by such a host never inherits the variable, so nested children stay headless regardless of their parent. See the [activity payload reference](gentle-agents-activity.md) for the exact schema, field bounds, and shrink order.
|
|
383
377
|
|
|
378
|
+
### Herdr lifecycle bridge
|
|
379
|
+
|
|
380
|
+
For an interactive isolated-home launch inside Herdr, `gentle-shell` explicitly loads the existing managed `extensions/herdr-agent-state.ts` bridge. It looks first in the selected agent home, then the incoming `PI_CODING_AGENT_DIR`, then `~/.pi/agent`, using the first readable file's canonical path. Pi deduplicates that same file against normal discovery, explicit `-e` aliases, and package-manifest entries; presence alone is not treated as proof that it loaded. The launcher does not implement a second reporter, copy the bridge, or rewrite home configuration.
|
|
381
|
+
|
|
382
|
+
Automatic loading requires `HERDR_ENV=1`, a nonempty `HERDR_PANE_ID`, an existing Unix socket at `HERDR_SOCKET_PATH`, and terminal stdin/stdout. It is skipped for `--no-extensions`/`-ne`, print/JSON/RPC modes (including interactive RPC hosts), export/model listing, package commands, and Gentle Agents children. `--mode text` still permits an interactive TUI. Linked and explicit custom homes keep their own resource policy; use normal Pi discovery or an explicit `-e` there. An absent or unreadable bridge is nonfatal. User-supplied extension paths remain unchanged, including under `--no-extensions`; this automatic bridge is not added on top of that opt-out.
|
|
383
|
+
|
|
384
|
+
### Herdr blocker events
|
|
385
|
+
|
|
386
|
+
The Gentle AI adapter projects native `gentle-pi:ask-user-question:blocked`, legacy `rpiv:ask-user:blocked`, choice blockers, and guarded confirmations into one balanced `herdr:blocked` interval. It emits one activation when blocking begins and one release after the last source clears, retaining the initial generic label without relabel pulses. Native and legacy questionnaires are tracked independently; duplicate or malformed source events are ignored. Questionnaire answers, prompts, and commands are not included in the projection. This adapter emits local events; transport availability is a separate concern.
|
|
387
|
+
|
|
384
388
|
## Quick start
|
|
385
389
|
|
|
386
390
|
```text
|
|
387
|
-
/gentle:status Check package
|
|
388
|
-
/gentle:doctor Run read-only diagnostics for
|
|
389
|
-
/gentle:
|
|
390
|
-
/gentle-sdd-init Create or refresh openspec/config.yaml (openspec/both stores only).
|
|
391
|
-
/gentle:models Assign global model/effort routing to SDD/custom agents.
|
|
391
|
+
/gentle:status Check package assets and global model config.
|
|
392
|
+
/gentle:doctor Run read-only diagnostics for assets, config, tools, and guards.
|
|
393
|
+
/gentle:models Assign global model/effort routing to packaged/custom agents.
|
|
392
394
|
/gentle:profiles Create, switch, and manage global agent-model profiles.
|
|
393
395
|
/gentle:persona Switch between gentleman and neutral persona modes.
|
|
394
396
|
/gentle:background-subagents Show or set the managed background-subagents policy, with its deciding source.
|
|
@@ -402,13 +404,12 @@ Typical flow:
|
|
|
402
404
|
1. Open Pi in your repo.
|
|
403
405
|
2. Run `/gentle:status`.
|
|
404
406
|
3. Describe the outcome, for example: "Add CSV export using the existing report filters." ODD explores, implements authorized changes, and checks the result.
|
|
405
|
-
4. For substantial work, inspect the feature document and evidence; resume reconciles the full file and Engram copy.
|
|
406
|
-
5. If you explicitly choose SDD instead, follow [its preflight and project setup](#sdd-preflight-and-project-files) and review its phase artifacts.
|
|
407
|
+
4. For substantial work, inspect the feature document and evidence; resume reconciles the full file and Engram copy.
|
|
407
408
|
|
|
408
409
|
## Core workflow
|
|
409
410
|
|
|
410
411
|
1. **Install and inspect.** Install `gentle-pi`, open Pi in the target repository, then run `/gentle:status` or `/gentle:doctor`.
|
|
411
|
-
2. **Use ODD
|
|
412
|
+
2. **Use ODD.** Explore and clarify proportionately; track substantial work in one feature document with a full Engram recovery copy.
|
|
412
413
|
3. **Build with evidence.** One focused writer implements authorized scope using the forwarded TDD mode/source/runner. Enabled TDD requires observed RED → GREEN → REFACTOR; disabled still runs functional checks. Test presence is not activation.
|
|
413
414
|
4. **Use runtime-owned RDD only when enabled by the user.** Gentle AI supplies any runtime-specific review instructions; this package does not recreate a lifecycle in documentation or prompts.
|
|
414
415
|
5. **Deliver through ordinary repository policy.** Review and Judgment Day evidence is informational only; Pi never creates a delivery route, authorization, target rederivation, or receipt gate.
|
|
@@ -424,9 +425,8 @@ Typical flow:
|
|
|
424
425
|
| Small, clear, local edit | Inline direct work. |
|
|
425
426
|
| Unknown codebase area or context-heavy investigation | Focused subagent delegation. |
|
|
426
427
|
| Substantial authorized work needing recoverable progress | ODD with a feature document and focused workers. |
|
|
427
|
-
| Explicit request or accepted proposal for formal phase artifacts | Optional SDD/OpenSpec flow. |
|
|
428
428
|
|
|
429
|
-
Size and uncertainty can call for scoped exploration or delegation within ODD
|
|
429
|
+
Size and uncertainty can call for scoped exploration or delegation within ODD. The delegation triggers below select execution topology, not a different development method.
|
|
430
430
|
|
|
431
431
|
### Delegation triggers
|
|
432
432
|
|
|
@@ -434,11 +434,11 @@ Size and uncertainty can call for scoped exploration or delegation within ODD, n
|
|
|
434
434
|
|
|
435
435
|
| Trigger | Required behavior |
|
|
436
436
|
| --------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
|
|
437
|
-
| Reading
|
|
437
|
+
| Reading beyond the evidence budget (one parallel batch of at most 3 calls, ~10k tokens), more than ~5 sequential lookups, or a long session ahead | Launch `scout`, `context-builder`, or the closest read-only mapping subagent; it returns a handoff of at most ~2k tokens with `path:line` evidence. Never force delegation for a small targeted question. |
|
|
438
438
|
| Touching 2+ non-trivial code files | Delegate one writer; do not continue inline unless delegation is unavailable. |
|
|
439
439
|
| Commit, push, or PR after code changes | Follow the loaded native instruction, or ordinary repository policy when none is supplied. |
|
|
440
440
|
| Wrong cwd, worktree/git accident, merge recovery, confusing test/env issue | Stop, preserve the affected scope, and investigate separately before resuming. |
|
|
441
|
-
|
|
|
441
|
+
| Parent context past ~150k tokens | Pause and delegate the next bounded unit of work, or stop and explain the exact blocker. Keep command output bounded; send full suites and builds to a verifier. |
|
|
442
442
|
|
|
443
443
|
The intended balanced loop for a bounded bugfix is:
|
|
444
444
|
|
|
@@ -491,10 +491,8 @@ flowchart TD
|
|
|
491
491
|
A["Clarify scope and acceptance criteria"] --> B{"Choose the smallest safe workflow"}
|
|
492
492
|
B -->|Small and local| C["Inline implementation"]
|
|
493
493
|
B -->|Context-heavy or multi-file| D["Focused subagent"]
|
|
494
|
-
B -->|Large or architectural| E["SDD phase artifacts"]
|
|
495
494
|
C --> F["Implement with test evidence"]
|
|
496
495
|
D --> F
|
|
497
|
-
E --> F
|
|
498
496
|
F --> G["Independent verification"]
|
|
499
497
|
G --> H["Target-scoped native status"]
|
|
500
498
|
H -->|Ambiguous or corrupted| X["Blocked: native maintainer action"]
|
|
@@ -519,13 +517,17 @@ flowchart TD
|
|
|
519
517
|
|
|
520
518
|
VALIDATE is informational. Commit, push, PR, and release commands follow ordinary repository policy; RDD never authorizes, rewrites, consumes review state for, or blocks them. Dangerous-command safety and destructive-review consent remain independent.
|
|
521
519
|
|
|
522
|
-
For the source checkout, native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI
|
|
520
|
+
For the source checkout, native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v4.0.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, and validate 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.
|
|
523
521
|
|
|
524
522
|
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.
|
|
525
523
|
|
|
526
524
|
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.
|
|
527
525
|
|
|
528
|
-
|
|
526
|
+
Candidate views materialize tracked Git symlinks from their frozen blobs even when `core.symlinks=false`, including unchanged links outside the changed scope. Unsafe targets fail before any link is created; a host without native symlink capability fails closed with `symlink-materialization-failed`. Pi does not alter the contributor's Git configuration or install symlink privileges.
|
|
527
|
+
|
|
528
|
+
On POSIX, if START rejects a group- or world-accessible `.git/gentle-ai/candidate-views` parent, Pi reports `candidate-owner-parent-privacy` before native START. When a sanitized probe shows the filesystem cannot represent private POSIX modes (for example WSL DrvFS mounts without `metadata`), Pi instead reports `candidate-owner-parent-chmod-ineffective` with guidance to move the Git common directory to a POSIX-metadata filesystem or enable metadata support. Inspect that parent's ownership and permissions and correct them out of band before retrying; Pi does not change them automatically. Other owner-preparation failures retain a generic diagnostic rather than exposing filesystem errors.
|
|
529
|
+
|
|
530
|
+
Once the source checkout's pinned gentle-ai runtime (currently v4.0.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.
|
|
529
531
|
|
|
530
532
|
### FINALIZE wrapper input
|
|
531
533
|
|
|
@@ -593,129 +595,22 @@ When RDD is on and an agent loop ends with an unreviewed candidate, `gentle-pi`
|
|
|
593
595
|
|
|
594
596
|
Review outcomes and receipt state are informational; commit, push, pull-request, and release delivery follow ordinary repository policy. No one-shot command authorization, publication-target revalidation, or receipt gate is required for delivery, and Pi does not inspect RDD mode or native authority to decide a Bash delivery command.
|
|
595
597
|
|
|
596
|
-
Dangerous-command safety remains independent and authoritative. Destructive-review-maintenance consent remains separate from delivery. Review operations
|
|
598
|
+
Dangerous-command safety remains independent and authoritative. Destructive-review-maintenance consent remains separate from delivery. Review operations and informational VALIDATE perform no commit, push, pull-request, release, or publication operation.
|
|
597
599
|
|
|
598
600
|
The Pi host relay bounds each locked-down reviewer subprocess by materialized prompt size rather than by one fixed number: a 15-minute floor plus 15 minutes per mebibyte of prompt, clamped to a 2-hour ceiling. Set `GENTLE_PI_REVIEW_RELAY_PI_TIMEOUT_MS` to a positive decimal to replace that derived bound with your own; malformed values are ignored and the same 2-hour ceiling still applies, so no configuration turns a foreground finalize into an unbounded child process. A reviewer killed by the bound reports `pi-host-relay-timeout` with the elapsed time and the limit it was measured against, and it explicitly does not ask you to relaunch the identical slot — that would re-spend the model tokens to reach the same wall. Reviewer results admitted earlier in the same finalize stay admitted and are not re-run.
|
|
599
601
|
|
|
600
602
|
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.
|
|
601
603
|
|
|
602
|
-
##
|
|
603
|
-
|
|
604
|
-
This is the explicitly selected alternative to [everyday ODD](#organic-driven-development), not a requirement for substantial or risky work. Keep the formal phase artifacts when they are part of what you want to review and maintain.
|
|
605
|
-
|
|
606
|
-
```text
|
|
607
|
-
init
|
|
608
|
-
↓
|
|
609
|
-
explore → research (optional) → proposal → spec ─┬→ design ─┐
|
|
610
|
-
└─────────┴→ tasks → apply → archive (verification optional)
|
|
611
|
-
```
|
|
604
|
+
## Package-managed agents and optional research
|
|
612
605
|
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
```text
|
|
616
|
-
planning artifacts implementation evidence canonical update
|
|
617
|
-
────────────────── ─────────────────────── ────────────────
|
|
618
|
-
proposal/spec/design/tasks → apply-progress → optional verify-report → archive-report + canonical update
|
|
619
|
-
```
|
|
620
|
-
|
|
621
|
-
For explicitly selected SDD work, the parent session coordinates the flow and each phase writes artifacts. That gives you:
|
|
622
|
-
|
|
623
|
-
- explicit requirements and non-goals;
|
|
624
|
-
- design decisions that survive compaction;
|
|
625
|
-
- task plans reviewers can reason about;
|
|
626
|
-
- implementation evidence;
|
|
627
|
-
- verification reports;
|
|
628
|
-
- archive-time canonical spec composition with explicit destructive-change consent;
|
|
629
|
-
- archive notes for future agents.
|
|
630
|
-
|
|
631
|
-
### OpenSpec artifact model
|
|
632
|
-
|
|
633
|
-
`gentle-pi` treats OpenSpec-compatible behavior as part of the harness. You do not need to install the external OpenSpec CLI/package for SDD.
|
|
634
|
-
|
|
635
|
-
In file-backed modes, canonical accepted behavior lives in `openspec/specs/`, while active changes carry deltas under `openspec/changes/`:
|
|
636
|
-
|
|
637
|
-
```text
|
|
638
|
-
openspec/
|
|
639
|
-
├── specs/ # accepted source of truth
|
|
640
|
-
│ └── {domain}/spec.md
|
|
641
|
-
└── changes/
|
|
642
|
-
├── {change}/ # active work
|
|
643
|
-
│ ├── proposal.md
|
|
644
|
-
│ ├── specs/{domain}/spec.md # full spec or delta spec
|
|
645
|
-
│ ├── design.md
|
|
646
|
-
│ ├── tasks.md
|
|
647
|
-
│ ├── apply-progress.md
|
|
648
|
-
│ └── verify-report.md # optional
|
|
649
|
-
└── archive/YYYY-MM-DD-{change}/ # immutable audit trail
|
|
650
|
-
```
|
|
651
|
-
|
|
652
|
-
Delta flow:
|
|
653
|
-
|
|
654
|
-
```text
|
|
655
|
-
openspec/changes/{change}/specs/{domain}/spec.md
|
|
656
|
-
│
|
|
657
|
-
│ sdd-archive applies ADDED / MODIFIED / REMOVED
|
|
658
|
-
▼
|
|
659
|
-
openspec/specs/{domain}/spec.md
|
|
660
|
-
│
|
|
661
|
-
│ sdd-archive moves the completed change folder
|
|
662
|
-
▼
|
|
663
|
-
openspec/changes/archive/YYYY-MM-DD-{change}/
|
|
664
|
-
```
|
|
665
|
-
|
|
666
|
-
When a canonical spec already exists, change specs use requirement operation sections:
|
|
667
|
-
|
|
668
|
-
```markdown
|
|
669
|
-
## ADDED Requirements
|
|
670
|
-
|
|
671
|
-
## MODIFIED Requirements
|
|
672
|
-
|
|
673
|
-
## REMOVED Requirements
|
|
674
|
-
```
|
|
675
|
-
|
|
676
|
-
`MODIFIED` requirements must include the full requirement block, including still-valid scenarios, because sync replaces the canonical block by requirement name. `sdd-archive` composes applicable file-backed deltas into `openspec/specs/{domain}/spec.md`, then moves the completed change to `openspec/changes/archive/YYYY-MM-DD-{change}/`.
|
|
677
|
-
|
|
678
|
-
Engram-only mode is different by design: Engram is working memory and does not maintain a canonical spec merge layer. Use `openspec` or `both` (hybrid file + memory persistence) when you need canonical spec evolution.
|
|
679
|
-
|
|
680
|
-
## SDD preflight and project files
|
|
681
|
-
|
|
682
|
-
`gentle-pi` does not require SDD agents to be copied into every project. The package installs and refreshes global Pi SDD assets under the Pi agent home on SDD activation, and treats project-local files only as overrides/debug copies. Slash SDD flows such as `/sdd-*`, `/gentle-sdd-init`, and the explicit `/gentle:sdd-preflight` command run a lazy preflight and resolve session-scoped SDD preferences. For natural-language requests, SDD requires an explicit user request or accepted proposal; only then does the parent run/reuse `/gentle:sdd-preflight` before continuing. ODD does not use this setup.
|
|
683
|
-
|
|
684
|
-
```text
|
|
685
|
-
~/.pi/agent/agents/sdd-*.md
|
|
686
|
-
~/.pi/agent/chains/sdd-*.chain.md
|
|
687
|
-
~/.pi/agent/gentle-ai/support/strict-tdd*.md
|
|
688
|
-
```
|
|
689
|
-
|
|
690
|
-
Every new interactive session confirms preflight on its first SDD invocation. Saved preferences and canonical defaults are suggestions: confirm the grouped values or change them. Cancellation leaves preflight unresolved. The parent `subagent_run` boundary enforces this before every shipped SDD child and prepends the exact rendered `## SDD Session Preflight` block through its existing `context`; RPC children consume it and never originate or persist defaults. Missing or malformed transport blocks before spawn. Only a safely distinguishable standalone headless parent retains silent defaults. Session confirmation does not reset project initialization: the cold-start order remains confirmation → `sdd-init` → explore.
|
|
691
|
-
|
|
692
|
-
Canonical values are `auto` execution mode, `openspec` artifact store, `ask-on-risk` delivery strategy, and a `400` changed-line review threshold. The delivery strategy domain is `ask-on-risk`, `auto-chain`, `single-pr`, or `exception-ok`; `chain_strategy` remains deferred until chaining is selected. `exception-ok` requires explicit `size:exception` acceptance and is never inferred. Consent, authorization, security, destructive/publishing, interactive phase approval, and ambiguous-scope gates remain human-controlled.
|
|
693
|
-
|
|
694
|
-
Startup refreshes only hash-proven delegation and review assets; existing SDD package content is preserved until SDD preflight or an explicit SDD installation command. For the previously unowned `sdd-research.md`, SDD refresh recognizes only the known old content hash (ignoring model/thinking routing), preserves routing, and records ownership. Body-edited or unknown assets remain untouched. Manual refresh uses the same ownership checks, scoped to the selected owner:
|
|
606
|
+
At startup, `gentle-pi` installs and refreshes only hash-proven delegation and review agents. User-edited files and project overrides remain untouched. Refresh a selected owner explicitly when needed:
|
|
695
607
|
|
|
696
608
|
```text
|
|
697
609
|
/gentle:install-delegation --force
|
|
698
610
|
/gentle:install-review --force
|
|
699
|
-
/gentle:install-sdd --force
|
|
700
611
|
```
|
|
701
612
|
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
### Selected research
|
|
705
|
-
|
|
706
|
-
Research capabilities use an explicit package mapping intersected with active Pi tools and the agent's allowlist. Official documentation requires only `fetch_content`; open-web requires all four tools: `web_search`, `source_check`, `fetch_content`, and `get_search_content`. Each must be active and approved/reachable in the child; none is optional. Inventory admission does not prove execution or source-backed evidence. The child receives exact registered names through `--tools` and rechecks its local inventory. SDK-only parent tools are not inherited by a CLI child.
|
|
707
|
-
|
|
708
|
-
Generic MCP and dynamic namespace gateways (including `mcp__context7`) are not method-scoped grants. Context7-only installations remain unavailable through those gateways until a narrow verified route exists; this does not disable supported direct web tools. Explicit source restrictions always apply. Selected supported research must run and record auditable source-backed claims; any selected unavailable or partial class blocks proposal readiness. Bash and invented citations are never fallbacks.
|
|
709
|
-
|
|
710
|
-
This downstream mapping implements the exact Pi grants defined by merged [Gentle AI PR #4420](https://github.com/Gentleman-Programming/gentle-ai/pull/4420) for gentle-ai#3846 and gentle-pi#471. Research admission is enforced locally against active child tools, not through the pinned native binary, so this change does not require a native release or re-pin. The opt-in live integration test verifies actual child tool execution and a source-backed passage independently of inventory checks.
|
|
711
|
-
|
|
712
|
-
Workspace edits do not activate a different installed package path. Activate the updated package separately before expecting these behaviors in new sessions; edited installed assets may still need an explicit human reconciliation.
|
|
713
|
-
|
|
714
|
-
Manual preflight command:
|
|
715
|
-
|
|
716
|
-
```text
|
|
717
|
-
/gentle:sdd-preflight
|
|
718
|
-
```
|
|
613
|
+
Saved model routing is applied separately; these installation commands do not change model settings. Optional ODD research depends on active, authorized tools. Verify source-backed findings, cite the sources actually retrieved, and disclose unavailable evidence instead of treating tool inventory as proof or inventing citations. Research is read-only; unavailable evidence pauses only decisions that depend on it. A source checkout edit does not activate an already installed package; activate the updated package separately before expecting changes in a new session.
|
|
719
614
|
|
|
720
615
|
## Skill registry
|
|
721
616
|
|
|
@@ -775,14 +670,13 @@ Skill discovery is a guardrail, not a workflow router: it helps Pi load the righ
|
|
|
775
670
|
|
|
776
671
|
`gentle-pi` also ships package-owned `gentle-ai-skill-creator` and `gentle-ai-skill-improver` skills plus the `/skill-creation` prompt for creating or updating project skills. Both skills use `docs/skill-style-guide.md` as their normative style contract. The workflow checks for duplicates, keeps `SKILL.md` concise, uses one-line trigger-rich frontmatter, and reminds maintainers to refresh the registry after skill changes.
|
|
777
672
|
|
|
778
|
-
Packaged skills include `cognitive-doc-design`, `comment-writer`, `gentle-ai-judgment-day`, `gentle-ai-skill-creator`, `gentle-ai-skill-improver`, and the other delivery/review skills under `skills/`.
|
|
673
|
+
Packaged skills include `cognitive-doc-design`, `comment-writer`, `gentle-ai-judgment-day`, `gentle-ai-skill-creator`, `gentle-ai-skill-improver`, and the other delivery/review skills under `skills/`.
|
|
779
674
|
|
|
780
675
|
Compatibility: the package keeps the existing skill folders (`skills/branch-pr`, `skills/cognitive-doc-design`, `skills/comment-writer`, `skills/judgment-day`, `skills/skill-creator`, `skills/skill-registry`, and `skills/work-unit-commits`) but their exported frontmatter names are prefixed to avoid collisions with user/global skills. Treat former package names such as `branch-pr`, `cognitive-doc-design`, `comment-writer`, `judgment-day`, `skill-creator`, `skill-registry`, and `work-unit-commits` as legacy aliases in prose; runtime skill selection should use `gentle-ai-branch-pr`, `gentle-ai-cognitive-doc-design`, `gentle-ai-comment-writer`, `gentle-ai-judgment-day`, `gentle-ai-skill-creator`, `gentle-ai-skill-registry`, and `gentle-ai-work-unit-commits`.
|
|
781
676
|
|
|
782
677
|
Delegation contract:
|
|
783
678
|
|
|
784
679
|
- parent/orchestrator resolves project/user skills from the registry and passes matching paths under `## Skills to load before work`;
|
|
785
|
-
- SDD subagents still use their assigned executor/phase skill;
|
|
786
680
|
- during normal runtime, subagents should not independently discover additional project/user `SKILL.md` files or the registry;
|
|
787
681
|
- fallback loading is degraded self-healing and must be reported via `skill_resolution` as `fallback-registry`, `fallback-path`, or `none`.
|
|
788
682
|
|
|
@@ -828,9 +722,8 @@ Recommended model/effort shape:
|
|
|
828
722
|
|
|
829
723
|
| Agent kind | Recommended model | Recommended effort (`thinking`) |
|
|
830
724
|
| -------------------------- | ---------------------------------------------------- | ------------------------------- |
|
|
831
|
-
| Explore
|
|
832
|
-
|
|
|
833
|
-
| Apply | Strong coding and tool-use model. | `medium` to `high` |
|
|
725
|
+
| Explore and mapping | Fast and cheap is usually enough. | `off` to `low` |
|
|
726
|
+
| Implementation | Strong coding and tool-use model. | `medium` to `high` |
|
|
834
727
|
| Verify / review | Strong fresh-context model. | `high` |
|
|
835
728
|
| Tiny utilities | Inherit active/default model unless they bottleneck. | `inherit` |
|
|
836
729
|
|
|
@@ -844,17 +737,17 @@ Existing project-local `.pi/gentle-ai/models.json` files are still read as a leg
|
|
|
844
737
|
|
|
845
738
|
Inside `/gentle:models`, press `x` to export the saved routing to `~/.pi/gentle-ai/models.export.json`, or `r` to restore from that file after confirmation. Export uses a versioned envelope and restore writes the normal `models.json` shape before applying routing to agents.
|
|
846
739
|
|
|
847
|
-
Press `u` to save
|
|
740
|
+
Press `u` to save global agent routing like `ctrl+s`, then capture that routing plus this session's orchestrator model and thinking level in the current profile. If this session has no model, `u` falls back to the orchestrator defaults in `settings.json`; it never changes those defaults. Unlike `/gentle:profiles` `s`, which snapshots persisted settings, `u` captures the live session when available. The panel names the profile `u` targets: the profile this repository pins when a pin wins, otherwise the globally active profile. When no profiles store exists yet, `u` seeds it with a `current` profile the way `/gentle:profiles` does on first open; when the store exists but nothing is active and nothing is pinned, the global save still happens and the panel points you to `/gentle:profiles`.
|
|
848
741
|
|
|
849
742
|
Config shape (per agent):
|
|
850
743
|
|
|
851
744
|
```json
|
|
852
745
|
{
|
|
853
|
-
"
|
|
746
|
+
"gentle-ai-worker": {
|
|
854
747
|
"model": "anthropic/claude-sonnet-4",
|
|
855
748
|
"thinking": "high"
|
|
856
749
|
},
|
|
857
|
-
"
|
|
750
|
+
"gentle-ai-explore": {
|
|
858
751
|
"model": "openai/gpt-5-mini"
|
|
859
752
|
}
|
|
860
753
|
}
|
|
@@ -911,7 +804,7 @@ Store shape:
|
|
|
911
804
|
"model": "anthropic/claude-sonnet-4",
|
|
912
805
|
"thinking": "high"
|
|
913
806
|
},
|
|
914
|
-
"
|
|
807
|
+
"gentle-ai-worker": {
|
|
915
808
|
"model": "anthropic/claude-sonnet-4",
|
|
916
809
|
"thinking": "high"
|
|
917
810
|
}
|
|
@@ -946,6 +839,12 @@ Both use the same shape, and both are a separate artifact from `profiles.json`:
|
|
|
946
839
|
}
|
|
947
840
|
```
|
|
948
841
|
|
|
842
|
+
The fullscreen shell header and Status → Project → Profile show the effective profile for the session
|
|
843
|
+
repository: `name (local)` for a clone-local pin, `name (repo)` for a repository declaration, or the
|
|
844
|
+
global active name without a suffix. Invalid or stale pins fall through to the next valid layer.
|
|
845
|
+
Changes made inside or outside the profiles panel appear within about two seconds while the UI
|
|
846
|
+
session is active; the indicator is omitted if no valid profile remains.
|
|
847
|
+
|
|
949
848
|
For a given working directory the winner is the local pin, then the repository declaration, then no pin. With no pin at all the repository keeps the behavior described above and follows the globally active profile. `p` and `P` are toggles: pressing one on the profile that already holds that layer removes it, and either key pressed outside a Git worktree writes nothing and says so.
|
|
950
849
|
|
|
951
850
|
In a pinned repository the pinned profile governs subagent launches: the agents it names take its model and effort, and the agents it omits return to inherit (their own definition, then the default model). The globally active profile and writes made through `/gentle:models` do not reach those launches, which `/gentle:models` reports when it runs inside a pinned repository. `enter` follows the same boundary: inside a pinned repository it re-pins that repository instead of writing the global routing, so the panel's main key can never move another repository's routing. The panel states which layer won, names the file that holds it, and marks the profile with `(pinned)`.
|
|
@@ -972,31 +871,28 @@ One limitation is worth stating. When a pinned profile omits an agent, that agen
|
|
|
972
871
|
|
|
973
872
|
| Command | What it does |
|
|
974
873
|
| -------------------------------- | ------------------------------------------------------------------- |
|
|
975
|
-
| `/gentle:status` | Shows package
|
|
976
|
-
| `/gentle:doctor` | Runs read-only diagnostics for
|
|
977
|
-
| `/gentle:
|
|
978
|
-
| `/gentle:models` | Opens global model + effort assignment UI. Press `x` to export, `r` to restore saved routing, and `u` to save and update the current profile. |
|
|
874
|
+
| `/gentle:status` | Shows package assets and global model config status. |
|
|
875
|
+
| `/gentle:doctor` | Runs read-only diagnostics for assets, model/persona config, memory tools, and safety guards. |
|
|
876
|
+
| `/gentle:models` | Opens global model + effort assignment UI. Press `x` to export, `r` to restore saved routing, and `u` to save routing and capture the session in the current profile. |
|
|
979
877
|
| `/gentle:profiles` | Opens global agent-model profiles: apply live, create, snapshot, duplicate, rename, delete, export, and import. |
|
|
980
|
-
| `/gentle:commands` | Opens the command palette (default `alt+k`): a curated, grouped menu (Configuration, Session, Diagnostics,
|
|
878
|
+
| `/gentle:commands` | Opens the command palette (default `alt+k`): a curated, grouped menu (Configuration, Session, Diagnostics, Skills) of registered Gentle commands; search and run by label. |
|
|
981
879
|
| `/gentle:persona` | Switches global persona mode, with project override support. |
|
|
982
880
|
| `/gentle:background-subagents` | Shows or sets the managed background-subagents policy (`status\|enable\|disable`), naming the source that decided it. |
|
|
983
881
|
| `/gentle:double-esc-cancel` | Shows or sets the double-esc-cancel preference (`status\|enable\|disable`); no argument toggles it. |
|
|
984
|
-
| `/gentle:animations` | Shows or sets global animations (`status\|quality\|performance\|potato`); no argument
|
|
882
|
+
| `/gentle:animations` | Shows or sets global animations (`status\|quality\|performance\|potato`); no argument opens a selector. |
|
|
883
|
+
| `/gentle:vim` | Shows or sets opt-in prompt Vim mode (`status\|enable\|disable`); no argument opens a selector. |
|
|
985
884
|
| `/gentle:telemetry` | Shows or changes the local Gentle AI telemetry trigger (`status\|enable\|disable\|preview`). |
|
|
986
885
|
| `/gentle:review-mode` | Shows or sets the receipt-driven development mode (`status\|enable\|disable`); user-initiated only, Pi automation never toggles it. |
|
|
987
886
|
| `/gentle:banner` | Configures startup banner rose, text logo, and color preset. |
|
|
988
887
|
| `/gentle:toggle-rose` | Toggles the startup rose. |
|
|
989
888
|
| `/gentle:toggle-text-logo` | Toggles the startup text logo. |
|
|
990
889
|
| `/gentle:banner-color` | Selects a startup banner color preset. |
|
|
991
|
-
| `/gentle-sdd-init` | Initializes or refreshes `openspec/config.yaml` (openspec/both stores only). |
|
|
992
890
|
| `/gentle:install-delegation` | Installs missing global delegation agents only; `--force` refreshes managed copies. |
|
|
993
891
|
| `/gentle:install-review` | Installs missing global review agents and chains only; `--force` refreshes managed copies. |
|
|
994
|
-
| `/gentle:install-sdd` | Installs missing global SDD agents, chains, and support only, without overwriting files. |
|
|
995
|
-
| `/gentle:install-sdd --force` | Refreshes only managed global SDD assets, preserving user edits and project overrides. |
|
|
996
892
|
| `/skill-registry:refresh` | Regenerates `.atl/skill-registry.md`. |
|
|
997
893
|
| `/skill-creation` | Creates or updates an LLM-first skill using the packaged `gentle-ai-skill-creator` contract and style guide. |
|
|
998
894
|
|
|
999
|
-
Startup installs and refreshes
|
|
895
|
+
Startup installs and refreshes delegation and review assets. Status and doctor identify missing or stale managed assets and the relevant repair command. User and project overrides are reported separately from package drift. Package refresh preserves overrides; explicit saved model settings may still update packaged or custom-agent routing at startup.
|
|
1000
896
|
|
|
1001
897
|
### Native cache warming (Pi 0.86.1+)
|
|
1002
898
|
|
|
@@ -1081,6 +977,24 @@ The selection is global: `<configHome>/animations.json`, where `configHome` hono
|
|
|
1081
977
|
|
|
1082
978
|
A successful command applies to the live prompt immediately, including while working. Starting and settling still request immediate renders. Pi owns enqueue repaint scheduling; Gentle shows the current queued state on the next host render without requiring an animation tick. A running startup banner retains its creation-time policy; the new selection applies at the next banner creation. Operational polling, refresh/debounce timers, Pi core animations, and install-time `tuiMode` are unchanged.
|
|
1083
979
|
|
|
980
|
+
### Vim prompt editing
|
|
981
|
+
|
|
982
|
+
`/gentle:vim enable` opts only the Gentle-owned prompt into modal editing; `/gentle:vim disable` restores ordinary Pi editing. `/gentle:vim status` reads the persisted preference and deciding source without writing, and reports the effective mode of the current Gentle prompt separately. With no argument, an interactive selector offers enable, disable, and status; headless use reports status. The global `<configHome>/vim.json` (default config home `~/.pi/gentle-ai`, overridable with `GENTLE_PI_CONFIG_HOME`) uses the strict shape `{"schema":"gentle-pi.vim/v1","policy":"on"}` or `off`. Missing means off; malformed or unreadable files warn and fall back to off without being rewritten. Enable/disable persist globally; compatible owned prompts apply the preference immediately. On compatibility rejection the on preference remains saved, but the active prompt stays in ordinary editing and the command never claims it applies now. Without an active Gentle prompt, the command reports that the preference will be tried at next prompt creation. A foreign editor is never replaced.
|
|
983
|
+
|
|
984
|
+
The frame labels INSERT, NORMAL, VISUAL (characterwise), or VISUAL LINE (linewise); narrow frames may omit the hint. INSERT uses Pi's normal input. Escape first leaves INSERT for NORMAL **without** aborting a running turn or clearing a draft. Escape in VISUAL or with a pending command cancels that selection/command first; a later Escape in plain NORMAL follows Gentle's existing working-cancel/queue or idle-draft clear behavior (including the configured double-Escape confirmation). Autocomplete and `!` bash drafts retain Pi's input/Escape handling. `Ctrl+[` acts as Escape only where Pi delivers it as Escape.
|
|
985
|
+
|
|
986
|
+
| Mode | Supported keys in this prompt |
|
|
987
|
+
| --- | --- |
|
|
988
|
+
| NORMAL → INSERT | `i/I/a/A` insert at cursor/first nonblank/after cursor/end; `o/O` open a line below/above. |
|
|
989
|
+
| NORMAL navigation | Counts where accepted; `h/j/k/l`, Space, `w/e/b`, `0/^/$`, `gg/G`, and same-line `f/F/t/T` with `;/,` repeat. Motions use grapheme boundaries on Unicode and multiline drafts; they do not search prompt history. |
|
|
990
|
+
| NORMAL editing | `x`, `s/S`, `J`, `p/P`, `d/c/y` with repeat for whole lines, word/line/find motions, and supported text objects (`iw/aw`, `iW/aW`, paired quotes/backticks/brackets); `>>/<<` and supported motion-based `>/<` indent/dedent lines. A yank fills this prompt's register. |
|
|
991
|
+
| VISUAL | `v` selects characters, `V` selects lines; motions and `o` adjust the range. `d/x`, `c/s`, `y`, `p`, `>/<`, `J`, `~/u/U`, and `r` act on the selection; `i/a` with word/WORD or quote/bracket selects a text object in characterwise VISUAL. No blockwise visual selection. |
|
|
992
|
+
| Undo/repeat | NORMAL `u` undoes prompt editor changes; `.` repeats supported completed NORMAL edits and insert/change sessions at the current cursor (counts supported). Each supported insert session or repeat is grouped as one undo unit. VISUAL `u` lowercases the selection instead of undoing. VISUAL edits are not dot-repeatable. |
|
|
993
|
+
|
|
994
|
+
**Deliberate `/` divergence from Claude Code:** NORMAL `/` hands off to **Pi's native slash commands and skills**, enters INSERT, and inserts `/` at the existing cursor. Pi offers slash completion only at the start of the first line; elsewhere it inserts a literal slash without moving or replacing the draft. There is **no reverse prompt-history search**. Pi's explicit history shortcuts still work, transferring to INSERT first. Unknown NORMAL printable input, encoded text and bracketed paste do not silently insert; application shortcuts can transfer to INSERT before acting.
|
|
995
|
+
|
|
996
|
+
This is a bounded command subset, not full Claude Code/Vim parity. The private editor adapter supports only the audited Pi coding-agent/TUI `0.99.1`, `0.99.2`, and `1.0.0` package pairs. The two 0.99 releases have byte-identical editor and undo-stack sources. Pi 1.0.0 is separately audited against the touched state, paste/history, cursor/layout, autocomplete and undo-snapshot contracts; actual bundled and unbundled 1.0.0 tests prove identity, edit/undo, paste, selection, wrapping/scroll and autocomplete behavior, not old/new byte identity. Fabricated metadata tests preserve exact-version admission coverage for the older audited releases. Version metadata must come from a canonical candidate host package root whose actual `CustomEditor` and `Editor` classes match the loaded classes, never from the extension's local metadata or CLI path alone. Unknown versions, mismatched prototypes, or invalid layouts fail closed: a single compatibility warning is shown and the prompt continues with ordinary editing instead of silently entering inert NORMAL mode. Operations that would cross a registered collapsed paste marker, or encounter duplicate occurrences of a registered marker ID, are rejected without editing it. Visual highlighting relies on Pi's render layout and may be omitted if its geometry cannot be validated. No live-terminal proof of every layout or complete parity is claimed.
|
|
997
|
+
|
|
1084
998
|
Startup banner settings remain global in `banner.json` under `GENTLE_PI_CONFIG_HOME` (default `~/.pi/gentle-ai`). Existing `showRose` and `showTextLogo` opt-outs independently control the main startup artwork; both default to enabled. Changes apply on the next session or `/reload`. Color presets are `pink` (default), `cyan`, `yellow`, and `green`. The static sidebar heading is independent of these preferences and follows the active theme.
|
|
1085
999
|
|
|
1086
1000
|
Startup flag:
|
|
@@ -1116,18 +1030,13 @@ pi install npm:gentle-engram
|
|
|
1116
1030
|
|
|
1117
1031
|
When memory tools are actually active, el Gentleman can save decisions, bug fixes, discoveries, user prompts, and session summaries across Pi sessions.
|
|
1118
1032
|
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
- parent/orchestrator owns memory retrieval and passes selected context into subagent prompts;
|
|
1122
|
-
- subagents should not independently search memory during normal runtime unless explicitly instructed to retrieve a specific artifact or observation;
|
|
1123
|
-
- subagents should save significant discoveries, decisions, bug fixes, and completed SDD phase artifacts before returning when memory tools are available;
|
|
1124
|
-
- in memory/hybrid mode, SDD artifacts use stable topic keys such as `sdd/<change>/proposal`, `sdd/<change>/spec`, `sdd/<change>/design`, `sdd/<change>/tasks`, `sdd/<change>/apply-progress`, and `sdd/<change>/verify-report`.
|
|
1033
|
+
For substantial ODD work, the parent reconciles the full `odd/tasks/<feature-name>.md` document with its `odd/<feature-name>/tasks` Engram mirror when memory is available. It passes relevant context to subagents; subagents save significant verified discoveries and completed work before returning, without independently searching unrelated memory.
|
|
1125
1034
|
|
|
1126
1035
|
## Telemetry
|
|
1127
1036
|
|
|
1128
1037
|
`gentle-pi` observes approved sanitized runtime usage fields in memory and asynchronously invokes `gentle-ai telemetry runtime send --json` once per accepted event. It never persists metric data, retries, or waits for delivery in provider callbacks; busy or failed attempts are silently discarded. [gentle-ai](https://github.com/Gentleman-Programming/gentle-ai) owns native delivery and the existing opt-out policy. See [Telemetry](telemetry.md) for fields and source limitations.
|
|
1129
1038
|
|
|
1130
|
-
Separately, at primary session start (never for a named
|
|
1039
|
+
Separately, at primary session start (never for a named subagent), Gentle Pi asks the local `gentle-ai` binary to handle its own install/heartbeat telemetry: it spawns `gentle-ai telemetry trigger --json` detached, with a 3 s deadline, discards its output, and never blocks session start or surfaces an error — an older binary without the verb is silently treated as nothing to do. This runs at most once per process.
|
|
1131
1040
|
|
|
1132
1041
|
Install counts for `gentle-pi` and `gentle-engram` come from npm download statistics; the package itself never emits an install event.
|
|
1133
1042
|
|
|
@@ -1143,8 +1052,8 @@ To opt out:
|
|
|
1143
1052
|
|
|
1144
1053
|
| Path | Purpose |
|
|
1145
1054
|
| ------------------------------ | ---------------------------------------------------------------------------------------------------------- |
|
|
1146
|
-
| `extensions/gentle-ai.ts` | Injects identity, orchestrates native review authority, refreshes delegation/review assets at startup
|
|
1147
|
-
| `lib/native-review-cli.ts` | Strict package-local adapter for Gentle AI
|
|
1055
|
+
| `extensions/gentle-ai.ts` | Injects identity, orchestrates native review authority, refreshes delegation/review assets at startup, registers commands, applies model/persona config, and enforces runtime safety. |
|
|
1056
|
+
| `lib/native-review-cli.ts` | Strict package-local adapter for Gentle AI review and status contracts. |
|
|
1148
1057
|
| `lib/review-integration-v2.ts` | Strict consumer decoder for negotiated capabilities, operations, target status, projections, repair, and failures against contract `review-integration/v2` (active today). |
|
|
1149
1058
|
| `lib/review-candidate-view.ts` | Builds immutable changed-scope actor views while preserving full-tree, path, mode, symlink, and index integrity. |
|
|
1150
1059
|
| `lib/review-canonical.ts` | Permanent Pi-owned canonical JSON and domain-hash primitives for consumer-side identities. |
|
|
@@ -1154,16 +1063,14 @@ To opt out:
|
|
|
1154
1063
|
| `contracts/review-integration/v1/` | Byte-identical provider schemas and conformance fixtures for contract `review-integration/v1`, hash-checked before packaging; retained on disk permanently because `/v2`'s schemas `$ref` into these fragments. |
|
|
1155
1064
|
| `contracts/review-integration/v2/` | Byte-identical provider schemas and conformance fixtures for contract `review-integration/v2` (immutable `base_tree`/`candidate_tree`, ordered `changed_path_manifest`, no inline candidate diff), hash-checked before packaging. |
|
|
1156
1065
|
| `extensions/startup-banner.ts` | Shows and configures the startup intro, color presets, and compact runtime panel. |
|
|
1157
|
-
| `extensions/sdd-init.ts` | Registers `/gentle-sdd-init` for OpenSpec initialization. |
|
|
1158
1066
|
| `extensions/skill-registry.ts` | Maintains `.atl/skill-registry.md` from project/user skills and closes file watchers on shutdown. |
|
|
1159
1067
|
| `assets/orchestrator.md` | Parent-session orchestration contract (always-on core). |
|
|
1160
1068
|
| `assets/orchestrator-delegation.md` | Lazy-loaded delegation/routing/review detail, including the mirrored gentle-ai canon. |
|
|
1161
|
-
| `assets/orchestrator-memory.md` | Lazy-loaded ODD feature continuity
|
|
1069
|
+
| `assets/orchestrator-memory.md` | Lazy-loaded ODD feature continuity and memory lifecycle rules. |
|
|
1162
1070
|
| `assets/orchestrator-skills.md` | Lazy-loaded skill registry fallback semantics and intent-driven skill discovery. |
|
|
1163
|
-
| `assets/
|
|
1164
|
-
| `assets/
|
|
1165
|
-
| `assets/
|
|
1166
|
-
| `assets/support/` | Strict TDD support docs for apply/verify phases. |
|
|
1071
|
+
| `assets/agents/` | Delegation and review agents installed as global Pi runtime assets. |
|
|
1072
|
+
| `assets/chains/` | Review chains installed as global Pi runtime assets. |
|
|
1073
|
+
| `assets/support/` | Strict TDD support docs for delegated implementation and verification. |
|
|
1167
1074
|
| `skills/` | Gentle AI delivery and collaboration skills. |
|
|
1168
1075
|
| `prompts/` | The `/skill-creation` prompt template. |
|
|
1169
1076
|
| `docs/skill-style-guide.md` | Normative style guide used by the packaged skill creation/improvement skills. |
|
|
@@ -1184,7 +1091,6 @@ Validate before publishing:
|
|
|
1184
1091
|
pnpm test
|
|
1185
1092
|
bun build extensions/skill-registry.ts --target=node --format=esm --outfile=/tmp/skill-registry.js
|
|
1186
1093
|
node --experimental-strip-types --check extensions/gentle-ai.ts
|
|
1187
|
-
node --experimental-strip-types --check extensions/sdd-init.ts
|
|
1188
1094
|
node --experimental-strip-types --check extensions/startup-banner.ts
|
|
1189
1095
|
npm pack --dry-run
|
|
1190
1096
|
```
|
|
@@ -1218,7 +1124,7 @@ Do not run `npm publish` locally for `gentle-pi`. Dispatch the trusted workflow
|
|
|
1218
1124
|
- Human control over agent momentum.
|
|
1219
1125
|
- Concepts before code.
|
|
1220
1126
|
- Artifacts over floating chat context.
|
|
1221
|
-
- ODD for
|
|
1127
|
+
- ODD for development work, with recoverable progress for substantial changes.
|
|
1222
1128
|
- TDD from configured mode or explicit choice, not test presence.
|
|
1223
1129
|
- One parent orchestrator, focused subagents.
|
|
1224
1130
|
- Reviewable changes over giant diffs.
|