@event4u/agent-config 1.20.0 → 1.21.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.
Files changed (238) hide show
  1. package/.agent-src/commands/agents.md +1 -1
  2. package/.agent-src/commands/bug-fix.md +1 -1
  3. package/.agent-src/commands/bug-investigate.md +2 -2
  4. package/.agent-src/commands/chat-history/import.md +60 -64
  5. package/.agent-src/commands/compress.md +12 -0
  6. package/.agent-src/commands/context/create.md +2 -2
  7. package/.agent-src/commands/context.md +1 -1
  8. package/.agent-src/commands/copilot-agents.md +1 -1
  9. package/.agent-src/commands/council/default.md +17 -5
  10. package/.agent-src/commands/council.md +1 -1
  11. package/.agent-src/commands/e2e-heal.md +1 -1
  12. package/.agent-src/commands/e2e-plan.md +1 -1
  13. package/.agent-src/commands/feature/dev.md +3 -3
  14. package/.agent-src/commands/feature.md +1 -1
  15. package/.agent-src/commands/fix/seeder.md +2 -2
  16. package/.agent-src/commands/fix.md +1 -1
  17. package/.agent-src/commands/jira-ticket.md +1 -1
  18. package/.agent-src/commands/judge.md +2 -2
  19. package/.agent-src/commands/memory.md +1 -1
  20. package/.agent-src/commands/mode.md +5 -5
  21. package/.agent-src/commands/module.md +1 -1
  22. package/.agent-src/commands/onboard.md +4 -4
  23. package/.agent-src/commands/optimize/augmentignore.md +1 -1
  24. package/.agent-src/commands/optimize-prompt.md +61 -0
  25. package/.agent-src/commands/optimize.md +1 -1
  26. package/.agent-src/commands/override.md +1 -1
  27. package/.agent-src/commands/review-changes.md +1 -1
  28. package/.agent-src/commands/review-routing.md +1 -1
  29. package/.agent-src/commands/roadmap.md +1 -1
  30. package/.agent-src/commands/set-cost-profile.md +3 -3
  31. package/.agent-src/commands/sync-agent-settings.md +2 -2
  32. package/.agent-src/commands/tests/create.md +2 -2
  33. package/.agent-src/commands/tests.md +1 -1
  34. package/.agent-src/commands/threat-model.md +4 -4
  35. package/.agent-src/contexts/authority/commit-mechanics.md +14 -1
  36. package/.agent-src/contexts/authority/destructive-mechanics.md +14 -1
  37. package/.agent-src/contexts/authority/scope-mechanics.md +5 -0
  38. package/.agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +76 -0
  39. package/.agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +1 -1
  40. package/.agent-src/contexts/communication/rules-auto/think-before-action-mechanics.md +98 -0
  41. package/.agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +93 -0
  42. package/.agent-src/contexts/communication/rules-auto/user-interaction-mechanics.md +128 -5
  43. package/.agent-src/contexts/execution/autonomy-mechanics.md +44 -0
  44. package/.agent-src/contexts/model-recommendations.md +2 -2
  45. package/.agent-src/contexts/override-system.md +1 -1
  46. package/.agent-src/personas/product-owner.md +2 -2
  47. package/.agent-src/personas/qa.md +1 -1
  48. package/.agent-src/rules/agent-authority.md +5 -6
  49. package/.agent-src/rules/agent-docs.md +11 -53
  50. package/.agent-src/rules/analysis-skill-routing.md +10 -40
  51. package/.agent-src/rules/architecture.md +6 -1
  52. package/.agent-src/rules/artifact-drafting-protocol.md +5 -0
  53. package/.agent-src/rules/artifact-engagement-recording.md +23 -59
  54. package/.agent-src/rules/ask-when-uncertain.md +24 -47
  55. package/.agent-src/rules/augment-portability.md +14 -62
  56. package/.agent-src/rules/augment-source-of-truth.md +10 -1
  57. package/.agent-src/rules/autonomous-execution.md +17 -98
  58. package/.agent-src/rules/capture-learnings.md +9 -80
  59. package/.agent-src/rules/cli-output-handling.md +12 -42
  60. package/.agent-src/rules/command-suggestion-policy.md +25 -73
  61. package/.agent-src/rules/commit-conventions.md +9 -58
  62. package/.agent-src/rules/commit-policy.md +16 -47
  63. package/.agent-src/rules/context-hygiene.md +5 -0
  64. package/.agent-src/rules/direct-answers.md +21 -50
  65. package/.agent-src/rules/docker-commands.md +11 -45
  66. package/.agent-src/rules/docs-sync.md +10 -56
  67. package/.agent-src/rules/downstream-changes.md +5 -0
  68. package/.agent-src/rules/e2e-testing.md +9 -44
  69. package/.agent-src/rules/guidelines.md +13 -75
  70. package/.agent-src/rules/improve-before-implement.md +10 -2
  71. package/.agent-src/rules/language-and-tone.md +41 -106
  72. package/.agent-src/rules/laravel-translations.md +11 -40
  73. package/.agent-src/rules/markdown-safe-codeblocks.md +4 -0
  74. package/.agent-src/rules/minimal-safe-diff.md +4 -0
  75. package/.agent-src/rules/missing-tool-handling.md +4 -0
  76. package/.agent-src/rules/model-recommendation.md +9 -61
  77. package/.agent-src/rules/no-attribution-footers.md +5 -0
  78. package/.agent-src/rules/no-cheap-questions.md +11 -27
  79. package/.agent-src/rules/no-council-references.md +76 -0
  80. package/.agent-src/rules/no-roadmap-references.md +7 -0
  81. package/.agent-src/rules/non-destructive-by-default.md +13 -43
  82. package/.agent-src/rules/onboarding-gate.md +9 -117
  83. package/.agent-src/rules/package-ci-checks.md +10 -37
  84. package/.agent-src/rules/php-coding.md +10 -55
  85. package/.agent-src/rules/preservation-guard.md +9 -0
  86. package/.agent-src/rules/review-routing-awareness.md +9 -97
  87. package/.agent-src/rules/reviewer-awareness.md +8 -83
  88. package/.agent-src/rules/roadmap-progress-sync.md +7 -170
  89. package/.agent-src/rules/role-mode-adherence.md +6 -2
  90. package/.agent-src/rules/rule-type-governance.md +8 -66
  91. package/.agent-src/rules/runtime-safety.md +5 -0
  92. package/.agent-src/rules/scope-control.md +17 -62
  93. package/.agent-src/rules/security-sensitive-stop.md +7 -1
  94. package/.agent-src/rules/size-enforcement.md +6 -1
  95. package/.agent-src/rules/skill-improvement-trigger.md +9 -49
  96. package/.agent-src/rules/skill-quality.md +7 -113
  97. package/.agent-src/rules/slash-command-routing-policy.md +11 -63
  98. package/.agent-src/rules/think-before-action.md +22 -87
  99. package/.agent-src/rules/token-efficiency.md +10 -74
  100. package/.agent-src/rules/token-optimizer-maintenance.md +68 -0
  101. package/.agent-src/rules/tool-safety.md +4 -0
  102. package/.agent-src/rules/ui-audit-gate.md +25 -61
  103. package/.agent-src/rules/upstream-proposal.md +9 -67
  104. package/.agent-src/rules/user-interaction.md +22 -108
  105. package/.agent-src/rules/verify-before-complete.md +1 -1
  106. package/.agent-src/skills/agent-docs-writing/SKILL.md +1 -1
  107. package/.agent-src/skills/ai-council/SKILL.md +65 -0
  108. package/.agent-src/skills/analysis-autonomous-mode/SKILL.md +1 -1
  109. package/.agent-src/skills/analysis-skill-router/SKILL.md +3 -3
  110. package/.agent-src/skills/artisan-commands/SKILL.md +2 -2
  111. package/.agent-src/skills/authz-review/SKILL.md +1 -1
  112. package/.agent-src/skills/aws-infrastructure/SKILL.md +5 -5
  113. package/.agent-src/skills/blast-radius-analyzer/SKILL.md +8 -8
  114. package/.agent-src/skills/bug-analyzer/SKILL.md +5 -5
  115. package/.agent-src/skills/code-refactoring/SKILL.md +4 -4
  116. package/.agent-src/skills/code-review/SKILL.md +2 -2
  117. package/.agent-src/skills/command-writing/SKILL.md +11 -0
  118. package/.agent-src/skills/composer-packages/SKILL.md +2 -2
  119. package/.agent-src/skills/context-authoring/SKILL.md +11 -0
  120. package/.agent-src/skills/context-document/SKILL.md +1 -1
  121. package/.agent-src/skills/copilot-agents-optimization/SKILL.md +23 -0
  122. package/.agent-src/skills/copilot-config/SKILL.md +1 -1
  123. package/.agent-src/skills/dependency-upgrade/SKILL.md +2 -2
  124. package/.agent-src/skills/devcontainer/SKILL.md +2 -2
  125. package/.agent-src/skills/developer-like-execution/SKILL.md +1 -1
  126. package/.agent-src/skills/docker/SKILL.md +1 -1
  127. package/.agent-src/skills/dto-creator/SKILL.md +1 -1
  128. package/.agent-src/skills/estimate-ticket/SKILL.md +2 -2
  129. package/.agent-src/skills/fe-design/SKILL.md +4 -4
  130. package/.agent-src/skills/feature-planning/SKILL.md +5 -5
  131. package/.agent-src/skills/funnel-analysis/SKILL.md +1 -1
  132. package/.agent-src/skills/laravel/SKILL.md +1 -1
  133. package/.agent-src/skills/laravel-notifications/SKILL.md +5 -5
  134. package/.agent-src/skills/laravel-pennant/SKILL.md +1 -1
  135. package/.agent-src/skills/laravel-pulse/SKILL.md +4 -4
  136. package/.agent-src/skills/laravel-reverb/SKILL.md +2 -2
  137. package/.agent-src/skills/laravel-scheduling/SKILL.md +1 -1
  138. package/.agent-src/skills/migration-creator/SKILL.md +7 -7
  139. package/.agent-src/skills/multi-tenancy/SKILL.md +8 -8
  140. package/.agent-src/skills/performance-analysis/SKILL.md +3 -3
  141. package/.agent-src/skills/pest-testing/SKILL.md +6 -6
  142. package/.agent-src/skills/php-service/SKILL.md +2 -2
  143. package/.agent-src/skills/project-analysis-hypothesis-driven/SKILL.md +3 -3
  144. package/.agent-src/skills/project-analysis-react/SKILL.md +1 -1
  145. package/.agent-src/skills/project-analysis-symfony/SKILL.md +1 -1
  146. package/.agent-src/skills/project-analysis-zend-laminas/SKILL.md +2 -2
  147. package/.agent-src/skills/project-analyzer/SKILL.md +4 -4
  148. package/.agent-src/skills/prompt-optimizer/SKILL.md +108 -0
  149. package/.agent-src/skills/readme-reviewer/SKILL.md +1 -1
  150. package/.agent-src/skills/rule-writing/SKILL.md +33 -0
  151. package/.agent-src/skills/sentry-integration/SKILL.md +1 -1
  152. package/.agent-src/skills/skill-writing/SKILL.md +14 -0
  153. package/.agent-src/skills/terraform/SKILL.md +2 -2
  154. package/.agent-src/skills/terragrunt/SKILL.md +8 -8
  155. package/.agent-src/skills/test-performance/SKILL.md +5 -5
  156. package/.agent-src/skills/threat-modeling/SKILL.md +2 -2
  157. package/.agent-src/skills/token-optimizer/SKILL.md +110 -0
  158. package/.agent-src/skills/universal-project-analysis/SKILL.md +1 -1
  159. package/.agent-src/templates/AGENTS.md +1 -1
  160. package/.agent-src/templates/agent-settings.md +21 -16
  161. package/.agent-src/templates/contexts/tenant-boundaries.md +2 -2
  162. package/.agent-src/templates/contexts.md +1 -1
  163. package/.agent-src/templates/copilot-instructions.md +21 -0
  164. package/.agent-src/templates/copilot-review-instructions.md +76 -0
  165. package/.agent-src/templates/features.md +1 -1
  166. package/.agent-src/templates/rule.md +127 -0
  167. package/.claude-plugin/marketplace.json +4 -1
  168. package/AGENTS.md +32 -5
  169. package/CHANGELOG.md +69 -3
  170. package/README.md +22 -21
  171. package/config/agent-settings.template.yml +44 -10
  172. package/config/gitignore-block.txt +7 -0
  173. package/docs/architecture.md +86 -5
  174. package/docs/catalog.md +16 -6
  175. package/docs/contracts/agent-memory-contract.md +1 -1
  176. package/docs/contracts/context-paths.md +2 -1
  177. package/docs/contracts/file-ownership-matrix.json +354 -500
  178. package/docs/contracts/iron-law-overrides.txt +25 -0
  179. package/docs/contracts/kernel-membership.md +273 -0
  180. package/docs/contracts/load-context-schema.md +26 -11
  181. package/docs/contracts/pilot/agent-authority.md +24 -0
  182. package/docs/contracts/pilot/direct-answers.md +70 -0
  183. package/docs/contracts/pilot/language-and-tone.md +63 -0
  184. package/docs/contracts/rule-classification.md +170 -0
  185. package/docs/contracts/rule-router.md +153 -0
  186. package/docs/customization.md +17 -6
  187. package/docs/decisions/ADR-001-kernel-swap-deferred.md +109 -0
  188. package/docs/decisions/ADR-002-kernel-bucket-overrides.md +124 -0
  189. package/docs/decisions/ADR-rule-kernel-and-router.md +122 -0
  190. package/docs/getting-started.md +2 -2
  191. package/docs/guidelines/agent-infra/roadmap-progress-mechanics.md +176 -0
  192. package/docs/guidelines/agent-infra/rule-type-governance.md +73 -0
  193. package/docs/guidelines/agent-infra/size-and-scope.md +13 -2
  194. package/docs/guidelines/agent-infra/skill-quality-checklist.md +119 -0
  195. package/docs/guidelines/augment-portability-patterns.md +68 -0
  196. package/docs/guidelines/php/php-coding-patterns.md +62 -0
  197. package/package.json +1 -1
  198. package/scripts/_p43_bodies.py +235 -0
  199. package/scripts/_p43_compress.py +118 -0
  200. package/scripts/_p4_migrate.py +199 -0
  201. package/scripts/_pilot_council_question.py +57 -0
  202. package/scripts/_pilot_measure.py +53 -0
  203. package/scripts/ai_council/session.py +107 -5
  204. package/scripts/build_linear_digest.py +3 -5
  205. package/scripts/check_always_budget.py +39 -6
  206. package/scripts/check_compressed_paths.py +213 -0
  207. package/scripts/check_compression.py +15 -0
  208. package/scripts/check_context_paths.py +1 -0
  209. package/scripts/check_council_layout.py +105 -0
  210. package/scripts/check_council_references.py +145 -0
  211. package/scripts/check_portability.py +2 -0
  212. package/scripts/check_references.py +2 -0
  213. package/scripts/check_token_optimizer_freshness.py +131 -0
  214. package/scripts/compile_router.py +148 -0
  215. package/scripts/compress.py +219 -11
  216. package/scripts/council_cli.py +9 -5
  217. package/scripts/council_prune.py +81 -0
  218. package/scripts/count_token_optimizer_usage.sh +54 -0
  219. package/scripts/install.sh +44 -2
  220. package/scripts/iron_law_sha.py +98 -0
  221. package/scripts/lint_load_context.py +35 -5
  222. package/scripts/measure_rule_budget.py +314 -0
  223. package/scripts/prototype_lint_contradictions.py +150 -0
  224. package/scripts/schemas/rule.schema.json +55 -6
  225. package/scripts/skill_linter.py +196 -6
  226. package/scripts/smoke_path_resolution.py +93 -0
  227. package/scripts/validate_frontmatter.py +41 -1
  228. package/.agent-src/contexts/communication/rules-auto/artifact-engagement-recording-mechanics.md +0 -72
  229. package/.agent-src/contexts/communication/rules-auto/augment-portability-mechanics.md +0 -79
  230. package/.agent-src/contexts/communication/rules-auto/cli-output-handling-mechanics.md +0 -87
  231. package/.agent-src/contexts/communication/rules-auto/command-suggestion-policy-mechanics.md +0 -62
  232. package/.agent-src/contexts/communication/rules-auto/docs-sync-mechanics.md +0 -78
  233. package/.agent-src/contexts/communication/rules-auto/package-ci-checks-mechanics.md +0 -85
  234. package/.agent-src/contexts/communication/rules-auto/review-routing-awareness-mechanics.md +0 -65
  235. package/.agent-src/contexts/communication/rules-auto/roadmap-progress-sync-mechanics.md +0 -78
  236. package/.agent-src/contexts/communication/rules-auto/ui-audit-gate-mechanics.md +0 -53
  237. /package/{docs → .agent-src/contexts}/contracts/artifact-engagement-flow.md +0 -0
  238. /package/{docs → .agent-src/contexts}/contracts/command-suggestion-flow.md +0 -0
@@ -25,7 +25,7 @@ the [`agent-settings` template](../templates/agent-settings.md#cost-profiles):
25
25
  - For first-run setup use [`/onboard`](onboard.md).
26
26
  - For any other single-value change, edit `.agent-settings.yml`
27
27
  directly or ask the agent — the merge rules live in
28
- [`layered-settings`](../../docs/guidelines/agent-infra/layered-settings.md#section-aware-merge-rules).
28
+ [`layered-settings`](../docs/guidelines/agent-infra/layered-settings.md#section-aware-merge-rules).
29
29
  - For role modes use [`/mode`](mode.md) — different concept (sets
30
30
  `roles.active_role`, not `cost_profile`).
31
31
 
@@ -73,7 +73,7 @@ value directly — still echo the old → new line in step 6.
73
73
  ### 5. Write the value
74
74
 
75
75
  Update `cost_profile` in `.agent-settings.yml` using the
76
- [section-aware merge rules](../../docs/guidelines/agent-infra/layered-settings.md#section-aware-merge-rules)
76
+ [section-aware merge rules](../docs/guidelines/agent-infra/layered-settings.md#section-aware-merge-rules)
77
77
  (preserve comments, preserve key order, touch only the changed field).
78
78
 
79
79
  If the user picked "Keep current", do nothing and stop.
@@ -107,6 +107,6 @@ flip. Cost behaviour on those surfaces is governed by the platform itself.
107
107
  ## See also
108
108
 
109
109
  - [`agent-settings`](../templates/agent-settings.md) — profile matrix and settings reference
110
- - [`layered-settings`](../../docs/guidelines/agent-infra/layered-settings.md) — merge rules for settings edits
110
+ - [`layered-settings`](../docs/guidelines/agent-infra/layered-settings.md) — merge rules for settings edits
111
111
  - [`onboard`](onboard.md) — first-run setup (includes profile confirmation)
112
112
  - [`mode`](mode.md) — role-mode setter (different concept)
@@ -15,7 +15,7 @@ Reconciles `.agent-settings.yml` with the shipped template
15
15
  (`config/agent-settings.template.yml`) and the selected cost-profile
16
16
  preset (`config/profiles/{profile}.ini`). Applies the section-aware
17
17
  merge rules documented in
18
- [`layered-settings`](../../docs/guidelines/agent-infra/layered-settings.md):
18
+ [`layered-settings`](../docs/guidelines/agent-infra/layered-settings.md):
19
19
 
20
20
  - Template section order wins — keys reorder to match.
21
21
  - Existing user scalar values are preserved.
@@ -129,6 +129,6 @@ is a local-agent concern.
129
129
  - [`scripts/sync_agent_settings.py`](../../../scripts/sync_agent_settings.py) — the helper
130
130
  - [`config/agent-settings.template.yml`](../../../config/agent-settings.template.yml) — canonical template
131
131
  - [`config/profiles/`](../../../config/profiles/) — profile presets
132
- - [`layered-settings`](../../docs/guidelines/agent-infra/layered-settings.md) — the merge rules this command enforces
132
+ - [`layered-settings`](../docs/guidelines/agent-infra/layered-settings.md) — the merge rules this command enforces
133
133
  - [`scripts/install.py`](../../../scripts/install.py) — first-install path; this command handles the update path
134
134
  - [`/sync-gitignore`](sync-gitignore.md) — sibling command for the `.gitignore` block
@@ -59,7 +59,7 @@ suggestion:
59
59
  - Place tests in the matching directory structure under `tests/` (mirror the source structure).
60
60
  - Group related tests with `describe` blocks (Pest) or separate test methods (PHPUnit).
61
61
  - Use data providers for testing multiple input/output combinations.
62
- - Mock external dependencies (database, HTTP, file system) — don't test infrastructure.
62
+ - Mock external deps (database, HTTP, file system) — don't test infrastructure.
63
63
 
64
64
  ### 6. Verify
65
65
 
@@ -70,7 +70,7 @@ suggestion:
70
70
 
71
71
  - **Do NOT commit or push.**
72
72
  - **Quality over quantity** — 5 meaningful tests beat 20 trivial ones.
73
- - If a class is hard to test (too many dependencies, global state), flag it and suggest a refactoring approach instead of writing brittle
73
+ - If a class is hard to test (too many deps, global state), flag it and suggest a refactoring approach instead of writing brittle
74
74
  tests.
75
75
 
76
76
  ## See also
@@ -22,7 +22,7 @@ commands with a single entry point + sub-command dispatch.
22
22
  | `/tests execute` | `commands/tests/execute.md` | Run PHP tests inside the Docker container |
23
23
 
24
24
  Sub-command names match the locked contract in
25
- [`docs/contracts/command-clusters.md`](../../docs/contracts/command-clusters.md).
25
+ [`docs/contracts/command-clusters.md`](../docs/contracts/command-clusters.md).
26
26
 
27
27
  ## Dispatch
28
28
 
@@ -71,7 +71,7 @@ Produce one combined report with these sections, in order:
71
71
  5. **Required controls** — the minimum set of validations, authorization
72
72
  checks, logging, and negative tests that must exist before the change ships
73
73
  6. **Open questions** — anything the skills flagged as uncertain and the user
74
- must answer before implementation starts
74
+ must answer before impl starts
75
75
 
76
76
  ### 5. Decide next step
77
77
 
@@ -83,7 +83,7 @@ After the report, ask:
83
83
  > 3. Stop here — threat model is the deliverable, no implementation yet
84
84
  ```
85
85
 
86
- - On **1**: hand off to the implementation flow (e.g., `feature-plan`,
86
+ - On **1**: hand off to the impl flow (e.g., `feature-plan`,
87
87
  `bug-fix`, or direct edit) with the required-controls list pinned
88
88
  - On **2**: re-gather context and re-dispatch
89
89
  - On **3**: save the report as the deliverable, stop
@@ -106,7 +106,7 @@ After the report, ask:
106
106
  - NEVER merge `threat-modeling` and `authz-review` outputs into a single
107
107
  block — each skill owns its format
108
108
  - NEVER write production code in the same turn as this command — the
109
- deliverable is the report; implementation is a separate step
109
+ deliverable is the report; impl is a separate step
110
110
  - NEVER mark the change "safe" if any 🔴 abuse case has no control
111
111
 
112
112
  ## See also
@@ -116,4 +116,4 @@ After the report, ask:
116
116
  - [`data-flow-mapper`](../skills/data-flow-mapper/SKILL.md) — trace specific data through the change
117
117
  - [`blast-radius-analyzer`](../skills/blast-radius-analyzer/SKILL.md) — enumerate affected call sites
118
118
  - [`security-sensitive-stop`](../rules/security-sensitive-stop.md) — the trigger rule
119
- - [`minimal-safe-diff`](../rules/minimal-safe-diff.md) — keep the implementation scoped
119
+ - [`minimal-safe-diff`](../rules/minimal-safe-diff.md) — keep the impl scoped
@@ -8,6 +8,19 @@ in autonomous vs. non-autonomous mode.
8
8
  **Size budget:** ≤ 3,000 chars. Tracked under Phase 6 of
9
9
  `road-to-pr-34-followups`.
10
10
 
11
+ ## The four commit exceptions — restated
12
+
13
+ Outside the four below, no commit is allowed and no commit ask is allowed.
14
+
15
+ 1. **User says so this turn** — "commit this now", "commit it", "go
16
+ ahead and commit". Single commit, not standing.
17
+ 2. **Standing instruction not yet revoked** — earlier "commit after
18
+ every phase"; cache the instruction and commit per its terms.
19
+ 3. **Commit command invoked** — `/commit` (split + confirm per commit)
20
+ or `/commit:in-chunks` (auto-split, Hard Floor still applies).
21
+ 4. **Roadmap authorization** — roadmap lists explicit commit steps and
22
+ the user invoked roadmap execution; each commit matches a step.
23
+
11
24
  ## Hard Floor still applies — bulk deletions and infra changes
12
25
 
13
26
  Even when one of the four `commit-policy` exceptions authorizes a
@@ -19,7 +32,7 @@ Hard Floor still fires when the diff:
19
32
  - Touches Terraform / Pulumi / k8s manifests / Ansible / cloud-config
20
33
 
21
34
  In those cases, **surface the diff** (paths + counts) and confirm
22
- this turn before committing — even under `/commit-in-chunks`,
35
+ this turn before committing — even under `/commit:in-chunks`,
23
36
  roadmap pre-scan authorization, or an explicit "commit this now". The
24
37
  four exceptions cover *whether* commits happen; the Hard Floor covers
25
38
  *which diffs* still need a separate confirmation.
@@ -9,6 +9,19 @@ context holds everything an agent reaches for once those have fired.
9
9
  **Size budget:** ≤ 3,500 chars. Tracked under Phase 7.4 of
10
10
  `road-to-pr-34-followups`.
11
11
 
12
+ ## Iron Law — restatement
13
+
14
+ The rule's Iron Law ("HARD FLOOR OVERRIDES EVERYTHING") is the universal
15
+ non-destructive-by-default safety net. No autonomy setting, roadmap step,
16
+ or standing instruction can lift it. This is the same Iron Law restated
17
+ in `commit-policy` (row 6 of its trigger table) and in `scope-control`
18
+ (production / infra / bulk-destructive subset).
19
+
20
+ The trigger surface covers production-branch merges, deploys / releases,
21
+ production data and infrastructure changes, pushes to remote, and
22
+ whimsical or unscoped bulk-destructive operations. Authorization is
23
+ "user said so this turn", never inferred from a previous turn.
24
+
12
25
  ## Bulk deletions during WIP — allowed if task-connected
13
26
 
14
27
  Deletions inside an **active, user-stated task** are allowed in the
@@ -58,7 +71,7 @@ the diff (paths + counts), get confirmation, then commit.
58
71
  - Committing a diff that removes a directory, deletes ≥5 unrelated
59
72
  files, or touches Terraform / k8s manifests / Ansible without
60
73
  surfacing the diff first — even when [`commit-policy`](../../rules/commit-policy.md)
61
- otherwise authorizes commits (e.g. `/commit-in-chunks`, roadmap
74
+ otherwise authorizes commits (e.g. `/commit:in-chunks`, roadmap
62
75
  pre-scan, an explicit "commit this now"). Bulk-deletion / infra
63
76
  commits need their own ask, every time.
64
77
  - Reading a roadmap step listing files to delete as authorization to
@@ -35,6 +35,11 @@ concerns:
35
35
  A roadmap step or earlier turn does **not** count as authorization
36
36
  for these. Authorization is "the user said so on this turn".
37
37
 
38
+ Earlier permission for a different operation does **not** carry over —
39
+ permission is per-operation, this-turn. Standing autonomy directives
40
+ narrow other rules but never grant permission for items in this Hard
41
+ Floor subset.
42
+
38
43
  ## Brief-before-asking — separate branch / PR / worktree
39
44
 
40
45
  If a task seems to need a separate branch or PR (spike, hotfix,
@@ -0,0 +1,76 @@
1
+ # Guidelines — index
2
+
3
+ Full table of available coding guidelines for the
4
+ [`guidelines`](../../../rules/guidelines.md) rule. The rule body
5
+ holds the obligation surface (always check the relevant guideline
6
+ before writing or reviewing code); this file is the catalog.
7
+
8
+ ## PHP (`docs/guidelines/php/`)
9
+
10
+ | File | Topic |
11
+ |---|---|
12
+ | `php.md` | General PHP style — strict types, naming, comparisons, early returns, JSON handling |
13
+ | `controllers.md` | Thin controllers, single responsibility, delegation to services |
14
+ | `eloquent.md` | Model conventions, relationships, scopes, accessors/mutators |
15
+ | `validations.md` | FormRequest patterns, custom rules, validation structure |
16
+ | `resources.md` | API Resource conventions, response structure |
17
+ | `jobs.md` | Queue job patterns, serialization, retry strategies |
18
+ | `git.md` | Branch naming, commit messages, PR conventions |
19
+ | `api-design.md` | API conventions — response format, status codes, pagination, error handling |
20
+ | `artisan-commands.md` | Console command conventions — naming, structure, safety, scheduling |
21
+ | `blade-ui.md` | Blade template conventions — views, components, forms, escaping |
22
+ | `database.md` | Database conventions — indexing, query optimization, migrations, transactions |
23
+ | `flux.md` | Flux UI component conventions — usage, variants, forms, Livewire integration |
24
+ | `livewire.md` | Livewire component conventions — state, actions, forms, performance, Alpine.js |
25
+ | `logging.md` | Logging conventions — levels, structured context, Sentry patterns |
26
+ | `naming.md` | Naming conventions — classes, database, routes, variables, modules, agent infra |
27
+ | `performance.md` | Performance conventions — caching, Redis, eager loading, response time targets |
28
+ | `security.md` | Security conventions — auth, authorization, SQL injection, XSS, CSRF, headers |
29
+ | `sql.md` | Raw SQL conventions — parameterization, MariaDB syntax, common mistakes |
30
+ | `websocket.md` | WebSocket conventions — Broadcasting, channel types, connection management |
31
+ | `patterns.md` | Design patterns index (links to `patterns/` subdirectory) |
32
+
33
+ ## PHP Patterns (`docs/guidelines/php/patterns/`)
34
+
35
+ | File | Pattern |
36
+ |---|---|
37
+ | `service-layer.md` | Service classes, business logic encapsulation |
38
+ | `repositories.md` | Repository pattern, query encapsulation |
39
+ | `dtos.md` | Data Transfer Objects, SimpleDto conventions |
40
+ | `dependency-injection.md` | Constructor injection, service container |
41
+ | `events.md` | Event/Listener patterns, dispatching |
42
+ | `policies.md` | Authorization policies, gate definitions |
43
+ | `factory.md` | Factory pattern usage |
44
+ | `pipelines.md` | Laravel Pipeline pattern |
45
+ | `strategy.md` | Strategy pattern implementation |
46
+
47
+ ## E2E (`docs/guidelines/e2e/`)
48
+
49
+ Playwright best practices, Page Objects, fixtures, CI.
50
+
51
+ ## Agent Infrastructure (`docs/guidelines/agent-infra/`)
52
+
53
+ | File | Topic |
54
+ |---|---|
55
+ | `size-and-scope.md` | Size limits and scope boundaries for rules, skills, commands, guidelines, AGENTS.md, copilot-instructions.md |
56
+ | `output-patterns.md` | Redirect / Summarize / Target pattern, targeted operations, tool-first policy, general CLI rules |
57
+
58
+ ## Boundary: Guidelines vs Skills
59
+
60
+ - Guidelines contain **conventions and reference knowledge**. Skills
61
+ contain **executable workflows**.
62
+ - A skill MAY reference a guideline for conventions, but MUST NOT
63
+ outsource its core execution steps to a guideline.
64
+ - Do NOT move a skill's operational core (procedure, validation,
65
+ decision logic) into a guideline.
66
+ - A skill that becomes "go read the guideline" has lost its purpose
67
+ — restore the workflow.
68
+
69
+ ## Adding new guidelines
70
+
71
+ When a new language or framework is introduced, create a directory:
72
+
73
+ docs/guidelines/{language}/
74
+
75
+ Follow the existing PHP structure as a template. Read the specific
76
+ guideline file on demand — don't memorize the full list.
@@ -4,7 +4,7 @@ Lookup table for the `slash-command-routing-policy` rule. Lists the
4
4
  locked clusters and their sub-commands so the rule itself can stay at
5
5
  its current LOC while still reflecting the full surface. Source of
6
6
  truth for the cluster names is
7
- [`docs/contracts/command-clusters.md`](../../../../docs/contracts/command-clusters.md);
7
+ [`docs/contracts/command-clusters.md`](../../../../../docs/contracts/command-clusters.md);
8
8
  this file mirrors that contract for runtime lookup. Linter:
9
9
  `scripts/check_cluster_patterns.py` (verifies dispatcher shape).
10
10
 
@@ -0,0 +1,98 @@
1
+ # Think Before Action — mechanics
2
+
3
+ Workflow tables, verification matrix, and failure modes for the
4
+ [`think-before-action`](../../../rules/think-before-action.md) rule.
5
+ The rule body holds the obligation surface (analyze before coding,
6
+ verify with real tools, no blind retries). This file is the lookup
7
+ material agents pull when the rule fires.
8
+
9
+ ## The Developer Workflow — five-step order
10
+
11
+ Work like a developer, not a text generator. Skipping steps 1–3 is the
12
+ #1 cause of wrong implementations and wasted retries.
13
+
14
+ 1. **Understand** — Read the task, ticket, acceptance criteria. Unclear
15
+ → ask, don't assume.
16
+ 2. **Analyze** — Read affected code, trace data flow, compare with
17
+ requirements and existing patterns.
18
+ 3. **Plan** — Decide what to change, what NOT to change, and how to
19
+ verify success.
20
+ 4. **Implement** — Focused changes. Follow existing patterns. No
21
+ unrelated rewrites.
22
+ 5. **Verify** — Run tests, hit the endpoint, check the UI. Real
23
+ execution, never "should work".
24
+
25
+ ## Minimum read set — read before you write
26
+
27
+ Before editing code, read the minimum set that defines its behavior:
28
+
29
+ 1. **Symbol under edit** — full method/function body, not just the
30
+ planned line.
31
+ 2. **Direct callers** — one level up (`grep -rn "<symbol>"` + open
32
+ the matches).
33
+ 3. **Tests** — if a test file exists, it encodes the contract.
34
+ 4. **One layer of related abstractions** — interface, parent class,
35
+ or trait (one hop, not the full hierarchy).
36
+ 5. **Data changes** — the migration that created the column + any
37
+ seeder/factory that references it.
38
+
39
+ Stop expanding once you can explain, in your own words, what the
40
+ symbol does, who calls it, and what breaks if you change its
41
+ behavior. Cannot → read more.
42
+
43
+ ## Consult memory before editing
44
+
45
+ Prior decisions and invariants live in the memory layer. Via
46
+ [`memory-access`](../../../../../docs/guidelines/agent-infra/memory-access.md),
47
+ call `retrieve(types=["architecture-decisions", "domain-invariants"], keys=<touched paths>, limit=3)`.
48
+ A matching `architecture-decision` explains *why* the current shape
49
+ exists; a matching `domain-invariant` is a hard constraint. Cite the
50
+ `id` if a match influences the plan.
51
+
52
+ ## Verify with real tools
53
+
54
+ | What changed | How to verify |
55
+ |---|---|
56
+ | **Backend/API** | `curl`, Postman (or Postman MCP if available), test endpoint |
57
+ | **Frontend/UI** | Playwright MCP or browser — check rendered state, interactions |
58
+ | **Logic/flow** | Xdebug (or Xdebug MCP if available) — trace execution, inspect variables |
59
+ | **CLI/Jobs** | Run the command, check side effects, verify exit code |
60
+ | **Database** | Query the result, check migrations ran correctly |
61
+
62
+ If a debugging/testing tool is available as MCP server — prefer it
63
+ over manual alternatives. Verification not possible (no endpoint, no
64
+ UI, no test) → state what is missing and explain how the change
65
+ should be tested.
66
+
67
+ ## Reduce output — targeted tools over full dumps
68
+
69
+ Never load full datasets into context. Extract what you need:
70
+
71
+ - `jq` for JSON: `curl -s /api/users | jq '.[0] | {id, email}'` — not the full response
72
+ - `rg` / `grep` for text: search specific patterns, not full files
73
+ - `head`, `tail`, `cut`, `sort`, `uniq` for narrowing results
74
+ - `--filter`, `--json`, `--format` flags on CLI tools — use them
75
+ - Laravel: `route:list --json | jq` over raw `route:list` dump
76
+ - Logs: filter by request ID, timestamp, or error type — not full log files
77
+
78
+ ## No blind retries
79
+
80
+ - Failure → **read the error**, analyze the cause, then fix it.
81
+ - Do NOT retry the same approach hoping for a different result.
82
+ - Do NOT loop through trial-and-error when one targeted inspection
83
+ would reveal the cause.
84
+ - Max 2 retries for the same approach — then stop and rethink.
85
+
86
+ ## Open files are context, not intent
87
+
88
+ The editor may report that the user has a file open. Background
89
+ context only — does NOT mean the user's message is about that file.
90
+
91
+ - The user's message determines intent — not which file is open.
92
+ - A user can have `README.md` open and type `/compress` — intent is
93
+ to compress, not to discuss the README.
94
+ - A user can have `UserController.php` open and ask "how do tests
95
+ work?" — intent is testing, not the controller.
96
+ - Treat the open file as relevant only when the user's message
97
+ explicitly references it (e.g. "fix this file", "what does this
98
+ do?", "update the open file").
@@ -0,0 +1,93 @@
1
+ # Token Efficiency — mechanics
2
+
3
+ Anti-loop patterns, conversation efficiency rules, and exception
4
+ catalog for the [`token-efficiency`](../../../rules/token-efficiency.md)
5
+ rule. The rule body holds the two Iron Laws and the fresh-output
6
+ principle; this file is the lookup material.
7
+
8
+ ## Anti-loop: Extended Reasoning
9
+
10
+ Do NOT use extended reasoning / chain-of-thought tools for simple
11
+ tasks like viewing files, running commands, or making straightforward
12
+ edits. They are ONLY for genuinely complex multi-step reasoning. If
13
+ calling such tools more than once per task — you are looping. Stop
14
+ immediately and act directly.
15
+
16
+ ## Anti-loop: "CRITICAL INSTRUCTION" and self-prompting
17
+
18
+ Generating text that starts with "CRITICAL INSTRUCTION", "I need
19
+ to", "Let me think", "Related tools:", or similar self-directed
20
+ reasoning inside a tool call or as a preamble before acting → **you
21
+ are in a loop**. Happens after connection errors or when the user
22
+ says "continue" / "mach weiter".
23
+
24
+ **Immediate action:**
25
+
26
+ 1. STOP generating self-instructions.
27
+ 2. Read the last user message — what did they actually ask?
28
+ 3. Do that ONE thing directly. No planning monologue, no tool
29
+ selection reasoning.
30
+ 4. Don't know what the user wanted → ask: "Where were we?"
31
+
32
+ ## Conversation Efficiency
33
+
34
+ ### Act, skip narration
35
+
36
+ - **Skip repeating the user's request.** They know what they asked.
37
+ - **Just do it** — skip announcing what you're about to do.
38
+ - **Skip explaining obvious tool calls.** Reading a file needs no
39
+ justification.
40
+ - **Report only outcomes** — skip intermediate step summaries unless
41
+ the user needs them.
42
+
43
+ This rule NEVER overrides `user-interaction` or command rules. Token
44
+ efficiency means fewer *unnecessary* words — NOT skipping required
45
+ questions, numbered options, or command steps. When a rule or
46
+ command says "ask the user", you ask.
47
+
48
+ ### Stop early — max 2 retries
49
+
50
+ - Command fails twice with same error → stop, rethink. Try a
51
+ different approach.
52
+ - `grep` / search returns nothing after 2 attempts → switch approach
53
+ or ask the user.
54
+ - Max 3 diagnostic commands per error. Read the error, think, act.
55
+ - One hypothesis at a time. Pick the most likely, try it. Fails →
56
+ ask.
57
+
58
+ ### Keep intermediate output minimal
59
+
60
+ Read `personal.minimal_output` (default: `true`) and
61
+ `personal.play_by_play` (default: `false`) from `.agent-settings.yml`.
62
+
63
+ When `personal.minimal_output: true`:
64
+
65
+ - Multi-step work: short bullet points only, no paragraphs.
66
+ - No thinking out loud — user doesn't need your reasoning.
67
+ - `personal.play_by_play: false` → silently investigate, report
68
+ conclusion only.
69
+ - `personal.play_by_play: true` → briefly share intermediate
70
+ findings.
71
+ - At the end: concise summary — what changed, what user needs to
72
+ know.
73
+
74
+ ### Don't re-read what you already know
75
+
76
+ - Edited a file → edit tool showed result. Don't re-read.
77
+ - Ran a command → you have output. Don't re-run to "verify".
78
+ - File in context from recent messages → don't reload.
79
+
80
+ ### Minimize tool calls
81
+
82
+ - Parallel reads — don't read 5 files sequentially.
83
+ - Regex search over full file reads. View specific line ranges.
84
+ - One codebase search call with all symbols — not 5 separate.
85
+ - Short question → short answer. Summary tables only for 3+ items.
86
+
87
+ ### Exceptions
88
+
89
+ - Small output (< 30 lines) — read directly.
90
+ - Debugging — OK to read more context around one error.
91
+ - User explicitly asks for full output — show it.
92
+
93
+ → Detailed patterns: `docs/guidelines/agent-infra/output-patterns.md`
@@ -1,10 +1,133 @@
1
1
  # User Interaction — mechanics
2
2
 
3
- Format examples, progress indicators, and summary patterns for the
4
- [`user-interaction`](../../../rules/user-interaction.md) rule. Iron
5
- Law 1 (single-source recommendation), Iron Law 2 (pre-send
6
- self-check), and the named failure-mode catalog live in the rule
7
- itself; this file is the lookup material for the format details.
3
+ Rationale, failure-mode catalog, format examples, progress
4
+ indicators, and summary patterns for the
5
+ [`user-interaction`](../../../rules/user-interaction.md) rule. The
6
+ rule body holds the two Iron Law fenced blocks (single-source
7
+ recommendation, pre-send self-check); this file is the lookup
8
+ material for everything else.
9
+
10
+ ## Why the agent must take a position
11
+
12
+ The agent has read the code, the contracts, the trade-offs.
13
+ Refusing to take a position dumps that work back on the user. Take
14
+ the position; be wrong out loud if needed. "Egal, was bevorzugst
15
+ Du?" / "no preference" is NEVER acceptable.
16
+
17
+ ## Position-agnostic — the most common slip
18
+
19
+ End-of-turn "Wie weiter?" / "What next?" / "How to proceed?" / "How
20
+ should we continue?" blocks with numbered options ARE numbered-options
21
+ blocks. Same Iron Law applies — exactly one `Empfehlung: N` /
22
+ `Recommendation: N` line, every time. No "these are just follow-up
23
+ suggestions" exception, no "the user knows better here" exception, no
24
+ "I genuinely don't have a preference" exception. If the agent prints
25
+ `1. … 2. … 3. …` anywhere in the reply, the recommendation line is
26
+ mandatory.
27
+
28
+ ## Format — non-negotiable
29
+
30
+ - Options block stays NEUTRAL — no `(recommended)`, no `(rec)`, no
31
+ `←`, no bold, no checkmark.
32
+ - Directly after the options block, ONE line, bolded, in the user's
33
+ language:
34
+ - English: `**Recommendation: N — <option-name>** — <why>. Caveat: <flip-condition>.`
35
+ - German: `**Empfehlung: N — <option-name>** — <warum>. Caveat: <flip-bedingung>.`
36
+ - Other numbers MAY appear later in the prose, but ONLY as caveats
37
+ (`escalate to 3 if …`, `flip to 1 when …`). NEVER as a primary
38
+ recommendation.
39
+ - Genuine tie (rare — true 50/50 with missing data) → say what data
40
+ would break the tie and ask for that instead.
41
+
42
+ ## No trailing open-ended question
43
+
44
+ Reply contains numbered options → the recommendation line IS the
45
+ closer. No `Welcher Pfad?` / `What's it gonna be?` / `Was meinst
46
+ Du?` / `Was sagst Du?` / `Welche willst Du?` / `What do you think?`
47
+ after the recommendation — that reframes the vote as opinion-poll
48
+ and is hedging in disguise. The user picks a number; the agent does
49
+ not re-ask. Permitted: a clarifying caveat sentence on the
50
+ recommendation line itself (`Caveat: flip to 2 if …`). Forbidden:
51
+ any standalone trailing question that re-opens the choice.
52
+
53
+ ## What does NOT count as a recommendation
54
+
55
+ - "Both work" / "either is fine" / "depends on what you prefer"
56
+ - Listing pros and cons without picking a number
57
+ - "I'd lean towards X" without a reason
58
+ - Hiding behind "you know the project better"
59
+ - Inline `(recommended)` tag with no follow-up `Recommendation: N` line
60
+
61
+ ## Pre-send self-check details
62
+
63
+ Before emitting any reply that contains numbered options, scan the
64
+ **entire drafted reply** — top to bottom, including end-of-turn
65
+ "Wie weiter?" / "What next?" continuation menus, follow-up
66
+ suggestion blocks, and any list of `1. … 2. … 3. …` regardless of
67
+ position or framing:
68
+
69
+ 1. Count occurrences of `(recommended)` / `(rec)` / `(empfohlen)`
70
+ inline next to a numbered option → MUST be **zero**. Found one →
71
+ rewrite, drop the tag.
72
+ 2. Count `1\\.\\s` / `2\\.\\s` / `3\\.\\s` patterns inside blockquotes
73
+ or top-level prose → if **any** numbered-option block exists
74
+ anywhere in the reply, the recommendation line is mandatory.
75
+ 3. Count distinct `Recommendation:\\s*N` / `Empfehlung:\\s*N` lines
76
+ (case-insensitive) → MUST be **exactly one per options block**.
77
+ Zero → add one. Two or more distinct numbers → rewrite, pick one.
78
+ 4. The number on the recommendation line MUST exist in the option
79
+ block it follows.
80
+ 5. Multiple options blocks (e.g. clarification block AND end-of-turn
81
+ menu) → each block gets its own `Recommendation: N` line directly
82
+ underneath.
83
+
84
+ Mechanical backstop:
85
+ `python3 scripts/check_reply_consistency.py --stdin < draft.md`
86
+ (non-zero exit on any rule above). Self-scan is the primary gate;
87
+ the script is the deterministic safety net for ambiguous cases.
88
+
89
+ ## Common failure modes — known, named, no excuses
90
+
91
+ - **End-of-turn menu skipped.** Reply answers fine, then ends with
92
+ `1. … 2. … 3. …` and no `Empfehlung:`. Iron Law 1 violated — these
93
+ are numbered options, position is irrelevant.
94
+ - **Trailing-question hedge.** Reply has options + recommendation,
95
+ but ends with `Welcher Pfad?` / `What's it gonna be?` — reframes
96
+ the vote as opinion-poll. Banned by Iron Law 1.
97
+ - **"Genuinely no preference" hedge.** Pick anyway. Agent has more
98
+ context than user on the trade-off; refusing to pick dumps the
99
+ work back. Pick the safest option, name the flip-condition.
100
+ - **"User knows the project better" hedge.** Same failure mode,
101
+ different costume. The user asked for an opinion by virtue of
102
+ accepting the options block; deliver it.
103
+ - **Multi-block reply with one recommendation.** Two options blocks
104
+ but only one `Empfehlung:` line — second block unguarded. Rule 5
105
+ of Iron Law 2 closes this.
106
+
107
+ ## Slip handling
108
+
109
+ Same protocol as
110
+ [`language-and-tone § slip-handling`](../../../rules/language-and-tone.md#slip-handling).
111
+ User calls out a missing or wrong recommendation → acknowledge once
112
+ in the user's language, rewrite the reply with a recommendation,
113
+ ship. No "from now on" promises — only the next reply proves
114
+ compliance.
115
+
116
+ ## Numbered Options — rules
117
+
118
+ - **Every question with choices** must use numbered options — no
119
+ exceptions.
120
+ - **Every numbered list with `1. … 2. … 3. …`** is a
121
+ numbered-options block, regardless of position. End-of-turn "Wie
122
+ weiter?" / "What next?" / "How to proceed?" menus, mid-reply
123
+ continuation prompts, and clarification blocks all count.
124
+ - **Keep options short** — one line each, with a brief explanation
125
+ after the dash.
126
+ - **Always include a "skip" or "no change" option** when applicable.
127
+ - **Always state a recommendation** — Iron Law 1.
128
+ - **Use the user's language** for the question and options.
129
+ - **Accept both** the number and a natural-language answer ("1" or
130
+ "the first one").
8
131
 
9
132
  ## Examples
10
133
 
@@ -27,3 +27,47 @@ The Hard Floor still applies on every surface, including cloud. There
27
27
  is no "cloud override" for production-branch merges, deploys, pushes,
28
28
  prod data/infra, or whimsical bulk deletions — see
29
29
  [`non-destructive-by-default`](../../rules/non-destructive-by-default.md#cloud-behavior).
30
+
31
+ ## Blocking — STILL ASK regardless of `personal.autonomy`
32
+
33
+ Beyond the Hard Floor, the autonomy setting also never overrides:
34
+
35
+ - **Vague-request triggers** in
36
+ [`ask-when-uncertain`](../../rules/ask-when-uncertain.md) —
37
+ ambiguous requirements stay ambiguous; pick-one-and-pray is wrong.
38
+ - **Architectural / structural choices** the codebase doesn't already
39
+ settle (multi-stack picks, library introductions).
40
+ - **Security-sensitive paths** — see
41
+ [`security-sensitive-stop`](../../rules/security-sensitive-stop.md).
42
+ - **Scope expansion** beyond the stated task — see
43
+ [`scope-control`](../../rules/scope-control.md).
44
+ - **Remote-state operations** — push, merge, rebase, force-push,
45
+ branch create/delete/switch, PR create/close/retarget, tag/release.
46
+ Permission-gated by
47
+ [`scope-control`](../../rules/scope-control.md); the prod-trunk
48
+ and deploy-tied subset is governed by
49
+ [`non-destructive-by-default`](../../rules/non-destructive-by-default.md).
50
+ - **Destructive ops** — see
51
+ [`non-destructive-by-default`](../../rules/non-destructive-by-default.md)
52
+ for the full taxonomy (whimsical bulk deletions, content
53
+ destruction, commits containing bulk deletions or infra changes).
54
+
55
+ In doubt whether something is trivial or blocking → it is blocking.
56
+ Ask.
57
+
58
+ ## Commit policy summary
59
+
60
+ Committing is governed by the canonical
61
+ [`commit-policy`](../../rules/commit-policy.md) rule, which applies
62
+ regardless of `personal.autonomy`:
63
+
64
+ - NEVER commit unless user said so this turn, a commit command was
65
+ invoked, a standing instruction is active, or the roadmap
66
+ authorizes it.
67
+ - NEVER ask about committing. The user invokes a command or says so.
68
+ - In autonomous mode, the **only** permitted commit-related question
69
+ is the one-shot pre-scan ask at the start of roadmap execution.
70
+
71
+ Push, merge, rebase, branch creation, PR operations, and tags
72
+ remain permission-gated by
73
+ [`scope-control § git-operations`](../../rules/scope-control.md#git-operations--permission-gated).
@@ -91,7 +91,7 @@ produce opus-level quality by enforcing habits that weaker models skip by defaul
91
91
  - **Default to `sonnet`** — it's the cost-efficient workhorse.
92
92
  - **Escalate to `opus`** only when architecture, refactoring, or unclear debugging is involved.
93
93
  - **After Opus work** (architecture plan, refactoring design, root cause found):
94
- → Recommend switching back to `sonnet` for implementation.
94
+ → Recommend switching back to `sonnet` for impl.
95
95
  - **Use `gpt`** for large-scale analysis, searching across many files, or automation.
96
96
 
97
97
  ## Recommendation Flow
@@ -121,7 +121,7 @@ When user says they want to continue with the current model:
121
121
  ### Downgrade reminder
122
122
 
123
123
  After completing an opus-level task (architecture plan done, refactoring complete, root cause found),
124
- remind the user to switch back to sonnet for the implementation phase:
124
+ remind the user to switch back to sonnet for the impl phase:
125
125
 
126
126
  ```
127
127
  > 💡 The {architecture/debugging/design} phase is done.