@event4u/agent-config 16.1.0 → 16.3.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 +98 -257
- package/README.md +14 -12
- package/dist/agent-src/commands/analyze/inbox.md +1 -1
- package/dist/agent-src/commands/analyze/roadmap-repos.md +1 -1
- package/dist/agent-src/commands/bug/fix.md +17 -2
- package/dist/agent-src/commands/feature/plan.md +1 -1
- package/dist/agent-src/commands/feature/roadmap.md +1 -1
- package/dist/agent-src/commands/fix/ci.md +1 -1
- package/dist/agent-src/commands/implement-ticket.md +1 -1
- package/dist/agent-src/commands/jira-ticket.md +1 -1
- package/dist/agent-src/commands/roadmap/create.md +1 -1
- package/dist/agent-src/commands/roadmap/materialize.md +1 -1
- package/dist/agent-src/commands/roadmap/process-full.md +5 -5
- package/dist/agent-src/commands/roadmap/resolve-blockers.md +361 -0
- package/dist/agent-src/commands/roadmap/triage-parked.md +325 -0
- package/dist/agent-src/commands/roadmap.md +18 -4
- package/dist/agent-src/commands/tests/create.md +17 -3
- package/dist/agent-src/commands/tests/execute.md +22 -5
- package/dist/agent-src/commands/work.md +4 -0
- package/dist/agent-src/contexts/authority/decision-revisit-gate-enforcement.md +43 -0
- package/dist/agent-src/contexts/communication/rules-auto/design-fidelity-enforcement.md +24 -0
- package/dist/agent-src/contexts/execution/auto-dispatch-classification.md +6 -6
- package/dist/agent-src/contexts/execution/autonomy-mechanics.md +4 -8
- package/dist/agent-src/contexts/execution/roadmap-process-loop.md +32 -2
- package/dist/agent-src/contexts/execution/session-canary-enforcement-history.md +67 -0
- package/dist/agent-src/contexts/execution/toolchain-resolver.md +101 -7
- package/dist/agent-src/rules/active-remediation.md +1 -1
- package/dist/agent-src/rules/autonomous-execution.md +1 -0
- package/dist/agent-src/rules/broken-access-control.md +1 -0
- package/dist/agent-src/rules/command-suggestion-policy.md +1 -0
- package/dist/agent-src/rules/context-hygiene.md +1 -1
- package/dist/agent-src/rules/decision-revisit-gate.md +16 -33
- package/dist/agent-src/rules/design-fidelity.md +13 -16
- package/dist/agent-src/rules/doc-screenshot-hygiene.md +1 -0
- package/dist/agent-src/rules/domain-safety-disclaimer.md +1 -0
- package/dist/agent-src/rules/domain-safety-pii.md +1 -0
- package/dist/agent-src/rules/domain-safety-retention.md +1 -0
- package/dist/agent-src/rules/engineering-safety-floor.md +1 -0
- package/dist/agent-src/rules/evaluator-independence.md +3 -2
- package/dist/agent-src/rules/fast-path-marker-visibility.md +1 -0
- package/dist/agent-src/rules/finance-safety-floor.md +1 -0
- package/dist/agent-src/rules/git-history-discipline.md +1 -0
- package/dist/agent-src/rules/image-likeness-and-rights.md +1 -0
- package/dist/agent-src/rules/legal-safety-floor.md +3 -2
- package/dist/agent-src/rules/lethal-trifecta-guard.md +1 -0
- package/dist/agent-src/rules/low-impact-corpus-privacy-floor.md +1 -0
- package/dist/agent-src/rules/media-governance-routing.md +14 -17
- package/dist/agent-src/rules/persona-governance.md +2 -2
- package/dist/agent-src/rules/provider-lifecycle-discipline.md +1 -1
- package/dist/agent-src/rules/question-not-instruction.md +1 -0
- package/dist/agent-src/rules/roadmap-progress-sync.md +1 -1
- package/dist/agent-src/rules/runtime-safety.md +1 -0
- package/dist/agent-src/rules/secret-vcs-guard.md +1 -0
- package/dist/agent-src/rules/security-sensitive-stop.md +3 -2
- package/dist/agent-src/rules/session-canary.md +8 -62
- package/dist/agent-src/rules/settings-ask-protocol.md +1 -0
- package/dist/agent-src/rules/source-confidentiality.md +1 -0
- package/dist/agent-src/rules/strategy-safety-floor.md +1 -0
- package/dist/agent-src/rules/tool-safety.md +1 -0
- package/dist/agent-src/rules/ui-audit-gate.md +1 -2
- package/dist/agent-src/rules/untrusted-input-defense.md +1 -0
- package/dist/agent-src/rules/user-interrupt-priority.md +1 -0
- package/dist/agent-src/scripts/archive_completed_roadmaps.ts +115 -20
- package/dist/agent-src/scripts/deferral_carry.ts +339 -0
- package/dist/agent-src/scripts/update_roadmap_progress.ts +4 -1
- package/dist/agent-src/skills/accessibility-auditor/data/aria-patterns.csv +1 -1
- package/dist/agent-src/skills/accessibility-auditor/data/manifest.json +2 -2
- package/dist/agent-src/skills/api-design/data/manifest.json +2 -2
- package/dist/agent-src/skills/api-testing/SKILL.md +17 -0
- package/dist/agent-src/skills/code-intelligence/SKILL.md +14 -2
- package/dist/agent-src/skills/design-review/SKILL.md +30 -4
- package/dist/agent-src/skills/design-review/references/verification-automation.md +32 -0
- package/dist/agent-src/skills/design-system-capture/references/import-procedure.md +1 -1
- package/dist/agent-src/skills/existing-ui-audit/SKILL.md +18 -3
- package/dist/agent-src/skills/existing-ui-audit/references/component-taxonomy-detection.md +56 -0
- package/dist/agent-src/skills/fe-design/SKILL.md +1 -1
- package/dist/agent-src/skills/iconography/SKILL.md +1 -1
- package/dist/agent-src/skills/js-library-packaging/SKILL.md +2 -2
- package/dist/agent-src/skills/markitdown/SKILL.md +4 -0
- package/dist/agent-src/skills/monorepo-workspace/SKILL.md +1 -1
- package/dist/agent-src/skills/playwright-testing/SKILL.md +30 -6
- package/dist/agent-src/skills/quality-tools/SKILL.md +11 -1
- package/dist/agent-src/skills/quality-tools/references/go-tools.md +76 -0
- package/dist/agent-src/skills/quality-tools/references/python-tools.md +104 -0
- package/dist/agent-src/skills/review-routing/SKILL.md +2 -2
- package/dist/agent-src/skills/skill-improvement-pipeline/SKILL.md +1 -1
- package/dist/agent-src/skills/storybook-workshop/SKILL.md +3 -3
- package/dist/agent-src/skills/tailwind-engineer/SKILL.md +1 -1
- package/dist/agent-src/skills/test-case-discovery/SKILL.md +7 -0
- package/dist/agent-src/skills/test-driven-development/SKILL.md +17 -0
- package/dist/agent-src/skills/test-performance/SKILL.md +19 -1
- package/dist/agent-src/skills/ui-component-architect/SKILL.md +25 -2
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
- package/dist/agent-src/templates/roadmaps.md +30 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/app_spec.ts +10 -4
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +302 -21
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/audit.ts +22 -3
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/scaffold.ts +6 -1
- package/dist/agent-src/templates/scripts/work_engine/stack/runner.ts +774 -109
- package/dist/agent-src/templates/scripts/work_engine/state.ts +57 -7
- package/dist/agent-src/templates/scripts/work_engine/taxonomy/detect.ts +500 -0
- package/dist/agent-src/templates/scripts/work_engine/taxonomy/place.ts +183 -0
- package/dist/cli/python/knowledge_ingest.js +1 -1
- package/dist/cli/python/workspace_drive.js +1 -1
- package/dist/cli/registry.js +1 -1
- package/dist/cli-delegate/archive_completed_roadmaps.js +92 -12
- package/dist/cli-delegate/check_update_banner.js +12 -1
- package/dist/cli-delegate/chunk-523HCFYO.js +90 -0
- package/dist/cli-delegate/{chunk-M2DPGFZ4.js → chunk-6V6TA25H.js} +22 -152
- package/dist/cli-delegate/chunk-7IQE3D5S.js +191 -0
- package/dist/cli-delegate/{chunk-6KFEC3G7.js → chunk-CQWX336L.js} +1 -1
- package/dist/cli-delegate/chunk-DEIV7XP7.js +108 -0
- package/dist/cli-delegate/chunk-EEHDXSYD.js +2040 -0
- package/dist/cli-delegate/{chunk-P6ZHP5W2.js → chunk-GKE7ZVFA.js} +4 -4
- package/dist/cli-delegate/chunk-JQOM7TTM.js +1201 -0
- package/dist/cli-delegate/{chunk-UNCRJBT3.js → chunk-JQVYKIZA.js} +41 -0
- package/dist/cli-delegate/{chunk-FC75PGJE.js → chunk-JY2I2DXV.js} +12 -1
- package/dist/cli-delegate/chunk-KB5FZ655.js +208 -0
- package/dist/cli-delegate/{chunk-YUM5KURG.js → chunk-KR6EM23A.js} +235 -1455
- package/dist/cli-delegate/{chunk-LTYVIY76.js → chunk-LIYTLH6O.js} +1 -1
- package/dist/cli-delegate/chunk-NQ7WT43P.js +2729 -0
- package/dist/cli-delegate/chunk-NXEILF2K.js +2160 -0
- package/dist/cli-delegate/{chunk-5R7HOLAF.js → chunk-NYX3L2PZ.js} +1 -1
- package/dist/cli-delegate/{chunk-4E2W63DA.js → chunk-OKJUIAPS.js} +62 -1
- package/dist/cli-delegate/{chunk-QAJS5YWY.js → chunk-PHD7OOLE.js} +2 -1
- package/dist/cli-delegate/{chunk-RGNIWTEA.js → chunk-QLDHIPWR.js} +1 -1
- package/dist/cli-delegate/{chunk-HDVVGPQW.js → chunk-RQNNW7IF.js} +1405 -567
- package/dist/cli-delegate/{chunk-S3VFXMTM.js → chunk-S4UMZNES.js} +1 -1
- package/dist/cli-delegate/{chunk-6KM6ORRY.js → chunk-S4YWNRKO.js} +24 -8
- package/dist/cli-delegate/{chunk-GJCBB2UG.js → chunk-TRI6DQZ6.js} +3054 -325
- package/dist/cli-delegate/chunk-ULQRUR23.js +208 -0
- package/dist/cli-delegate/{chunk-NUHLI2RX.js → chunk-YCU3TIXH.js} +2 -0
- package/dist/cli-delegate/chunk-ZBZV2G5R.js +210 -0
- package/dist/cli-delegate/{chunk-WGXTVKCQ.js → chunk-ZUZKZYCN.js} +5 -3
- 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 +1862 -809
- package/dist/cli-delegate/cmd_doctor.js +13 -6
- package/dist/cli-delegate/cmd_doctor_neighbours.js +23 -0
- package/dist/cli-delegate/cmd_explain.js +5 -5
- package/dist/cli-delegate/cmd_export.js +11 -8
- package/dist/cli-delegate/cmd_fleet.js +3 -3
- package/dist/cli-delegate/cmd_handoff.js +10 -7
- package/dist/cli-delegate/cmd_mcp_available.js +1 -1
- package/dist/cli-delegate/cmd_memory_get.js +3 -1
- package/dist/cli-delegate/cmd_migrate.js +2 -2
- package/dist/cli-delegate/cmd_packs_active.js +3 -3
- package/dist/cli-delegate/cmd_preflight.js +6 -6
- package/dist/cli-delegate/cmd_prune.js +11 -8
- package/dist/cli-delegate/cmd_refresh.js +2 -1
- package/dist/cli-delegate/cmd_route_audit.js +8 -6
- package/dist/cli-delegate/cmd_route_explain.js +4 -4
- package/dist/cli-delegate/cmd_session_recycle.js +4 -3
- package/dist/cli-delegate/cmd_settings_get.js +1 -1
- package/dist/cli-delegate/cmd_settings_migrate.js +11 -8
- package/dist/cli-delegate/cmd_settings_set.js +4 -4
- package/dist/cli-delegate/cmd_sync.js +11 -8
- package/dist/cli-delegate/cmd_uninstall.js +11 -8
- package/dist/cli-delegate/cmd_update.js +1 -1
- package/dist/cli-delegate/cmd_upgrade.js +3 -2
- package/dist/cli-delegate/cmd_validate.js +11 -8
- package/dist/cli-delegate/cmd_versions.js +1 -1
- package/dist/cli-delegate/deferral_carry.js +16 -0
- package/dist/cli-delegate/gate_execute.js +2 -2
- package/dist/cli-delegate/roadmap_gates.js +5 -5
- package/dist/cli-delegate/update_roadmap_progress.js +1 -1
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +132 -80
- 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 +7 -5
- package/dist/discovery/trust-report.md +2 -2
- package/dist/discovery/workspaces.json +6 -4
- package/dist/hooks/dispatch.js +7972 -5186
- package/dist/hooks/dispatch.sha256 +1 -0
- package/dist/install/claudePathsPlan.js +47 -6
- package/dist/install/claudeRuleRewrite.js +7 -0
- package/dist/install/emit_host_rules_cli.js +39 -36
- package/dist/install/globalRuleScope.js +87 -0
- package/dist/install/host_rule_ownership.js +160 -0
- package/dist/install/install.mjs +2226 -1055
- package/dist/install/installThinLayer.js +261 -0
- package/dist/install/installedRuleLinks.js +176 -0
- package/dist/install/wizard-plan.js +24 -0
- package/dist/mcp/registry-manifest.json +3 -3
- package/dist/mcp/server.json +2 -2
- package/dist/mcp/server.mjs +40913 -34865
- package/dist/scripts/_lib/agent_settings.js +11 -0
- package/dist/scripts/_lib/claude_settings_hooks.js +10 -8
- package/dist/scripts/_lib/installed_layer.js +378 -0
- package/dist/scripts/_lib/lean_projection_mode.js +218 -15
- package/dist/scripts/_lib/rule_consequence_class.js +45 -0
- package/dist/scripts/_lib/rule_injection.js +67 -10
- package/dist/scripts/_lib/rule_law_section.js +122 -0
- package/dist/scripts/_lib/thin_rules.js +458 -0
- package/dist/scripts/_lib/windsurf_render.js +60 -0
- package/dist/scripts/condense.js +14 -26
- package/dist/scripts/project_thin_rules.js +14 -294
- package/dist/server/schemas/settings.js +29 -0
- package/dist/shared/skillRanking.js +74 -13
- package/dist/ui/assets/index-Cwq4d0hX.js +23 -0
- package/dist/ui/assets/index-Cyjy8bWO.css +1 -0
- package/dist/ui/index.html +2 -2
- package/docs/contracts/settings-classes.md +10 -6
- package/package.json +4 -4
- package/src/agent-src/scripts/archive_completed_roadmaps.ts +115 -20
- package/src/agent-src/scripts/deferral_carry.ts +339 -0
- package/src/agent-src/scripts/update_roadmap_progress.ts +4 -1
- package/src/agent-src/templates/scripts/work_engine/directives/ui/app_spec.ts +10 -4
- package/src/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +302 -21
- package/src/agent-src/templates/scripts/work_engine/directives/ui/audit.ts +22 -3
- package/src/agent-src/templates/scripts/work_engine/directives/ui/scaffold.ts +6 -1
- package/src/agent-src/templates/scripts/work_engine/stack/runner.ts +774 -109
- package/src/agent-src/templates/scripts/work_engine/state.ts +57 -7
- package/src/agent-src/templates/scripts/work_engine/taxonomy/detect.ts +500 -0
- package/src/agent-src/templates/scripts/work_engine/taxonomy/place.ts +183 -0
- package/src/config/agent-settings.template.yml +91 -22
- package/src/config/ci-local-parity.yml +18 -0
- package/src/config/continuity-surface.json +9 -2
- package/src/config/evaluator-budgets.json +4 -4
- package/src/config/gate-coverage.yml +327 -3
- package/src/config/gate-violation-baselines.json +21 -9
- package/src/config/hook-bundle-budget.json +25 -0
- package/src/config/hook-latency-budget.json +21 -0
- package/src/config/hook-token-budget.json +8 -3
- package/src/config/host-instruction-limits.json +33 -0
- package/src/config/metric-registry.yml +114 -0
- package/src/config/placeholder-drift-budget.json +10 -0
- package/src/config/routing-coverage-seed.json +38 -3
- package/src/config/rule-activation-census.json +7 -3
- package/src/config/rule-consequence-class.json +161 -0
- package/src/config/rule-law-ceilings.json +99 -0
- package/src/install/claudePathsPlan.ts +46 -4
- package/src/install/claudeRuleRewrite.ts +10 -1
- package/src/install/emit_host_rules_cli.ts +43 -34
- package/src/install/globalRuleScope.ts +109 -0
- package/src/install/host_rule_ownership.ts +170 -0
- package/src/install/installThinLayer.ts +312 -0
- package/src/install/installedRuleLinks.ts +220 -0
- package/src/install/wizard-plan.ts +24 -0
- package/src/scripts/_cli/cmd_doctor.ts +28 -90
- package/src/scripts/_cli/cmd_doctor_neighbours.ts +293 -0
- package/src/scripts/_cli/doctor_execution.ts +100 -17
- package/src/scripts/_cli/doctor_network_posture.ts +226 -0
- package/src/scripts/_dispatch.bash +16 -2
- package/src/scripts/_lib/agent_settings.ts +11 -0
- package/src/scripts/_lib/body_portable.ts +102 -0
- package/src/scripts/_lib/cc_transcript.ts +132 -1
- package/src/scripts/_lib/claude_settings_hooks.ts +10 -8
- package/src/scripts/_lib/concern_sla_window.ts +200 -0
- package/src/scripts/_lib/estate_offsets.ts +241 -0
- package/src/scripts/_lib/exemption_shape.ts +143 -0
- package/src/scripts/_lib/fnv.ts +23 -0
- package/src/scripts/_lib/foreign_scan.ts +106 -0
- package/src/scripts/_lib/forge_protection.ts +114 -0
- package/src/scripts/_lib/forge_reader.ts +558 -0
- package/src/scripts/_lib/gitignore_block.ts +314 -0
- package/src/scripts/_lib/global_deploy_inventory.ts +32 -0
- package/src/scripts/_lib/graph_feeder_record.ts +214 -0
- package/src/scripts/_lib/hook_settings.ts +73 -0
- package/src/scripts/_lib/host_capability.ts +40 -19
- package/src/scripts/_lib/host_env_write.ts +111 -0
- package/src/scripts/_lib/host_hook_merge.ts +165 -0
- package/src/scripts/_lib/installed_layer.ts +538 -0
- package/src/scripts/_lib/json_merge.ts +82 -0
- package/src/scripts/_lib/json_pointers.ts +93 -11
- package/src/scripts/_lib/lean_projection_mode.ts +275 -15
- package/src/scripts/_lib/llm_proposer_transport.ts +14 -4
- package/src/scripts/_lib/machine_wake.ts +16 -3
- package/src/scripts/_lib/neighbour_census.ts +760 -0
- package/src/scripts/_lib/neighbour_scan.ts +122 -0
- package/src/scripts/_lib/neighbour_tool_use.ts +189 -0
- package/src/scripts/_lib/obligations.ts +119 -8
- package/src/scripts/_lib/probe_inputs.ts +271 -0
- package/src/scripts/_lib/prompt_shape.ts +46 -0
- package/src/scripts/_lib/read_surface_scan.ts +322 -0
- package/src/scripts/_lib/release_highlights.ts +2 -1
- package/src/scripts/_lib/release_migration_gate.ts +19 -3
- package/src/scripts/_lib/reserved_name_sweep.ts +73 -0
- package/src/scripts/_lib/retrieval_sanitize.ts +77 -16
- package/src/scripts/_lib/review_coverage.ts +134 -0
- package/src/scripts/_lib/rule_consequence_class.ts +71 -0
- package/src/scripts/_lib/rule_injection.ts +130 -10
- package/src/scripts/_lib/rule_law_section.ts +147 -0
- package/src/scripts/_lib/rule_layer_overlap.ts +58 -0
- package/src/scripts/_lib/shell_write_shapes.ts +108 -0
- package/src/scripts/_lib/skill_origin.ts +254 -0
- package/src/scripts/_lib/structural_hiding.ts +622 -0
- package/src/scripts/_lib/structured_ask.ts +64 -21
- package/src/scripts/_lib/thin_rules.ts +540 -0
- package/src/scripts/_lib/touched_file_quality.ts +434 -0
- package/src/scripts/_lib/turn_end_refusals.ts +600 -4
- package/src/scripts/_lib/turn_end_transcript.ts +216 -0
- package/src/scripts/_lib/verification_command.ts +324 -0
- package/src/scripts/_lib/verification_evidence.ts +647 -0
- package/src/scripts/_lib/verify_clause.ts +280 -0
- package/src/scripts/_lib/windsurf_render.ts +63 -0
- package/src/scripts/ai_council/cli_call_budget.ts +13 -5
- package/src/scripts/ai_council/clients.ts +26 -57
- package/src/scripts/ai_council/config.ts +1 -1
- package/src/scripts/ai_council/vendor_defaults.ts +45 -0
- package/src/scripts/ai_team/team_dispatch.ts +4 -0
- package/src/scripts/audit_skill_overlap.ts +261 -0
- package/src/scripts/before_complete_hook.ts +573 -25
- package/src/scripts/bench_hook_latency.ts +412 -5
- package/src/scripts/bench_touched_file_quality.ts +238 -0
- package/src/scripts/cache_realization_report.ts +61 -1
- package/src/scripts/check_argument_hint.ts +287 -0
- package/src/scripts/check_claims.ts +125 -1
- package/src/scripts/check_enforcement_coverage.ts +38 -9
- package/src/scripts/check_enforcement_matrix.ts +621 -22
- package/src/scripts/check_estate_count.ts +130 -153
- package/src/scripts/check_finding_dispositions.ts +138 -7
- package/src/scripts/check_generator_sync.ts +71 -0
- package/src/scripts/check_hook_bundle_composition.ts +370 -0
- package/src/scripts/check_host_docs_digest.ts +786 -0
- package/src/scripts/check_host_format_column.ts +559 -0
- package/src/scripts/check_input_references.ts +228 -0
- package/src/scripts/check_inputs_parity.ts +235 -0
- package/src/scripts/check_kernel_edit_ratified.ts +89 -9
- package/src/scripts/check_kill_switch_table.ts +294 -0
- package/src/scripts/check_memory.ts +7 -1
- package/src/scripts/check_placeholder_drift.ts +221 -0
- package/src/scripts/check_read_surface_coverage.ts +515 -0
- package/src/scripts/check_release_highlights.ts +10 -0
- package/src/scripts/check_release_holds.ts +2 -1
- package/src/scripts/check_release_pr_shape.ts +38 -15
- package/src/scripts/check_routing_coverage.ts +378 -11
- package/src/scripts/check_standing_rule_delivery.ts +33 -13
- package/src/scripts/check_static_parity.ts +17 -0
- package/src/scripts/check_verify_expectation_delta.ts +521 -0
- package/src/scripts/ci_settle.ts +145 -19
- package/src/scripts/closure_scan.ts +115 -1
- package/src/scripts/code_graph/detect.ts +127 -7
- package/src/scripts/code_graph/foreign.ts +194 -0
- package/src/scripts/code_graph/query.ts +217 -4
- package/src/scripts/code_graph/types.ts +26 -2
- package/src/scripts/code_graph/validate.ts +3 -1
- package/src/scripts/code_graph/verbs.ts +103 -0
- package/src/scripts/compile_hook_manifest.ts +90 -14
- package/src/scripts/condense.ts +14 -27
- package/src/scripts/estate_exemption_shape.ts +202 -0
- package/src/scripts/external_sources_denylist.json +29 -4
- package/src/scripts/generate_host_cost_table.ts +1 -1
- package/src/scripts/hook_manifest.json +1 -1
- package/src/scripts/hook_manifest.yaml +192 -14
- package/src/scripts/hooks/block_config_weakening.ts +294 -4
- package/src/scripts/hooks/block_kernel_rule_writes.ts +9 -78
- package/src/scripts/hooks/block_plumbing_writes.ts +342 -0
- package/src/scripts/hooks/bundle_integrity.ts +291 -0
- package/src/scripts/hooks/chain_nudge_hook.ts +1 -2
- package/src/scripts/hooks/code_graph_context_hook.ts +253 -25
- package/src/scripts/hooks/comment_discipline_hook.ts +1 -3
- package/src/scripts/hooks/concern_failure_policy.ts +280 -0
- package/src/scripts/hooks/concern_registry.ts +2 -0
- package/src/scripts/hooks/concern_timings.ts +94 -0
- package/src/scripts/hooks/delegation_nudge_hook.ts +1 -2
- package/src/scripts/hooks/design_pass_hook.ts +100 -9
- package/src/scripts/hooks/design_slop_hook.ts +1 -2
- package/src/scripts/hooks/dispatch_hook.ts +77 -71
- package/src/scripts/hooks/edit_shape_hook.ts +1 -2
- package/src/scripts/hooks/end_review_nudge_hook.ts +1 -1
- package/src/scripts/hooks/evidence_independence.ts +1 -2
- package/src/scripts/hooks/exit_codes.ts +129 -0
- package/src/scripts/hooks/host_lowering.json +1 -0
- package/src/scripts/hooks/host_lowering.ts +146 -3
- package/src/scripts/hooks/host_lowering.yaml +262 -46
- package/src/scripts/hooks/host_semantics.ts +30 -2
- package/src/scripts/hooks/injection_budget.ts +9 -2
- package/src/scripts/hooks/interruption_ledger_hook.ts +1 -2
- package/src/scripts/hooks/journal_record_hook.ts +1 -2
- package/src/scripts/hooks/memory_recall_hook.ts +1 -2
- package/src/scripts/hooks/obligation_settle_hook.ts +151 -5
- package/src/scripts/hooks/one_question_per_ask_hook.ts +43 -6
- package/src/scripts/hooks/orchestration_record_hook.ts +1 -2
- package/src/scripts/hooks/payload_stub.ts +10 -1
- package/src/scripts/hooks/permission_gate.ts +1 -2
- package/src/scripts/hooks/push_settle_hook.ts +1 -3
- package/src/scripts/hooks/replay_hook.ts +2 -1
- package/src/scripts/hooks/reread_guard_hook.ts +1 -2
- package/src/scripts/hooks/review_baseline_hook.ts +1 -2
- package/src/scripts/hooks/rtk_wrap_hook.ts +1 -2
- package/src/scripts/hooks/rule_inject_hook.ts +765 -68
- package/src/scripts/hooks/run_continuation_hook.ts +13 -15
- package/src/scripts/hooks/skill_route_hook.ts +1 -2
- package/src/scripts/hooks/source_first_gate_hook.ts +1 -2
- package/src/scripts/hooks/spawn_guard_shadow_hook.ts +1 -2
- package/src/scripts/hooks/subagent_ledger_hook.ts +1 -2
- package/src/scripts/hooks/suggestion_capture_hook.ts +1 -1
- package/src/scripts/hooks/table_fingerprint.ts +70 -0
- package/src/scripts/hooks/telemetry_flush_hook.ts +1 -2
- package/src/scripts/hooks/telemetry_usage_hook.ts +65 -10
- package/src/scripts/hooks/tool_result_bytes_hook.ts +93 -9
- package/src/scripts/hooks/turn_end_gate_hook.ts +421 -324
- package/src/scripts/hooks/ui_route_nudge_hook.ts +1 -2
- package/src/scripts/hooks_status.ts +112 -0
- package/src/scripts/injection_scan_hook.ts +7 -0
- package/src/scripts/install.ts +75 -189
- package/src/scripts/installed_layer_report.ts +103 -0
- package/src/scripts/language_mirror_hook.ts +15 -6
- package/src/scripts/learning_sidecar.ts +119 -8
- package/src/scripts/lint_deny_text.ts +419 -0
- package/src/scripts/lint_exit_codes.ts +262 -0
- package/src/scripts/lint_hook_manifest.ts +108 -0
- package/src/scripts/lint_major_migration_sections.ts +156 -26
- package/src/scripts/lint_pack_boundaries.ts +63 -5
- package/src/scripts/lint_roadmap_blockers.ts +78 -12
- package/src/scripts/lint_rule_law_section.ts +517 -0
- package/src/scripts/lint_skill_descriptions.ts +1 -1
- package/src/scripts/lint_skill_scripts_readonly.ts +1 -1
- package/src/scripts/lint_workflow_security.ts +161 -5
- package/src/scripts/mcp_server/consumer_tool_catalog.json +53 -0
- package/src/scripts/mcp_server/graph_tools.ts +72 -3
- package/src/scripts/mcp_server/prompts.ts +142 -1
- package/src/scripts/measure_routing_signal.ts +54 -16
- package/src/scripts/measure_skill_ranker_baseline.ts +515 -53
- package/src/scripts/measure_turn_end_gate.ts +193 -0
- package/src/scripts/memory_learn_hook.ts +91 -6
- package/src/scripts/memory_lookup.ts +1 -1
- package/src/scripts/model_rule_injection.ts +52 -5
- package/src/scripts/prepack-check.mjs +53 -0
- package/src/scripts/project_thin_rules.ts +34 -327
- package/src/scripts/release_publication.ts +13 -1
- package/src/scripts/report_evidence_temperature.ts +657 -0
- package/src/scripts/report_installed_rule_links.ts +157 -0
- package/src/scripts/report_invocation_surface.ts +383 -0
- package/src/scripts/report_label_agreement.ts +233 -0
- package/src/scripts/report_obligation_carriers.ts +699 -0
- package/src/scripts/report_obligation_mechanism.ts +230 -0
- package/src/scripts/report_obligation_writer_split.ts +236 -0
- package/src/scripts/report_single_token_triggers.ts +277 -0
- package/src/scripts/report_skill_menu_census.ts +208 -0
- package/src/scripts/report_skill_ranker_confusion.ts +442 -0
- package/src/scripts/report_standing_payload_by_host.ts +188 -15
- package/src/scripts/report_verification_record_coverage.ts +306 -0
- package/src/scripts/roadmap_verify_share.ts +213 -0
- package/src/scripts/rule_activation_census.ts +5 -2
- package/src/scripts/rule_trigger_eval.ts +9 -9
- package/src/scripts/schemas/command.schema.json +44 -0
- package/src/scripts/schemas/review-findings.schema.json +7 -2
- package/src/scripts/schemas/rule.schema.json +5 -0
- package/src/scripts/schemas/skill.schema.json +44 -0
- package/src/scripts/self_review_gate.ts +421 -17
- package/src/scripts/semantic_parity_census.ts +314 -0
- package/src/scripts/session_eol_report.ts +54 -1
- package/src/scripts/skill_tools/score_skill_relevance.ts +290 -25
- package/src/scripts/sweep_dead_scan_roots.ts +1 -1
- package/src/scripts/sweep_skill_ranker_signals.ts +129 -0
- package/src/scripts/sync_gitignore.ts +29 -235
- package/src/scripts/trigger_eval_grandfather.json +0 -7
- package/src/scripts/trigger_eval_rotation.ts +122 -27
- package/src/scripts/ui_conformance_probe.ts +156 -4
- package/src/scripts/update_prices.ts +85 -3
- package/src/scripts/write_bundle_digest.mjs +74 -0
- package/src/server/schemas/settings.ts +41 -0
- package/src/shared/skillRanking.ts +117 -11
- package/src/templates/consumer-settings/ONBOARDING.md +1 -0
- package/dist/cli-delegate/chunk-FXYUYU4N.js +0 -4416
- package/dist/cli-delegate/chunk-QJWAUMJW.js +0 -1072
- package/dist/cli-delegate/chunk-YDPILCOL.js +0 -152
- package/dist/ui/assets/index-DH1xc62v.js +0 -29
- package/dist/ui/assets/index-jSfMW8_t.css +0 -1
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
#!/usr/bin/env tsx
|
|
2
|
+
/**
|
|
3
|
+
* The runnable share of `verify:` clauses, per roadmap.
|
|
4
|
+
*
|
|
5
|
+
* A `verify:` clause names a command and never names what the command must
|
|
6
|
+
* produce, so a step can be flipped on a command that cannot fail. Two numbers
|
|
7
|
+
* say how bad that is, and neither had a producing command before this script:
|
|
8
|
+
* how many clauses name a COMMAND at all (the runnable share), and how many
|
|
9
|
+
* name an EXPECTATION (the falsifiable share).
|
|
10
|
+
*
|
|
11
|
+
* THIS IS A READER, NOT A GATE. It exits 0 on every corpus, including one where
|
|
12
|
+
* both shares are zero. That is a property of the reader, not a description of
|
|
13
|
+
* the tree: measured 2026-09-29, the tree carried 230 clauses, 93 naming a
|
|
14
|
+
* command and 6 naming an expectation — neither share is zero, and the
|
|
15
|
+
* commissioning roadmap's claim that the second one was is the first thing this
|
|
16
|
+
* script refuted. A ratchet needs a false-positive rate and two readings a
|
|
17
|
+
* quarter apart; it has neither, and a gate that reds all but a handful of
|
|
18
|
+
* roadmaps at once gets weakened until it finds nothing. What it buys instead
|
|
19
|
+
* is that the NEXT reading is a delta rather than a re-derivation.
|
|
20
|
+
*
|
|
21
|
+
* THE UNIT, stated because the figure is meaningless without it. One unit is
|
|
22
|
+
* one STEP BLOCK (`- [ ]`, `- [x]`, `- [~]`, `- [-]`, plus its continuation
|
|
23
|
+
* lines) that carries a `verify:` clause. Not one line: a clause wraps, and a
|
|
24
|
+
* line count would double-count a wrapped clause and count prose that merely
|
|
25
|
+
* mentions the token. Step blocks come from `closure_scan`'s own `units()`, so
|
|
26
|
+
* the two instruments agree on what a step is; that also inherits its
|
|
27
|
+
* exclusions — fenced code, and the `## Decisions` / `## Blockers` /
|
|
28
|
+
* `## Kill register` / `## Risk Register` discharge sections, where a mention
|
|
29
|
+
* of `verify:` is commentary rather than a step's oracle.
|
|
30
|
+
*
|
|
31
|
+
* Closed steps are counted. A `[x]` flipped on a clause that could not fail is
|
|
32
|
+
* the defect in its completed form, and excluding them would report the
|
|
33
|
+
* backlog as smaller every time someone closed one.
|
|
34
|
+
*
|
|
35
|
+
* CLI:
|
|
36
|
+
* ./scripts-run src/scripts/roadmap_verify_share
|
|
37
|
+
* ./scripts-run src/scripts/roadmap_verify_share --json
|
|
38
|
+
* ./scripts-run src/scripts/roadmap_verify_share --root <dir> [--recursive]
|
|
39
|
+
*
|
|
40
|
+
* Exit codes: 0 always, except 2 for bad argv or a dead scan root.
|
|
41
|
+
*/
|
|
42
|
+
import * as fs from 'node:fs';
|
|
43
|
+
import * as path from 'node:path';
|
|
44
|
+
import process from 'node:process';
|
|
45
|
+
import { fileURLToPath } from 'node:url';
|
|
46
|
+
|
|
47
|
+
import { units } from './closure_scan.js';
|
|
48
|
+
import { DeadScopeError, assertScanned } from './_lib/scan_scope.js';
|
|
49
|
+
import { parseVerifyClause } from './_lib/verify_clause.js';
|
|
50
|
+
|
|
51
|
+
const _HERE = fileURLToPath(import.meta.url);
|
|
52
|
+
const _PROG = 'roadmap_verify_share';
|
|
53
|
+
const REPO_ROOT = path.resolve(path.dirname(_HERE), '..', '..');
|
|
54
|
+
const DEFAULT_ROOT = 'agents/roadmaps';
|
|
55
|
+
|
|
56
|
+
export interface FileShare {
|
|
57
|
+
readonly file: string;
|
|
58
|
+
/** Step blocks carrying a `verify:` clause. */
|
|
59
|
+
readonly clauses: number;
|
|
60
|
+
/** Of those, the ones naming a command — the runnable share. */
|
|
61
|
+
readonly withCommand: number;
|
|
62
|
+
/** Of those, the ones naming an expectation — the falsifiable share. */
|
|
63
|
+
readonly withExpectation: number;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export interface ShareReport {
|
|
67
|
+
readonly root: string;
|
|
68
|
+
readonly files: number;
|
|
69
|
+
readonly clauses: number;
|
|
70
|
+
readonly withCommand: number;
|
|
71
|
+
readonly withExpectation: number;
|
|
72
|
+
readonly perFile: readonly FileShare[];
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/** Count the clauses in one roadmap's text. */
|
|
76
|
+
export function shareOf(file: string, text: string): FileShare {
|
|
77
|
+
let clauses = 0;
|
|
78
|
+
let withCommand = 0;
|
|
79
|
+
let withExpectation = 0;
|
|
80
|
+
for (const u of units(text.split('\n'))) {
|
|
81
|
+
if (!u.hasVerify) continue;
|
|
82
|
+
const clause = parseVerifyClause(u.blockText);
|
|
83
|
+
if (clause === null) continue;
|
|
84
|
+
clauses += 1;
|
|
85
|
+
if (clause.command !== null) withCommand += 1;
|
|
86
|
+
if (clause.expect !== null) withExpectation += 1;
|
|
87
|
+
}
|
|
88
|
+
return { file, clauses, withCommand, withExpectation };
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
function markdownFiles(root: string, recursive: boolean): string[] {
|
|
92
|
+
const out: string[] = [];
|
|
93
|
+
const walk = (dir: string): void => {
|
|
94
|
+
let entries: fs.Dirent[];
|
|
95
|
+
try {
|
|
96
|
+
entries = fs.readdirSync(dir, { withFileTypes: true });
|
|
97
|
+
} catch {
|
|
98
|
+
return;
|
|
99
|
+
}
|
|
100
|
+
for (const e of entries) {
|
|
101
|
+
const full = path.join(dir, e.name);
|
|
102
|
+
if (e.isDirectory()) {
|
|
103
|
+
if (recursive) walk(full);
|
|
104
|
+
continue;
|
|
105
|
+
}
|
|
106
|
+
if (e.name.endsWith('.md')) out.push(full);
|
|
107
|
+
}
|
|
108
|
+
};
|
|
109
|
+
walk(root);
|
|
110
|
+
return out.sort();
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export function report(rootAbs: string, rootLabel: string, recursive: boolean): ShareReport {
|
|
114
|
+
const files = markdownFiles(rootAbs, recursive);
|
|
115
|
+
// A root that resolved to nothing is blindness, not cleanliness: the share
|
|
116
|
+
// would read as a clean 0/0 and the reader would believe it.
|
|
117
|
+
assertScanned({ gate: _PROG, scanned: files.length, units: 'roadmap(s)', roots: [rootLabel] });
|
|
118
|
+
const perFile = files
|
|
119
|
+
.map((f) => shareOf(path.relative(REPO_ROOT, f), fs.readFileSync(f, 'utf-8')))
|
|
120
|
+
.filter((s) => s.clauses > 0);
|
|
121
|
+
return {
|
|
122
|
+
root: rootLabel,
|
|
123
|
+
files: files.length,
|
|
124
|
+
clauses: perFile.reduce((n, s) => n + s.clauses, 0),
|
|
125
|
+
withCommand: perFile.reduce((n, s) => n + s.withCommand, 0),
|
|
126
|
+
withExpectation: perFile.reduce((n, s) => n + s.withExpectation, 0),
|
|
127
|
+
perFile,
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
function pct(n: number, of: number): string {
|
|
132
|
+
return of === 0 ? 'n/a' : `${((n / of) * 100).toFixed(1)}%`;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
export function render(r: ShareReport): string {
|
|
136
|
+
const lines: string[] = [];
|
|
137
|
+
lines.push(`root: ${r.root}`);
|
|
138
|
+
lines.push(`roadmaps scanned: ${String(r.files)}`);
|
|
139
|
+
lines.push(`verify clauses: ${String(r.clauses)}`);
|
|
140
|
+
lines.push(` naming a command: ${String(r.withCommand)} (${pct(r.withCommand, r.clauses)})`);
|
|
141
|
+
lines.push(` naming an expectation: ${String(r.withExpectation)} (${pct(r.withExpectation, r.clauses)})`);
|
|
142
|
+
lines.push('');
|
|
143
|
+
lines.push('| roadmap | clauses | command | expectation |');
|
|
144
|
+
lines.push('|---|---:|---:|---:|');
|
|
145
|
+
for (const s of r.perFile) {
|
|
146
|
+
lines.push(
|
|
147
|
+
`| \`${path.basename(s.file)}\` | ${String(s.clauses)} | ${String(s.withCommand)} | ${String(s.withExpectation)} |`,
|
|
148
|
+
);
|
|
149
|
+
}
|
|
150
|
+
return lines.join('\n') + '\n';
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
function _usage(): string {
|
|
154
|
+
return (
|
|
155
|
+
`usage: ${_PROG} [-h] [--json] [--root <dir>] [--recursive]\n\n` +
|
|
156
|
+
`Report the runnable and falsifiable share of \`verify:\` clauses. Gates nothing.\n`
|
|
157
|
+
);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export function main(argv?: readonly string[]): number {
|
|
161
|
+
const args = argv ?? process.argv.slice(2);
|
|
162
|
+
let json = false;
|
|
163
|
+
let recursive = false;
|
|
164
|
+
let root = DEFAULT_ROOT;
|
|
165
|
+
for (let i = 0; i < args.length; i += 1) {
|
|
166
|
+
const a = args[i] as string;
|
|
167
|
+
if (a === '-h' || a === '--help') {
|
|
168
|
+
process.stdout.write(_usage());
|
|
169
|
+
return 0;
|
|
170
|
+
} else if (a === '--json') json = true;
|
|
171
|
+
else if (a === '--recursive') recursive = true;
|
|
172
|
+
else if (a === '--root') {
|
|
173
|
+
const next = args[i + 1];
|
|
174
|
+
if (next === undefined) {
|
|
175
|
+
process.stderr.write(`${_usage()}${_PROG}: error: --root needs a directory\n`);
|
|
176
|
+
return 2;
|
|
177
|
+
}
|
|
178
|
+
root = next;
|
|
179
|
+
i += 1;
|
|
180
|
+
} else {
|
|
181
|
+
process.stderr.write(`${_usage()}${_PROG}: error: unrecognized arguments: ${a}\n`);
|
|
182
|
+
return 2;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
const rootAbs = path.isAbsolute(root) ? root : path.join(REPO_ROOT, root);
|
|
187
|
+
let r: ShareReport;
|
|
188
|
+
try {
|
|
189
|
+
r = report(rootAbs, root, recursive);
|
|
190
|
+
} catch (e) {
|
|
191
|
+
if (e instanceof DeadScopeError) {
|
|
192
|
+
process.stderr.write(`${e.message}\n`);
|
|
193
|
+
return 2;
|
|
194
|
+
}
|
|
195
|
+
throw e;
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
process.stdout.write(json ? JSON.stringify(r, null, 2) + '\n' : render(r));
|
|
199
|
+
return 0;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
function _isCliEntry(): boolean {
|
|
203
|
+
if (!process.argv[1]) return false;
|
|
204
|
+
try {
|
|
205
|
+
return fs.realpathSync(_HERE) === fs.realpathSync(path.resolve(process.argv[1]));
|
|
206
|
+
} catch {
|
|
207
|
+
return false;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
if (_isCliEntry() || process.argv[1] === _HERE) {
|
|
212
|
+
process.exitCode = main();
|
|
213
|
+
}
|
|
@@ -131,8 +131,11 @@ export function classify_rule(
|
|
|
131
131
|
const type = typeof meta['type'] === 'string' ? (meta['type'] as string) : 'unknown';
|
|
132
132
|
const always = Boolean(meta['alwaysApply'] || type === 'always');
|
|
133
133
|
|
|
134
|
-
// `_has_non_path_trigger` is the guard's own predicate and is
|
|
135
|
-
//
|
|
134
|
+
// `_has_non_path_trigger` is the guard's own predicate, and it is BROADER
|
|
135
|
+
// than `has_text_trigger`: it counts every match key that is not
|
|
136
|
+
// path-shaped, so `command:` triggers count too. It used to enumerate
|
|
137
|
+
// `keyword` and `phrase` and therefore missed them — `roadmap-progress-sync`
|
|
138
|
+
// read as path-only here while losing three command routes on Claude.
|
|
136
139
|
// Reported separately rather than conflated, because a rule that is mixed by
|
|
137
140
|
// the guard's definition is the one that flipped.
|
|
138
141
|
const mixed = has_path_trigger && _has_non_path_trigger(meta);
|
|
@@ -51,6 +51,7 @@ import {
|
|
|
51
51
|
} from './skill_trigger_eval.js';
|
|
52
52
|
import { AnthropicFetchRouter, loadKeyFromFile } from './_lib/trigger_routers.js';
|
|
53
53
|
import { RULES_MODE_FLOOR } from './_lib/trigger_eval_floors.js';
|
|
54
|
+
import { fnv1a } from './_lib/fnv.js';
|
|
54
55
|
|
|
55
56
|
const _HERE = path.dirname(fileURLToPath(import.meta.url));
|
|
56
57
|
const REPO_ROOT = path.resolve(_HERE, '..', '..');
|
|
@@ -144,15 +145,14 @@ export interface RuleCase {
|
|
|
144
145
|
expected: boolean;
|
|
145
146
|
}
|
|
146
147
|
|
|
147
|
-
/**
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
}
|
|
148
|
+
/**
|
|
149
|
+
* FNV-1a 32-bit — deterministic sampling key (no Math.random).
|
|
150
|
+
*
|
|
151
|
+
* Moved to `_lib/fnv.ts` when the held-out partition in
|
|
152
|
+
* `measure_skill_ranker_baseline` became its second caller; re-exported here
|
|
153
|
+
* because this module's own suite imports the name from this file.
|
|
154
|
+
*/
|
|
155
|
+
export { fnv1a };
|
|
156
156
|
|
|
157
157
|
/**
|
|
158
158
|
* Derive the eval suite from the routing-matrix fixtures: positive →
|
|
@@ -8,6 +8,50 @@
|
|
|
8
8
|
"additionalProperties": false,
|
|
9
9
|
"required": ["name", "description", "disable-model-invocation"],
|
|
10
10
|
"properties": {
|
|
11
|
+
"inputs": {
|
|
12
|
+
"type": "array",
|
|
13
|
+
"minItems": 1,
|
|
14
|
+
"description": "Structured declaration of the parameters this artifact takes. OPTIONAL on every artifact: one with no block validates unchanged, so nothing existing breaks and no migration is owed. Where the block IS present it is the single authority — the argument-hint and the MCP `arguments` set are derived from it, and a hand-written hint on the same artifact is a conflict rather than a merge (road-to-an-invocation-contract-that-reaches-the-wire).",
|
|
15
|
+
"items": {
|
|
16
|
+
"type": "object",
|
|
17
|
+
"additionalProperties": false,
|
|
18
|
+
"required": ["name", "type"],
|
|
19
|
+
"properties": {
|
|
20
|
+
"name": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"pattern": "^[a-z][a-z0-9_]*$",
|
|
23
|
+
"description": "Parameter name. Lowercase snake_case, so it is safe both as a wire key and as an in-body ${name} reference."
|
|
24
|
+
},
|
|
25
|
+
"type": {
|
|
26
|
+
"enum": ["string", "number", "boolean", "enum", "path"],
|
|
27
|
+
"description": "Closed set on purpose: an unknown type must FAIL validation rather than reach a host that cannot interpret it."
|
|
28
|
+
},
|
|
29
|
+
"required": {
|
|
30
|
+
"type": "boolean",
|
|
31
|
+
"description": "Absent means optional."
|
|
32
|
+
},
|
|
33
|
+
"default": {
|
|
34
|
+
"description": "Value used when the caller supplies none. Any JSON type — it is checked against `type` by the consuming generator, not here."
|
|
35
|
+
},
|
|
36
|
+
"enum": {
|
|
37
|
+
"type": "array",
|
|
38
|
+
"minItems": 1,
|
|
39
|
+
"items": {
|
|
40
|
+
"type": "string",
|
|
41
|
+
"minLength": 1,
|
|
42
|
+
"pattern": "^[^|\\]>]+$",
|
|
43
|
+
"description": "A value. `|`, `]` and `>` are excluded because they are the delimiters of the derived argument-hint — permitting them would make the hint ambiguous and break the round-trip the hint gate asserts."
|
|
44
|
+
},
|
|
45
|
+
"description": "Allowed values. Only meaningful when `type` is `enum`."
|
|
46
|
+
},
|
|
47
|
+
"description": {
|
|
48
|
+
"type": "string",
|
|
49
|
+
"minLength": 1,
|
|
50
|
+
"description": "One line, shown to a caller choosing a value."
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
},
|
|
11
55
|
"name": {
|
|
12
56
|
"type": "string",
|
|
13
57
|
"pattern": "^[a-z][a-z0-9]*(-[a-z0-9]+)*$",
|
|
@@ -111,9 +111,10 @@
|
|
|
111
111
|
"open",
|
|
112
112
|
"fixed",
|
|
113
113
|
"accepted_risk",
|
|
114
|
-
"false_positive"
|
|
114
|
+
"false_positive",
|
|
115
|
+
"still_open"
|
|
115
116
|
],
|
|
116
|
-
"description": "Disposition. `fixed` / `false_positive` / `accepted_risk` are the three terminal states check_finding_dispositions accepts; `open` is the initial state. NOTE the underscore spelling — the Markdown track writes `accepted-risk` with a hyphen in its Status cell, and the two vocabularies are deliberately not unified here: renaming either would break committed artefacts on that track."
|
|
117
|
+
"description": "Disposition. `fixed` / `false_positive` / `accepted_risk` are the three terminal states check_finding_dispositions accepts ON A BLOCKING ROW; `open` is the initial state, meaning nobody has looked yet. `still_open` is a fourth TERMINAL state: a row somebody re-read against a named head, confirmed as a real unfixed issue, and recorded as such. It is deliberately distinct from `open`, which the two look identical to a reader checking only for a non-empty field while being opposites — nobody looked, versus somebody looked and this is the answer. `check_finding_dispositions.TERMINAL_STATUSES` carries all four and `DISPOSITION_STATUSES` only the first three, so a BLOCKING row marked `still_open` reports as an unknown status and keeps the gate red, which is the behaviour a blocking finding that is still open should have. NOTE the underscore spelling — the Markdown track writes `accepted-risk` with a hyphen in its Status cell, and the two vocabularies are deliberately not unified here: renaming either would break committed artefacts on that track."
|
|
117
118
|
},
|
|
118
119
|
"rationale": {
|
|
119
120
|
"type": "string",
|
|
@@ -127,6 +128,10 @@
|
|
|
127
128
|
"type": "string",
|
|
128
129
|
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
|
|
129
130
|
"description": "ISO calendar date of the disposition."
|
|
131
|
+
},
|
|
132
|
+
"contradicted": {
|
|
133
|
+
"type": "string",
|
|
134
|
+
"description": "The tree's mechanical disproof of the finding's premise, written by self_review_gate.annotateContradicted when a deletion claim names an artifact the range does not delete and the working tree still holds. A finding carrying this is NOT merge-blocking in either gate (self_review_gate.classifyBlocking and check_finding_dispositions.isBlocking both read it), and it is still reported so a human sees what was claimed and why it was set aside."
|
|
130
135
|
}
|
|
131
136
|
}
|
|
132
137
|
}
|
|
@@ -212,6 +212,11 @@
|
|
|
212
212
|
},
|
|
213
213
|
"description": "What mechanically enforces this rule. `validator:<script>` and `test:<path>` must resolve on disk AND be wired into a taskfile, workflow, or the hook manifest — a script that exists but runs nowhere resolves to unwired, not covered. `hook:<name>` must be registered in hook_manifest.yaml with fail_closed: true; a hook that never blocks is `observer:`, not `validator:`. `instruction-only: <reason>` declares an honestly model-carried obligation and is counted as a recorded gap — the reason is MANDATORY in the pattern, because a bare marker is a claim with no triage record behind it and resolves to `missing`, which the --check ratchet reds on. The bare `none` spelling it replaces stays legal for exactly one reason: `non-destructive-by-default` still carries it and is a kernel rule that block_kernel_rule_writes denies agent writes to, so retiring the value outright would make a CI-green tree unreachable for any agent. Resolved, not trusted, by check_enforcement_coverage.ts."
|
|
214
214
|
},
|
|
215
|
+
"consequence_class": {
|
|
216
|
+
"type": "string",
|
|
217
|
+
"enum": ["irreversible-external", "security-boundary", "authority-bypass"],
|
|
218
|
+
"description": "Which clause of the high-consequence criterion this rule meets, declared only by rules that meet one (road-to-rule-laws-that-can-stand Phase 2). THE CRITERION, and it is meant to be applied by reading the rule's own law section rather than its name: a rule is high-consequence when violating the obligation its law states would (a) `irreversible-external` \u2014 perform an action that leaves this repository and that this agent cannot undo: a deploy, a published egress, a paid render, a rewrite of published history, a destroyed record; or (b) `security-boundary` \u2014 cross a security or data-exposure boundary: authorization, secrets, private or personal data, confidentiality, or untrusted content reaching a privileged path; or (c) `authority-bypass` \u2014 take, or let the agent take, a decision reserved to the user, the owner, or an independent evaluator. A rule whose violation costs quality, tokens, consistency, consistency of style, or rework is NOT high-consequence however important it is \u2014 that reading is what makes the class a measurement rather than a list of favourites. Exactly one clause per rule: where two apply, the declared one is the clause the rule's own law text names. The class is what the criterion produces: every member, every near-miss considered and rejected with its reason, and every member whose law cannot yet stand in a stub are all recorded in src/config/rule-consequence-class.json and checked by tests/scripts/rule_consequence_class.test.ts. Consumed by project_thin_rules, which ships a class member as a stub plus its own law section, byte-copied and digest-checked."
|
|
219
|
+
},
|
|
215
220
|
"obligation_frequency": {
|
|
216
221
|
"type": "string",
|
|
217
222
|
"enum": ["per-edit", "per-turn", "per-task", "per-session", "per-event", "per-commit", "per-file-write", "none"],
|
|
@@ -13,6 +13,50 @@
|
|
|
13
13
|
"domain"
|
|
14
14
|
],
|
|
15
15
|
"properties": {
|
|
16
|
+
"inputs": {
|
|
17
|
+
"type": "array",
|
|
18
|
+
"minItems": 1,
|
|
19
|
+
"description": "Structured declaration of the parameters this artifact takes. OPTIONAL on every artifact: one with no block validates unchanged, so nothing existing breaks and no migration is owed. Where the block IS present it is the single authority — the argument-hint and the MCP `arguments` set are derived from it, and a hand-written hint on the same artifact is a conflict rather than a merge (road-to-an-invocation-contract-that-reaches-the-wire).",
|
|
20
|
+
"items": {
|
|
21
|
+
"type": "object",
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"required": ["name", "type"],
|
|
24
|
+
"properties": {
|
|
25
|
+
"name": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"pattern": "^[a-z][a-z0-9_]*$",
|
|
28
|
+
"description": "Parameter name. Lowercase snake_case, so it is safe both as a wire key and as an in-body ${name} reference."
|
|
29
|
+
},
|
|
30
|
+
"type": {
|
|
31
|
+
"enum": ["string", "number", "boolean", "enum", "path"],
|
|
32
|
+
"description": "Closed set on purpose: an unknown type must FAIL validation rather than reach a host that cannot interpret it."
|
|
33
|
+
},
|
|
34
|
+
"required": {
|
|
35
|
+
"type": "boolean",
|
|
36
|
+
"description": "Absent means optional."
|
|
37
|
+
},
|
|
38
|
+
"default": {
|
|
39
|
+
"description": "Value used when the caller supplies none. Any JSON type — it is checked against `type` by the consuming generator, not here."
|
|
40
|
+
},
|
|
41
|
+
"enum": {
|
|
42
|
+
"type": "array",
|
|
43
|
+
"minItems": 1,
|
|
44
|
+
"items": {
|
|
45
|
+
"type": "string",
|
|
46
|
+
"minLength": 1,
|
|
47
|
+
"pattern": "^[^|\\]>]+$",
|
|
48
|
+
"description": "A value. `|`, `]` and `>` are excluded because they are the delimiters of the derived argument-hint — permitting them would make the hint ambiguous and break the round-trip the hint gate asserts."
|
|
49
|
+
},
|
|
50
|
+
"description": "Allowed values. Only meaningful when `type` is `enum`."
|
|
51
|
+
},
|
|
52
|
+
"description": {
|
|
53
|
+
"type": "string",
|
|
54
|
+
"minLength": 1,
|
|
55
|
+
"description": "One line, shown to a caller choosing a value."
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
16
60
|
"name": {
|
|
17
61
|
"type": "string",
|
|
18
62
|
"pattern": "^[a-z][a-z0-9-]*$",
|