@event4u/agent-config 14.21.0 → 14.23.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 (235) hide show
  1. package/.augment-plugin/marketplace.json +3 -3
  2. package/.augment-plugin/plugin.json +1 -1
  3. package/.claude-plugin/marketplace.json +1 -1
  4. package/CHANGELOG.md +164 -187
  5. package/CREDITS.md +37 -0
  6. package/README.md +1 -1
  7. package/dist/agent-src/commands/analyze/inbox.md +380 -5
  8. package/dist/agent-src/commands/analyze/repo.md +4 -2
  9. package/dist/agent-src/commands/pr/merge.md +47 -38
  10. package/dist/agent-src/commands/roadmap/next.md +8 -0
  11. package/dist/agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +69 -0
  12. package/dist/agent-src/contexts/execution/auto-dispatch-classification.md +5 -5
  13. package/dist/agent-src/contexts/execution/autonomy-mechanics.md +12 -0
  14. package/dist/agent-src/rules/external-code-graph-interop.md +19 -14
  15. package/dist/agent-src/rules/notes-first-reasoning.md +36 -25
  16. package/dist/agent-src/rules/token-efficiency.md +26 -3
  17. package/dist/agent-src/scripts/_cli_entry.ts +51 -0
  18. package/dist/agent-src/scripts/archive_completed_roadmaps.ts +120 -27
  19. package/dist/agent-src/scripts/roadmap_gates.ts +4 -20
  20. package/dist/agent-src/scripts/roadmap_set_step.ts +5 -2
  21. package/dist/agent-src/scripts/stubs_due.ts +4 -18
  22. package/dist/agent-src/scripts/update_roadmap_progress.ts +7 -24
  23. package/dist/agent-src/skills/code-intelligence/SKILL.md +82 -1
  24. package/dist/agent-src/skills/git-workflow/references/push-closes-its-loop.md +9 -0
  25. package/dist/agent-src/skills/roadmap-writing/SKILL.md +17 -0
  26. package/dist/agent-src/skills/tailwind-engineer/SKILL.md +52 -2
  27. package/dist/agent-src/templates/agent-settings.md +0 -1
  28. package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
  29. package/dist/cli/registry.js +1 -1
  30. package/dist/cli-delegate/_cli_entry.js +8 -0
  31. package/dist/cli-delegate/_lib/pin_resolver.js +170 -0
  32. package/dist/cli-delegate/archival_sweep.js +8 -0
  33. package/dist/cli-delegate/archive_completed_roadmaps.js +542 -0
  34. package/dist/cli-delegate/check_update_banner.js +923 -0
  35. package/dist/cli-delegate/{chunk-ZVBOHSVF.js → chunk-2KKXJW25.js} +23 -9
  36. package/dist/cli-delegate/chunk-5EK5WQN6.js +28 -0
  37. package/dist/cli-delegate/chunk-7XGD2OEU.js +96 -0
  38. package/dist/cli-delegate/chunk-DBH4AHDK.js +155 -0
  39. package/dist/cli-delegate/{chunk-4FS4WRXP.js → chunk-IAI3XL43.js} +15 -3
  40. package/dist/cli-delegate/chunk-JO25G5H7.js +20 -0
  41. package/dist/cli-delegate/{chunk-643Z7FIC.js → chunk-KCNTUSPI.js} +7 -1
  42. package/dist/cli-delegate/chunk-LTYVIY76.js +7961 -0
  43. package/dist/cli-delegate/chunk-QAJS5YWY.js +999 -0
  44. package/dist/cli-delegate/{chunk-YS6XTLEK.js → chunk-TYSY33MD.js} +56 -6
  45. package/dist/cli-delegate/chunk-ULET4BYS.js +328 -0
  46. package/dist/cli-delegate/chunk-YDQSHTD7.js +187 -0
  47. package/dist/cli-delegate/chunk-YWVXLR44.js +48 -0
  48. package/dist/cli-delegate/chunk-ZZQBUHFK.js +273 -0
  49. package/dist/cli-delegate/cmd_conformance.js +2 -2
  50. package/dist/cli-delegate/cmd_export.js +2 -2
  51. package/dist/cli-delegate/cmd_handoff.js +45 -13
  52. package/dist/cli-delegate/cmd_prune.js +2 -2
  53. package/dist/cli-delegate/cmd_session_recycle.js +4 -14
  54. package/dist/cli-delegate/cmd_settings_migrate.js +2 -2
  55. package/dist/cli-delegate/cmd_settings_set.js +1 -1
  56. package/dist/cli-delegate/cmd_sync.js +2 -2
  57. package/dist/cli-delegate/cmd_uninstall.js +2 -2
  58. package/dist/cli-delegate/cmd_validate.js +2 -2
  59. package/dist/cli-delegate/dashboard_mode.js +16 -0
  60. package/dist/cli-delegate/gate_budget.js +24 -0
  61. package/dist/cli-delegate/gate_execute.js +25 -0
  62. package/dist/cli-delegate/guarded_baseline.js +18 -0
  63. package/dist/cli-delegate/resume_probe.js +22 -0
  64. package/dist/cli-delegate/roadmap_gates.js +638 -0
  65. package/dist/cli-delegate/roadmap_set_step.js +173 -0
  66. package/dist/cli-delegate/stub_queue.js +47 -0
  67. package/dist/cli-delegate/stubs_due.js +38 -0
  68. package/dist/cli-delegate/ticket_bundles.js +59 -0
  69. package/dist/cli-delegate/update_roadmap_progress.js +60 -0
  70. package/dist/discovery/deprecation-report.md +1 -1
  71. package/dist/discovery/discovery-manifest.json +13 -13
  72. package/dist/discovery/discovery-manifest.json.sha256 +1 -1
  73. package/dist/discovery/discovery-manifest.summary.md +1 -1
  74. package/dist/discovery/dormancy-report.md +1 -1
  75. package/dist/discovery/orphan-report.md +1 -1
  76. package/dist/discovery/packs.json +2 -2
  77. package/dist/discovery/trust-report.md +1 -1
  78. package/dist/discovery/workspaces.json +2 -2
  79. package/dist/hooks/dispatch.js +1813 -946
  80. package/dist/install/claudeLayerCarriage.js +237 -0
  81. package/dist/install/claudePathsPlan.js +79 -0
  82. package/dist/install/hostLayerFingerprint.js +1 -1
  83. package/dist/install/install.mjs +21 -3
  84. package/dist/install/partitionEligibility.js +231 -117
  85. package/dist/install/ruleLayerPartition.js +10 -7
  86. package/dist/mcp/registry-manifest.json +2 -2
  87. package/dist/mcp/server.json +2 -2
  88. package/dist/mcp/server.mjs +10870 -7641
  89. package/dist/scripts/_lib/lean_projection_mode.js +108 -0
  90. package/dist/scripts/_lib/router_match.js +243 -0
  91. package/dist/scripts/_lib/rule_injection.js +216 -0
  92. package/dist/scripts/condense.js +52 -45
  93. package/dist/scripts/project_thin_rules.js +139 -19
  94. package/dist/server/schemas/settings.js +16 -3
  95. package/docs/MIGRATION.md +105 -1
  96. package/docs/contracts/settings-classes.md +40 -8
  97. package/docs/guidelines/agent-infra/minimal-safe-diff-mechanics.md +73 -0
  98. package/docs/guidelines/agent-infra/notes-horizon-mechanics.md +90 -0
  99. package/llms.txt +1 -1
  100. package/package.json +7 -4
  101. package/src/agent-src/scripts/_cli_entry.ts +51 -0
  102. package/src/agent-src/scripts/archive_completed_roadmaps.ts +120 -27
  103. package/src/agent-src/scripts/roadmap_gates.ts +4 -20
  104. package/src/agent-src/scripts/roadmap_set_step.ts +5 -2
  105. package/src/agent-src/scripts/stubs_due.ts +4 -18
  106. package/src/agent-src/scripts/update_roadmap_progress.ts +7 -24
  107. package/src/config/agent-settings.template.yml +47 -1
  108. package/src/config/continuity-surface.json +516 -0
  109. package/src/config/estate-count-budget.json +1 -1
  110. package/src/config/evaluator-budgets.json +4 -4
  111. package/src/config/gate-coverage.yml +29 -8
  112. package/src/config/gate-violation-baselines.json +8 -8
  113. package/src/config/gitignore-block.txt +19 -0
  114. package/src/config/hook-token-budget.json +7 -6
  115. package/src/config/host-injection-effect.json +73 -0
  116. package/src/config/packed-binary-manifest.json +33 -0
  117. package/src/config/preamble-payload-budget.json +112 -105
  118. package/src/config/publish-surface.json +4 -2
  119. package/src/config/routing-coverage-seed.json +9 -2
  120. package/src/install/claudeLayerCarriage.ts +273 -0
  121. package/src/install/claudePathsPlan.ts +76 -0
  122. package/src/install/hostLayerFingerprint.ts +1 -1
  123. package/src/install/partitionEligibility.ts +261 -127
  124. package/src/install/ruleLayerPartition.ts +19 -23
  125. package/src/scripts/_cli/cmd_session_recycle.ts +2 -25
  126. package/src/scripts/_cli/handoff_sessions.ts +14 -44
  127. package/src/scripts/_dispatch.bash +77 -27
  128. package/src/scripts/_lib/auto_dispatch.ts +2 -2
  129. package/src/scripts/_lib/catalogue_layer_parity.ts +146 -0
  130. package/src/scripts/_lib/continuity_slot.ts +295 -0
  131. package/src/scripts/_lib/continuity_surface.ts +296 -0
  132. package/src/scripts/_lib/continuity_writer.ts +253 -0
  133. package/src/scripts/_lib/corpus_manifest.ts +26 -9
  134. package/src/scripts/_lib/hook_settings.ts +86 -1
  135. package/src/scripts/_lib/injection_effect.ts +151 -0
  136. package/src/scripts/_lib/layer_overlap_notice.ts +50 -6
  137. package/src/scripts/_lib/lean_projection_mode.ts +127 -0
  138. package/src/scripts/_lib/packed_binary_predicate.ts +262 -0
  139. package/src/scripts/_lib/pin_resolver.ts +13 -0
  140. package/src/scripts/_lib/recycle_envelope_paths.ts +109 -21
  141. package/src/scripts/_lib/regression_neighbourhood.ts +159 -22
  142. package/src/scripts/_lib/retired_status.ts +74 -0
  143. package/src/scripts/_lib/session_eol.ts +44 -0
  144. package/src/scripts/_lib/session_index_trust.ts +346 -0
  145. package/src/scripts/_lib/skill_catalogue.ts +156 -21
  146. package/src/scripts/_lib/standing_bound_ratchet.ts +154 -0
  147. package/src/scripts/_lib/subagent_capsule.ts +117 -8
  148. package/src/scripts/_lib/vendored_grammar_upstream.ts +280 -0
  149. package/src/scripts/ai_council/api_transport.ts +5 -0
  150. package/src/scripts/ai_council/deliberation_metrics.ts +353 -0
  151. package/src/scripts/ai_council/prompts.ts +9 -0
  152. package/src/scripts/ai_council/synthesis_disagreement.ts +206 -0
  153. package/src/scripts/audit_mcp_tools.ts +69 -25
  154. package/src/scripts/build_mcp_catalog.ts +24 -1
  155. package/src/scripts/capture_skill_catalogue.ts +24 -11
  156. package/src/scripts/check_candidate_lines.ts +499 -0
  157. package/src/scripts/check_continuity_surface.ts +475 -0
  158. package/src/scripts/check_dependency_floors.ts +13 -6
  159. package/src/scripts/check_estate_count.ts +40 -79
  160. package/src/scripts/check_host_tree_parity.ts +291 -0
  161. package/src/scripts/check_pack_size.ts +262 -23
  162. package/src/scripts/check_preamble_payload_budget.ts +136 -7
  163. package/src/scripts/check_roadmap_trackable.ts +19 -16
  164. package/src/scripts/check_rule_layer_partition.ts +54 -34
  165. package/src/scripts/check_rule_projection_integrity.ts +102 -2
  166. package/src/scripts/check_single_delivery.ts +97 -31
  167. package/src/scripts/check_update_banner.ts +13 -0
  168. package/src/scripts/ci_settle.ts +205 -5
  169. package/src/scripts/code_graph/build.ts +217 -15
  170. package/src/scripts/code_graph/cli.ts +334 -15
  171. package/src/scripts/code_graph/detect.ts +38 -0
  172. package/src/scripts/code_graph/extract.ts +11 -0
  173. package/src/scripts/code_graph/grammar_probe.ts +43 -0
  174. package/src/scripts/code_graph/loader.ts +88 -14
  175. package/src/scripts/code_graph/query.ts +144 -11
  176. package/src/scripts/code_graph/resolution_tiers.ts +238 -0
  177. package/src/scripts/code_graph/sqlite_store.ts +262 -6
  178. package/src/scripts/code_graph/types.ts +117 -3
  179. package/src/scripts/code_graph/validate.ts +26 -1
  180. package/src/scripts/code_graph/verbs.ts +590 -0
  181. package/src/scripts/condense.ts +54 -42
  182. package/src/scripts/corpus_manifest.ts +5 -5
  183. package/src/scripts/council_cli.ts +11 -12
  184. package/src/scripts/count_intent_disagreement.ts +426 -0
  185. package/src/scripts/handoff_context_hook.ts +118 -1
  186. package/src/scripts/hook_effect_doctor.ts +82 -1
  187. package/src/scripts/hook_manifest.json +1 -1
  188. package/src/scripts/hook_manifest.yaml +87 -12
  189. package/src/scripts/hooks/block_speaking_inbox_dir.ts +182 -16
  190. package/src/scripts/hooks/chain_nudge_hook.ts +282 -0
  191. package/src/scripts/hooks/code_graph_context_hook.ts +201 -0
  192. package/src/scripts/hooks/concern_registry.ts +4 -2
  193. package/src/scripts/hooks/host_semantics.ts +1 -1
  194. package/src/scripts/hooks/orchestration_record_hook.ts +2 -2
  195. package/src/scripts/hooks/push_settle_hook.ts +3 -2
  196. package/src/scripts/hooks/rule_inject_hook.ts +108 -21
  197. package/src/scripts/hooks/session_eol_hook.ts +120 -2
  198. package/src/scripts/hooks/skill_route_hook.ts +11 -4
  199. package/src/scripts/hot_context_hook.ts +62 -7
  200. package/src/scripts/inbox_source_census.ts +322 -0
  201. package/src/scripts/install-hooks.sh +82 -0
  202. package/src/scripts/{lint_carrier_integrity.ts → lint_deferral_integrity.ts} +60 -214
  203. package/src/scripts/lint_plan_risk_register.ts +13 -17
  204. package/src/scripts/lint_roadmap_blockers.ts +164 -1
  205. package/src/scripts/mcp_server/consumer_tool_catalog.json +152 -2
  206. package/src/scripts/mcp_server/graph_tools.ts +294 -0
  207. package/src/scripts/mcp_server/path_util.ts +31 -0
  208. package/src/scripts/mcp_server/suggest_skill.ts +72 -0
  209. package/src/scripts/mcp_server/tool_catalog_source.ts +7 -1
  210. package/src/scripts/mcp_server/tools.ts +5 -69
  211. package/src/scripts/media/lib/adapter-contract.md +7 -2
  212. package/src/scripts/media/lib/fixtures/flux/asset-0001.png +0 -0
  213. package/src/scripts/media/lib/fixtures/gemini-image/asset-0001.png +0 -0
  214. package/src/scripts/media/lib/fixtures/ideogram/asset-0001.png +0 -0
  215. package/src/scripts/model_rule_injection.ts +61 -4
  216. package/src/scripts/project_thin_rules.ts +149 -16
  217. package/src/scripts/rdp_candidates_delta.ts +276 -0
  218. package/src/scripts/rdp_quality_eval.ts +217 -19
  219. package/src/scripts/release_mix_taxonomy.json +3 -2
  220. package/src/scripts/report_host_injection_effect.ts +189 -0
  221. package/src/scripts/report_layer_overlap.ts +41 -0
  222. package/src/scripts/report_skill_menu_census.ts +341 -0
  223. package/src/scripts/report_standing_payload_by_host.ts +650 -0
  224. package/src/scripts/schemas/agent-settings.schema.json +7 -1
  225. package/src/scripts/session_memory_index.ts +81 -8
  226. package/src/scripts/skill_tools/score_skill_relevance.ts +70 -6
  227. package/src/scripts/skill_tools/suggest_skill_for_task.ts +37 -3
  228. package/src/server/schemas/settings.ts +23 -4
  229. package/src/vendor/grammars/README.md +86 -0
  230. package/src/vendor/grammars/tree-sitter-javascript.wasm +0 -0
  231. package/src/vendor/grammars/tree-sitter-php.wasm +0 -0
  232. package/src/vendor/grammars/tree-sitter-typescript.wasm +0 -0
  233. package/src/scripts/_lib/carrier_status.ts +0 -118
  234. package/src/scripts/_lib/estate_carrier_cases.ts +0 -72
  235. package/src/scripts/hooks/code_graph_nudge_hook.ts +0 -191
@@ -0,0 +1,173 @@
1
+ #!/usr/bin/env tsx
2
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
3
+ import {
4
+ isCliEntry
5
+ } from "./chunk-5EK5WQN6.js";
6
+ import "./chunk-JO25G5H7.js";
7
+
8
+ // src/agent-src/scripts/roadmap_set_step.ts
9
+ import * as fs from "node:fs";
10
+ import * as path from "node:path";
11
+ import process from "node:process";
12
+ import { fileURLToPath } from "node:url";
13
+ var _HERE = fileURLToPath(import.meta.url);
14
+ var GLYPHS = ["x", " ", "~", "-"];
15
+ var LOCK_STALE_MS = 6e4;
16
+ var RoadmapWriteError = class extends Error {
17
+ };
18
+ function scanSteps(content) {
19
+ const out = [];
20
+ const lines = content.split("\n");
21
+ for (let i = 0; i < lines.length; i += 1) {
22
+ const m = /^(\s*-\s\[)([ x~-])(\]\s?)(.*)$/.exec(lines[i]);
23
+ if (m !== null) out.push({ line: i, glyph: m[2], text: m[4] });
24
+ }
25
+ return out;
26
+ }
27
+ function findStep(content, stepId) {
28
+ const needle = stepId.trim();
29
+ if (needle === "") throw new RoadmapWriteError("step id is empty");
30
+ const strip = (t) => t.replace(/^\*\*/, "");
31
+ const hits = scanSteps(content).filter(
32
+ (s) => s.text.startsWith(needle) || strip(s.text).startsWith(strip(needle))
33
+ );
34
+ if (hits.length === 0) {
35
+ throw new RoadmapWriteError(`no step whose text starts with "${needle}"`);
36
+ }
37
+ if (hits.length > 1) {
38
+ throw new RoadmapWriteError(
39
+ `"${needle}" matches ${String(hits.length)} steps (lines ${hits.map((h) => h.line + 1).join(", ")}) \u2014 refusing rather than picking the first. Give a longer prefix.`
40
+ );
41
+ }
42
+ return hits[0];
43
+ }
44
+ function setGlyphOnLine(content, lineIndex, glyph) {
45
+ const lines = content.split("\n");
46
+ const line = lines[lineIndex];
47
+ if (line === void 0) throw new RoadmapWriteError(`line ${String(lineIndex)} is out of range`);
48
+ const m = /^(\s*-\s\[)([ x~-])(\].*)$/.exec(line);
49
+ if (m === null) throw new RoadmapWriteError(`line ${String(lineIndex + 1)} is not a checkbox line`);
50
+ lines[lineIndex] = `${m[1]}${glyph}${m[3]}`;
51
+ return lines.join("\n");
52
+ }
53
+ function acquireLock(file, nowMs = Date.now()) {
54
+ const lock = `${file}.lock`;
55
+ try {
56
+ fs.writeFileSync(lock, `${String(process.pid)}
57
+ `, { flag: "wx" });
58
+ return lock;
59
+ } catch {
60
+ let age = 0;
61
+ try {
62
+ age = nowMs - fs.statSync(lock).mtimeMs;
63
+ } catch {
64
+ fs.writeFileSync(lock, `${String(process.pid)}
65
+ `, { flag: "wx" });
66
+ return lock;
67
+ }
68
+ if (age > LOCK_STALE_MS) {
69
+ fs.rmSync(lock, { force: true });
70
+ fs.writeFileSync(lock, `${String(process.pid)}
71
+ `, { flag: "wx" });
72
+ return lock;
73
+ }
74
+ throw new RoadmapWriteError(
75
+ `${path.basename(file)} is locked by another writer (${String(Math.round(age / 1e3))}s old) \u2014 refusing`
76
+ );
77
+ }
78
+ }
79
+ function setStep(file, stepId, glyph, nowMs = Date.now()) {
80
+ const lock = acquireLock(file, nowMs);
81
+ try {
82
+ const before = fs.readFileSync(file, "utf8");
83
+ const stepsBefore = scanSteps(before).length;
84
+ const target = findStep(before, stepId);
85
+ const after = setGlyphOnLine(before, target.line, glyph);
86
+ const stepsAfter = scanSteps(after).length;
87
+ if (stepsAfter !== stepsBefore) {
88
+ throw new RoadmapWriteError(
89
+ `structural invariant failed: ${String(stepsBefore)} step(s) before, ${String(stepsAfter)} after. A glyph flip may not change the step count \u2014 this is the signature of a pattern that spanned entries.`
90
+ );
91
+ }
92
+ const tmp = `${file}.${String(process.pid)}.tmp`;
93
+ fs.writeFileSync(tmp, after, "utf8");
94
+ fs.renameSync(tmp, file);
95
+ const verify = fs.readFileSync(file, "utf8");
96
+ const survivors = scanSteps(verify).filter(
97
+ (s) => s.line === target.line && s.glyph === glyph && s.text === target.text
98
+ );
99
+ if (survivors.length !== 1) {
100
+ throw new RoadmapWriteError(
101
+ `write did not survive: expected exactly 1 occurrence of the mutated step, found ${String(survivors.length)}. A parallel writer very likely landed after ours.`
102
+ );
103
+ }
104
+ return { file, line: target.line + 1, from: target.glyph, to: glyph, stepsBefore, stepsAfter };
105
+ } finally {
106
+ fs.rmSync(lock, { force: true });
107
+ }
108
+ }
109
+ function resolvePlan(roots) {
110
+ const found = [];
111
+ for (const root of roots) {
112
+ const dir = path.join(root, "agents", "roadmaps");
113
+ if (!fs.existsSync(dir)) continue;
114
+ for (const name of fs.readdirSync(dir)) {
115
+ if (name.endsWith(".md") && name !== "README.md") found.push(path.join(dir, name));
116
+ }
117
+ }
118
+ if (found.length === 0) throw new RoadmapWriteError("no active roadmap found under any candidate root");
119
+ if (found.length > 1) {
120
+ throw new RoadmapWriteError(
121
+ `ambiguous plan \u2014 ${String(found.length)} active roadmaps in scope:
122
+ ${found.join("\n ")}
123
+ Refusing to choose. Name the file explicitly with --file.`
124
+ );
125
+ }
126
+ return found[0];
127
+ }
128
+ function main(argv = process.argv.slice(2)) {
129
+ const usage = "usage: roadmap_set_step --file <roadmap.md> --step <id-prefix> --glyph <x| |~|->\n Refuses on: an ambiguous step prefix, a changed step count, a write that did not survive.\n";
130
+ if (argv.includes("-h") || argv.includes("--help")) {
131
+ process.stdout.write(usage);
132
+ return 0;
133
+ }
134
+ const val = (flag) => {
135
+ const i = argv.indexOf(flag);
136
+ return i !== -1 && i + 1 < argv.length ? argv[i + 1] : null;
137
+ };
138
+ const file = val("--file");
139
+ const step = val("--step");
140
+ const glyph = val("--glyph");
141
+ if (file === null || step === null || glyph === null || !GLYPHS.includes(glyph)) {
142
+ process.stderr.write(`roadmap_set_step: error: --file, --step and a valid --glyph are required
143
+ ${usage}`);
144
+ return 2;
145
+ }
146
+ try {
147
+ const r = setStep(path.resolve(file), step, glyph);
148
+ process.stdout.write(
149
+ `\u2705 ${path.basename(r.file)}:${String(r.line)} [${r.from}] \u2192 [${r.to}] \xB7 ${String(r.stepsAfter)} step(s) intact
150
+ `
151
+ );
152
+ return 0;
153
+ } catch (e) {
154
+ process.stderr.write(`\u274C ${e instanceof Error ? e.message : String(e)}
155
+ `);
156
+ return e instanceof RoadmapWriteError ? 1 : 2;
157
+ }
158
+ }
159
+ if (isCliEntry(import.meta.url, "roadmap_set_step")) {
160
+ process.exit(main());
161
+ }
162
+ export {
163
+ GLYPHS,
164
+ LOCK_STALE_MS,
165
+ RoadmapWriteError,
166
+ acquireLock,
167
+ findStep,
168
+ main,
169
+ resolvePlan,
170
+ scanSteps,
171
+ setGlyphOnLine,
172
+ setStep
173
+ };
@@ -0,0 +1,47 @@
1
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
2
+ import "./chunk-JO25G5H7.js";
3
+
4
+ // src/agent-src/scripts/stub_queue.ts
5
+ import * as fs from "node:fs";
6
+ import * as path from "node:path";
7
+ var FRONTMATTER_RE = /^---\n([\s\S]*?)\n---[ \t\n\r\f\v]*\n/;
8
+ var OWNER_ROUTING = [
9
+ "owner-reserved",
10
+ "owner reserved",
11
+ "owner: maintainer",
12
+ "reserved to the owner",
13
+ "requires owner",
14
+ "maintainer decision",
15
+ "owner decision",
16
+ "owner sign-off",
17
+ "awaiting the owner"
18
+ ];
19
+ function stub_queue_counts(roadmap_root, today = (/* @__PURE__ */ new Date()).toISOString().slice(0, 10)) {
20
+ const dir = path.join(roadmap_root, "stubs");
21
+ let names;
22
+ try {
23
+ names = fs.readdirSync(dir).filter((n) => n.endsWith(".md") && n !== "README.md");
24
+ } catch {
25
+ return null;
26
+ }
27
+ if (names.length === 0) return null;
28
+ let overdue = 0;
29
+ let owner = 0;
30
+ for (const n of names) {
31
+ let source;
32
+ try {
33
+ source = fs.readFileSync(path.join(dir, n), "utf-8");
34
+ } catch {
35
+ continue;
36
+ }
37
+ const fm = FRONTMATTER_RE.exec(source);
38
+ const due = /^review_by:\s*(\d{4}-\d{2}-\d{2})\s*$/m.exec(fm?.[1] ?? "");
39
+ if (due === null || due[1] <= today) overdue += 1;
40
+ const lower = source.toLowerCase();
41
+ if (OWNER_ROUTING.some((phrase) => lower.includes(phrase))) owner += 1;
42
+ }
43
+ return { overdue, owner };
44
+ }
45
+ export {
46
+ stub_queue_counts
47
+ };
@@ -0,0 +1,38 @@
1
+ #!/usr/bin/env node
2
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
3
+ import {
4
+ BLOCKED_QUICKWIN_FIELDS,
5
+ CADENCE_DAYS,
6
+ CHANGELOG_ERAS,
7
+ QUICKWIN_BLOCKER_CLASSES,
8
+ count_owner_decisions,
9
+ counts,
10
+ due_date,
11
+ headerFragment,
12
+ is_blocked_quickwin,
13
+ main,
14
+ release_dates,
15
+ releases_since,
16
+ repo_root,
17
+ scan,
18
+ scan_dir
19
+ } from "./chunk-ULET4BYS.js";
20
+ import "./chunk-5EK5WQN6.js";
21
+ import "./chunk-JO25G5H7.js";
22
+ export {
23
+ BLOCKED_QUICKWIN_FIELDS,
24
+ CADENCE_DAYS,
25
+ CHANGELOG_ERAS,
26
+ QUICKWIN_BLOCKER_CLASSES,
27
+ count_owner_decisions,
28
+ counts,
29
+ due_date,
30
+ headerFragment,
31
+ is_blocked_quickwin,
32
+ main,
33
+ release_dates,
34
+ releases_since,
35
+ repo_root,
36
+ scan,
37
+ scan_dir
38
+ };
@@ -0,0 +1,59 @@
1
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
2
+ import "./chunk-JO25G5H7.js";
3
+
4
+ // src/agent-src/scripts/ticket_bundles.ts
5
+ import { createRequire } from "node:module";
6
+ import * as fs from "node:fs";
7
+ import * as path from "node:path";
8
+ var _require = createRequire(import.meta.url);
9
+ function _isDir(p) {
10
+ try {
11
+ return fs.statSync(p).isDirectory();
12
+ } catch {
13
+ return false;
14
+ }
15
+ }
16
+ function collect_bundles(repo_root) {
17
+ const reg = path.join(repo_root, "agents", "tickets", "_registry.yml");
18
+ if (!fs.existsSync(reg)) {
19
+ return [];
20
+ }
21
+ let YAML;
22
+ try {
23
+ YAML = _require("yaml");
24
+ } catch {
25
+ return [];
26
+ }
27
+ let data;
28
+ try {
29
+ data = YAML.parse(fs.readFileSync(reg, { encoding: "utf-8" }), { version: "1.1" }) ?? {};
30
+ } catch {
31
+ return [];
32
+ }
33
+ const out = [];
34
+ const bundles = data && typeof data === "object" && !Array.isArray(data) ? data["bundles"] ?? null : null;
35
+ const bundleMap = bundles && typeof bundles === "object" && !Array.isArray(bundles) ? bundles : {};
36
+ for (const slug of Object.keys(bundleMap).sort()) {
37
+ const metaRaw = bundleMap[slug];
38
+ const meta = metaRaw && typeof metaRaw === "object" && !Array.isArray(metaRaw) ? metaRaw : {};
39
+ const bdir = path.join(repo_root, "agents", "tickets", slug);
40
+ let n = 0;
41
+ if (_isDir(bdir)) {
42
+ try {
43
+ n = fs.readdirSync(bdir).filter((f) => f.startsWith("T-") && f.endsWith(".md")).length;
44
+ } catch {
45
+ n = 0;
46
+ }
47
+ }
48
+ out.push({
49
+ slug,
50
+ tickets: n,
51
+ status: meta["status"] ?? "?",
52
+ roadmap: meta["source_roadmap"] ?? ""
53
+ });
54
+ }
55
+ return out;
56
+ }
57
+ export {
58
+ collect_bundles
59
+ };
@@ -0,0 +1,60 @@
1
+ #!/usr/bin/env tsx
2
+ import { createRequire as __acCreateRequire } from 'node:module'; const require = globalThis.require ?? __acCreateRequire(import.meta.url);
3
+ import {
4
+ CHECKBOX_RE,
5
+ FRONTMATTER_RE,
6
+ PHASE_RE,
7
+ PhaseStats,
8
+ RoadmapStats,
9
+ TITLE_RE,
10
+ _pyRound,
11
+ bar,
12
+ blocker_class,
13
+ blocker_is_resolved,
14
+ blocker_needs_user,
15
+ collect,
16
+ collect_bundles,
17
+ count_checkboxes,
18
+ is_roadmap_candidate,
19
+ is_unscheduled,
20
+ main,
21
+ merge_gated_pending,
22
+ parse_blockers,
23
+ parse_frontmatter,
24
+ parse_roadmap,
25
+ pending_iron_law_3,
26
+ render,
27
+ unarchived_complete
28
+ } from "./chunk-QAJS5YWY.js";
29
+ import "./chunk-ULET4BYS.js";
30
+ import "./chunk-5EK5WQN6.js";
31
+ import "./chunk-YWVXLR44.js";
32
+ import "./chunk-7XGD2OEU.js";
33
+ import "./chunk-YDQSHTD7.js";
34
+ import "./chunk-JO25G5H7.js";
35
+ export {
36
+ CHECKBOX_RE,
37
+ FRONTMATTER_RE,
38
+ PHASE_RE,
39
+ PhaseStats,
40
+ RoadmapStats,
41
+ TITLE_RE,
42
+ _pyRound,
43
+ bar,
44
+ blocker_class,
45
+ blocker_is_resolved,
46
+ blocker_needs_user,
47
+ collect,
48
+ collect_bundles,
49
+ count_checkboxes,
50
+ is_roadmap_candidate,
51
+ is_unscheduled,
52
+ main,
53
+ merge_gated_pending,
54
+ parse_blockers,
55
+ parse_frontmatter,
56
+ parse_roadmap,
57
+ pending_iron_law_3,
58
+ render,
59
+ unarchived_complete
60
+ };
@@ -1,6 +1,6 @@
1
1
  # Discovery — Deprecation Report
2
2
 
3
- - Generated: `2026-09-07T14:13:52Z`
3
+ - Generated: `2026-09-09T13:37:07Z`
4
4
  - Deprecated artefacts: **0**
5
5
 
6
6
  _None. Tree is clean._
@@ -361,7 +361,7 @@
361
361
  },
362
362
  {
363
363
  "category": "command",
364
- "checksum": "sha256:1d1332f264559b672056ffff251598bd7ea9115d237d8932e65d457616925dad",
364
+ "checksum": "sha256:e1965998bd3055f5848a07b09168167219f80beffb3adaca8552f446f71a39a6",
365
365
  "install": {
366
366
  "default": true,
367
367
  "removable": false
@@ -486,7 +486,7 @@
486
486
  },
487
487
  {
488
488
  "category": "command",
489
- "checksum": "sha256:2047dbc3f325b811312ecdc170a0215e24327149eb8d94cb1653e34b9d76b2a6",
489
+ "checksum": "sha256:43a65c016638da0d799e876bde537378e056e206c68dcf72ba2c8416f27f8718",
490
490
  "install": {
491
491
  "default": true,
492
492
  "removable": false
@@ -2422,12 +2422,12 @@
2422
2422
  },
2423
2423
  {
2424
2424
  "category": "command",
2425
- "checksum": "sha256:74b20b35447065553ac5e40a22e0fda92e9191d3cd74350cae8895a4fac35337",
2425
+ "checksum": "sha256:21332b2ed898e38da738030ec3add5f2be4f7672ee72e531205dfdaef3d6a26b",
2426
2426
  "install": {
2427
2427
  "default": true,
2428
2428
  "removable": false
2429
2429
  },
2430
- "intent": "Prepare an open PR to mergeable — sync the base in, resolve conflicts semantically, drive required checks green — merging itself is gated and inert",
2430
+ "intent": "Prepare an open PR to mergeable — sync the base in, resolve conflicts semantically, drive required checks green — then merge what the invocation named",
2431
2431
  "lifecycle": "active",
2432
2432
  "name": "git-pr-merge",
2433
2433
  "pack": "git",
@@ -5113,7 +5113,7 @@
5113
5113
  },
5114
5114
  {
5115
5115
  "category": "command",
5116
- "checksum": "sha256:e8de5246b3d5b6631a7ad24e2bea091fe490e0552edacace5c3ac080e9271c12",
5116
+ "checksum": "sha256:5a10124143c2baa3fb481461ce0225f7eaece711ff688811ad66763654fee531",
5117
5117
  "install": {
5118
5118
  "default": true,
5119
5119
  "removable": false
@@ -6361,7 +6361,7 @@
6361
6361
  },
6362
6362
  {
6363
6363
  "category": "rule",
6364
- "checksum": "sha256:3861cd884113414d968a6de79c4f2391da668ff469f17266340e10abe4425815",
6364
+ "checksum": "sha256:c879c0699998f3ebf50d08ec1199b2f78c70e74201af3bdbbb28dc293746758c",
6365
6365
  "install": {
6366
6366
  "default": true,
6367
6367
  "removable": false
@@ -7123,7 +7123,7 @@
7123
7123
  },
7124
7124
  {
7125
7125
  "category": "rule",
7126
- "checksum": "sha256:e89979656ebfee82c9ef2e929e663992c75d3c3115cdd46f209e9f4a426bc99d",
7126
+ "checksum": "sha256:185fe198df456bd7e3b0ed79e2665a29ea0352df338a20e98214c6d88825b4c2",
7127
7127
  "install": {
7128
7128
  "default": true,
7129
7129
  "removable": false
@@ -7998,7 +7998,7 @@
7998
7998
  },
7999
7999
  {
8000
8000
  "category": "rule",
8001
- "checksum": "sha256:dd70f0ea2b5afbc29f8f22039336e91db123cc54d1bbed5c11a8fad260140498",
8001
+ "checksum": "sha256:8e1a0c0f7fccaa87dc91e496561e80e2d9dac9eed54251b66c86b53f5c866fae",
8002
8002
  "install": {
8003
8003
  "default": true,
8004
8004
  "removable": false
@@ -8987,7 +8987,7 @@
8987
8987
  },
8988
8988
  {
8989
8989
  "category": "skill",
8990
- "checksum": "sha256:92818fb17a955560ee92ef421b18b8dd76552c51037e09fcd17b81e676c88334",
8990
+ "checksum": "sha256:90de0462c11d94c41340447e32e4d5d004d540f3d6d9c02ded4634782d481753",
8991
8991
  "install": {
8992
8992
  "default": true,
8993
8993
  "removable": false
@@ -13415,7 +13415,7 @@
13415
13415
  },
13416
13416
  {
13417
13417
  "category": "skill",
13418
- "checksum": "sha256:360a42db776044fa1c4b73d2baaa9b7eee73803af9eea4ce1dc79b953452ebd0",
13418
+ "checksum": "sha256:b7ece37dfb4884630b616914fa0d72449156973383bdd92c9b03e5dc96b52e91",
13419
13419
  "install": {
13420
13420
  "default": true,
13421
13421
  "removable": false
@@ -14141,7 +14141,7 @@
14141
14141
  },
14142
14142
  {
14143
14143
  "category": "skill",
14144
- "checksum": "sha256:6ebc9ffda0b1fd23d47c7606afd1595bbcf1a2cc653a1c83d235281c572c1522",
14144
+ "checksum": "sha256:ca9de1086258a23f5bcc3cd626434545f493f736a67f93eb52621746c136fca6",
14145
14145
  "install": {
14146
14146
  "default": true,
14147
14147
  "removable": false
@@ -14818,7 +14818,7 @@
14818
14818
  "workspaces": []
14819
14819
  }
14820
14820
  ],
14821
- "checksum": "sha256:cf03b5ccd276ba03e81909bd96e990e377a6d0335b59cf003ffd22a8ea2ac2a2",
14821
+ "checksum": "sha256:aa82784e196e180afe8767be33e034fe331d62b7f2f1a257eee5e67a7f61ee89",
14822
14822
  "deprecations": [
14823
14823
  {
14824
14824
  "key": "tier",
@@ -14967,7 +14967,7 @@
14967
14967
  "reason": "scaffold template for ticket-bundle tickets (ADR-101); carries no runtime frontmatter — emit-tickets fills it in per ticket"
14968
14968
  }
14969
14969
  ],
14970
- "generated_at": "2026-09-07T14:13:52Z",
14970
+ "generated_at": "2026-09-09T13:37:07Z",
14971
14971
  "packs": [
14972
14972
  {
14973
14973
  "artefact_count": 128,
@@ -1 +1 @@
1
- d39fa064d7fd108c014186a747f95fec8dd418e52a2120bb58cb19dd3c0593e0 discovery-manifest.json
1
+ d129b3747c38a0ef013d82f0afa89a18a205d4fdb4294fd7b8b427b526d92c7d discovery-manifest.json
@@ -1,6 +1,6 @@
1
1
  # Discovery Manifest — Summary
2
2
 
3
- - Generated: `2026-09-07T14:13:52Z`
3
+ - Generated: `2026-09-09T13:37:07Z`
4
4
  - Scanner: `de0a22b4ac4c`
5
5
  - Artefacts: **625**
6
6
  - Unassigned: **0**
@@ -1,6 +1,6 @@
1
1
  # Discovery — Dormancy Report
2
2
 
3
- - Generated: `2026-09-07T14:13:52Z`
3
+ - Generated: `2026-09-09T13:37:07Z`
4
4
  - Window: **6 months** without a commit
5
5
 
6
6
  > Dormancy triggers **review, never auto-deprecation**
@@ -1,6 +1,6 @@
1
1
  # Discovery — Orphan Report
2
2
 
3
- - Generated: `2026-09-07T14:13:52Z`
3
+ - Generated: `2026-09-09T13:37:07Z`
4
4
  - Orphan artefacts: **0**
5
5
 
6
6
  > An orphan is an artefact whose declared pack has no other members.
@@ -1,6 +1,6 @@
1
1
  {
2
- "checksum": "sha256:cf03b5ccd276ba03e81909bd96e990e377a6d0335b59cf003ffd22a8ea2ac2a2",
3
- "generated_at": "2026-09-07T14:13:52Z",
2
+ "checksum": "sha256:aa82784e196e180afe8767be33e034fe331d62b7f2f1a257eee5e67a7f61ee89",
3
+ "generated_at": "2026-09-09T13:37:07Z",
4
4
  "packs": [
5
5
  {
6
6
  "always_on": false,
@@ -1,6 +1,6 @@
1
1
  # Discovery — Trust Report
2
2
 
3
- - Generated: `2026-09-07T14:13:52Z`
3
+ - Generated: `2026-09-09T13:37:07Z`
4
4
  - Workspaces tracked: **10**
5
5
  - Human-review-required artefacts: **3**
6
6
 
@@ -1,6 +1,6 @@
1
1
  {
2
- "checksum": "sha256:cf03b5ccd276ba03e81909bd96e990e377a6d0335b59cf003ffd22a8ea2ac2a2",
3
- "generated_at": "2026-09-07T14:13:52Z",
2
+ "checksum": "sha256:aa82784e196e180afe8767be33e034fe331d62b7f2f1a257eee5e67a7f61ee89",
3
+ "generated_at": "2026-09-09T13:37:07Z",
4
4
  "scanner_version": "de0a22b4ac4c",
5
5
  "workspaces": [
6
6
  {