@event4u/agent-config 14.10.0 → 14.11.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 +335 -0
- package/README.md +1 -1
- package/dist/agent-src/commands/design.md +88 -0
- package/dist/agent-src/commands/project/analyze.md +47 -0
- package/dist/agent-src/commands/review/changes.md +67 -6
- package/dist/agent-src/commands/roadmap/create.md +49 -0
- package/dist/agent-src/commands/roadmap/next.md +27 -11
- package/dist/agent-src/commands/roadmap/process-full.md +14 -0
- package/dist/agent-src/commands/video/from-script.md +60 -3
- package/dist/agent-src/commands/video/stitch.md +14 -0
- package/dist/agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +1 -0
- package/dist/agent-src/contexts/execution/roadmap-process-loop.md +154 -2
- package/dist/agent-src/rules/active-remediation.md +3 -3
- package/dist/agent-src/rules/code-provenance.md +2 -2
- package/dist/agent-src/rules/context-hygiene.md +13 -33
- package/dist/agent-src/rules/council-availability.md +2 -2
- package/dist/agent-src/rules/decision-revisit-gate.md +3 -1
- package/dist/agent-src/rules/design-fidelity.md +18 -0
- package/dist/agent-src/rules/design-review-after-ui-write.md +2 -2
- package/dist/agent-src/rules/evaluator-independence.md +56 -44
- package/dist/agent-src/rules/fix-what-you-see.md +9 -1
- package/dist/agent-src/rules/framework-neutrality-in-generic-skills.md +1 -1
- package/dist/agent-src/rules/minimal-safe-diff.md +14 -20
- package/dist/agent-src/rules/missing-skill-recovery.md +13 -1
- package/dist/agent-src/rules/playbook-precedence.md +105 -0
- package/dist/agent-src/rules/recurring-criticism.md +3 -1
- package/dist/agent-src/rules/roadmap-progress-sync.md +14 -13
- package/dist/agent-src/rules/scale-discipline.md +24 -0
- package/dist/agent-src/rules/security-sensitive-stop.md +2 -2
- package/dist/agent-src/rules/settings-ask-protocol.md +2 -2
- package/dist/agent-src/rules/ui-audit-gate.md +27 -15
- package/dist/agent-src/rules/untrusted-input-defense.md +2 -2
- package/dist/agent-src/skills/accessibility-auditor/SKILL.md +19 -0
- package/dist/agent-src/skills/adr-create/SKILL.md +7 -0
- package/dist/agent-src/skills/agents-md-thin-root/SKILL.md +33 -0
- package/dist/agent-src/skills/ai-council/references/advanced-modes.md +17 -3
- package/dist/agent-src/skills/ai-council/references/output-and-synthesis.md +31 -0
- package/dist/agent-src/skills/ai-council/references/procedure.md +19 -0
- package/dist/agent-src/skills/alerting-doctrine/SKILL.md +225 -0
- package/dist/agent-src/skills/alerting-doctrine/evals/triggers.json +17 -0
- package/dist/agent-src/skills/authz-review/SKILL.md +0 -1
- package/dist/agent-src/skills/blast-radius-analyzer/SKILL.md +32 -0
- package/dist/agent-src/skills/brand/SKILL.md +3 -0
- package/dist/agent-src/skills/brand-asset-generation/SKILL.md +3 -0
- package/dist/agent-src/skills/brand-audit/SKILL.md +3 -0
- package/dist/agent-src/skills/brand-identity/SKILL.md +3 -0
- package/dist/agent-src/skills/brand-strategy/SKILL.md +3 -0
- package/dist/agent-src/skills/brand-to-tokens/SKILL.md +3 -0
- package/dist/agent-src/skills/check-refs/SKILL.md +3 -0
- package/dist/agent-src/skills/code-review/SKILL.md +11 -0
- package/dist/agent-src/skills/command-routing/SKILL.md +6 -0
- package/dist/agent-src/skills/condense-memory/SKILL.md +3 -0
- package/dist/agent-src/skills/context-authoring/SKILL.md +1 -1
- package/dist/agent-src/skills/conventional-commits-writing/SKILL.md +3 -0
- package/dist/agent-src/skills/copilot-agents-optimization/SKILL.md +10 -0
- package/dist/agent-src/skills/corpus-grounding/SKILL.md +3 -0
- package/dist/agent-src/skills/design-intelligence/SKILL.md +3 -0
- package/dist/agent-src/skills/design-intelligence/data/landing.csv +36 -35
- package/dist/agent-src/skills/design-intelligence/data/stacks/threejs.csv +1 -0
- package/dist/agent-src/skills/design-review/SKILL.md +79 -1
- package/dist/agent-src/skills/design-review/references/verification-automation.md +41 -0
- package/dist/agent-src/skills/design-system-capture/SKILL.md +35 -40
- package/dist/agent-src/skills/design-system-capture/references/import-procedure.md +50 -0
- package/dist/agent-src/skills/design-tokens/SKILL.md +3 -0
- package/dist/agent-src/skills/design-variations/SKILL.md +3 -0
- package/dist/agent-src/skills/developer-like-execution/SKILL.md +3 -0
- package/dist/agent-src/skills/estimate-ticket/SKILL.md +3 -0
- package/dist/agent-src/skills/existing-ui-audit/SKILL.md +20 -3
- package/dist/agent-src/skills/fe-design/SKILL.md +74 -41
- package/dist/agent-src/skills/fe-design/evals/triggers.json +65 -53
- package/dist/agent-src/skills/fe-design/references/craft-floor.md +52 -0
- package/dist/agent-src/skills/fe-design/references/source-led-port.md +36 -0
- package/dist/agent-src/skills/file-editor/SKILL.md +5 -0
- package/dist/agent-src/skills/finishing-a-development-branch/SKILL.md +2 -2
- package/dist/agent-src/skills/git-workflow/SKILL.md +3 -0
- package/dist/agent-src/skills/html-deck/SKILL.md +3 -0
- package/dist/agent-src/skills/iconography/SKILL.md +3 -0
- package/dist/agent-src/skills/image-editing/SKILL.md +3 -0
- package/dist/agent-src/skills/image-generation/SKILL.md +3 -0
- package/dist/agent-src/skills/image-provider-routing/SKILL.md +3 -0
- package/dist/agent-src/skills/incident-commander/SKILL.md +10 -0
- package/dist/agent-src/skills/js-library-packaging/SKILL.md +173 -0
- package/dist/agent-src/skills/js-library-packaging/evals/triggers.json +17 -0
- package/dist/agent-src/skills/js-library-packaging/scripts/check_package_surface.ts +270 -0
- package/dist/agent-src/skills/laravel-migration/SKILL.md +3 -0
- package/dist/agent-src/skills/learning-to-rule-or-skill/SKILL.md +3 -0
- package/dist/agent-src/skills/lint-skills/SKILL.md +3 -0
- package/dist/agent-src/skills/llm-provider-knowledge/SKILL.md +3 -0
- package/dist/agent-src/skills/logging-monitoring/SKILL.md +234 -51
- package/dist/agent-src/skills/logo-generation/SKILL.md +3 -0
- package/dist/agent-src/skills/md-language-check/SKILL.md +3 -0
- package/dist/agent-src/skills/monorepo-workspace/SKILL.md +149 -0
- package/dist/agent-src/skills/monorepo-workspace/evals/triggers.json +17 -0
- package/dist/agent-src/skills/motion-choreographer/SKILL.md +6 -0
- package/dist/agent-src/skills/multi-tenancy/SKILL.md +4 -0
- package/dist/agent-src/skills/operational-readiness/SKILL.md +184 -0
- package/dist/agent-src/skills/operational-readiness/evals/triggers.json +17 -0
- package/dist/agent-src/skills/override-management/SKILL.md +3 -0
- package/dist/agent-src/skills/persona-improvement/SKILL.md +3 -0
- package/dist/agent-src/skills/pest-testing/SKILL.md +3 -0
- package/dist/agent-src/skills/playbook-authoring/SKILL.md +162 -0
- package/dist/agent-src/skills/playwright-testing/SKILL.md +3 -0
- package/dist/agent-src/skills/privacy-review/SKILL.md +3 -0
- package/dist/agent-src/skills/prompt-engineering-image/SKILL.md +3 -0
- package/dist/agent-src/skills/quality-tools/SKILL.md +5 -0
- package/dist/agent-src/skills/react-shadcn-ui/SKILL.md +52 -21
- package/dist/agent-src/skills/readme-reviewer/SKILL.md +3 -0
- package/dist/agent-src/skills/readme-writing/SKILL.md +3 -0
- package/dist/agent-src/skills/readme-writing-package/SKILL.md +3 -0
- package/dist/agent-src/skills/receiving-code-review/SKILL.md +2 -2
- package/dist/agent-src/skills/refine-prompt/SKILL.md +3 -0
- package/dist/agent-src/skills/refine-ticket/SKILL.md +3 -0
- package/dist/agent-src/skills/requesting-code-review/SKILL.md +2 -2
- package/dist/agent-src/skills/review-routing/SKILL.md +2 -2
- package/dist/agent-src/skills/roadmap-writing/SKILL.md +23 -41
- package/dist/agent-src/skills/roadmap-writing/references/follow-up-roadmap-shape.md +47 -0
- package/dist/agent-src/skills/rtk-output-filtering/SKILL.md +22 -6
- package/dist/agent-src/skills/runway-cognition/SKILL.md +3 -0
- package/dist/agent-src/skills/scene-expander/scene-blueprint.schema.yaml +26 -0
- package/dist/agent-src/skills/secrets-management/SKILL.md +4 -0
- package/dist/agent-src/skills/server-hardening/SKILL.md +159 -0
- package/dist/agent-src/skills/server-hardening/evals/triggers.json +17 -0
- package/dist/agent-src/skills/skill-improvement-pipeline/SKILL.md +3 -0
- package/dist/agent-src/skills/skill-management/SKILL.md +3 -0
- package/dist/agent-src/skills/skill-reviewer/SKILL.md +3 -0
- package/dist/agent-src/skills/skill-writing/SKILL.md +6 -0
- package/dist/agent-src/skills/spreadsheet-authoring/SKILL.md +3 -0
- package/dist/agent-src/skills/storybook-workshop/SKILL.md +194 -0
- package/dist/agent-src/skills/storybook-workshop/evals/triggers.json +17 -0
- package/dist/agent-src/skills/storybook-workshop/scripts/story_contrast_floor.ts +134 -0
- package/dist/agent-src/skills/subagent-orchestration/SKILL.md +1 -1
- package/dist/agent-src/skills/subagent-orchestration/prompts/README.md +25 -0
- package/dist/agent-src/skills/supply-chain-intake/SKILL.md +12 -0
- package/dist/agent-src/skills/systematic-debugging/SKILL.md +1 -1
- package/dist/agent-src/skills/terraform/SKILL.md +3 -0
- package/dist/agent-src/skills/test-driven-development/SKILL.md +1 -1
- package/dist/agent-src/skills/threat-modeling/SKILL.md +0 -3
- package/dist/agent-src/skills/token-optimizer/SKILL.md +3 -0
- package/dist/agent-src/skills/typography-system/SKILL.md +3 -0
- package/dist/agent-src/skills/ui-component-architect/SKILL.md +9 -1
- package/dist/agent-src/skills/upstream-contribute/SKILL.md +3 -0
- package/dist/agent-src/skills/validate-feature-fit/SKILL.md +3 -0
- package/dist/agent-src/skills/verify-completion-evidence/SKILL.md +2 -2
- package/dist/agent-src/skills/wireframe/SKILL.md +3 -0
- package/dist/agent-src/skills/wireframe/references/story-beat-ledger.schema.json +115 -0
- package/dist/agent-src/skills/workspace-link/SKILL.md +131 -0
- package/dist/agent-src/skills/workspace-link/evals/triggers.json +17 -0
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
- package/dist/agent-src/templates/playbook.md +75 -0
- package/dist/agent-src/templates/roadmaps.md +37 -0
- package/dist/agent-src/templates/scripts/check_playbook_invokes.ts +231 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +24 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/polish.ts +2 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/review.ts +216 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/scaffold.ts +159 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/stack_bundles.ts +73 -4
- package/dist/agent-src/templates/scripts/work_engine/stack/detect.ts +325 -40
- package/dist/cli/commands/uiAudit.js +221 -0
- package/dist/cli/commands/uiAudit.js.map +1 -0
- package/dist/cli/commands/uiRender.js +206 -0
- package/dist/cli/commands/uiRender.js.map +1 -0
- package/dist/cli/main.js +22 -1
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/mcp/content.js +64 -1
- package/dist/cli/mcp/content.js.map +1 -1
- package/dist/cli/mcp/dispatch.js +175 -10
- package/dist/cli/mcp/dispatch.js.map +1 -1
- package/dist/cli/registry.js +3 -0
- package/dist/cli/registry.js.map +1 -1
- package/dist/cli-delegate/{chunk-H4VIVD4C.js → chunk-236PNQZK.js} +413 -391
- package/dist/cli-delegate/{chunk-G23AT6GD.js → chunk-DMSZHXZS.js} +57 -1
- package/dist/cli-delegate/{chunk-77GR3VD4.js → chunk-FF7WAFMR.js} +58 -3
- package/dist/cli-delegate/{chunk-PLSG6UL5.js → chunk-K4FFODTS.js} +341 -204
- package/dist/cli-delegate/{chunk-YM4GZDJG.js → chunk-L43NCYPB.js} +5 -0
- package/dist/cli-delegate/{chunk-B2ERU2VA.js → chunk-WOKWX5PL.js} +1 -1
- package/dist/cli-delegate/cmd_brand_status.js +8 -6
- package/dist/cli-delegate/cmd_conformance.js +3 -3
- package/dist/cli-delegate/cmd_doctor.js +3 -3
- package/dist/cli-delegate/cmd_export.js +4 -4
- package/dist/cli-delegate/cmd_handoff.js +1 -1
- package/dist/cli-delegate/cmd_preflight.js +2 -2
- package/dist/cli-delegate/cmd_prune.js +4 -4
- package/dist/cli-delegate/cmd_session_recycle.js +70 -9
- package/dist/cli-delegate/cmd_settings_migrate.js +4 -4
- package/dist/cli-delegate/cmd_settings_set.js +1 -1
- package/dist/cli-delegate/cmd_sync.js +4 -4
- package/dist/cli-delegate/cmd_uninstall.js +4 -4
- package/dist/cli-delegate/cmd_validate.js +4 -4
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +359 -124
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +4 -4
- package/dist/discovery/dormancy-report.md +1 -1
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +18 -8
- package/dist/discovery/trust-report.md +3 -3
- package/dist/discovery/workspaces.json +16 -6
- package/dist/hooks/dispatch.js +2337 -1436
- package/dist/install/install.mjs +795 -708
- package/dist/mcp/registry-manifest.json +3 -3
- package/dist/mcp/server.json +2 -2
- package/dist/mcp/server.mjs +1685 -1250
- package/dist/router.json +1 -1
- package/dist/scripts/_lib/lean_projection_mode.js +40 -0
- package/dist/scripts/_lib/lean_projection_mode.js.map +1 -0
- package/dist/scripts/_lib/scoped_projection.js +84 -0
- package/dist/scripts/_lib/scoped_projection.js.map +1 -1
- package/dist/scripts/_lib/ui_surface.js +89 -0
- package/dist/scripts/_lib/ui_surface.js.map +1 -0
- package/dist/scripts/condense.js +6 -10
- package/dist/scripts/condense.js.map +1 -1
- package/dist/scripts/project_thin_rules.js +40 -2
- package/dist/scripts/project_thin_rules.js.map +1 -1
- package/dist/server/schemas/settings.js +3 -0
- package/dist/server/schemas/settings.js.map +1 -1
- package/dist/shared/skillRanking.js +159 -0
- package/dist/shared/skillRanking.js.map +1 -0
- package/docs/contracts/provider-lifecycle.md +47 -18
- package/docs/contracts/settings-classes.md +14 -4
- package/docs/guidelines/agent-infra/context-hygiene-mechanics.md +49 -0
- package/docs/guidelines/agent-infra/evaluator-independence-mechanics.md +92 -0
- package/docs/guidelines/agent-infra/minimal-safe-diff-mechanics.md +45 -1
- package/docs/guidelines/agent-infra/roadmap-deferred-resolution-provenance.md +54 -0
- package/docs/guidelines/design-antipatterns.md +4 -2
- package/docs/guidelines/design-asset-discipline.md +38 -0
- package/docs/guidelines/design-fidelity-mechanics.md +45 -29
- package/docs/guidelines/design-handover-extraction.md +35 -5
- package/docs/guidelines/design-modes.md +41 -1
- package/docs/guidelines/monorepo-antipatterns.md +141 -0
- package/llms.txt +50 -39
- package/package.json +1 -1
- package/src/agent-src/templates/scripts/check_playbook_invokes.ts +231 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +24 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/polish.ts +2 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/review.ts +216 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/scaffold.ts +159 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/stack_bundles.ts +73 -4
- package/src/agent-src/templates/scripts/work_engine/stack/detect.ts +325 -40
- package/src/config/agent-settings.template.yml +28 -0
- package/src/config/assurance-capability-registry.json +223 -0
- package/src/config/assurance-threshold-budget.json +65 -0
- package/src/config/ci-local-parity.yml +14 -0
- package/src/config/discovery/unassigned-artefacts.yml +2 -0
- package/src/config/dispatch-economy-metrics.json +4 -2
- package/src/config/evaluator-budgets.json +14 -14
- package/src/config/gate-coverage.yml +207 -8
- package/src/config/gate-violation-baselines.json +76 -72
- package/src/config/hook-latency-budget.json +1 -0
- package/src/config/hook-token-budget.json +137 -125
- package/src/config/pack-size-budget.json +4 -2
- package/src/config/quorum-attendance-budget.json +12 -4
- package/src/config/rule-activation-census.json +7 -3
- package/src/config/rule-enforcement-baseline.json +0 -1
- package/src/config/rule-stub-ceilings.json +112 -91
- package/src/scripts/_cli/cmd_doctor.ts +15 -16
- package/src/scripts/_cli/doctor_install_mode.ts +49 -0
- package/src/scripts/_cli/doctor_overrides.ts +154 -0
- package/src/scripts/_dispatch.bash +17 -0
- package/src/scripts/_lib/as_of.ts +412 -0
- package/src/scripts/_lib/exec_evidence.ts +7 -0
- package/src/scripts/_lib/hook_settings.ts +33 -0
- package/src/scripts/_lib/host_listing_model.ts +192 -0
- package/src/scripts/_lib/lean_projection_mode.ts +44 -0
- package/src/scripts/_lib/mcp_bridge.ts +199 -0
- package/src/scripts/_lib/review_independence.ts +62 -10
- package/src/scripts/_lib/rule_injection.ts +239 -0
- package/src/scripts/_lib/run_checkpoint.ts +54 -1
- package/src/scripts/_lib/scoped_projection.ts +96 -0
- package/src/scripts/_lib/session_register.ts +44 -2
- package/src/scripts/_lib/skill_catalogue.ts +38 -2
- package/src/scripts/_lib/transcript_reads.ts +207 -0
- package/src/scripts/_lib/ui_authority.test.ts +251 -0
- package/src/scripts/_lib/ui_authority.ts +343 -0
- package/src/scripts/ai-video/adapters/fal.sh +8 -3
- package/src/scripts/ai-video/adapters/gemini-veo.sh +10 -0
- package/src/scripts/ai-video/adapters/higgsfield.sh +10 -2
- package/src/scripts/ai-video/adapters/kling.sh +10 -0
- package/src/scripts/ai-video/adapters/sora.sh +10 -0
- package/src/scripts/ai-video/lib/calibrate-cost.sh +145 -0
- package/src/scripts/ai-video/lib/model-capabilities/README.md +53 -7
- package/src/scripts/ai-video/lib/model-capabilities/comfyui.json +15 -3
- package/src/scripts/ai-video/lib/model-capabilities/fal.json +36 -6
- package/src/scripts/ai-video/lib/model-capabilities/gemini-veo.json +23 -0
- package/src/scripts/ai-video/lib/model-capabilities/higgsfield.json +23 -0
- package/src/scripts/ai-video/lib/model-capabilities/kling.json +23 -0
- package/src/scripts/ai-video/lib/model-capabilities/musetalk.json +8 -2
- package/src/scripts/ai-video/lib/model-capabilities/replicate.json +36 -6
- package/src/scripts/ai-video/lib/model-capabilities/sora.json +45 -0
- package/src/scripts/ai-video/lib/model-capabilities/syncso.json +8 -2
- package/src/scripts/ai-video/lib/parse-blueprint.sh +52 -5
- package/src/scripts/ai-video/lib/resume-scan.sh +92 -3
- package/src/scripts/ai-video/lib/seam-plan.sh +212 -0
- package/src/scripts/ai-video/smoke-trace.sh +450 -2
- package/src/scripts/ai-video/stitch.sh +191 -10
- package/src/scripts/ai-video/test-pipeline.sh +84 -6
- package/src/scripts/ai_council/cli_agency_bounds.ts +139 -0
- package/src/scripts/ai_council/cli_least_agency_canary.ts +347 -0
- package/src/scripts/ai_council/clients.ts +3 -2
- package/src/scripts/ai_council/consensus.ts +63 -6
- package/src/scripts/ai_council/events_log.ts +46 -1
- package/src/scripts/ai_council/orchestrator.ts +103 -108
- package/src/scripts/ai_council/orchestrator_results.ts +166 -0
- package/src/scripts/ai_council/prompts.ts +12 -5
- package/src/scripts/ai_council/quorum.ts +82 -1
- package/src/scripts/ai_council/quorum_wiring.ts +82 -5
- package/src/scripts/ai_council/stance_tally.ts +22 -0
- package/src/scripts/bench_hook_latency.ts +62 -0
- package/src/scripts/build_proof.ts +12 -1
- package/src/scripts/capture_skill_catalogue.ts +21 -0
- package/src/scripts/check_always_budget.ts +2 -1
- package/src/scripts/check_augmentignore.ts +2 -1
- package/src/scripts/check_beta_review_markers.ts +2 -1
- package/src/scripts/check_composite_arming.ts +364 -0
- package/src/scripts/check_corpus_staleness.ts +2 -1
- package/src/scripts/check_council_pin_staleness.ts +3 -1
- package/src/scripts/check_enforcement_coverage.ts +116 -3
- package/src/scripts/check_enforcement_denominator.ts +365 -0
- package/src/scripts/check_gate_coverage.ts +2 -1
- package/src/scripts/check_hook_bundle_freshness.ts +13 -1
- package/src/scripts/check_knowledge_cards.ts +2 -1
- package/src/scripts/check_knowledge_pages.ts +3 -2
- package/src/scripts/check_memory.ts +2 -1
- package/src/scripts/check_no_automerge_key.ts +287 -0
- package/src/scripts/check_pack_conformance_fixture.ts +565 -0
- package/src/scripts/check_proposal.ts +2 -1
- package/src/scripts/check_reach_staleness.ts +2 -1
- package/src/scripts/check_release_adjacent_health.ts +2 -1
- package/src/scripts/check_release_pr_shape.ts +5 -0
- package/src/scripts/check_review_schema.ts +34 -1
- package/src/scripts/check_roadmap_trackable.ts +48 -3
- package/src/scripts/check_source_size_budget.ts +2 -1
- package/src/scripts/check_standing_payload_delta.ts +505 -0
- package/src/scripts/check_trigger_evals.ts +2 -1
- package/src/scripts/classify_change_risk.ts +281 -0
- package/src/scripts/compute_skill_tiers.ts +186 -0
- package/src/scripts/condense.ts +8 -13
- package/src/scripts/council_attendance_metrics.ts +183 -0
- package/src/scripts/council_cli.ts +10 -8
- package/src/scripts/council_parse_rate.ts +116 -0
- package/src/scripts/derive_playbooks.ts +406 -0
- package/src/scripts/design_slop_rules.test.ts +7 -0
- package/src/scripts/design_slop_rules.ts +56 -2
- package/src/scripts/dispatch_r2_reviewer.ts +16 -0
- package/src/scripts/frontend_corpus_hash.ts +116 -0
- package/src/scripts/grade_target_readiness.ts +478 -0
- package/src/scripts/hook_manifest.json +1 -1
- package/src/scripts/hook_manifest.yaml +97 -16
- package/src/scripts/hooks/concern_registry.ts +4 -0
- package/src/scripts/hooks/design_pass_hook.ts +356 -0
- package/src/scripts/hooks/rtk_wrap_hook.ts +30 -7
- package/src/scripts/hooks/rule_inject_hook.ts +318 -0
- package/src/scripts/hot_context_hook.ts +74 -7
- package/src/scripts/install.ts +40 -89
- package/src/scripts/lint_adapter_tier.ts +663 -0
- package/src/scripts/lint_archived_skills.ts +93 -0
- package/src/scripts/lint_budget_ownership.ts +2 -1
- package/src/scripts/lint_deterministic_time.ts +470 -0
- package/src/scripts/lint_framework_leakage.ts +5 -0
- package/src/scripts/lint_handoffs.ts +525 -1
- package/src/scripts/lint_judge_prompt_expectation.ts +155 -0
- package/src/scripts/lint_marketplace.ts +88 -0
- package/src/scripts/lint_media_policy_linkage.ts +140 -1
- package/src/scripts/lint_one_off_age.ts +6 -1
- package/src/scripts/lint_override_kernel_guard.ts +87 -5
- package/src/scripts/lint_roadmap_complexity.ts +56 -0
- package/src/scripts/lint_rule_enforcement_declaration.ts +24 -7
- package/src/scripts/lint_rule_norm_pin.ts +321 -0
- package/src/scripts/lint_spawn_payload.ts +42 -5
- package/src/scripts/lint_symptom_intake.ts +2 -1
- package/src/scripts/mcp_parity_smoke.ts +30 -4
- package/src/scripts/mcp_render.ts +66 -1
- package/src/scripts/mcp_tool_fingerprint.ts +241 -0
- package/src/scripts/measure_risk_class_drift.ts +140 -0
- package/src/scripts/measure_skill_ranker_baseline.ts +212 -0
- package/src/scripts/media/lib/adapter-common.sh +211 -1
- package/src/scripts/media/lib/adapter-contract.md +74 -6
- package/src/scripts/model_rule_injection.ts +907 -0
- package/src/scripts/project_thin_rules.ts +45 -2
- package/src/scripts/release.ts +66 -860
- package/src/scripts/release_drill.ts +59 -3
- package/src/scripts/release_env.ts +298 -0
- package/src/scripts/release_publication.ts +720 -0
- package/src/scripts/roadmap_context.ts +778 -0
- package/src/scripts/schemas/fidelity-measurement-sheet.schema.json +169 -0
- package/src/scripts/schemas/rule.schema.json +24 -2
- package/src/scripts/schemas/skill.schema.json +39 -0
- package/src/scripts/schemas/ui-authority.schema.json +114 -0
- package/src/scripts/session_register_hook.ts +29 -3
- package/src/scripts/sessions_cli.ts +67 -3
- package/src/scripts/skill_tools/score_skill_relevance.ts +36 -53
- package/src/scripts/token_sink_report.ts +239 -0
- package/src/scripts/trigger_coverage.ts +122 -3
- package/src/scripts/update_counts.ts +7 -3
- package/src/scripts/validate_frontmatter.ts +66 -0
- package/src/server/schemas/settings.ts +5 -0
- package/src/shared/skillRanking.ts +183 -0
|
@@ -3,12 +3,12 @@ model_tier: high
|
|
|
3
3
|
name: review-changes
|
|
4
4
|
pack: engineering-base
|
|
5
5
|
intent: "Multi-judge review of the current diff — bugs, security, tests, quality, architecture"
|
|
6
|
-
routes_to: [code-review, judge-bug-hunter, judge-security-auditor, judge-test-coverage, judge-code-quality, architecture-review-lens]
|
|
6
|
+
routes_to: [code-review, judge-bug-hunter, judge-security-auditor, judge-test-coverage, judge-code-quality, architecture-review-lens, overbuild-review-lens]
|
|
7
7
|
replaces: []
|
|
8
8
|
visibility: internal
|
|
9
9
|
sub: changes
|
|
10
10
|
cluster: review
|
|
11
|
-
skills: [code-review, subagent-orchestration, judge-bug-hunter, judge-security-auditor, judge-test-coverage, judge-code-quality, architecture-review-lens, judge-synthesis, git-workflow]
|
|
11
|
+
skills: [code-review, subagent-orchestration, judge-bug-hunter, judge-security-auditor, judge-test-coverage, judge-code-quality, architecture-review-lens, overbuild-review-lens, judge-synthesis, git-workflow]
|
|
12
12
|
description: Self-review local changes before creating a PR — dispatches to six specialized judges (bug, security, tests, quality, architecture, spec) and consolidates verdicts
|
|
13
13
|
suggestion:
|
|
14
14
|
eligible: false
|
|
@@ -122,10 +122,21 @@ PR body, commit messages) and runs independently. The judges are:
|
|
|
122
122
|
| [`judge-code-quality`](../../skills/judge-code-quality/SKILL.md) | Naming, SRP, DRY, dead code, consistency with codebase conventions |
|
|
123
123
|
| [`architecture-review-lens`](../../skills/architecture-review-lens/SKILL.md) | Layer violations, dependency direction, leaky abstractions, cross-service contract drift |
|
|
124
124
|
| [`judge-spec-compliance`](../../skills/judge-spec-compliance/SKILL.md) | Does the diff satisfy every acceptance criterion **as stated**? Reads the criteria before the diff, and never infers them from it |
|
|
125
|
+
| [`overbuild-review-lens`](../../skills/overbuild-review-lens/SKILL.md) | Speculative abstraction, premature generality, features nobody asked for, a rewrite where an edit was the task |
|
|
125
126
|
|
|
126
|
-
The
|
|
127
|
+
The seven judges weight equally in the consolidated verdict — none
|
|
127
128
|
overrides another.
|
|
128
129
|
|
|
130
|
+
**Why the seventh exists (road-to-trigger-delivered-rule-bodies A5).**
|
|
131
|
+
`overbuild-review-lens` shipped and **no command routed to it** — `grep -rln
|
|
132
|
+
overbuild-review-lens dist/agent-src/commands/` returned nothing, so a lens
|
|
133
|
+
built to catch the most common failure of AI-written code was reachable only by
|
|
134
|
+
being asked for by name. The other six all ask whether the diff is *good*; this
|
|
135
|
+
one asks whether it should have been this *large*, which is the one question a
|
|
136
|
+
diff cannot answer about itself. It is dispatched on demand like the others, so
|
|
137
|
+
it adds no standing token cost — verified: `check_preamble_payload_budget`'s
|
|
138
|
+
measured total is unchanged by this routing.
|
|
139
|
+
|
|
129
140
|
**Why the sixth exists, and why it is not a severity.** The other five all ask a
|
|
130
141
|
craft-or-correctness question, so a change that is correct, clean, well-tested
|
|
131
142
|
and architecturally sound — and **does not do what was asked** — used to pass
|
|
@@ -146,12 +157,12 @@ Pick dispatch mode based on diff size and environment:
|
|
|
146
157
|
|
|
147
158
|
- **Sequential** (default, simplest) — run bug-hunter → security-auditor
|
|
148
159
|
→ test-coverage → code-quality → architecture-review-lens →
|
|
149
|
-
spec-compliance, collect each verdict
|
|
160
|
+
spec-compliance → overbuild, collect each verdict
|
|
150
161
|
- **Parallel** — if `subagents.max_parallel` in `.agent-settings.yml` is
|
|
151
|
-
≥ 5 and subagent dispatch is available, run all
|
|
162
|
+
≥ 5 and subagent dispatch is available, run all seven concurrently
|
|
152
163
|
following the `do-in-parallel` pattern in
|
|
153
164
|
[`subagent-orchestration`](../../skills/subagent-orchestration/SKILL.md);
|
|
154
|
-
the
|
|
165
|
+
the seven judges operate on the same diff but produce independent
|
|
155
166
|
reports, so no shared-state risk
|
|
156
167
|
|
|
157
168
|
Each judge returns its own `Judge / Model / Target / Verdict /
|
|
@@ -189,6 +200,56 @@ If picked **1**:
|
|
|
189
200
|
|
|
190
201
|
If picked **2** → continue with internal judges only.
|
|
191
202
|
|
|
203
|
+
### 4b-fresh. The fresh reviewer — the one input with no implementation context
|
|
204
|
+
|
|
205
|
+
The six judges above all read **the same diff plus the task context**, and on the common
|
|
206
|
+
path they run in-session: the party that wrote the diff also reads it, with the whole
|
|
207
|
+
implementation context in scope. That is a self-review, and calling it a review is the
|
|
208
|
+
defect `road-to-review-independence` exists to close.
|
|
209
|
+
|
|
210
|
+
So a **seventh input** is added, and its distinguishing property is a negative one: it
|
|
211
|
+
has **no implementation context**. Not a new mechanism —
|
|
212
|
+
[`dispatch_r2_reviewer.ts`](../../../../scripts/dispatch_r2_reviewer.ts) already derives
|
|
213
|
+
the scope and persists the prompt it sent:
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
./scripts-run src/scripts/dispatch_r2_reviewer --slug <slug> --base origin/main
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
The six in-session judges stay exactly as they are. This is an addition, not a
|
|
220
|
+
replacement — a fresh reviewer is worse than a spec judge at spec compliance, and the
|
|
221
|
+
point is not to be better at their job but to be uncontaminated by the author's framing.
|
|
222
|
+
|
|
223
|
+
**When the route is taken.** Whenever the diff is going to a PR — i.e. every
|
|
224
|
+
pre-PR review, which is what this command's own opening line describes itself as. It is
|
|
225
|
+
skipped only for a diff that will not be proposed to anyone: a scratch branch, a probe,
|
|
226
|
+
a measurement re-run.
|
|
227
|
+
|
|
228
|
+
**When dispatch is unavailable — the honest degraded answer.** If a fresh dispatch cannot
|
|
229
|
+
be made (no subagent primitive on this host, a spend ceiling, a dispatcher error), the
|
|
230
|
+
review **says so in the report** and records `fresh_review: unavailable` with the reason.
|
|
231
|
+
It does **not** fall back to the in-session judges and present the result as a review:
|
|
232
|
+
|
|
233
|
+
```
|
|
234
|
+
A SELF-REVIEW PRESENTED AS A REVIEW IS THE DEFECT, NOT THE DEGRADED MODE.
|
|
235
|
+
NO FRESH REVIEWER -> THE REPORT SAYS SO. NEVER SILENTLY.
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
That wording is deliberate. A silent fallback is worse than a missing input, because the
|
|
239
|
+
reader cannot tell which one they got — and this command's own `criteria_source` table
|
|
240
|
+
already applies the same rule to a different input (`not_provided` is never a pass).
|
|
241
|
+
|
|
242
|
+
**The implementer envelope does NOT reach this reviewer.** The judge prompts hand it over
|
|
243
|
+
on purpose — `prompts/do-and-judge.md:70` carries an `IMPLEMENTER ENVELOPE:` line with the
|
|
244
|
+
envelope placeholder — which is correct for a judge validating a claim and wrong for a
|
|
245
|
+
reviewer whose entire value is not having the author's framing.
|
|
246
|
+
|
|
247
|
+
The placeholder is described rather than written out here on purpose: step 1.3's verify is
|
|
248
|
+
a grep for its **absence** from this route, and prose that trips a grep-shaped verify is a
|
|
249
|
+
trap for the next reader. The asymmetry is stated in
|
|
250
|
+
[`prompts/README.md`](../../../../skills/subagent-orchestration/prompts/README.md) so the
|
|
251
|
+
next prompt author does not copy the envelope line into a fresh-reviewer template.
|
|
252
|
+
|
|
192
253
|
### 4c. Optional adversarial verification council (opt-in, high-risk)
|
|
193
254
|
|
|
194
255
|
Read `subagents.adversarial_council` from `.agent-settings.yml` (default
|
|
@@ -35,6 +35,50 @@ lookup, and assess the four 95%-conditions against the seed.
|
|
|
35
35
|
- **Explicit user bypass** ("just write it") → skip the gate for this turn;
|
|
36
36
|
count the bypass.
|
|
37
37
|
|
|
38
|
+
### 0b. Context probe — before step 1
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
agent-config roadmap:context
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Run it before gathering any content, and surface its hits to the user as ONE
|
|
45
|
+
list:
|
|
46
|
+
|
|
47
|
+
- an `agents/tmp/` inbox note on the same topic (names only — the probe never
|
|
48
|
+
reads the bodies);
|
|
49
|
+
- a sibling roadmap in `later/`, `stubs/`, `archive/` or the active set whose
|
|
50
|
+
slug or title shares the topic;
|
|
51
|
+
- an open PR touching the paths the new roadmap would cite.
|
|
52
|
+
|
|
53
|
+
This is the axis step 6's collision check cannot reach. That check is a
|
|
54
|
+
recursive `find -iname`, so it already covers `later/`, `stubs/` and `archive/`
|
|
55
|
+
— **lexically**. Same topic under a different name passes it clean, and the
|
|
56
|
+
probe is the semantic half.
|
|
57
|
+
|
|
58
|
+
Naming an overlap is **required**, not optional, and it is coordination rather
|
|
59
|
+
than content generation — see the amended rule below.
|
|
60
|
+
|
|
61
|
+
**Then write the `relates:` block from the hits** (template rule 18). One
|
|
62
|
+
numbered-options question per hit — `extends` / `supersedes` / `depends` /
|
|
63
|
+
`disjoint` — and the relation is never inferred: `extends` and `supersedes` rest
|
|
64
|
+
on the same lexical evidence and are opposite decisions, so guessing manufactures
|
|
65
|
+
the reflex-empty failure in a louder form. A `depends` answer mirrors into
|
|
66
|
+
`depends:` in the same edit.
|
|
67
|
+
|
|
68
|
+
Zero hits needs no question — it is fully determined, so write it silently:
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
agent-config roadmap:context --relates # prints the block, ready to paste
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
```yaml
|
|
75
|
+
relates: [] # scanned: 716 roadmap file(s), 0 sibling hits
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
The `scanned:` count is what separates *somebody looked and found nothing* from
|
|
79
|
+
*nobody looked*; without it the empty list carries no information and is worse
|
|
80
|
+
than an absent field.
|
|
81
|
+
|
|
38
82
|
### 1. Determine location
|
|
39
83
|
|
|
40
84
|
Ask the user (in their language) where the roadmap should be created:
|
|
@@ -313,6 +357,11 @@ Failure modes covered by this hard stop:
|
|
|
313
357
|
### Rules
|
|
314
358
|
|
|
315
359
|
- **Do NOT auto-generate content** — always ask the user for input.
|
|
360
|
+
- **Naming an overlap is coordination, not content generation, and it is
|
|
361
|
+
required.** The rule above governs the roadmap's *substance*; it never
|
|
362
|
+
licenses staying silent about a sibling roadmap, an inbox note, or an open PR
|
|
363
|
+
that step 0b's probe surfaced. Report every hit, let the user decide what it
|
|
364
|
+
means, and write the outcome into the `relates:` block (template rule 18).
|
|
316
365
|
- **Do NOT commit or push.**
|
|
317
366
|
- **Do NOT offer execution after save** — Step 11 is a hard stop.
|
|
318
367
|
Execution starts on a later turn with an explicit execution verb
|
|
@@ -34,20 +34,28 @@ One invocation = one roadmap = one branch = one PR.
|
|
|
34
34
|
Selection reads live state, never memory, a dashboard count, or an
|
|
35
35
|
earlier fetch (per [`direct-answers`](../../rules/direct-answers.md)
|
|
36
36
|
Iron Law 2 and [`roadmap-process-loop § 1`](../../contexts/execution/roadmap-process-loop.md#1-resolve-roadmap)).
|
|
37
|
-
Run
|
|
37
|
+
Run ONE command:
|
|
38
38
|
|
|
39
39
|
```bash
|
|
40
|
-
|
|
41
|
-
git ls-tree --name-only origin/main agents/roadmaps/ # still active?
|
|
42
|
-
git ls-tree --name-only origin/main agents/roadmaps/archive/ # already closed?
|
|
43
|
-
gh pr list --state open --json number,title,headRefName # in flight?
|
|
44
|
-
agent-config sessions:list # claimed right now?
|
|
40
|
+
agent-config roadmap:context
|
|
45
41
|
```
|
|
46
42
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
43
|
+
The four hand-written reads this block used to carry — the pruning fetch, the
|
|
44
|
+
active and archived roadmap listings, the open-PR listing, and the session
|
|
45
|
+
register — are now one probe
|
|
46
|
+
([`roadmap_context.ts`](../../../../scripts/roadmap_context.ts)), so all five
|
|
47
|
+
`/roadmap:*` entry points screen the same way instead of one command file
|
|
48
|
+
screening well and four not screening at all.
|
|
49
|
+
|
|
50
|
+
Both session axes are still in the report and for the same reason: the live
|
|
51
|
+
records AND the unmerged branches checked out in other worktrees. The branch
|
|
52
|
+
axis is the one that does not need a peer to have claimed anything, and it is
|
|
53
|
+
the half that cannot be silent.
|
|
54
|
+
|
|
55
|
+
The probe never refuses. With no network, no `gh`, or no authentication it
|
|
56
|
+
prints `scanned: 0 PRs (network unavailable)` and exits 0 — a probe that failed
|
|
57
|
+
closed would make the call site conditional, which is the failure this
|
|
58
|
+
extraction removes.
|
|
51
59
|
|
|
52
60
|
Excluded from the candidate set: `template.md`, `archive/`,
|
|
53
61
|
`skipped/`, `later/`, anything with `status: draft` whose promotion
|
|
@@ -157,9 +165,17 @@ GOODHART MOVE THIS PACKAGE'S OWN DISCIPLINE FORBIDS.
|
|
|
157
165
|
### 3b. Claim the pick, so the next session's screen sees it
|
|
158
166
|
|
|
159
167
|
```bash
|
|
160
|
-
agent-config sessions:claim <roadmap-slug>
|
|
168
|
+
agent-config sessions:claim <roadmap-slug> [--paths src/a.ts,src/b.ts]
|
|
161
169
|
```
|
|
162
170
|
|
|
171
|
+
`--paths` publishes the run's owned-path set — the same set the § 2 screen
|
|
172
|
+
derived — into the session record as `owned_paths`. It is what turns the third
|
|
173
|
+
collision axis on: without it a peer editing the same file under a different
|
|
174
|
+
roadmap and a different branch name is invisible on every axis, which is the
|
|
175
|
+
shape of the two duplications the branch axis already failed to catch. Declaring
|
|
176
|
+
nothing degrades to today's behaviour exactly, and the field is absent rather
|
|
177
|
+
than empty in the record.
|
|
178
|
+
|
|
163
179
|
Immediately after the pick, before any branch or commit. This writes the slug
|
|
164
180
|
into `agents/runtime/state/roadmap-claim-<session>.json`; the next heartbeat lifts
|
|
165
181
|
it into this session's register record, so another session's step 1 excludes it
|
|
@@ -98,6 +98,20 @@ command already does.
|
|
|
98
98
|
`archive/` and `stubs/` are out of scope.
|
|
99
99
|
2. **Order the queue.** Roadmaps at or above 10 % checkbox progress first, in
|
|
100
100
|
**descending** progress — nearly-done first, because they convert soonest.
|
|
101
|
+
|
|
102
|
+
**This is a recorded exception to [`/roadmap:next` § 3](../next/command.md),
|
|
103
|
+
not an oversight.** That command's Iron Law is explicit: *"RANK BY DEFECT
|
|
104
|
+
SEVERITY, NEVER BY PERCENT-DONE OR STEP COUNT … picking by checkbox count is
|
|
105
|
+
the Goodhart move this package's own discipline forbids."* This step orders by
|
|
106
|
+
exactly that. The two are not in conflict because they answer different
|
|
107
|
+
questions: `next` **selects one** roadmap out of many and must not be gamed by
|
|
108
|
+
a cheap-to-finish file, while `--all` has already committed to draining the
|
|
109
|
+
**whole** estate — every member runs, so the ranking decides only the order in
|
|
110
|
+
which finished work becomes reviewable, never what gets done. Under a total
|
|
111
|
+
drain the Goodhart pressure is absent by construction: there is nothing to
|
|
112
|
+
pick, so a proxy cannot be optimised against.
|
|
113
|
+
The exception is scoped to `--all`. A single-roadmap invocation of this
|
|
114
|
+
command selects nothing and inherits `next`'s doctrine unchanged.
|
|
101
115
|
Roadmaps below 10 % are appended after, ascending by declared `complexity:`
|
|
102
116
|
tier (lightweight → bounded → structural), tiebreak ascending total
|
|
103
117
|
checkbox count. Both buckets need a **total** order or two runs over the
|
|
@@ -6,7 +6,7 @@ visibility: internal
|
|
|
6
6
|
cluster: video
|
|
7
7
|
sub: from-script
|
|
8
8
|
description: Drive a script end-to-end through the AI video pipeline — scenes → blueprint → image → operator pick → motion → video → stitch. Preview default; --mode commit spends behind the cost gate.
|
|
9
|
-
argument-hint: "<path-to-script.md> [--mode preview|commit] [--max-spend-usd <usd>] [--
|
|
9
|
+
argument-hint: "<path-to-script.md> [--mode preview|commit] [--max-spend-usd <usd>] [--no-calibrate] [--{image,video}-provider <id>]"
|
|
10
10
|
personas: [hollywood-director, ai-video-technical-director]
|
|
11
11
|
skills: [scene-expander, video-director, pixar-storyteller, character-consistency, motion-choreographer]
|
|
12
12
|
suggestion:
|
|
@@ -20,7 +20,7 @@ packs:
|
|
|
20
20
|
|
|
21
21
|
# /video:from-script
|
|
22
22
|
|
|
23
|
-
`/video:from-script <path-to-script.md> [--mode preview|commit] [--max-spend-usd <usd>] [--image-provider <id>] [--video-provider <id>]`
|
|
23
|
+
`/video:from-script <path-to-script.md> [--mode preview|commit] [--max-spend-usd <usd>] [--no-calibrate] [--image-provider <id>] [--video-provider <id>]`
|
|
24
24
|
|
|
25
25
|
Drives a Markdown script through the full pipeline. Provider flags
|
|
26
26
|
override the `<default-image-provider>` / `<default-video-provider>`
|
|
@@ -89,9 +89,66 @@ For each scene blueprint:
|
|
|
89
89
|
`0`). When `--max-spend-usd` is set and the summed estimate exceeds
|
|
90
90
|
it, hard-block before the first live call — confirmation does not
|
|
91
91
|
override the cap.
|
|
92
|
-
3.
|
|
92
|
+
3. **Calibration probe (default on; `--no-calibrate` skips).** Before the
|
|
93
|
+
batch, render exactly **one** still and **one** clip, then run:
|
|
94
|
+
|
|
95
|
+
```bash
|
|
96
|
+
scripts/ai-video/lib/calibrate-cost.sh <project> <scene-id> \
|
|
97
|
+
--adapter <id> --model <id> --scenes <n>
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
It reads the `charged_usd` the pipeline already writes to
|
|
101
|
+
`<project>/scenes/<id>/cost.json` and prints one line:
|
|
102
|
+
|
|
103
|
+
```
|
|
104
|
+
calibration: modeled $0.0800/s · charged $0.1100/s · +37.5 % · extrapolated batch $4.40 (modeled $3.20)
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Re-confirm **only** when the charged figure exceeds the modeled one by
|
|
108
|
+
more than **25 %** — the script exits **13** in that case and **0**
|
|
109
|
+
otherwise. Under the threshold, print the line and continue: a calibration
|
|
110
|
+
that interrupts on every run is a confirmation nobody reads.
|
|
111
|
+
|
|
112
|
+
Exit 13 is a halt for a human, not a failure. `--max-spend-usd` is not a
|
|
113
|
+
substitute for it — that cap bounds *total spend*, while this catches a
|
|
114
|
+
wrong *per-second model*, which is what makes the total wrong in the first
|
|
115
|
+
place.
|
|
116
|
+
|
|
117
|
+
This folds into the existing `lib/operator-pick.sh` moment rather than
|
|
118
|
+
adding a gate of its own, so the operator sees the calibration line at
|
|
119
|
+
the checkpoint they were already stopping at.
|
|
120
|
+
|
|
121
|
+
`charged: null` is **not** `0`: an unpriceable or not-yet-charged scene
|
|
122
|
+
prints `charged: null`, extrapolates nothing, and never re-confirms. A
|
|
123
|
+
modeled figure is only ever corrected by a measured one.
|
|
124
|
+
|
|
125
|
+
Every reading appends one row to
|
|
126
|
+
`agents/evidence/ai-video/cost-ledger.jsonl` — see § Cost ledger below.
|
|
127
|
+
The read-back itself is not new: `lib/resume-scan.sh` already reads
|
|
128
|
+
`cost.json .charged_usd` and sums it as `spent_usd`. What is new is that
|
|
129
|
+
the number now **feeds back**: before this, money spent was recorded and
|
|
130
|
+
never read into the model it contradicted.
|
|
131
|
+
|
|
132
|
+
4. Call the image adapter (`run` subcommand) N times where N =
|
|
93
133
|
`<tuning/best-of-n>` (default 1).
|
|
94
134
|
|
|
135
|
+
### 5b. Cost ledger — the only route from charged to modeled
|
|
136
|
+
|
|
137
|
+
`manifest.cost_per_second_usd` is a **modeled** estimate. It may be
|
|
138
|
+
re-modeled only from measured charges, and only with the rows it averaged
|
|
139
|
+
cited in the same diff:
|
|
140
|
+
|
|
141
|
+
```bash
|
|
142
|
+
# one row per (adapter, model) reading, append-only
|
|
143
|
+
{"adapter":"fal","model":"fal-ai/ltx-2/text-to-video","modeled":0.16,"charged":0.21,"date":"2026-08-23"}
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
`lint_adapter_tier --cost-diff <base-ref>` **warns** when a manifest's
|
|
147
|
+
`cost_per_second_usd` changed in a diff that adds no ledger row. A warning,
|
|
148
|
+
not a failure: re-modelling an estimate is a legitimate human act. Doing it
|
|
149
|
+
silently *after* a live run measured the real charge is not — that is the
|
|
150
|
+
moment a guess becomes a contradicted measurement.
|
|
151
|
+
|
|
95
152
|
### 6. Operator pick (best-of-N checkpoint)
|
|
96
153
|
|
|
97
154
|
```bash
|
|
@@ -55,6 +55,20 @@ the first missing clip) flags. Reject any other flag — this command
|
|
|
55
55
|
does not render, so `--image-provider` / `--video-provider` are
|
|
56
56
|
contract bugs.
|
|
57
57
|
|
|
58
|
+
**`--mode` and `--xfade` exist on the script and are deliberately not
|
|
59
|
+
reachable from here.** `stitch.sh` now carries `--mode cut|handoff`, and in
|
|
60
|
+
handoff mode an optional `--xfade <s>` (≤ 0.25) at handoff seams. `cut` is the
|
|
61
|
+
default and is byte-identical to the only behaviour this command has ever
|
|
62
|
+
produced. `handoff` **re-encodes** (`libx264 -crf 20 -g 8 +faststart -an`) where
|
|
63
|
+
`cut` stream-copies, so it pays a generation loss and drops audio — a spend-free
|
|
64
|
+
but not cost-free change of the output. Reaching it needs the seam plan that
|
|
65
|
+
`lib/seam-plan.sh` builds from per-scene `continuity:` directives, which this
|
|
66
|
+
command does not read. Passing either flag here is therefore rejected by the
|
|
67
|
+
rule above, and that is the intended answer, not a gap: the continuity path is
|
|
68
|
+
driven from `/video:from-script`, and `--crossfade` remains refused in every
|
|
69
|
+
mode. Port invariants: `docs/contracts/skill-bundled-assets.md` § Port
|
|
70
|
+
invariants.
|
|
71
|
+
|
|
58
72
|
### 4. Stitch
|
|
59
73
|
|
|
60
74
|
```bash
|
|
@@ -11,6 +11,7 @@ before writing or reviewing code); this file is the catalog.
|
|
|
11
11
|
|---|---|
|
|
12
12
|
| `abstraction-thresholds.md` | Per-class extraction-threshold canon (code 2 · UI shell 3+ · stateful component ~4+state · utility-class string ≥3) — the single source every numeric threshold cites (ADR-213) |
|
|
13
13
|
| `code-clarity.md` | Cross-language clarity rules — inline single-use values, carve-outs (side effects, loops, type narrowing, debugger) |
|
|
14
|
+
| `monorepo-antipatterns.md` | Diff-detectable monorepo task-graph anti-patterns (root scripts bypassing the runner, lifecycle-hook sibling builds, `&&`-chained tasks, shared code under `apps/`, `../` in `inputs`, missing `outputs`) plus the classes deliberately not harvested |
|
|
14
15
|
| `component-oriented-and-oop-development.md` | Reuse-first components (FE) + OOP-where-it-reduces-complexity (backend); carve-out index; bounded by the anti-over-engineering anchors |
|
|
15
16
|
|
|
16
17
|
## PHP (`docs/guidelines/php/`)
|
|
@@ -8,10 +8,62 @@ resolution, commit-step pre-scan, halt conditions, and archival check.
|
|
|
8
8
|
The three command files are thin wrappers that bind only the **scope
|
|
9
9
|
delta**.
|
|
10
10
|
|
|
11
|
-
**Size budget:** ≤
|
|
11
|
+
**Size budget:** ≤ 57,000 chars — restated from the original 4,000.
|
|
12
|
+
|
|
13
|
+
The old figure described nothing: the file measured 47,115 bytes against it, a
|
|
14
|
+
factor of 11.8, so it was a dead budget rather than a typo. Restated at the
|
|
15
|
+
measured size rather than split, because splitting a contract this load-bearing
|
|
16
|
+
into referenced fragments is a large change with its own risk, and the step that
|
|
17
|
+
found this asked for hygiene.
|
|
18
|
+
|
|
19
|
+
**Why it moved:** this file is not a page a reader skims but the canonical
|
|
20
|
+
autonomous-execution loop — roadmap discovery, cadence resolution, the step loop,
|
|
21
|
+
the flip-guard, the halt list, the terminal outcomes, and the archival check. The
|
|
22
|
+
original 4,000 was inherited from the sibling context docs (`≤ 3,000`, `≤ 6,000`)
|
|
23
|
+
without asking whether the same shape applied.
|
|
24
|
+
|
|
25
|
+
**Read it as a ratchet, not a target.** A budget that rises whenever the file
|
|
26
|
+
does is not a budget. It may fall; raising it again needs the same kind of note
|
|
27
|
+
as this one.
|
|
28
|
+
|
|
29
|
+
**Nothing enforces this line**, and saying so is the point: no gate reads it, so
|
|
30
|
+
it is a declaration a future edit can falsify exactly as the 4,000 was falsified.
|
|
31
|
+
A true declaration with a stated enforcement boundary is worth more than a false
|
|
32
|
+
one, and less than a check — the same `enforced_by: none` honesty the rules in
|
|
33
|
+
this tree state about their own obligations.
|
|
12
34
|
|
|
13
35
|
## 1. Resolve roadmap
|
|
14
36
|
|
|
37
|
+
### Context probe — unconditionally, before resolving the roadmap
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
agent-config roadmap:context --roadmap <slug> # slug omitted on a bare invocation
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Run it **before resolving the roadmap**, on every invocation, and print its
|
|
44
|
+
report in the pre-run summary (§ 2). Unconditional is the whole point: the live
|
|
45
|
+
merge-state clause below fires only when a message would *describe* a roadmap
|
|
46
|
+
as in-flight or merged, so a run that never makes such a claim has never looked.
|
|
47
|
+
Measured on the population that motivated this: 4 of 24 active roadmaps were
|
|
48
|
+
already closed in an open PR, and 2 of 22 six days later — the same sample
|
|
49
|
+
halved inside a week, which is why the probe re-runs on a cadence (§ 5e) rather
|
|
50
|
+
than once at branch time.
|
|
51
|
+
|
|
52
|
+
The report carries open PRs with the files they change, remote branches carrying
|
|
53
|
+
a roadmap slug, live sessions on both axes, `agents/tmp/` note names, sibling
|
|
54
|
+
roadmaps on the same topic, and roadmap-to-PR file overlap. Two readings act:
|
|
55
|
+
|
|
56
|
+
- **The roadmap is closed in an open PR** → name the PR number and stop. This is
|
|
57
|
+
a **selection error**, not a halt: nothing on the halt list fired, the run
|
|
58
|
+
simply picked work that is already done. It does not touch the halt list and
|
|
59
|
+
it is not a `blocked` outcome.
|
|
60
|
+
- **The roadmap is partially covered by an open PR** → name the PR and continue,
|
|
61
|
+
on a branch cut from `origin/main`. Never rebase onto the foreign branch.
|
|
62
|
+
|
|
63
|
+
Same honesty boundary the probe states in its own header: **the probe is
|
|
64
|
+
deterministic once invoked, and the invocation is model-carried.** Nothing fires
|
|
65
|
+
it and nothing notices when it is skipped.
|
|
66
|
+
|
|
15
67
|
Search both locations:
|
|
16
68
|
|
|
17
69
|
- `agents/roadmaps/*.md` (project root)
|
|
@@ -417,6 +469,34 @@ of [`roadmap-progress-sync`](../../rules/roadmap-progress-sync.md))
|
|
|
417
469
|
forces an immediate regen regardless of cadence. The checkbox flip
|
|
418
470
|
itself is **never** batchable — only the subprocess.
|
|
419
471
|
|
|
472
|
+
### Context refresh — a comparison, not a third cadence key
|
|
473
|
+
|
|
474
|
+
There is **no `roadmap.context_refresh_cadence` setting**, deliberately. The
|
|
475
|
+
refresh trigger is derived:
|
|
476
|
+
|
|
477
|
+
```bash
|
|
478
|
+
agent-config roadmap:context --fingerprint # cheap: one rev-parse + one gh call
|
|
479
|
+
```
|
|
480
|
+
|
|
481
|
+
At every phase boundary (and at run end), take the fingerprint and compare it
|
|
482
|
+
with the one § 1's probe returned. **Differs → re-probe in full** and apply the
|
|
483
|
+
reaction table in § 5e. **Same → nothing moved; continue without paying for a
|
|
484
|
+
probe.** Cache the new value as the run's baseline either way.
|
|
485
|
+
|
|
486
|
+
The fingerprint covers `origin/main` **and the head SHA of every open PR**. The
|
|
487
|
+
second half is the case a `main`-only trigger misses: a peer pushing to their own
|
|
488
|
+
PR branch mid-run can add a file that now overlaps this run's owned paths while
|
|
489
|
+
`origin/main` has not moved at all.
|
|
490
|
+
|
|
491
|
+
Why a comparison and not a knob: `docs/contracts/settings-classes.md` classifies
|
|
492
|
+
a fixed-beat flag as `derivable` — "the mechanism itself can decide, from the
|
|
493
|
+
situation, better than a flag can" — behind a ratchet whose count may only fall.
|
|
494
|
+
A cadence enum was implemented, refused by `lint_settings_classes`, and replaced
|
|
495
|
+
by this; the full reasoning, the options rejected, and what the substitution costs
|
|
496
|
+
are in `agents/evidence/analysis/situational-awareness-cadence-key-decision.md`.
|
|
497
|
+
Turning the refresh off is a one-line revert of this subsection, which is the same
|
|
498
|
+
reversibility a `cadence: off` value would have bought.
|
|
499
|
+
|
|
420
500
|
## 5. Step loop
|
|
421
501
|
|
|
422
502
|
For each open step in the working set (scope-bound — see wrapper):
|
|
@@ -510,6 +590,26 @@ For each open step in the working set (scope-bound — see wrapper):
|
|
|
510
590
|
links the directory. Not a gate: the memo is what makes an
|
|
511
591
|
autonomous resolution reviewable after the fact, which is the
|
|
512
592
|
condition under which it is legitimate at all.
|
|
593
|
+
4b. **Stale-artefact check — a vanished file is never a closed step.**
|
|
594
|
+
|
|
595
|
+
Before flipping anything, check the step's own cited paths against the tree:
|
|
596
|
+
|
|
597
|
+
```
|
|
598
|
+
NEVER MARK STALE WORK COMPLETE JUST BECAUSE IT DISAPPEARED.
|
|
599
|
+
ABSENCE OF THE FILE IS ABSENCE OF EVIDENCE, NOT EVIDENCE OF COMPLETION.
|
|
600
|
+
```
|
|
601
|
+
|
|
602
|
+
Any cited path missing → the step resolves to **`unverified`**: surface it in
|
|
603
|
+
the run report, name the missing path, and flip **no** checkbox. Not `[x]`
|
|
604
|
+
(the evidence cannot be checked), not `[-]` (nobody decided to skip it), not
|
|
605
|
+
`[~]` (nobody deferred it) — the box stays open and the report carries the
|
|
606
|
+
reason. `staleArtefactVerdict` in `roadmap_context.ts` is the predicate.
|
|
607
|
+
|
|
608
|
+
The failure this catches is quiet: "nothing to do here" reads identically to
|
|
609
|
+
"already done", and one of those is a closed step while the other is a lost
|
|
610
|
+
one. A step citing no paths is unaffected — there is nothing to check, and
|
|
611
|
+
inventing a doubt would fire this on every prose step.
|
|
612
|
+
|
|
513
613
|
5. **Atomic flip — same reply, every step.**
|
|
514
614
|
Flip the checkbox in `agents/roadmaps/<file>.md`: `[x]` done ·
|
|
515
615
|
`[~]` partial · `[-]` skipped. **Non-skippable, non-batchable**
|
|
@@ -634,10 +734,46 @@ sibling worktree moved, the dying session finished a step it never recorded),
|
|
|
634
734
|
and the `actual` column is what to resume from. Treating progress as corruption
|
|
635
735
|
would refuse every healthy resume.
|
|
636
736
|
|
|
737
|
+
**The checkpoint carries a repository fingerprint too, not only roadmap counts.**
|
|
738
|
+
`context_fingerprint` is the `roadmap:context --fingerprint` value the dying run
|
|
739
|
+
last held. Every other field on the checkpoint reports **roadmap** drift; none
|
|
740
|
+
reported **repository** drift, so a run resumed after a long gap trusted a context
|
|
741
|
+
reading it never re-took — the exact staleness § 4's refresh exists to end,
|
|
742
|
+
reappearing across the one boundary a mid-run cadence cannot see.
|
|
743
|
+
|
|
744
|
+
A resumed run therefore re-probes and passes the fresh fingerprint into
|
|
745
|
+
`verifyCheckpoint`. A disagreement forces a full re-probe and the § 5e reactions
|
|
746
|
+
**before the first step**. A `null` or absent value on either side reads as *not
|
|
747
|
+
known* and never as a disagreement — the same rule `head` already follows, and for
|
|
748
|
+
the same reason: a false alarm on the field whose job is to say whether anything
|
|
749
|
+
moved trains the reader to skip the line.
|
|
750
|
+
|
|
637
751
|
`agent-config run:supervise --once` reports which runs died with open steps
|
|
638
752
|
left. It never merges, pushes, or closes anything — that boundary is a named
|
|
639
753
|
rejection, not a missing feature.
|
|
640
754
|
|
|
755
|
+
### 5e. Context refresh — four reactions, enumerated and closed
|
|
756
|
+
|
|
757
|
+
At each due point (§ 4 — fingerprint differs) re-probe and act. **These four rows
|
|
758
|
+
are the whole set.** Nothing here is a halt: none of them appears on the halt list
|
|
759
|
+
and none of them is a `blocked` outcome.
|
|
760
|
+
|
|
761
|
+
| # | What the refresh found | Reaction |
|
|
762
|
+
|---|---|---|
|
|
763
|
+
| a | A PR touching my owned paths **merged** since the last refresh | Run `sync_pr_branch` now — already the documented resolution, only push-bound until this row existed. Re-read the current step's files, continue. |
|
|
764
|
+
| b | An **open** PR touches my owned paths | Continue. Name the collision in the PR description and in the final report. **Never rebase onto a foreign branch.** |
|
|
765
|
+
| c | A peer session shows `PATH OVERLAP` | Take disjoint steps first if ordering allows; otherwise name it and continue. The register is advisory, never a lock. |
|
|
766
|
+
| d | The roadmap itself was **archived on `origin/main`** | Stop. The same **selection error** as § 1, detected late — not a halt, and no checkbox is flipped to reach it. |
|
|
767
|
+
|
|
768
|
+
Deliberately NOT a drift-level taxonomy. A severity ladder over these four would
|
|
769
|
+
invite a fifth row for every new shape of surprise, and the value here is that the
|
|
770
|
+
set is closed: an agent that meets something outside it has met an ordinary step,
|
|
771
|
+
not a new reaction.
|
|
772
|
+
|
|
773
|
+
Row (a) is the one that changes behaviour mid-run rather than only reporting. Rows
|
|
774
|
+
(b) and (c) exist to make the collision **visible in the artefact** — a run that
|
|
775
|
+
silently produces a conflicting PR has spent the reviewer's time, not its own.
|
|
776
|
+
|
|
641
777
|
### Halt conditions
|
|
642
778
|
|
|
643
779
|
- Hard-Floor trigger ([`non-destructive-by-default`](../../rules/non-destructive-by-default.md))
|
|
@@ -681,14 +817,30 @@ setting, pushing, opening a PR, re-running CI, updating a merge base, fixing a
|
|
|
681
817
|
test, spending inside a budget — the agent can do all of it. That is remediation
|
|
682
818
|
work, and a `process-full` invocation grants it.
|
|
683
819
|
|
|
684
|
-
|
|
820
|
+
Four outcomes, and only one of them is success:
|
|
685
821
|
|
|
686
822
|
| Outcome | When | What it reports |
|
|
687
823
|
|---|---|---|
|
|
688
824
|
| `complete` | `count_open == 0` and the PR is open | the roadmap is finished; archival check runs (§ 6) |
|
|
689
825
|
| `blocked` | every remaining open step is **externally impossible** for the agent | the work that DID close, plus the specific impossibility |
|
|
826
|
+
| `superseded` | the remaining work **already landed** on `origin/main`, in a merged PR | which steps the tree already satisfies, with the PR number and the evidence per step |
|
|
690
827
|
| a halt | one of the five conditions above fired | the halt, its evidence, and what remains |
|
|
691
828
|
|
|
829
|
+
**Why `superseded` is here and not on the halt list.** A run that meets a merged
|
|
830
|
+
PR which already closed its remaining steps had, until this row existed, no legal
|
|
831
|
+
move: *"let the open PRs merge first"* is a forbidden non-halt reason below, the
|
|
832
|
+
halt list calls itself exhaustive, and neither `complete` nor `blocked` is true —
|
|
833
|
+
the work is done and it was not externally impossible. The only two available
|
|
834
|
+
actions were a rule violation or duplicate work. This row is the third.
|
|
835
|
+
|
|
836
|
+
It is a **report**, not a licence to flip anything. Marking a step the tree
|
|
837
|
+
already closed is a separate, deliberately unbuilt mechanism: it needs the step's
|
|
838
|
+
own `verify:` green against `origin/main`, a decision memo, and a one-strike kill
|
|
839
|
+
criterion, and an autonomous run writing a completion marker into the source of
|
|
840
|
+
truth is not switched on unasked. Until it is, `superseded` reports and the boxes
|
|
841
|
+
stay open — the same discipline the `[~]` prohibition below enforces for
|
|
842
|
+
`blocked`.
|
|
843
|
+
|
|
692
844
|
`blocked-preflight` **no longer exists** (ADR-237 § 4). A run always starts.
|
|
693
845
|
|
|
694
846
|
```
|
|
@@ -17,7 +17,7 @@ routes_to:
|
|
|
17
17
|
workspaces: [engineering]
|
|
18
18
|
packs: [engineering-base]
|
|
19
19
|
enforced_by:
|
|
20
|
-
- "
|
|
20
|
+
- "instruction-only: the note, the ask and the user decision are all prose, so no gate can tell a discharged issue from a mentioned one"
|
|
21
21
|
collision_ok:
|
|
22
22
|
"refactor": "an explicit clean-up/refactor ask is the remediation ladder's own trigger"
|
|
23
23
|
# obligation: line 31
|
|
@@ -97,11 +97,11 @@ While implementing/modifying code you pass an issue outside the literal task. Al
|
|
|
97
97
|
- The issue is the task itself — then it's just the task (no ladder needed).
|
|
98
98
|
- The user already decided this item (fixed later, or explicitly ignored).
|
|
99
99
|
|
|
100
|
-
## Honest enforcement — `
|
|
100
|
+
## Honest enforcement — `instruction-only`
|
|
101
101
|
|
|
102
102
|
The note, the ask and the user's decision are all prose, and the issue set is
|
|
103
103
|
whatever the agent happened to see, so no gate can tell a discharged issue from a
|
|
104
|
-
mentioned one. This rule ships `
|
|
104
|
+
mentioned one. This rule ships `instruction-only` — the honesty boundary
|
|
105
105
|
[`security-sensitive-stop`](security-sensitive-stop.md) and
|
|
106
106
|
[`ui-audit-gate`](ui-audit-gate.md) state for their own obligations. The ladder
|
|
107
107
|
is the control; skipping it is caught by nothing.
|
|
@@ -22,7 +22,7 @@ workspaces: [engineering]
|
|
|
22
22
|
packs: [engineering-base]
|
|
23
23
|
roles: [developer, reviewer, tester, po, incident, planner]
|
|
24
24
|
enforced_by:
|
|
25
|
-
- "
|
|
25
|
+
- "instruction-only: close-the-source-and-re-derive is a pre-write reasoning step only the model observes; CI checks the ledger, never the derivation"
|
|
26
26
|
# obligation: line 40
|
|
27
27
|
obligation_frequency: "per-edit"
|
|
28
28
|
---
|
|
@@ -129,7 +129,7 @@ checks the ledger's own records, not similarity, and cannot catch an
|
|
|
129
129
|
unrecorded borrow. The discipline above **is** the control; skipping it is
|
|
130
130
|
not caught downstream by anything automatic. No script can enforce "close
|
|
131
131
|
the source and re-derive" — a pre-write reasoning step only the model
|
|
132
|
-
observes — so this rule ships `
|
|
132
|
+
observes — so this rule ships `instruction-only`, same honesty stance as
|
|
133
133
|
`security-sensitive-stop` and `untrusted-input-defense`.
|
|
134
134
|
|
|
135
135
|
`lint_harvest_provenance.ts` stands in exactly the same relation to the
|