@event4u/agent-config 9.11.0 → 9.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (183) hide show
  1. package/.claude-plugin/marketplace.json +1 -1
  2. package/CHANGELOG.md +80 -204
  3. package/README.md +8 -1
  4. package/dist/agent-src/commands/fix/ci.md +29 -0
  5. package/dist/agent-src/commands/pr/create.md +60 -0
  6. package/dist/agent-src/contexts/authority/kernel-rule-edits.md +18 -2
  7. package/dist/agent-src/rules/active-remediation.md +0 -2
  8. package/dist/agent-src/rules/architecture.md +0 -1
  9. package/dist/agent-src/rules/artifact-drafting-protocol.md +0 -4
  10. package/dist/agent-src/rules/autonomous-execution.md +1 -2
  11. package/dist/agent-src/rules/broken-access-control.md +0 -2
  12. package/dist/agent-src/rules/code-comment-discipline.md +0 -3
  13. package/dist/agent-src/rules/code-provenance.md +0 -3
  14. package/dist/agent-src/rules/communication-through-line.md +2 -3
  15. package/dist/agent-src/rules/content-quoting-floor.md +0 -2
  16. package/dist/agent-src/rules/context-hygiene.md +1 -3
  17. package/dist/agent-src/rules/decision-revisit-gate.md +0 -2
  18. package/dist/agent-src/rules/design-fidelity.md +30 -1
  19. package/dist/agent-src/rules/domain-adoption-policy.md +0 -3
  20. package/dist/agent-src/rules/downstream-changes.md +10 -1
  21. package/dist/agent-src/rules/external-reference-deep-dive.md +0 -7
  22. package/dist/agent-src/rules/fast-path-marker-visibility.md +0 -1
  23. package/dist/agent-src/rules/git-history-discipline.md +0 -7
  24. package/dist/agent-src/rules/guidelines.md +0 -2
  25. package/dist/agent-src/rules/improve-before-implement.md +4 -2
  26. package/dist/agent-src/rules/invite-challenge.md +0 -4
  27. package/dist/agent-src/rules/linked-projects-onboarding-gate.md +0 -2
  28. package/dist/agent-src/rules/markdown-safe-codeblocks.md +0 -1
  29. package/dist/agent-src/rules/minimal-safe-diff.md +2 -2
  30. package/dist/agent-src/rules/missing-tool-handling.md +0 -1
  31. package/dist/agent-src/rules/no-attribution-footers.md +0 -3
  32. package/dist/agent-src/rules/no-decorative-emojis-in-git-surfaces.md +8 -5
  33. package/dist/agent-src/rules/no-pr-progress-comments.md +1 -3
  34. package/dist/agent-src/rules/no-roadmap-references.md +0 -2
  35. package/dist/agent-src/rules/output-discipline.md +0 -1
  36. package/dist/agent-src/rules/prefer-enums-over-literals.md +0 -2
  37. package/dist/agent-src/rules/preservation-guard.md +0 -3
  38. package/dist/agent-src/rules/role-mode-adherence.md +0 -1
  39. package/dist/agent-src/rules/secret-vcs-guard.md +0 -2
  40. package/dist/agent-src/rules/senior-engineering-discipline.md +0 -2
  41. package/dist/agent-src/rules/session-canary.md +0 -2
  42. package/dist/agent-src/rules/size-enforcement.md +0 -5
  43. package/dist/agent-src/rules/source-confidentiality.md +0 -3
  44. package/dist/agent-src/rules/source-discovery-gate.md +0 -2
  45. package/dist/agent-src/rules/think-before-action.md +3 -3
  46. package/dist/agent-src/rules/token-budget-discipline.md +0 -1
  47. package/dist/agent-src/rules/token-efficiency.md +1 -2
  48. package/dist/agent-src/rules/tool-safety.md +0 -1
  49. package/dist/agent-src/rules/user-interaction.md +0 -3
  50. package/dist/agent-src/rules/user-interrupt-priority.md +0 -1
  51. package/dist/agent-src/skills/agent-docs-writing/SKILL.md +8 -0
  52. package/dist/agent-src/skills/ai-code-blindspots/SKILL.md +1 -0
  53. package/dist/agent-src/skills/analysis-skill-router/SKILL.md +55 -86
  54. package/dist/agent-src/skills/character-consistency/SKILL.md +7 -4
  55. package/dist/agent-src/skills/decision-record/SKILL.md +8 -0
  56. package/dist/agent-src/skills/design-intelligence/SKILL.md +27 -1
  57. package/dist/agent-src/skills/design-intelligence/data/font-pairings-reference.csv +74 -74
  58. package/dist/agent-src/skills/design-intelligence/data/manifest.json +2 -0
  59. package/dist/agent-src/skills/design-review/SKILL.md +11 -0
  60. package/dist/agent-src/skills/design-system-capture/reference/design-system-json.md +8 -0
  61. package/dist/agent-src/skills/design-tokens/scripts/tokens.ts +0 -7
  62. package/dist/agent-src/skills/existing-ui-audit/SKILL.md +34 -3
  63. package/dist/agent-src/skills/fe-design/SKILL.md +10 -0
  64. package/dist/agent-src/skills/motion-choreographer/SKILL.md +7 -4
  65. package/dist/agent-src/skills/overbuild-review-lens/SKILL.md +201 -0
  66. package/dist/agent-src/skills/performance/SKILL.md +14 -0
  67. package/dist/agent-src/skills/pixar-storyteller/SKILL.md +8 -5
  68. package/dist/agent-src/skills/scene-expander/SKILL.md +9 -6
  69. package/dist/agent-src/skills/supply-chain-intake/SKILL.md +10 -0
  70. package/dist/agent-src/skills/typography-system/SKILL.md +55 -11
  71. package/dist/agent-src/skills/ui-apply-generic/SKILL.md +180 -0
  72. package/dist/agent-src/skills/universal-project-analysis/SKILL.md +14 -37
  73. package/dist/agent-src/skills/video-director/SKILL.md +9 -6
  74. package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
  75. package/dist/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +162 -17
  76. package/dist/agent-src/templates/scripts/work_engine/directives/ui/design.ts +118 -0
  77. package/dist/agent-src/templates/scripts/work_engine/directives/ui/polish.ts +49 -6
  78. package/dist/agent-src/templates/scripts/work_engine/directives/ui/review.ts +9 -5
  79. package/dist/agent-src/templates/scripts/work_engine/directives/ui/stack_bundles.ts +182 -29
  80. package/dist/agent-src/templates/scripts/work_engine/stack/detect.ts +311 -24
  81. package/dist/agent-src/templates/scripts/work_engine/state.ts +55 -0
  82. package/dist/cli-delegate/chunk-523HCFYO.js +90 -0
  83. package/dist/cli-delegate/{chunk-IR7P7JWA.js → chunk-A3HJ6NTI.js} +271 -59
  84. package/dist/cli-delegate/chunk-EJYIGZ3T.js +125 -0
  85. package/dist/cli-delegate/{chunk-RDGRHAAB.js → chunk-HYWSRNUX.js} +6 -86
  86. package/dist/cli-delegate/{chunk-YMFO6FDN.js → chunk-QFKQLQ7X.js} +313 -81
  87. package/dist/cli-delegate/{chunk-4SV3XGFA.js → chunk-TEGJU2JX.js} +7 -9
  88. package/dist/cli-delegate/chunk-TJIAM5FW.js +133 -0
  89. package/dist/cli-delegate/cmd_conformance.js +4 -7
  90. package/dist/cli-delegate/cmd_doctor.js +3 -5
  91. package/dist/cli-delegate/cmd_explain.js +153 -85
  92. package/dist/cli-delegate/cmd_export.js +5 -3
  93. package/dist/cli-delegate/cmd_fleet.js +2 -1
  94. package/dist/cli-delegate/cmd_preflight.js +6 -123
  95. package/dist/cli-delegate/cmd_prune.js +5 -3
  96. package/dist/cli-delegate/cmd_settings_migrate.js +5 -3
  97. package/dist/cli-delegate/cmd_sync.js +5 -3
  98. package/dist/cli-delegate/cmd_uninstall.js +6 -5
  99. package/dist/cli-delegate/cmd_validate.js +5 -3
  100. package/dist/discovery/deprecation-report.md +1 -1
  101. package/dist/discovery/discovery-manifest.json +116 -72
  102. package/dist/discovery/discovery-manifest.json.sha256 +1 -1
  103. package/dist/discovery/discovery-manifest.summary.md +3 -3
  104. package/dist/discovery/orphan-report.md +1 -1
  105. package/dist/discovery/packs.json +7 -5
  106. package/dist/discovery/trust-report.md +2 -2
  107. package/dist/discovery/workspaces.json +6 -4
  108. package/dist/hooks/dispatch.js +174 -13
  109. package/dist/install/install.mjs +605 -412
  110. package/dist/install/ruleInScope.js +123 -0
  111. package/dist/install/ruleInScope.js.map +1 -0
  112. package/dist/install/rule_scope.js +2 -2
  113. package/dist/install/rule_scope.js.map +1 -1
  114. package/dist/install/wizard-plan.js +10 -1
  115. package/dist/install/wizard-plan.js.map +1 -1
  116. package/dist/mcp/registry-manifest.json +3 -3
  117. package/dist/mcp/server.json +2 -2
  118. package/dist/mcp/server.mjs +710 -2491
  119. package/dist/router.json +1 -1
  120. package/dist/scripts/condense.js +8 -24
  121. package/dist/scripts/condense.js.map +1 -1
  122. package/docs/MIGRATION.md +1 -1
  123. package/docs/guidelines/agent-infra/agent-interaction-and-decision-quality.md +71 -0
  124. package/docs/guidelines/agent-infra/minimal-safe-diff-mechanics.md +24 -1
  125. package/docs/guidelines/code-clarity.md +9 -2
  126. package/docs/guidelines/design-fidelity-mechanics.md +58 -0
  127. package/llms.txt +63 -27
  128. package/package.json +4 -4
  129. package/src/agent-src/templates/scripts/work_engine/directives/ui/apply.ts +162 -17
  130. package/src/agent-src/templates/scripts/work_engine/directives/ui/design.ts +118 -0
  131. package/src/agent-src/templates/scripts/work_engine/directives/ui/polish.ts +49 -6
  132. package/src/agent-src/templates/scripts/work_engine/directives/ui/review.ts +9 -5
  133. package/src/agent-src/templates/scripts/work_engine/directives/ui/stack_bundles.ts +182 -29
  134. package/src/agent-src/templates/scripts/work_engine/stack/detect.ts +311 -24
  135. package/src/agent-src/templates/scripts/work_engine/state.ts +55 -0
  136. package/src/config/agent-settings.template.yml +8 -0
  137. package/src/install/ruleInScope.ts +133 -0
  138. package/src/install/rule_scope.ts +2 -2
  139. package/src/install/wizard-plan.ts +11 -1
  140. package/src/scripts/_lib/counted_probe.ts +142 -0
  141. package/src/scripts/_lib/global_deploy_inventory.ts +38 -2
  142. package/src/scripts/_lib/overbuild_lens_contract.ts +196 -0
  143. package/src/scripts/_lib/release_scope.ts +207 -0
  144. package/src/scripts/ai_council/stance_tally.ts +37 -2
  145. package/src/scripts/audit_auto_rules.ts +9 -9
  146. package/src/scripts/audit_likelihood.ts +3 -3
  147. package/src/scripts/audit_overlap.ts +2 -2
  148. package/src/scripts/audit_skill_overlap.ts +233 -95
  149. package/src/scripts/audit_skill_overlap_allowlist.json +4 -0
  150. package/src/scripts/build_proof.ts +15 -1
  151. package/src/scripts/check_dependency_floors.ts +16 -6
  152. package/src/scripts/check_gate_coverage.ts +6 -6
  153. package/src/scripts/check_installer_import_purity.ts +295 -0
  154. package/src/scripts/check_kernel_rule_bundle.ts +5 -4
  155. package/src/scripts/check_token_quality_golden.ts +0 -18
  156. package/src/scripts/code_graph/loader.ts +35 -6
  157. package/src/scripts/compile_router.ts +3 -8
  158. package/src/scripts/condense.ts +9 -30
  159. package/src/scripts/explain_run.ts +0 -1
  160. package/src/scripts/generate_pack_manifests.ts +3 -20
  161. package/src/scripts/hooks/block_kernel_rule_writes.ts +145 -10
  162. package/src/scripts/hooks/block_no_verify.ts +101 -0
  163. package/src/scripts/install-hooks.sh +36 -4
  164. package/src/scripts/install.ts +210 -5
  165. package/src/scripts/lint_agent_security.ts +5 -4
  166. package/src/scripts/lint_framework_leakage_allowlist.json +2 -2
  167. package/src/scripts/lint_regression.ts +92 -1
  168. package/src/scripts/lint_skill_descriptions.ts +93 -5
  169. package/src/scripts/lint_ui_stack_bundles.ts +31 -0
  170. package/src/scripts/project_thin_rules.ts +2 -2
  171. package/src/scripts/release.ts +107 -3
  172. package/src/scripts/resolve_lint_scope.ts +53 -0
  173. package/src/scripts/router_telemetry.ts +0 -5
  174. package/src/scripts/runtime_dispatcher.ts +40 -0
  175. package/src/scripts/schemas/pack.schema.json +1 -5
  176. package/src/scripts/schemas/rule.schema.json +1 -2
  177. package/src/scripts/self_review_gate.ts +15 -73
  178. package/src/scripts/skill_linter.ts +93 -11
  179. package/src/scripts/sweep_dead_scan_roots.ts +550 -0
  180. package/src/scripts/trigger_coverage.ts +11 -37
  181. package/dist/cli-delegate/chunk-7DSAMZFU.js +0 -356
  182. package/dist/cli-delegate/chunk-BJGXZNPM.js +0 -266
  183. package/dist/cli-delegate/chunk-TFG57JJM.js +0 -1969
@@ -10,11 +10,6 @@ import {
10
10
  claude_plugin_snapshot_version,
11
11
  codex_plugin_identity
12
12
  } from "./chunk-FTAISGDQ.js";
13
- import {
14
- LEGACY_ALL,
15
- excludedRuleBasenames,
16
- ruleScopeFromSettings
17
- } from "./chunk-TFG57JJM.js";
18
13
  import {
19
14
  DEFAULT_GITATTRIBUTES,
20
15
  SECTION_HEADER,
@@ -22,18 +17,21 @@ import {
22
17
  } from "./chunk-736JCWLM.js";
23
18
  import {
24
19
  DEFAULT_DEPLOY_ROOTS,
20
+ MANAGED_SIGNATURE,
25
21
  SCHEMA_VERSIONS_SUPPORTED,
22
+ build_claude_hook_matrix,
26
23
  global_deploy_inventory_exports,
27
24
  manifest_path,
28
25
  read_manifest
29
- } from "./chunk-IR7P7JWA.js";
26
+ } from "./chunk-A3HJ6NTI.js";
30
27
  import {
31
28
  read_lockfile
32
29
  } from "./chunk-GRRPEPRN.js";
33
30
  import {
34
- MANAGED_SIGNATURE,
35
- build_claude_hook_matrix
36
- } from "./chunk-7DSAMZFU.js";
31
+ LEGACY_ALL,
32
+ excludedRuleBasenames,
33
+ ruleScopeFromSettings
34
+ } from "./chunk-TJIAM5FW.js";
37
35
  import {
38
36
  PROJECT_ROOT_ENV,
39
37
  ProjectRootError,
@@ -0,0 +1,133 @@
1
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
2
+ import {
3
+ require_dist
4
+ } from "./chunk-OY53J6II.js";
5
+ import {
6
+ __toESM
7
+ } from "./chunk-J55WI3RR.js";
8
+
9
+ // src/install/rule_scope.ts
10
+ import * as fs2 from "node:fs";
11
+ import * as path from "node:path";
12
+
13
+ // src/install/ruleInScope.ts
14
+ var YAML = __toESM(require_dist(), 1);
15
+ import * as fs from "node:fs";
16
+ function parseYaml(text) {
17
+ try {
18
+ const data = YAML.parse(text, { version: "1.1" });
19
+ return data === void 0 ? null : data;
20
+ } catch {
21
+ return null;
22
+ }
23
+ }
24
+ function strip(s) {
25
+ return s.replace(/^\s+/u, "").replace(/\s+$/u, "");
26
+ }
27
+ function lstripNewlines(s) {
28
+ return s.replace(/^\n+/, "");
29
+ }
30
+ function parseFrontmatter(content) {
31
+ if (!content.startsWith("---")) {
32
+ return [{}, content];
33
+ }
34
+ const end = content.indexOf("\n---", 3);
35
+ if (end === -1) {
36
+ return [{}, content];
37
+ }
38
+ const raw = strip(content.slice(3, end));
39
+ const body = lstripNewlines(content.slice(end + 4));
40
+ let meta = parseYaml(raw);
41
+ if (meta === null || meta === void 0) {
42
+ meta = {};
43
+ }
44
+ if (typeof meta === "object" && meta !== null && !Array.isArray(meta)) {
45
+ return [meta, body];
46
+ }
47
+ return [{}, body];
48
+ }
49
+ function rule_in_scope(source_path, scope, pack_scope = null, role_scope = null) {
50
+ if (scope === null && pack_scope === null && role_scope === null) {
51
+ return true;
52
+ }
53
+ const [meta] = parseFrontmatter(fs.readFileSync(source_path, "utf-8"));
54
+ if (meta["type"] === "always" || meta["alwaysApply"] === true) {
55
+ return true;
56
+ }
57
+ const axis = (key, configured) => {
58
+ if (configured === null) {
59
+ return true;
60
+ }
61
+ const values = Array.isArray(meta[key]) ? meta[key].map((w) => String(w)) : [];
62
+ if (values.length === 0) {
63
+ return true;
64
+ }
65
+ return values.some((v) => configured.includes(v));
66
+ };
67
+ return axis("workspaces", scope) && axis("packs", pack_scope) && axis("roles", role_scope);
68
+ }
69
+
70
+ // src/install/rule_scope.ts
71
+ var COMPAT_ALWAYS_EXCLUDED = ["source-of-truth.md"];
72
+ var LEGACY_ALL = { workspaces: null, packs: null };
73
+ function _list(value) {
74
+ if (Array.isArray(value) && value.length > 0) {
75
+ return value.map((v) => String(v));
76
+ }
77
+ return null;
78
+ }
79
+ function ruleScopeFromSettings(settings) {
80
+ const proj = settings["projection"];
81
+ if (typeof proj !== "object" || proj === null || Array.isArray(proj)) {
82
+ return LEGACY_ALL;
83
+ }
84
+ const p = proj;
85
+ return {
86
+ workspaces: _list(p["rule_workspaces"]),
87
+ packs: _list(p["rule_packs"]),
88
+ roles: _list(p["rule_roles"])
89
+ };
90
+ }
91
+ function ruleFileArrives(sourcePath, scope) {
92
+ if (!sourcePath.endsWith(".md")) {
93
+ return true;
94
+ }
95
+ const basename2 = path.basename(sourcePath);
96
+ if (COMPAT_ALWAYS_EXCLUDED.includes(basename2)) {
97
+ return false;
98
+ }
99
+ return rule_in_scope(sourcePath, scope.workspaces, scope.packs, scope.roles ?? null);
100
+ }
101
+ function excludedRuleBasenames(rulesDir, scope) {
102
+ let entries;
103
+ try {
104
+ entries = fs2.readdirSync(rulesDir).sort();
105
+ } catch {
106
+ return [];
107
+ }
108
+ const out = [];
109
+ for (const name of entries) {
110
+ if (!name.endsWith(".md")) {
111
+ continue;
112
+ }
113
+ const full = path.join(rulesDir, name);
114
+ try {
115
+ if (!fs2.statSync(full).isFile()) {
116
+ continue;
117
+ }
118
+ } catch {
119
+ continue;
120
+ }
121
+ if (!ruleFileArrives(full, scope)) {
122
+ out.push(name);
123
+ }
124
+ }
125
+ return out;
126
+ }
127
+
128
+ export {
129
+ LEGACY_ALL,
130
+ ruleScopeFromSettings,
131
+ ruleFileArrives,
132
+ excludedRuleBasenames
133
+ };
@@ -11,19 +11,16 @@ import {
11
11
  _run_checks,
12
12
  _run_checks_no_manifest,
13
13
  _scan_foreign
14
- } from "./chunk-4SV3XGFA.js";
14
+ } from "./chunk-TEGJU2JX.js";
15
15
  import "./chunk-FTAISGDQ.js";
16
- import "./chunk-TFG57JJM.js";
17
16
  import "./chunk-736JCWLM.js";
18
- import "./chunk-BJGXZNPM.js";
19
17
  import {
18
+ atomicAppendLine,
20
19
  manifest_path,
21
20
  read_manifest
22
- } from "./chunk-IR7P7JWA.js";
21
+ } from "./chunk-A3HJ6NTI.js";
23
22
  import "./chunk-GRRPEPRN.js";
24
- import {
25
- atomicAppendLine
26
- } from "./chunk-7DSAMZFU.js";
23
+ import "./chunk-TJIAM5FW.js";
27
24
  import "./chunk-HJ6DAJHR.js";
28
25
  import "./chunk-NDJLNC6Q.js";
29
26
  import {
@@ -64,14 +64,12 @@ import {
64
64
  _skipped_manifest_check,
65
65
  _wizard_state_path,
66
66
  main
67
- } from "./chunk-4SV3XGFA.js";
67
+ } from "./chunk-TEGJU2JX.js";
68
68
  import "./chunk-FTAISGDQ.js";
69
- import "./chunk-TFG57JJM.js";
70
69
  import "./chunk-736JCWLM.js";
71
- import "./chunk-BJGXZNPM.js";
72
- import "./chunk-IR7P7JWA.js";
70
+ import "./chunk-A3HJ6NTI.js";
73
71
  import "./chunk-GRRPEPRN.js";
74
- import "./chunk-7DSAMZFU.js";
72
+ import "./chunk-TJIAM5FW.js";
75
73
  import "./chunk-HJ6DAJHR.js";
76
74
  import "./chunk-NDJLNC6Q.js";
77
75
  import "./chunk-MCJYCQPF.js";