@event4u/agent-config 14.23.0 → 16.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/.augment-plugin/marketplace.json +3 -3
- package/.augment-plugin/plugin.json +1 -1
- package/.claude-plugin/marketplace.json +1 -1
- package/CHANGELOG.md +144 -152
- package/README.md +1 -1
- package/dist/agent-src/commands/agent-handoff.md +8 -7
- package/dist/agent-src/commands/agents/init.md +1 -1
- package/dist/agent-src/commands/agents/user/accept.md +4 -4
- package/dist/agent-src/commands/agents/user/delete.md +2 -2
- package/dist/agent-src/commands/agents/user/init.md +3 -3
- package/dist/agent-src/commands/agents/user/review.md +3 -3
- package/dist/agent-src/commands/agents/user/show.md +3 -3
- package/dist/agent-src/commands/agents/user/update.md +2 -2
- package/dist/agent-src/commands/agents/user.md +6 -6
- package/dist/agent-src/commands/analytics/prune.md +1 -1
- package/dist/agent-src/commands/analytics/show.md +2 -2
- package/dist/agent-src/commands/analyze/decision.md +2 -2
- package/dist/agent-src/commands/analyze/inbox.md +5 -5
- package/dist/agent-src/commands/analyze/incident.md +3 -3
- package/dist/agent-src/commands/analyze/near-miss.md +3 -3
- package/dist/agent-src/commands/analyze/postmortem.md +4 -4
- package/dist/agent-src/commands/analyze/premortem.md +2 -2
- package/dist/agent-src/commands/analyze.md +2 -2
- package/dist/agent-src/commands/bug/fix.md +1 -1
- package/dist/agent-src/commands/bug/investigate.md +2 -2
- package/dist/agent-src/commands/cost/profile.md +3 -3
- package/dist/agent-src/commands/design.md +1 -1
- package/dist/agent-src/commands/feature/explore.md +1 -1
- package/dist/agent-src/commands/feature/plan.md +2 -2
- package/dist/agent-src/commands/feature/roadmap.md +2 -2
- package/dist/agent-src/commands/ghostwriter/fetch.md +4 -4
- package/dist/agent-src/commands/ghostwriter/list.md +1 -1
- package/dist/agent-src/commands/ghostwriter/show.md +1 -1
- package/dist/agent-src/commands/ghostwriter/write.md +9 -9
- package/dist/agent-src/commands/humanize.md +6 -6
- package/dist/agent-src/commands/jira-ticket.md +1 -1
- package/dist/agent-src/commands/judge/solo.md +1 -1
- package/dist/agent-src/commands/judge.md +1 -1
- package/dist/agent-src/commands/knowledge/cross-repo.md +1 -1
- package/dist/agent-src/commands/knowledge/forget.md +1 -1
- package/dist/agent-src/commands/knowledge/ingest.md +2 -2
- package/dist/agent-src/commands/knowledge/list.md +1 -1
- package/dist/agent-src/commands/memory/add.md +3 -3
- package/dist/agent-src/commands/memory/load.md +4 -4
- package/dist/agent-src/commands/memory/mine-session.md +1 -1
- package/dist/agent-src/commands/memory/promote.md +4 -4
- package/dist/agent-src/commands/memory/propose.md +2 -2
- package/dist/agent-src/commands/mode.md +5 -5
- package/dist/agent-src/commands/post-as/ghostwriter.md +3 -3
- package/dist/agent-src/commands/post-as/me.md +7 -7
- package/dist/agent-src/commands/pr/create.md +1 -1
- package/dist/agent-src/commands/pr/merge.md +1 -1
- package/dist/agent-src/commands/profile/activate.md +1 -1
- package/dist/agent-src/commands/profile/show.md +1 -1
- package/dist/agent-src/commands/research/deep.md +2 -2
- package/dist/agent-src/commands/research/report.md +2 -2
- package/dist/agent-src/commands/review/changes.md +1 -1
- package/dist/agent-src/commands/review/routing.md +1 -1
- package/dist/agent-src/commands/roadmap/create.md +4 -3
- package/dist/agent-src/commands/roadmap/materialize.md +2 -2
- package/dist/agent-src/commands/roadmap/next.md +1 -1
- package/dist/agent-src/commands/roadmap/process-full.md +2 -2
- package/dist/agent-src/commands/security-audit-config.md +3 -3
- package/dist/agent-src/commands/skill/preview.md +1 -1
- package/dist/agent-src/commands/skills/discover.md +1 -1
- package/dist/agent-src/commands/sync/agent-settings.md +2 -2
- package/dist/agent-src/commands/sync/gitignore/fix.md +1 -1
- package/dist/agent-src/commands/tests/create.md +1 -1
- package/dist/agent-src/commands/tests/e2e-heal.md +1 -1
- package/dist/agent-src/commands/tests/e2e-plan.md +1 -1
- package/dist/agent-src/contexts/authority/kernel-rule-edits.md +6 -6
- package/dist/agent-src/contexts/communication/rules-auto/slash-command-routing-policy-mechanics.md +1 -2
- package/dist/agent-src/contexts/communication/rules-auto/think-before-action-mechanics.md +2 -2
- package/dist/agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +88 -1
- package/dist/agent-src/contexts/communication/rules-auto/user-interaction-mechanics.md +51 -1
- package/dist/agent-src/contexts/contracts/frugality-charter.md +1 -1
- package/dist/agent-src/contexts/execution/auto-dispatch-classification.md +1 -1
- package/dist/agent-src/contexts/execution/auto-orchestration-activation.md +1 -1
- package/dist/agent-src/contexts/execution/autonomy-mechanics.md +1 -1
- package/dist/agent-src/contexts/execution/cheap-question-mechanics.md +1 -1
- package/dist/agent-src/contexts/execution/contract-decision-sheet.md +3 -3
- package/dist/agent-src/contexts/execution/mandated-lines.md +1 -1
- package/dist/agent-src/contexts/execution/non-interactive-contract.md +1 -1
- package/dist/agent-src/contexts/execution/orchestration-telemetry.md +1 -1
- package/dist/agent-src/contexts/execution/plan-confidence-gate.md +5 -5
- package/dist/agent-src/contexts/execution/roadmap-execution-contract.md +1 -1
- package/dist/agent-src/contexts/execution/subagent-modes-detail.md +1 -1
- package/dist/agent-src/contexts/execution/subagent-routing.md +2 -2
- package/dist/agent-src/contexts/execution/subagent-spawn-contract.md +1 -1
- package/dist/agent-src/contexts/execution/user-memory-channels.md +3 -3
- package/dist/agent-src/contexts/execution/verification-mechanics.md +1 -1
- package/dist/agent-src/contexts/judges/persona-voice-rubric.md +2 -2
- package/dist/agent-src/guidelines/abstraction-thresholds.md +88 -0
- package/dist/agent-src/guidelines/agent-infra/5w2h-analysis.md +260 -0
- package/dist/agent-src/guidelines/agent-infra/active-remediation-mechanics.md +99 -0
- package/dist/agent-src/guidelines/agent-infra/agent-interaction-and-decision-quality.md +325 -0
- package/dist/agent-src/guidelines/agent-infra/api-cost-levers.md +177 -0
- package/dist/agent-src/guidelines/agent-infra/artifact-drafting-protocol-mechanics.md +222 -0
- package/dist/agent-src/guidelines/agent-infra/ask-when-uncertain-demos.md +134 -0
- package/dist/agent-src/guidelines/agent-infra/asking-and-brevity-examples.md +198 -0
- package/dist/agent-src/guidelines/agent-infra/break-glass-usage.md +113 -0
- package/dist/agent-src/guidelines/agent-infra/carve-out-predicates.md +17 -0
- package/dist/agent-src/guidelines/agent-infra/comparison-matrix.md +179 -0
- package/dist/agent-src/guidelines/agent-infra/context-hygiene-mechanics.md +165 -0
- package/dist/agent-src/guidelines/agent-infra/corpus-grounding-authoring.md +91 -0
- package/dist/agent-src/guidelines/agent-infra/critical-thinking.md +156 -0
- package/dist/agent-src/guidelines/agent-infra/cross-source-consistency-mechanics.md +109 -0
- package/dist/agent-src/guidelines/agent-infra/developer-judgment.md +82 -0
- package/dist/agent-src/guidelines/agent-infra/direct-answers-demos.md +142 -0
- package/dist/agent-src/guidelines/agent-infra/domain-adoption-gates.md +112 -0
- package/dist/agent-src/guidelines/agent-infra/domain-eval-anti-pattern.md +53 -0
- package/dist/agent-src/guidelines/agent-infra/domain-pack-architecture.md +56 -0
- package/dist/agent-src/guidelines/agent-infra/downstream-changes-mechanics.md +91 -0
- package/dist/agent-src/guidelines/agent-infra/emphasis-budget.md +45 -0
- package/dist/agent-src/guidelines/agent-infra/engineering-memory-data-format.md +210 -0
- package/dist/agent-src/guidelines/agent-infra/evaluator-independence-mechanics.md +92 -0
- package/dist/agent-src/guidelines/agent-infra/existence-question-verdicts.md +80 -0
- package/dist/agent-src/guidelines/agent-infra/failure-signatures.md +70 -0
- package/dist/agent-src/guidelines/agent-infra/false-green.md +233 -0
- package/dist/agent-src/guidelines/agent-infra/first-principles.md +192 -0
- package/dist/agent-src/guidelines/agent-infra/framework-neutrality-patterns.md +66 -0
- package/dist/agent-src/guidelines/agent-infra/frontier-reasoning-operating-profile.md +169 -0
- package/dist/agent-src/guidelines/agent-infra/gate-authoring.md +177 -0
- package/dist/agent-src/guidelines/agent-infra/guarded-baseline.md +39 -0
- package/dist/agent-src/guidelines/agent-infra/installed-tools-manifest.md +142 -0
- package/dist/agent-src/guidelines/agent-infra/inversion-thinking.md +388 -0
- package/dist/agent-src/guidelines/agent-infra/ios-simulator-guide.md +378 -0
- package/dist/agent-src/guidelines/agent-infra/language-and-tone-examples.md +141 -0
- package/dist/agent-src/guidelines/agent-infra/layered-settings.md +317 -0
- package/dist/agent-src/guidelines/agent-infra/linked-projects-onboarding-gate.md +80 -0
- package/dist/agent-src/guidelines/agent-infra/mcp-request-signing.md +197 -0
- package/dist/agent-src/guidelines/agent-infra/memory-access.md +149 -0
- package/dist/agent-src/guidelines/agent-infra/mental-models.md +314 -0
- package/dist/agent-src/guidelines/agent-infra/minimal-safe-diff-mechanics.md +241 -0
- package/dist/agent-src/guidelines/agent-infra/missing-tool-handling.md +66 -0
- package/dist/agent-src/guidelines/agent-infra/model-recommendation.md +101 -0
- package/dist/agent-src/guidelines/agent-infra/naming.md +69 -0
- package/dist/agent-src/guidelines/agent-infra/notes-horizon-mechanics.md +90 -0
- package/dist/agent-src/guidelines/agent-infra/output-patterns.md +117 -0
- package/dist/agent-src/guidelines/agent-infra/recurring-criticism-mechanics.md +96 -0
- package/dist/agent-src/guidelines/agent-infra/reuse-verdict-mechanics.md +71 -0
- package/dist/agent-src/guidelines/agent-infra/review-routing-data-format.md +143 -0
- package/dist/agent-src/guidelines/agent-infra/roadmap-deferred-resolution-provenance.md +54 -0
- package/dist/agent-src/guidelines/agent-infra/roadmap-progress-mechanics.md +274 -0
- package/dist/agent-src/guidelines/agent-infra/role-contracts.md +209 -0
- package/dist/agent-src/guidelines/agent-infra/role-mode-router.md +89 -0
- package/dist/agent-src/guidelines/agent-infra/rule-body-migration-inventory.md +241 -0
- package/dist/agent-src/guidelines/agent-infra/rule-type-governance.md +73 -0
- package/dist/agent-src/guidelines/agent-infra/runtime-layer.md +89 -0
- package/dist/agent-src/guidelines/agent-infra/scqa-framework.md +526 -0
- package/dist/agent-src/guidelines/agent-infra/security-lint-containment.md +121 -0
- package/dist/agent-src/guidelines/agent-infra/self-improvement-pipeline.md +134 -0
- package/dist/agent-src/guidelines/agent-infra/simplicity-and-goal-demos.md +211 -0
- package/dist/agent-src/guidelines/agent-infra/six-hats.md +353 -0
- package/dist/agent-src/guidelines/agent-infra/size-and-scope.md +229 -0
- package/dist/agent-src/guidelines/agent-infra/skill-quality-checklist.md +157 -0
- package/dist/agent-src/guidelines/agent-infra/source-confidentiality-mechanics.md +109 -0
- package/dist/agent-src/guidelines/agent-infra/symptom-driven-harvest-loop.md +104 -0
- package/dist/agent-src/guidelines/agent-infra/systems-thinking.md +220 -0
- package/dist/agent-src/guidelines/agent-infra/tool-description-as-policy.md +35 -0
- package/dist/agent-src/guidelines/agent-infra/tool-integration.md +73 -0
- package/dist/agent-src/guidelines/agent-infra/traceability-field-mechanics.md +50 -0
- package/dist/agent-src/guidelines/agent-infra/untrusted-input-spotlighting.md +166 -0
- package/dist/agent-src/guidelines/agent-infra/verify-before-complete-demos.md +128 -0
- package/dist/agent-src/guidelines/augment-portability-patterns.md +70 -0
- package/dist/agent-src/guidelines/code-clarity.md +350 -0
- package/dist/agent-src/guidelines/component-oriented-and-oop-development.md +189 -0
- package/dist/agent-src/guidelines/cross-role-handoff.md +127 -0
- package/dist/agent-src/guidelines/design-antipatterns-triggers.json +18 -0
- package/dist/agent-src/guidelines/design-antipatterns.md +327 -0
- package/dist/agent-src/guidelines/design-asset-discipline.md +38 -0
- package/dist/agent-src/guidelines/design-canon.md +63 -0
- package/dist/agent-src/guidelines/design-fidelity-mechanics.md +293 -0
- package/dist/agent-src/guidelines/design-fidelity-routing.md +78 -0
- package/dist/agent-src/guidelines/design-handover-extraction.md +117 -0
- package/dist/agent-src/guidelines/design-modes.md +143 -0
- package/dist/agent-src/guidelines/design-reconciliation.md +172 -0
- package/dist/agent-src/guidelines/docs/readme-size-and-splitting.md +209 -0
- package/dist/agent-src/guidelines/e2e/playwright.md +363 -0
- package/dist/agent-src/guidelines/gtm-handoff.md +114 -0
- package/dist/agent-src/guidelines/monorepo-antipatterns.md +141 -0
- package/dist/agent-src/guidelines/php/api-design.md +115 -0
- package/dist/agent-src/guidelines/php/artisan-commands.md +81 -0
- package/dist/agent-src/guidelines/php/blade-ui.md +78 -0
- package/dist/agent-src/guidelines/php/controllers.md +90 -0
- package/dist/agent-src/guidelines/php/database.md +194 -0
- package/dist/agent-src/guidelines/php/eloquent.md +208 -0
- package/dist/agent-src/guidelines/php/flux.md +80 -0
- package/dist/agent-src/guidelines/php/general.md +207 -0
- package/dist/agent-src/guidelines/php/git.md +164 -0
- package/dist/agent-src/guidelines/php/jobs.md +111 -0
- package/dist/agent-src/guidelines/php/livewire.md +71 -0
- package/dist/agent-src/guidelines/php/logging.md +79 -0
- package/dist/agent-src/guidelines/php/naming.md +89 -0
- package/dist/agent-src/guidelines/php/patterns/dependency-injection.md +57 -0
- package/dist/agent-src/guidelines/php/patterns/dtos.md +199 -0
- package/dist/agent-src/guidelines/php/patterns/events.md +67 -0
- package/dist/agent-src/guidelines/php/patterns/factory.md +53 -0
- package/dist/agent-src/guidelines/php/patterns/pipelines.md +66 -0
- package/dist/agent-src/guidelines/php/patterns/policies.md +66 -0
- package/dist/agent-src/guidelines/php/patterns/repositories.md +122 -0
- package/dist/agent-src/guidelines/php/patterns/service-layer.md +64 -0
- package/dist/agent-src/guidelines/php/patterns/strategy.md +247 -0
- package/dist/agent-src/guidelines/php/patterns.md +28 -0
- package/dist/agent-src/guidelines/php/performance.md +92 -0
- package/dist/agent-src/guidelines/php/php-coding-patterns.md +80 -0
- package/dist/agent-src/guidelines/php/resources.md +100 -0
- package/dist/agent-src/guidelines/php/security.md +110 -0
- package/dist/agent-src/guidelines/php/sql.md +97 -0
- package/dist/agent-src/guidelines/php/validations.md +119 -0
- package/dist/agent-src/guidelines/php/websocket.md +100 -0
- package/dist/agent-src/guidelines/prompt-templates.md +189 -0
- package/dist/agent-src/guidelines/redundancy-taxonomy.md +208 -0
- package/dist/agent-src/guidelines/wing4-handoff.md +127 -0
- package/dist/agent-src/personas/README.md +1 -1
- package/dist/agent-src/personas/_template-specialist/persona.md +1 -1
- package/dist/agent-src/personas/product-owner.md +1 -1
- package/dist/agent-src/rules/active-remediation.md +1 -1
- package/dist/agent-src/rules/architecture.md +2 -2
- package/dist/agent-src/rules/artifact-drafting-protocol.md +1 -1
- package/dist/agent-src/rules/ask-when-uncertain.md +2 -2
- package/dist/agent-src/rules/brand-source-of-truth.md +9 -7
- package/dist/agent-src/rules/code-comment-discipline.md +2 -2
- package/dist/agent-src/rules/code-provenance.md +1 -1
- package/dist/agent-src/rules/content-quoting-floor.md +1 -1
- package/dist/agent-src/rules/context-hygiene.md +5 -5
- package/dist/agent-src/rules/cross-source-consistency.md +1 -1
- package/dist/agent-src/rules/design-fidelity.md +36 -46
- package/dist/agent-src/rules/direct-answers.md +2 -2
- package/dist/agent-src/rules/domain-adoption-policy.md +1 -1
- package/dist/agent-src/rules/evaluator-independence.md +1 -1
- package/dist/agent-src/rules/framework-neutrality-in-generic-skills.md +1 -1
- package/dist/agent-src/rules/icon-consistency.md +5 -1
- package/dist/agent-src/rules/improve-before-implement.md +1 -1
- package/dist/agent-src/rules/language-and-tone.md +3 -3
- package/dist/agent-src/rules/minimal-safe-diff.md +1 -1
- package/dist/agent-src/rules/notes-first-reasoning.md +2 -2
- package/dist/agent-src/rules/recurring-criticism.md +1 -1
- package/dist/agent-src/rules/roadmap-progress-sync.md +1 -1
- package/dist/agent-src/rules/role-mode-adherence.md +2 -2
- package/dist/agent-src/rules/security-sensitive-stop.md +1 -1
- package/dist/agent-src/rules/size-enforcement.md +1 -1
- package/dist/agent-src/rules/source-confidentiality.md +2 -2
- package/dist/agent-src/rules/think-before-action.md +1 -1
- package/dist/agent-src/rules/token-efficiency.md +7 -5
- package/dist/agent-src/rules/ui-audit-gate.md +3 -2
- package/dist/agent-src/rules/untrusted-input-defense.md +3 -3
- package/dist/agent-src/rules/user-interaction.md +31 -30
- package/dist/agent-src/skills/activation-design/SKILL.md +2 -2
- package/dist/agent-src/skills/adr-create/SKILL.md +5 -5
- package/dist/agent-src/skills/ai-council/SKILL.md +1 -1
- package/dist/agent-src/skills/ai-council/references/advanced-modes.md +1 -1
- package/dist/agent-src/skills/blade-ui/SKILL.md +1 -1
- package/dist/agent-src/skills/blast-radius-analyzer/SKILL.md +1 -1
- package/dist/agent-src/skills/brand-to-tokens/SKILL.md +24 -3
- package/dist/agent-src/skills/bug-analyzer/SKILL.md +1 -1
- package/dist/agent-src/skills/build-buy-partner/SKILL.md +1 -1
- package/dist/agent-src/skills/churn-prevention/SKILL.md +2 -2
- package/dist/agent-src/skills/code-refactoring/SKILL.md +3 -3
- package/dist/agent-src/skills/code-review/SKILL.md +3 -3
- package/dist/agent-src/skills/command-writing/SKILL.md +3 -3
- package/dist/agent-src/skills/comp-banding/SKILL.md +1 -1
- package/dist/agent-src/skills/competitive-moat-analysis/SKILL.md +1 -1
- package/dist/agent-src/skills/competitive-positioning/SKILL.md +2 -2
- package/dist/agent-src/skills/complexity-first-planning/SKILL.md +1 -1
- package/dist/agent-src/skills/condense-memory/SKILL.md +1 -1
- package/dist/agent-src/skills/content-funnel-design/SKILL.md +2 -2
- package/dist/agent-src/skills/contracts-cognition/SKILL.md +1 -1
- package/dist/agent-src/skills/copilot-agents-optimization/SKILL.md +2 -2
- package/dist/agent-src/skills/corpus-grounding/SKILL.md +2 -2
- package/dist/agent-src/skills/customer-research/SKILL.md +2 -2
- package/dist/agent-src/skills/dashboard-design/SKILL.md +1 -1
- package/dist/agent-src/skills/data-handling-judgment/SKILL.md +1 -1
- package/dist/agent-src/skills/deal-qualification-meddic/SKILL.md +2 -2
- package/dist/agent-src/skills/decision-record/SKILL.md +3 -3
- package/dist/agent-src/skills/decision-review/SKILL.md +8 -8
- package/dist/agent-src/skills/deep-reading-analyst/SKILL.md +22 -22
- package/dist/agent-src/skills/design-intelligence/SKILL.md +4 -4
- package/dist/agent-src/skills/design-intelligence/references/context-and-registers.md +2 -2
- package/dist/agent-src/skills/design-review/SKILL.md +4 -4
- package/dist/agent-src/skills/design-system-capture/references/design-system-json.md +20 -1
- package/dist/agent-src/skills/design-tokens/SKILL.md +17 -2
- package/dist/agent-src/skills/design-variations/SKILL.md +2 -2
- package/dist/agent-src/skills/developer-like-execution/SKILL.md +2 -2
- package/dist/agent-src/skills/discovery-interview/SKILL.md +2 -2
- package/dist/agent-src/skills/doc-coauthoring/SKILL.md +3 -3
- package/dist/agent-src/skills/editorial-calendar/SKILL.md +2 -2
- package/dist/agent-src/skills/error-handling-patterns/SKILL.md +9 -0
- package/dist/agent-src/skills/existing-ui-audit/SKILL.md +44 -1
- package/dist/agent-src/skills/existing-ui-audit/references/anti-slop-cross-reference.md +2 -2
- package/dist/agent-src/skills/expansion-playbook/SKILL.md +2 -2
- package/dist/agent-src/skills/experiment-loop/SKILL.md +1 -1
- package/dist/agent-src/skills/experiment-loop/references/protocol.md +1 -1
- package/dist/agent-src/skills/fe-design/SKILL.md +3 -3
- package/dist/agent-src/skills/fe-design/references/design-patterns.md +1 -1
- package/dist/agent-src/skills/fe-design/references/design-read-and-memory.md +3 -3
- package/dist/agent-src/skills/fe-design/references/source-led-port.md +1 -1
- package/dist/agent-src/skills/feature-planning/SKILL.md +1 -1
- package/dist/agent-src/skills/flux/SKILL.md +1 -1
- package/dist/agent-src/skills/forecast-accuracy/SKILL.md +2 -2
- package/dist/agent-src/skills/forecasting/SKILL.md +2 -2
- package/dist/agent-src/skills/fundraising-narrative/SKILL.md +2 -2
- package/dist/agent-src/skills/funnel-analysis/SKILL.md +2 -2
- package/dist/agent-src/skills/gtm-launch/SKILL.md +2 -2
- package/dist/agent-src/skills/hiring-loop-design/SKILL.md +1 -1
- package/dist/agent-src/skills/html-deck/SKILL.md +5 -5
- package/dist/agent-src/skills/humanizer/SKILL.md +1 -1
- package/dist/agent-src/skills/humanizer/data/patterns.md +1 -1
- package/dist/agent-src/skills/iconography/SKILL.md +3 -3
- package/dist/agent-src/skills/judge-synthesis/SKILL.md +1 -1
- package/dist/agent-src/skills/laravel-api-endpoint/SKILL.md +2 -2
- package/dist/agent-src/skills/launch-readiness/SKILL.md +3 -3
- package/dist/agent-src/skills/learning-to-rule-or-skill/SKILL.md +6 -6
- package/dist/agent-src/skills/livewire/SKILL.md +1 -1
- package/dist/agent-src/skills/market-entry-analysis/SKILL.md +1 -1
- package/dist/agent-src/skills/mcp-builder/SKILL.md +1 -1
- package/dist/agent-src/skills/memory-consolidation/SKILL.md +3 -3
- package/dist/agent-src/skills/messaging-architecture/SKILL.md +2 -2
- package/dist/agent-src/skills/monorepo-workspace/SKILL.md +1 -1
- package/dist/agent-src/skills/onboarding-design/SKILL.md +2 -2
- package/dist/agent-src/skills/onboarding-program/SKILL.md +1 -1
- package/dist/agent-src/skills/one-on-one-cadence/SKILL.md +1 -1
- package/dist/agent-src/skills/org-design/SKILL.md +1 -1
- package/dist/agent-src/skills/overbuild-review-lens/SKILL.md +3 -3
- package/dist/agent-src/skills/override-management/SKILL.md +1 -1
- package/dist/agent-src/skills/perf-feedback-craft/SKILL.md +1 -1
- package/dist/agent-src/skills/persona-writing/SKILL.md +1 -1
- package/dist/agent-src/skills/php-coder/SKILL.md +1 -1
- package/dist/agent-src/skills/pipeline-strategy/SKILL.md +2 -2
- package/dist/agent-src/skills/playwright-testing/SKILL.md +3 -3
- package/dist/agent-src/skills/po-discovery/SKILL.md +1 -1
- package/dist/agent-src/skills/positioning-strategy/SKILL.md +2 -2
- package/dist/agent-src/skills/privacy-review/SKILL.md +1 -1
- package/dist/agent-src/skills/prompt-optimizer/SKILL.md +3 -3
- package/dist/agent-src/skills/react-shadcn-ui/SKILL.md +1 -1
- package/dist/agent-src/skills/reasoning-orchestrator/SKILL.md +2 -2
- package/dist/agent-src/skills/receiving-code-review/SKILL.md +1 -1
- package/dist/agent-src/skills/refine-ticket/SKILL.md +2 -2
- package/dist/agent-src/skills/release-comms/SKILL.md +2 -2
- package/dist/agent-src/skills/retention-loops/SKILL.md +2 -2
- package/dist/agent-src/skills/review-routing/SKILL.md +2 -2
- package/dist/agent-src/skills/roadmap-management/SKILL.md +1 -1
- package/dist/agent-src/skills/roadmap-management/references/archival.md +1 -1
- package/dist/agent-src/skills/roadmap-writing/SKILL.md +5 -5
- package/dist/agent-src/skills/rule-writing/SKILL.md +6 -6
- package/dist/agent-src/skills/runway-cognition/SKILL.md +2 -2
- package/dist/agent-src/skills/scenario-modeling/SKILL.md +2 -2
- package/dist/agent-src/skills/skill-writing/SKILL.md +2 -2
- package/dist/agent-src/skills/skill-writing/references/procedure.md +1 -1
- package/dist/agent-src/skills/skill-writing/references/section-patterns.md +3 -3
- package/dist/agent-src/skills/spreadsheet-authoring/SKILL.md +1 -1
- package/dist/agent-src/skills/stakeholder-tradeoff/SKILL.md +3 -3
- package/dist/agent-src/skills/subagent-orchestration/SKILL.md +1 -1
- package/dist/agent-src/skills/supply-chain-intake/SKILL.md +1 -1
- package/dist/agent-src/skills/systematic-debugging/SKILL.md +2 -2
- package/dist/agent-src/skills/tailwind-engineer/SKILL.md +11 -5
- package/dist/agent-src/skills/throughput-vs-morale-tradeoff/SKILL.md +1 -1
- package/dist/agent-src/skills/token-optimizer/SKILL.md +1 -1
- package/dist/agent-src/skills/typography-system/SKILL.md +2 -2
- package/dist/agent-src/skills/ui-component-architect/SKILL.md +28 -8
- package/dist/agent-src/skills/unit-economics-modeling/SKILL.md +2 -2
- package/dist/agent-src/skills/upstream-contribute/SKILL.md +1 -1
- package/dist/agent-src/skills/validate-feature-fit/SKILL.md +2 -2
- package/dist/agent-src/skills/verify-repair-loop/SKILL.md +2 -2
- package/dist/agent-src/skills/vision-articulation/SKILL.md +1 -1
- package/dist/agent-src/skills/voc-extract/SKILL.md +2 -2
- package/dist/agent-src/skills/voice-and-tone-design/SKILL.md +2 -2
- package/dist/agent-src/skills/wireframe/SKILL.md +1 -1
- package/dist/agent-src/skills/workspace-link/SKILL.md +1 -1
- package/dist/agent-src/templates/agent-settings.md +6 -6
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
- package/dist/agent-src/templates/contexts/knowledge-pages.md +2 -3
- package/dist/agent-src/templates/copilot-instructions.md +1 -1
- package/dist/agent-src/templates/roadmaps.md +1 -1
- package/dist/agent-src/templates/scripts/README.md +2 -2
- package/dist/agent-src/user-types/_template/user-type.md +1 -1
- package/dist/cli-delegate/check_update_banner.js +12 -1
- package/dist/cli-delegate/{chunk-NLP54U3J.js → chunk-2XY7ILBT.js} +13 -1
- package/dist/cli-delegate/{chunk-IAI3XL43.js → chunk-3FKR64R5.js} +22 -6
- package/dist/cli-delegate/{chunk-J3RFNKG4.js → chunk-55ACLDUE.js} +2 -2
- package/dist/cli-delegate/{chunk-PKOBQADP.js → chunk-57PN4GYJ.js} +1 -1
- package/dist/cli-delegate/{chunk-KCNTUSPI.js → chunk-AK6HODNQ.js} +4 -4
- package/dist/cli-delegate/{chunk-2FTMENJL.js → chunk-GYC3VRYN.js} +1 -1
- package/dist/cli-delegate/{chunk-LWTYTX6F.js → chunk-H32DGUJH.js} +15 -84
- package/dist/cli-delegate/{chunk-6RJA2F5A.js → chunk-IVBPRCQO.js} +1 -1
- package/dist/cli-delegate/chunk-NUHLI2RX.js +80 -0
- package/dist/cli-delegate/{chunk-TYSY33MD.js → chunk-QJWAUMJW.js} +12 -2
- package/dist/cli-delegate/{chunk-2KKXJW25.js → chunk-S3VFXMTM.js} +1 -1
- package/dist/cli-delegate/{chunk-I6RHFQEG.js → chunk-YUM5KURG.js} +17 -1
- package/dist/cli-delegate/cmd_analyze_session.js +1 -1
- package/dist/cli-delegate/cmd_brand_status.js +1 -1
- package/dist/cli-delegate/cmd_conformance.js +834 -275
- package/dist/cli-delegate/cmd_doctor.js +3 -3
- package/dist/cli-delegate/cmd_explain.js +5 -3
- package/dist/cli-delegate/cmd_export.js +4 -4
- package/dist/cli-delegate/cmd_handoff.js +6 -6
- package/dist/cli-delegate/cmd_mcp_available.js +1 -1
- package/dist/cli-delegate/cmd_memory_get.js +1 -1
- package/dist/cli-delegate/cmd_migrate.js +2 -2
- package/dist/cli-delegate/cmd_packs_active.js +3 -2
- package/dist/cli-delegate/cmd_prune.js +4 -4
- package/dist/cli-delegate/cmd_route_audit.js +3 -3
- package/dist/cli-delegate/cmd_route_explain.js +1 -1
- package/dist/cli-delegate/cmd_session_recycle.js +3 -3
- package/dist/cli-delegate/cmd_settings_get.js +15 -9
- package/dist/cli-delegate/cmd_settings_migrate.js +4 -4
- package/dist/cli-delegate/cmd_settings_set.js +54 -11
- package/dist/cli-delegate/cmd_sync.js +4 -4
- package/dist/cli-delegate/cmd_uninstall.js +4 -4
- package/dist/cli-delegate/cmd_update.js +1 -1
- package/dist/cli-delegate/cmd_upgrade.js +1 -1
- package/dist/cli-delegate/cmd_validate.js +4 -4
- package/dist/cli-delegate/cmd_versions.js +1 -1
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +25 -78
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +3 -3
- package/dist/discovery/dormancy-report.md +1 -1
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +5 -7
- package/dist/discovery/trust-report.md +2 -2
- package/dist/discovery/workspaces.json +4 -6
- package/dist/hooks/dispatch.js +9684 -9304
- package/dist/install/install.mjs +36 -8
- package/dist/mcp/registry-manifest.json +3 -3
- package/dist/mcp/server.json +2 -2
- package/dist/mcp/server.mjs +2147 -1470
- package/dist/router.json +1 -1
- package/dist/scripts/_lib/agent_settings.js +73 -0
- package/dist/scripts/_lib/agent_src.js +20 -0
- package/dist/scripts/_lib/guidelines_lane.js +158 -0
- package/dist/scripts/_lib/installed_lock.js +1 -1
- package/dist/scripts/condense.js +2 -5
- package/dist/server/io/yamlIO.js +175 -17
- package/dist/server/schemas/settings.js +18 -4
- package/dist/shared/settingsSurface.js +6 -1
- package/docs/contracts/settings-classes.md +18 -9
- package/docs/guidelines/abstraction-thresholds.md +35 -0
- package/docs/guidelines/agent-infra/active-remediation-mechanics.md +3 -3
- package/docs/guidelines/agent-infra/false-green.md +2 -2
- package/docs/guidelines/agent-infra/roadmap-progress-mechanics.md +1 -1
- package/docs/guidelines/agent-infra/skill-quality-checklist.md +1 -1
- package/docs/guidelines/design-fidelity-mechanics.md +4 -0
- package/docs/guidelines/design-fidelity-routing.md +78 -0
- package/docs/guidelines/design-reconciliation.md +172 -0
- package/docs/guidelines/gtm-handoff.md +2 -2
- package/docs/guidelines/wing4-handoff.md +2 -2
- package/package.json +7 -3
- package/src/config/agent-settings.template.yml +55 -8
- package/src/config/ci-local-parity.yml +34 -0
- package/src/config/continuity-surface.json +11 -32
- package/src/config/gate-coverage.yml +31 -8
- package/src/config/gate-reachability-exemptions.json +1 -0
- package/src/config/gate-violation-baselines.json +3 -3
- package/src/config/hook-token-budget.json +1 -1
- package/src/config/host-injection-effect.json +2 -2
- package/src/config/pack-size-budget.json +55 -4
- package/src/config/platform-anchor.json +47 -0
- package/src/config/preamble-payload-budget.json +12 -8
- package/src/config/preamble-payload-exceptions.json +28 -0
- package/src/config/publish-surface.json +4 -2
- package/src/config/ratification-policy.json +7 -0
- package/src/config/rule-stub-ceilings.json +16 -9
- package/src/scripts/_cli/cmd_settings_get.ts +22 -7
- package/src/scripts/_dispatch.bash +3 -1
- package/src/scripts/_lib/agent_settings.ts +85 -0
- package/src/scripts/_lib/agent_src.ts +21 -0
- package/src/scripts/_lib/artifact_maturity.ts +242 -0
- package/src/scripts/_lib/base_ref_payload.ts +315 -0
- package/src/scripts/_lib/conformance_report.ts +403 -0
- package/src/scripts/_lib/continuity_writer.ts +72 -13
- package/src/scripts/_lib/design_system_import.ts +20 -0
- package/src/scripts/_lib/design_tolerance.ts +281 -0
- package/src/scripts/_lib/dropped_decision.ts +142 -0
- package/src/scripts/_lib/guidelines_lane.ts +164 -0
- package/src/scripts/_lib/installed_lock.ts +1 -1
- package/src/scripts/_lib/measured_payload_ceiling.ts +424 -0
- package/src/scripts/_lib/obligation_frequency.ts +2 -3
- package/src/scripts/_lib/payload_catalogue_completeness.ts +211 -0
- package/src/scripts/_lib/platform_anchor.ts +1053 -0
- package/src/scripts/_lib/ratification_artifact.ts +278 -0
- package/src/scripts/_lib/release_findings_ingest.ts +324 -0
- package/src/scripts/_lib/release_tag_dispatch.ts +63 -0
- package/src/scripts/_lib/review_baseline.ts +254 -0
- package/src/scripts/_lib/review_skipped_record.ts +61 -1
- package/src/scripts/_lib/security_lint.ts +23 -2
- package/src/scripts/_lib/self_repair.ts +21 -0
- package/src/scripts/_lib/session_index_trust.ts +42 -1
- package/src/scripts/_lib/standing_bound_ratchet.ts +267 -88
- package/src/scripts/_lib/tolerance_shadow.ts +177 -0
- package/src/scripts/_lib/turn_end_refusals.ts +51 -4
- package/src/scripts/ai_council/redact_low_impact_entry.ts +8 -0
- package/src/scripts/autonomy_friction_traffic.ts +379 -0
- package/src/scripts/check_beta_review_markers.ts +35 -4
- package/src/scripts/check_finding_dispositions.ts +167 -16
- package/src/scripts/check_held_object_arrivals.ts +381 -0
- package/src/scripts/check_kernel_edit_ratified.ts +462 -0
- package/src/scripts/check_loss_class_declared.ts +793 -46
- package/src/scripts/check_platform_anchor.ts +390 -0
- package/src/scripts/check_preamble_payload_budget.ts +672 -107
- package/src/scripts/check_projected_rule_routes.ts +395 -0
- package/src/scripts/check_release_published.ts +1 -1
- package/src/scripts/check_reply_consistency.ts +86 -17
- package/src/scripts/code_graph/cli.ts +6 -0
- package/src/scripts/condense.ts +2 -6
- package/src/scripts/generate_host_cost_table.ts +354 -0
- package/src/scripts/hook_manifest.json +1 -1
- package/src/scripts/hook_manifest.yaml +74 -30
- package/src/scripts/hooks/block_kernel_rule_writes.ts +12 -2
- package/src/scripts/hooks/category_a.ts +1 -1
- package/src/scripts/hooks/chain_nudge_hook.ts +311 -25
- package/src/scripts/hooks/concern_registry.ts +2 -0
- package/src/scripts/hooks/end_review_nudge_hook.ts +101 -21
- package/src/scripts/hooks/review_baseline_hook.ts +130 -0
- package/src/scripts/hooks/session_eol_hook.ts +68 -154
- package/src/scripts/hooks/source_first_gate_hook.ts +12 -0
- package/src/scripts/hooks/turn_end_gate_hook.ts +232 -14
- package/src/scripts/hooks/ui_route_nudge_hook.ts +52 -15
- package/src/scripts/hooks_doctor.ts +4 -1
- package/src/scripts/hot_context_hook.ts +41 -401
- package/src/scripts/install.ts +1 -1
- package/src/scripts/interruption_report.ts +8 -2
- package/src/scripts/janitor.ts +8 -1
- package/src/scripts/lint_evidence_artifacts.ts +1 -0
- package/src/scripts/lint_knowledge_scale.ts +0 -26
- package/src/scripts/measure_turn_end_gate.ts +302 -5
- package/src/scripts/memory_lookup.ts +9 -9
- package/src/scripts/release.ts +52 -64
- package/src/scripts/release_drill.ts +193 -14
- package/src/scripts/release_env.ts +1 -1
- package/src/scripts/release_publication.ts +1 -1
- package/src/scripts/report_held_object_arrivals.ts +456 -0
- package/src/scripts/report_standing_payload_by_host.ts +7 -7
- package/src/scripts/session_memory_index.ts +5 -0
- package/src/scripts/sync_agent_settings.ts +394 -12
- package/src/server/io/yamlIO.ts +175 -17
- package/src/server/schemas/settings.ts +25 -5
- package/src/shared/settingsSurface.ts +13 -2
- package/src/templates/compact-instructions.md +8 -3
- package/dist/agent-src/commands/chat-history/import.md +0 -170
- package/dist/agent-src/commands/chat-history.md +0 -63
|
@@ -108,6 +108,39 @@ The step-2 grep is not a second probe of the same file for the same fact — it
|
|
|
108
108
|
returns information step 1 did not have, so it is one operation with step 3, per
|
|
109
109
|
the enumerated-set carve-out.
|
|
110
110
|
|
|
111
|
+
### Where the 800 came from, and what would falsify it
|
|
112
|
+
|
|
113
|
+
Migrated out of `token-efficiency.md` on 2026-09-09 to fund that rule's
|
|
114
|
+
provided-artifact carve-out — a named substitution rather than a deletion, per
|
|
115
|
+
the council verdict on `blocker: standing-payload-headroom`.
|
|
116
|
+
|
|
117
|
+
The number is a **stated default, not a measured optimum** — said plainly rather
|
|
118
|
+
than implying a derivation it does not have. *Revisit-if:* a run records a
|
|
119
|
+
probe-then-slice that cost more than the full read would have, or the host's
|
|
120
|
+
ranged-read primitive changes its own default. Either falsifies the number, not
|
|
121
|
+
the obligation.
|
|
122
|
+
|
|
123
|
+
### The provided-artifact carve-out
|
|
124
|
+
|
|
125
|
+
A handed-over design artifact is not a large file to be probed; it is the spec,
|
|
126
|
+
and reading it whole is the work. A bundle of several thousand lines across
|
|
127
|
+
markup, CSS and tokens is ordinary, so the agent that reads it properly is the
|
|
128
|
+
one the size gate and the read-loop detector both punish, while the agent that
|
|
129
|
+
skims it produces the fidelity failure `design-fidelity` exists to prevent.
|
|
130
|
+
|
|
131
|
+
Two obligations, and they compose rather than cancel:
|
|
132
|
+
|
|
133
|
+
1. **The size gate does not fire on it.** Read the artifact whole.
|
|
134
|
+
2. **The read is declared** — [`context-hygiene`](../../../guidelines/agent-infra/context-hygiene-mechanics.md)
|
|
135
|
+
§ the declared-protocol cap — with its goal, its expected read count and the
|
|
136
|
+
output shape, before the reading starts. Declaring raises the read-only abort
|
|
137
|
+
from 5 turns to 8; it never suspends it, and exceeding the declared count by
|
|
138
|
+
more than 2 is still the violation.
|
|
139
|
+
|
|
140
|
+
What this does NOT do: it does not exempt an *undeclared* read loop, and it does
|
|
141
|
+
not apply to a file that merely happens to be large. The discriminator is the
|
|
142
|
+
handover, not the size.
|
|
143
|
+
|
|
111
144
|
### Exceptions
|
|
112
145
|
|
|
113
146
|
- Small output (< 30 lines) — read directly.
|
|
@@ -187,6 +220,47 @@ Over 40,268 real Bash calls from one maintainer's transcripts:
|
|
|
187
220
|
measurement artifact. It is not: that shape cannot be written as an
|
|
188
221
|
allowlist pattern at all, so it shrinks only by not being written.
|
|
189
222
|
|
|
223
|
+
### Re-measured 2026-09-10, with a shipped probe
|
|
224
|
+
|
|
225
|
+
The figures above were computed once by hand. `autonomy_friction_traffic`
|
|
226
|
+
(`./scripts-run src/scripts/autonomy_friction_traffic --store <dir> --limit 40`)
|
|
227
|
+
recomputes them from a transcript store and shares the live detectors — and the
|
|
228
|
+
metacharacter class is `category_a`'s own exported constant — so those cannot
|
|
229
|
+
drift; the bucket ORDER restates the classifier by hand and is pinned by a test.
|
|
230
|
+
Over **7,569 distinct** Bash calls in 39 transcripts (deduplicated by tool-use
|
|
231
|
+
id, measuring session excluded):
|
|
232
|
+
|
|
233
|
+
- **1.7 %** (126) are category A. Of the 7,443 uncovered calls, **7,143** are
|
|
234
|
+
disqualified by a shell metacharacter before their argv is read, 21 name a
|
|
235
|
+
consequence operation, and **279** get as far as the head list. Widening the
|
|
236
|
+
head list therefore cannot move this number — the shape can. The 279 is an
|
|
237
|
+
upper bound: a directory flag whose value escapes the tree lands there too.
|
|
238
|
+
- **73.8 %** (5,585) carry the chain class; `cd` heads 3,573 of the uncovered
|
|
239
|
+
calls — a different denominator from the shape classes, which count every call.
|
|
240
|
+
- **4.0 %** (306) write a file through the shell: 216 `cat >`, 66 `sed -i`,
|
|
241
|
+
16 a `python3 -c` opening a path for writing, 7 `perl -i`, 1 `tee`. A **floor**
|
|
242
|
+
— the rules are a positive list of five commands, so `echo >`, `jq >` and `cp`
|
|
243
|
+
are silent.
|
|
244
|
+
|
|
245
|
+
**Two host facts that decide what any of this can buy**, both read out of the
|
|
246
|
+
host's own permission documentation on 2026-09-10. First, `permissions.allow`
|
|
247
|
+
does **not** bypass the auto-mode classifier — they are layers, so an allow
|
|
248
|
+
entry cannot make a prompt go away on its own. Second, "don't ask again" saves a
|
|
249
|
+
permanent rule for a read-only command and only a session-lifetime one for a
|
|
250
|
+
write-shaped one. The second is why the write class earns its own line: no
|
|
251
|
+
amount of confirming makes the next `sed -i` cheaper. The adjacent question —
|
|
252
|
+
whether a hook's `permissionDecision: allow` suppresses the classifier — was
|
|
253
|
+
looked for in the same pass and **not found documented**.
|
|
254
|
+
|
|
255
|
+
**And a correction to the table below.** `git -C /repo status` is the right
|
|
256
|
+
substitution for the host's matcher, but it is **not** category A: `category_a`
|
|
257
|
+
refuses a global option whose value is absolute, and every cross-worktree
|
|
258
|
+
invocation in a multi-worktree checkout writes an absolute one. So unwinding a
|
|
259
|
+
chain removes the metacharacter without buying the allow. The row stays because
|
|
260
|
+
it is still the cheaper shape; what changes is the claim that it lands inside
|
|
261
|
+
category A. Pinned in `tests/scripts/autonomy_friction_traffic.test.ts` §
|
|
262
|
+
"the recommended substitution is only covered with a RELATIVE path".
|
|
263
|
+
|
|
190
264
|
### The substitutions
|
|
191
265
|
|
|
192
266
|
| Instead of | Write |
|
|
@@ -195,6 +269,9 @@ Over 40,268 real Bash calls from one maintainer's transcripts:
|
|
|
195
269
|
| `V=$(git rev-parse HEAD); echo $V` | two calls, the second using the printed value |
|
|
196
270
|
| `mkdir -p x && cp a x/` | two calls in the same block |
|
|
197
271
|
| `cd sub && <cmd>` | the directory flag the tool already has (`-C`, `--cwd`, `--prefix`) |
|
|
272
|
+
| `sed -i '' -e 's/a/b/' f` | the **Edit** tool — a write-shaped Bash grant expires with the session |
|
|
273
|
+
| `cat > f <<'EOF' … EOF` | the **Write** tool for a new file, **Edit** for a change to an existing one |
|
|
274
|
+
| `python3 -c "open(p,'w').write(s)"` | the same two tools; keep the interpreter for reads and computation |
|
|
198
275
|
|
|
199
276
|
A loop that genuinely cannot be expressed without the shell stays a loop —
|
|
200
277
|
prefer a script file over an inline `for` when it recurs.
|
|
@@ -211,7 +288,17 @@ first time a session chains work. It is ON by default with
|
|
|
211
288
|
because the fact this one carries is a property of the host's permission
|
|
212
289
|
matcher and holds in every consumer.
|
|
213
290
|
|
|
214
|
-
|
|
291
|
+
Since 2026-09-10 it carries a second shape class — a Bash command that fills a
|
|
292
|
+
file (`sed -i`, `cat > f`, `tee f`, `perl -i`, a `python3 -c` opening a path for
|
|
293
|
+
writing) — and the latch is per class, so a session sees at most one line per
|
|
294
|
+
class instead of one line for whichever mistake came first. A redirect that
|
|
295
|
+
names no file being filled (`2>&1`, `> /dev/null`) is still not a write and is
|
|
296
|
+
still not flagged. The two classes read different views: the chain rules see
|
|
297
|
+
quoted spans and heredocs removed, the write rules see quoted spans removed and
|
|
298
|
+
heredoc BODIES removed with the command line kept — a heredoc marker and the
|
|
299
|
+
redirect sharing its line cannot be separated otherwise.
|
|
300
|
+
|
|
301
|
+
**It never blocks, and each class fires once.** So it changes what the agent knows,
|
|
215
302
|
not what the agent may do: compliance stays model-carried, and the concern's
|
|
216
303
|
tests establish detector behavior, not adherence. On a host with no
|
|
217
304
|
`pre_tool_use` slot nothing fires at all and the rule is model-carried end to
|
|
@@ -189,7 +189,7 @@ rendered as a bulleted list of reasons — declines are short prose (one or
|
|
|
189
189
|
two sentences), because a bulleted refusal reads as a checklist to argue
|
|
190
190
|
against rather than a direct answer.
|
|
191
191
|
|
|
192
|
-
Full example set: [`asking-and-brevity-examples § Bullet floor`](
|
|
192
|
+
Full example set: [`asking-and-brevity-examples § Bullet floor`](../../../guidelines/agent-infra/asking-and-brevity-examples.md#bullet-floor).
|
|
193
193
|
|
|
194
194
|
## Summaries
|
|
195
195
|
|
|
@@ -202,3 +202,53 @@ After completing a batch of actions, provide a summary table:
|
|
|
202
202
|
| 2 | `test.php` | Updated assertion |
|
|
203
203
|
| 3 | `config.php` | Skipped (intentional) |
|
|
204
204
|
```
|
|
205
|
+
|
|
206
|
+
## The trigger is a decision, not a format — the measurement behind it
|
|
207
|
+
|
|
208
|
+
Migrated out of `user-interaction.md` on 2026-09-11 to pay for Iron Law 3
|
|
209
|
+
under the per-spawn preamble budget. The obligation stays in the rule; this
|
|
210
|
+
is the evidence for it.
|
|
211
|
+
|
|
212
|
+
Measured (30-session conformance audit, 2026-08-06): **every** malformed ask
|
|
213
|
+
was a one-line parenthetical or a trailing free-text offer — a German
|
|
214
|
+
"say the word if I should take the three lines along", an English "shall I
|
|
215
|
+
implement it this way?" — while the same sessions formatted their **large**
|
|
216
|
+
asks perfectly. So the rule is being read as *if numbered options, then a
|
|
217
|
+
recommendation line*. It is the other way round, and an ask that feels too
|
|
218
|
+
small for a block is exactly the one that escapes the format.
|
|
219
|
+
|
|
220
|
+
Three further caught shapes: a contentless filler option; an inline
|
|
221
|
+
"(recommended)" tag **beside** the recommendation line (the dual source
|
|
222
|
+
Iron Law 1 forbids); an option set answerable only as `1,3,4`.
|
|
223
|
+
|
|
224
|
+
**No gate ships for this.** `check_reply_consistency` can read a draft on
|
|
225
|
+
stdin, but it inspects *numbered-option blocks* — and every measured failure
|
|
226
|
+
had no block by construction, so it scans exactly the surface that did not
|
|
227
|
+
fail. `conformance:behavior` deliberately does not score ask-shape, so an
|
|
228
|
+
unmoved rate is a finding rather than a silence.
|
|
229
|
+
|
|
230
|
+
## Iron Law 3 — why laws 1 and 2 do not reach across a turn boundary
|
|
231
|
+
|
|
232
|
+
Iron Laws 1 and 2 are discharged by the shape of the reply that carries the
|
|
233
|
+
block. Neither survives a turn boundary, which is the gap Iron Law 3 closes:
|
|
234
|
+
a second assistant execution with no user message between it and the ask is
|
|
235
|
+
not a new conversation, and from the user's side a thread that ends without
|
|
236
|
+
the question ended without the question.
|
|
237
|
+
|
|
238
|
+
**The measured failure.** A turn put three numbered options and a
|
|
239
|
+
recommendation line to the user. A `stop` concern then produced a second
|
|
240
|
+
assistant execution with no intervening user message, and that second reply
|
|
241
|
+
handled the concern while demoting the open question to a subordinate clause.
|
|
242
|
+
The four rules that could have caught it did not, each for a stated reason:
|
|
243
|
+
Iron Law 1 inspects a reply that HAS an options block, `check_reply_consistency`
|
|
244
|
+
receives a draft rather than a transcript, `active-remediation` governs
|
|
245
|
+
findings rather than issued decisions, and `no-cheap-questions` guards the
|
|
246
|
+
opposite direction.
|
|
247
|
+
|
|
248
|
+
**Carrier, stated honestly.** The deterministic half is the
|
|
249
|
+
`pending-decision` detector in `src/scripts/hooks/turn_end_gate_hook.ts` —
|
|
250
|
+
it refuses a turn-end when an earlier reply in the same user turn carried a
|
|
251
|
+
block and the closing reply carries none. It sees one user turn on one host,
|
|
252
|
+
so everything outside that is model-carried, exactly like Iron Law 2's own
|
|
253
|
+
"no gate ships for this" note. `check_reply_consistency` reads a single draft
|
|
254
|
+
and holds no cross-turn state; it cannot see this law at all.
|
|
@@ -56,4 +56,4 @@ kernel chars. The pointers below replace them.
|
|
|
56
56
|
|
|
57
57
|
## Decidable carve-out predicates
|
|
58
58
|
|
|
59
|
-
Predicates with one-sentence tests live in [`docs/guidelines/agent-infra/carve-out-predicates.md`](
|
|
59
|
+
Predicates with one-sentence tests live in [`docs/guidelines/agent-infra/carve-out-predicates.md`](../../guidelines/agent-infra/carve-out-predicates.md). Default-terse applies unless a predicate's test is yes/no decidable from the artifact alone.
|
|
@@ -129,7 +129,7 @@ tier `inferSliceTier` (§ below) already raised.
|
|
|
129
129
|
Deny-by-default — a direction not listed here is denied. Direction rules,
|
|
130
130
|
payload allow/deny lists, the report-only boundary, the no-recursion clause and
|
|
131
131
|
the human egress gate:
|
|
132
|
-
[`cross-vendor-worker-direction`](
|
|
132
|
+
[`cross-vendor-worker-direction`](../../docs/contracts/cross-vendor-worker-direction.md).
|
|
133
133
|
Role pairs, never vendor names — `classifyLadder` carries no vendor identity
|
|
134
134
|
([`subagent-routing`](subagent-routing.md) § Why vendor-neutral).
|
|
135
135
|
|
|
@@ -20,7 +20,7 @@ set, and what the host can physically do.
|
|
|
20
20
|
| `subagents.downshift` | `true` | Route delegable sub-tasks to the lowest-capable tier (Phase 2). |
|
|
21
21
|
| `subagents.quota_arbitrage` | `true` | Prefer a separate-quota-pool model where the host manifest allows it (Phase 2 bonus). |
|
|
22
22
|
| `subagents.model_map` | `{}` | Optional per-tier model override for downshift routing. |
|
|
23
|
-
| `emergency.orchestration_halt` | `false` | The ONE audited incident switch — see [`settings-classes.md`](
|
|
23
|
+
| `emergency.orchestration_halt` | `false` | The ONE audited incident switch — see [`settings-classes.md`](../../docs/contracts/settings-classes.md) § "The one exception". NOT an activation gate: on-by-default, ceremony-free to arm, requires a non-empty `orchestration_halt_justification` to disarm. |
|
|
24
24
|
|
|
25
25
|
## Activation decision
|
|
26
26
|
|
|
@@ -13,7 +13,7 @@ relevant. Detection logic lives in [`autonomy-detection.md`](autonomy-detection.
|
|
|
13
13
|
| `auto` (default) | Same as `off` by default. Flips to `on` for the rest of the conversation as soon as the user expresses the intent "stop asking, just work". See [detection logic](autonomy-detection.md) — match by **intent**, not exact string. The flip never lifts the Hard Floor. |
|
|
14
14
|
|
|
15
15
|
The value is read once on the first turn (per
|
|
16
|
-
[`layered-settings`](
|
|
16
|
+
[`layered-settings`](../../guidelines/agent-infra/layered-settings.md#section-aware-merge-rules))
|
|
17
17
|
and cached. Missing key → treat as `auto` (fail-closed — same behavior
|
|
18
18
|
as the shipped template default; absence of a key never grants the most
|
|
19
19
|
permissive mode). The one exception is the explicit cloud carve-out
|
|
@@ -4,7 +4,7 @@ Catalog material for [`no-cheap-questions`](../../rules/no-cheap-questions.md)
|
|
|
4
4
|
|
|
5
5
|
## Cheap classes — full catalog
|
|
6
6
|
|
|
7
|
-
Sequencing · format-only · commit / CI / test asks · fenced re-ask · Iron-Law option · context-derived · dominant option · re-ask after decline · paternalistic (IL 3) · continuation under mandate (IL 4) · prereq-for-authorized-action (IL 5) · destination-already-stated (IL 6) · self-cleaning artefact follow-up · disguised commit ask (preview-as-bait) · commit-chunking-strategy (one-or-multiple / which-first / how-to-split). Extended examples: [`asking-and-brevity-examples`](
|
|
7
|
+
Sequencing · format-only · commit / CI / test asks · fenced re-ask · Iron-Law option · context-derived · dominant option · re-ask after decline · paternalistic (IL 3) · continuation under mandate (IL 4) · prereq-for-authorized-action (IL 5) · destination-already-stated (IL 6) · self-cleaning artefact follow-up · disguised commit ask (preview-as-bait) · commit-chunking-strategy (one-or-multiple / which-first / how-to-split). Extended examples: [`asking-and-brevity-examples`](../../guidelines/agent-infra/asking-and-brevity-examples.md#cheap-question-class-catalog--extended-examples).
|
|
8
8
|
|
|
9
9
|
## Iron Law 3 — No Paternalistic State-Assuming Options
|
|
10
10
|
|
|
@@ -24,7 +24,7 @@ sheet-eligible when **all** hold:
|
|
|
24
24
|
- it is answerable **before** the run starts — its answer does not depend on
|
|
25
25
|
something the run itself produces;
|
|
26
26
|
- its decision class is `trivial`, `low_impact`, or `medium_impact`
|
|
27
|
-
([`ai-council-config`](
|
|
27
|
+
([`ai-council-config`](../../docs/contracts/ai-council-config.md)
|
|
28
28
|
§ decision_resolution);
|
|
29
29
|
- a **conservative default** exists and can be stated in one line.
|
|
30
30
|
|
|
@@ -68,7 +68,7 @@ cost: each override is a decision the default did not carry.
|
|
|
68
68
|
|
|
69
69
|
The contradiction was resolved on **the sheet's** side deliberately, and the
|
|
70
70
|
asymmetry is durable rather than incidental: `user-interaction` is one of the
|
|
71
|
-
locked nine ([`kernel-membership § 4`](
|
|
71
|
+
locked nine ([`kernel-membership § 4`](../../docs/contracts/kernel-membership.md)),
|
|
72
72
|
so amending its clause is an owner-reserved edit that `block-kernel-rule-writes`
|
|
73
73
|
refuses at tool-call time, while the answer SHAPE is this page's own. When a
|
|
74
74
|
page and a kernel rule contradict each other, the page is both the cheaper half
|
|
@@ -110,6 +110,6 @@ by whichever mechanism happened to hit them first.
|
|
|
110
110
|
|
|
111
111
|
- [`roadmap-execution-contract`](roadmap-execution-contract.md) — the screen this renders inside; its single Accept is the authorization.
|
|
112
112
|
- [`roadmap-process-loop § 3`](roadmap-process-loop.md) — the pre-scan that produces the rows, and the § 3a ladder that decides whether a contract is derived at all.
|
|
113
|
-
- [`ai-council-config`](
|
|
113
|
+
- [`ai-council-config`](../../docs/contracts/ai-council-config.md) § decision_resolution — the class table and the locked-class Iron Law.
|
|
114
114
|
- [`ask-when-uncertain`](../../rules/ask-when-uncertain.md) — one question per turn; one sheet answered by one keystroke is one question.
|
|
115
115
|
- [`user-interaction`](../../rules/user-interaction.md) — the numbered-options shape and the single recommendation line.
|
|
@@ -175,6 +175,6 @@ counter and is the first thing to look at before adding a sixth line.
|
|
|
175
175
|
|
|
176
176
|
## See also
|
|
177
177
|
|
|
178
|
-
- [`docs/contracts/settings-classes.md`](
|
|
178
|
+
- [`docs/contracts/settings-classes.md`](../../docs/contracts/settings-classes.md) — a sibling contract in the same shape: prose that a gate reads.
|
|
179
179
|
- [`verify-before-complete`](../../rules/verify-before-complete.md) — the evidence gate the pre-send sweep runs beside.
|
|
180
180
|
- `src/scripts/lint_mandated_lines.ts` — the deterministic half.
|
|
@@ -127,6 +127,6 @@ A misbehaving heuristic is disabled by config, not by reverting 6.1.0.
|
|
|
127
127
|
|
|
128
128
|
## See also
|
|
129
129
|
|
|
130
|
-
- [`command-clusters`](
|
|
130
|
+
- [`command-clusters`](../../docs/contracts/command-clusters.md) — the locked cluster/sub-command set.
|
|
131
131
|
- [`user-interaction`](../../rules/user-interaction.md) — numbered-options + recommendation rules the interactive path obeys.
|
|
132
132
|
- [`non-destructive-by-default`](../../rules/non-destructive-by-default.md) — the Hard Floor destructive sub-commands still answer to.
|
|
@@ -243,7 +243,7 @@ removes or tightens THE TRIGGER, and the removal PR cites the numbers.
|
|
|
243
243
|
|
|
244
244
|
## Related
|
|
245
245
|
|
|
246
|
-
- [`audit-log-v1`](
|
|
246
|
+
- [`audit-log-v1`](../../docs/contracts/audit-log-v1.md) — the frozen
|
|
247
247
|
JSONL contract this object rides on; the `orchestration` field is optional
|
|
248
248
|
and additive, schema_version unchanged.
|
|
249
249
|
- [`host-capability-manifest`](host-capability-manifest.md) — the manifest that
|
|
@@ -7,7 +7,7 @@ the [`roadmap-writing`](../../skills/roadmap-writing/SKILL.md) skill,
|
|
|
7
7
|
[`/feature:roadmap`](../../commands/feature/roadmap.md) — each of which links
|
|
8
8
|
here instead of restating the gate. Machine-checked grammars (the C→R1 state
|
|
9
9
|
schema, marker lines) are owned by
|
|
10
|
-
[`docs/contracts/plan-review-gates.md`](
|
|
10
|
+
[`docs/contracts/plan-review-gates.md`](../../docs/contracts/plan-review-gates.md);
|
|
11
11
|
this context carries the agent-side procedure.
|
|
12
12
|
|
|
13
13
|
## Activation
|
|
@@ -22,7 +22,7 @@ equivalents drop the gate immediately
|
|
|
22
22
|
(`DE: "einfach schreiben", "Interview überspringen" · EN: "just write it", "skip the interview"`).
|
|
23
23
|
A bypass is **counted**, never punished: append a `gate_c_bypass` event to
|
|
24
24
|
`agents/evidence/metrics/gate-metrics.jsonl` (see
|
|
25
|
-
[`plan-review-gates § metrics`](
|
|
25
|
+
[`plan-review-gates § metrics`](../../docs/contracts/plan-review-gates.md))
|
|
26
26
|
so gate erosion stays visible.
|
|
27
27
|
|
|
28
28
|
## When it fires — and when NOT
|
|
@@ -127,7 +127,7 @@ On completing the gate (either path that ran an interview), write
|
|
|
127
127
|
`agents/runtime/state/gate-c-<plan-slug>.json` so the R1 risk pass never
|
|
128
128
|
re-asks resolved branches — the user is never interviewed twice for one
|
|
129
129
|
plan. Schema (canonical:
|
|
130
|
-
[`plan-review-gates § C→R1 handoff`](
|
|
130
|
+
[`plan-review-gates § C→R1 handoff`](../../docs/contracts/plan-review-gates.md)):
|
|
131
131
|
resolved branches, plan hash, timestamp, and a mandatory `transcript_ref`
|
|
132
132
|
(path + content hash of the interview transcript artifact).
|
|
133
133
|
|
|
@@ -136,7 +136,7 @@ resolved branches, plan hash, timestamp, and a mandatory `transcript_ref`
|
|
|
136
136
|
lint and no hook entry behind it, and the state file is gitignored so CI never
|
|
137
137
|
sees it — a human reading the diff is what catches a violation (stated
|
|
138
138
|
`enforced_by: none` in
|
|
139
|
-
[`plan-review-gates § 4.1`](
|
|
139
|
+
[`plan-review-gates § 4.1`](../../docs/contracts/plan-review-gates.md)).
|
|
140
140
|
The rule defends against silent agent shortcuts, not against the local human
|
|
141
141
|
(who holds the settings escape hatch anyway).
|
|
142
142
|
Confident-path runs (no interview) write no state file; R1 then runs its
|
|
@@ -155,7 +155,7 @@ risk pass fresh.
|
|
|
155
155
|
|
|
156
156
|
- [`/challenge-me vision`](../../commands/challenge-me/vision.md) — the four
|
|
157
157
|
95%-conditions and the interview this gate routes into.
|
|
158
|
-
- [`plan-review-gates`](
|
|
158
|
+
- [`plan-review-gates`](../../docs/contracts/plan-review-gates.md) — machine
|
|
159
159
|
grammars: C→R1 state schema, Risk Register, completion review.
|
|
160
160
|
- [`ask-when-uncertain`](../../rules/ask-when-uncertain.md) — the
|
|
161
161
|
one-question-per-turn floor the degrade protocol runs under.
|
|
@@ -191,7 +191,7 @@ bodies.
|
|
|
191
191
|
Identity semantics, revision semantics, the three senses of "gate" and the
|
|
192
192
|
`[AC:<id>]` convention — including the verified fact that nothing parses
|
|
193
193
|
`verify:` lines structurally today — are in
|
|
194
|
-
[`guideline:agent-infra/traceability-field-mechanics`](
|
|
194
|
+
[`guideline:agent-infra/traceability-field-mechanics`](../../guidelines/agent-infra/traceability-field-mechanics.md).
|
|
195
195
|
They are not optional reading: a slug grammar does not imply a namespace, and
|
|
196
196
|
`evidence_refs` are syntactically safe tokens rather than verified evidence.
|
|
197
197
|
|
|
@@ -114,7 +114,7 @@ Cross-wing or cross-skill chain executed across isolated git
|
|
|
114
114
|
worktrees — each handoff in the chain runs in its own worktree, so
|
|
115
115
|
the workspace state of one step never leaks into the next. Operationalizes
|
|
116
116
|
the worktree boundary clause in
|
|
117
|
-
[`docs/contracts/cross-wing-handoff.md`](
|
|
117
|
+
[`docs/contracts/cross-wing-handoff.md`](../../docs/contracts/cross-wing-handoff.md)
|
|
118
118
|
§ 3. State-machine layer only — worktree creation/destruction lives
|
|
119
119
|
in [`using-git-worktrees`](../../skills/using-git-worktrees/SKILL.md) and
|
|
120
120
|
[`finishing-a-development-branch`](../../skills/finishing-a-development-branch/SKILL.md).
|
|
@@ -49,7 +49,7 @@ THE SAME MINUS THE QUOTA WIN.
|
|
|
49
49
|
for a removed category — and because `session_tier` sits non-null in 0 of 327
|
|
50
50
|
records, leaving the saving unmeasurable in principle. Migration record and
|
|
51
51
|
the union revisit-if:
|
|
52
|
-
[`budget-routing` contract](
|
|
52
|
+
[`budget-routing` contract](../../docs/contracts/budget-routing.md).
|
|
53
53
|
**Tier resolution therefore ends at step 3.** What survives of the module is
|
|
54
54
|
`TIER_ORDER` and `readCooldowns`, read by `routing:doctor` as a diagnostic —
|
|
55
55
|
monitoring, not routing, and note that nothing writes the cool-down file any
|
|
@@ -177,7 +177,7 @@ This resolves the direction; it does not license downshifting as a target. The
|
|
|
177
177
|
cold start is paid per leg regardless of tier, which is precisely what the
|
|
178
178
|
non-escalation floor above bounds. Analogous downgrade/cache coupling on the
|
|
179
179
|
council side: see
|
|
180
|
-
[`docs/contracts/ai-council-config.md`](
|
|
180
|
+
[`docs/contracts/ai-council-config.md`](../../docs/contracts/ai-council-config.md)
|
|
181
181
|
§ `model_downgrade` for the analogous downgrade/cache coupling this suite
|
|
182
182
|
already ships on the council side.
|
|
183
183
|
|
|
@@ -22,7 +22,7 @@ task without re-inventing any taxonomy.
|
|
|
22
22
|
|
|
23
23
|
| Element | Source |
|
|
24
24
|
|---|---|
|
|
25
|
-
| `role_mode` | The six contracts in [`role-contracts`](
|
|
25
|
+
| `role_mode` | The six contracts in [`role-contracts`](../../guidelines/agent-infra/role-contracts.md). A review sub-task → `reviewer`; a planning sub-task → `planner`; default → null (no contract). |
|
|
26
26
|
| `profile` | The active profile (`profile.id` in `.agent-settings.yml`); inherited from the session unless the sub-task is a different domain. |
|
|
27
27
|
| `personas` | The persona ids already cited in the task's skill frontmatter (review lenses). Capped at 2 (`MAX_PERSONAS`). |
|
|
28
28
|
| `knowledge_refs` | A SMALL set of knowledge references (ingest ids / file paths) relevant to the sub-task. Capped at 5 (`MAX_KNOWLEDGE_REFS`). |
|
|
@@ -18,7 +18,7 @@ behaviour was to detect it and throw it away. It now has a second
|
|
|
18
18
|
destination: `~/.event4u/agent-config/user/observations.jsonl`, the global
|
|
19
19
|
observation buffer from ADR-138's sibling phase — mirroring, one level up,
|
|
20
20
|
the project-local `.agent-user.observations.jsonl` contract in
|
|
21
|
-
[`agent-user-schema.md § Observation buffer`](
|
|
21
|
+
[`agent-user-schema.md § Observation buffer`](../../docs/contracts/agent-user-schema.md#observation-buffer).
|
|
22
22
|
|
|
23
23
|
**The project-scoped rule in Phase 3 (CONSOLIDATE) is unchanged.** No user
|
|
24
24
|
fact enters `agents/memory/` curated YAML through this or any other path —
|
|
@@ -73,7 +73,7 @@ than at review, and from reusing the existing redaction gate verbatim:
|
|
|
73
73
|
birthdays · financial figures · health / legal / therapy status ·
|
|
74
74
|
demographics · external-source identifiers — refused when the
|
|
75
75
|
observation is captured, per
|
|
76
|
-
[`agent-user-schema.md § Explicit exclusions`](
|
|
76
|
+
[`agent-user-schema.md § Explicit exclusions`](../../docs/contracts/agent-user-schema.md#explicit-exclusions).
|
|
77
77
|
- **Hidden unicode.** Every write routes through
|
|
78
78
|
`knowledge_global_redaction.redaction_scan`, including its
|
|
79
79
|
`hidden_unicode` class (the ADR-103 zero-width-smuggling detector) — the
|
|
@@ -120,7 +120,7 @@ against the project root once, during ORIENT:
|
|
|
120
120
|
`seen_in[]` recurrence tally to the fact and appends it to the SAME
|
|
121
121
|
global buffer Phase 2 uses — never a second store, never a
|
|
122
122
|
project-indexed directory (the council's round-2 namespace refusal; see
|
|
123
|
-
[`agent-user-schema.md § Project attribution`](
|
|
123
|
+
[`agent-user-schema.md § Project attribution`](../../docs/contracts/agent-user-schema.md#project-attribution-road-to-global-user-memory-phase-3)).
|
|
124
124
|
|
|
125
125
|
**This is the only generalisation path.** A fact recurring in a
|
|
126
126
|
*different* unmanaged project (Jaccard similarity ≥ `MERGE_THRESHOLD`,
|
|
@@ -96,6 +96,6 @@ on the follow-up PR.
|
|
|
96
96
|
### Examples
|
|
97
97
|
|
|
98
98
|
Wrong/right/why demos (hedged claims, trusting earlier runs,
|
|
99
|
-
partial-verification creep): [`verify-before-complete-demos`](
|
|
99
|
+
partial-verification creep): [`verify-before-complete-demos`](../../guidelines/agent-infra/verify-before-complete-demos.md).
|
|
100
100
|
Outcome baseline:
|
|
101
101
|
[`tests/golden/outcomes/verify_before_complete.json`](../../../../tests/golden/outcomes/verify_before_complete.json).
|
|
@@ -133,8 +133,8 @@ files `contexts/judges/no-consolidate-rationale.md`.
|
|
|
133
133
|
|
|
134
134
|
## References
|
|
135
135
|
|
|
136
|
-
- [`docs/contracts/context-paths.md`](
|
|
136
|
+
- [`docs/contracts/context-paths.md`](../../docs/contracts/context-paths.md)
|
|
137
137
|
— locked path tree (this file lives at `contexts/judges/`).
|
|
138
|
-
- [`docs/contracts/load-context-schema.md`](
|
|
138
|
+
- [`docs/contracts/load-context-schema.md`](../../docs/contracts/load-context-schema.md)
|
|
139
139
|
— frontmatter contract for citing this rubric from a slimmed `judge-*`
|
|
140
140
|
skill in Phase 3a.2.
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
# Abstraction Thresholds — the per-class canon
|
|
2
|
+
|
|
3
|
+
> The single source of truth for "how many repetitions before you extract". Every
|
|
4
|
+
> other artifact that states a numeric extraction threshold cites this table and
|
|
5
|
+
> names its artifact class — a bare number outside this file is drift
|
|
6
|
+
> (enforced by `src/scripts/lint_abstraction_thresholds.ts`).
|
|
7
|
+
|
|
8
|
+
_Origin: council convergence 2026-08-03 (claude-sonnet-4-5 + gpt-4o, unanimous), recorded in ADR-213. Before this file, four artifacts stated four bare numbers (2 / 3+ / ≥4 / ≥3) with no scope tags — an agent loading them together received contradictory instructions._
|
|
9
|
+
|
|
10
|
+
## Why the bars differ — cost scales with the artifact class
|
|
11
|
+
|
|
12
|
+
Extracting a pure helper function is a near-zero-cost act; extracting a stateful
|
|
13
|
+
UI component creates a file, a props contract, and a test surface. The threshold
|
|
14
|
+
is a price signal: the heavier the extraction, the more proven repetition it
|
|
15
|
+
must buy. These are **deliberately different bars for different acts**, not
|
|
16
|
+
editorial drift.
|
|
17
|
+
|
|
18
|
+
## The canon
|
|
19
|
+
|
|
20
|
+
| Artifact class | Concrete tag (what to check) | Threshold |
|
|
21
|
+
|---|---|---|
|
|
22
|
+
| **Code-level abstraction** — helper, method, class, Strategy, generic, config layer | any non-UI code shape | **2 real repetitions** (or a genuine second axis of change) |
|
|
23
|
+
| **Pure-markup UI shell** — props-only fragment, no state (button shell, card frame, header) | renders props, holds no state | **3+ uses** |
|
|
24
|
+
| **Stateful UI component** — carries real props/state (form, table, filter) | repeats **AND** has varying props / local state | **~4+ repeats AND real state** (both conditions) |
|
|
25
|
+
| **Utility-class string** (Tailwind et al.) — repeated class list | identical class string | **≥ 3 duplications** (mechanism table: [`tailwind-engineer`](../skills/tailwind-engineer/SKILL.md)) |
|
|
26
|
+
|
|
27
|
+
The code-level bar of **two** is this suite's settled base decision (the
|
|
28
|
+
borrowed "Rule of Three" for code was evaluated and not adopted — see
|
|
29
|
+
[`minimal-safe-diff-mechanics`](agent-infra/minimal-safe-diff-mechanics.md)).
|
|
30
|
+
The UI rows are scoped carve-outs **above** that base bar, never a license to
|
|
31
|
+
lower it.
|
|
32
|
+
|
|
33
|
+
## The qualitative floor — applies to every row
|
|
34
|
+
|
|
35
|
+
A number alone never justifies an extraction. In every class, a reviewer must
|
|
36
|
+
be able to name the **concrete duplication or the concrete second axis of
|
|
37
|
+
change** the abstraction removes. One occurrence is not a component; one branch
|
|
38
|
+
is not a Strategy; a repeat with no varying props is inlined, not extracted.
|
|
39
|
+
|
|
40
|
+
## Precedence
|
|
41
|
+
|
|
42
|
+
[`minimal-safe-diff`](../rules/minimal-safe-diff.md) / YAGNI win on every
|
|
43
|
+
conflict: these thresholds authorize extraction when repetition is **already
|
|
44
|
+
present in the diff** — never speculative abstraction for "this could grow
|
|
45
|
+
later". See [`component-oriented-and-oop-development`](component-oriented-and-oop-development.md)
|
|
46
|
+
§ The load-bearing caveat.
|
|
47
|
+
|
|
48
|
+
## The provided-artifact clause — repetition observable before the code exists
|
|
49
|
+
|
|
50
|
+
ADR-213 authorises extraction on repetition **already present in the diff**. A
|
|
51
|
+
handed-over **runnable** artifact makes repetition observable before any code
|
|
52
|
+
exists at all: four `<Card>` instances are visible in the handover, so a port
|
|
53
|
+
that writes them one at a time and extracts on the second is doing the
|
|
54
|
+
threshold's own arithmetic in the wrong order.
|
|
55
|
+
|
|
56
|
+
This is a **different mechanism** than the one the threshold tested, not a
|
|
57
|
+
loophole in it. `adr_cite_check ADR-213` reports the record LIVE with an
|
|
58
|
+
**indeterminate** review trigger and `reopen_policy: unclassified`, so
|
|
59
|
+
investigation is permitted; the numbers themselves — 2 · 3+ · ~4+ — are
|
|
60
|
+
**unchanged**, and this clause moves only *when* the count may be taken.
|
|
61
|
+
|
|
62
|
+
**Two guards, both required. The first alone is insufficient.**
|
|
63
|
+
|
|
64
|
+
1. **A runnable artifact, not a design comp.** A comp shows a picture of four
|
|
65
|
+
cards; a runnable artifact carries four instances of a thing. Counting
|
|
66
|
+
rectangles in an image is not counting repetition, and a comp therefore does
|
|
67
|
+
not qualify.
|
|
68
|
+
2. **Repetition of the ELEMENT, not of its compositional context.** Four
|
|
69
|
+
`<Card>` instances show that Card is used four times. They do **not** show
|
|
70
|
+
that a `CardGrid` is needed — that needs multiple distinct contexts each
|
|
71
|
+
arranging several cards. Without this guard the clause would license
|
|
72
|
+
extracting a wrapper for every layout the artifact happens to contain once,
|
|
73
|
+
which is speculative abstraction with an artifact as its excuse.
|
|
74
|
+
|
|
75
|
+
**Enforcement, stated honestly: guard (2) is model-carried and audit-enforced.**
|
|
76
|
+
Nothing mechanical separates *"I saw four Cards"* from *"I saw a CardGrid
|
|
77
|
+
pattern"* — the distinction is about what the repetition MEANS, and
|
|
78
|
+
`lint_abstraction_thresholds.ts` checks numeric threshold drift, which is a
|
|
79
|
+
different property. Guard (1) is checkable (is the handover runnable), guard (2)
|
|
80
|
+
is not, and claiming otherwise would be the coverage inflation this tree forbids
|
|
81
|
+
elsewhere. The discipline is the control.
|
|
82
|
+
|
|
83
|
+
## See also
|
|
84
|
+
|
|
85
|
+
- [`architecture`](../rules/architecture.md) — the rule that carries the code-level bar.
|
|
86
|
+
- [`fe-design`](../skills/fe-design/SKILL.md) § Component granularity — the UI-shell bar in context.
|
|
87
|
+
- [`ui-component-architect`](../skills/ui-component-architect/SKILL.md) § Componentization threshold — the stateful-component bar in context.
|
|
88
|
+
- ADR-213 — the decision record scoping the bars.
|