@ybotok/loam 0.2.0-alpha.6 → 0.2.0-alpha.9

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 (691) hide show
  1. package/CHANGELOG.md +1477 -1
  2. package/COMPARISON.md +91 -3
  3. package/CONTRIBUTING.md +37 -0
  4. package/MIGRATING-from-OpenSpec.md +40 -22
  5. package/QUICKSTART.md +181 -9
  6. package/README.md +256 -57
  7. package/ROADMAP.md +108 -11
  8. package/SCHEMA.md +721 -130
  9. package/WORKFLOW.md +272 -62
  10. package/dist/cli.js +26 -8
  11. package/dist/cli.js.map +1 -1
  12. package/dist/commands/adopt/adopt.js +5 -10
  13. package/dist/commands/adopt/adopt.js.map +1 -1
  14. package/dist/commands/archive/archive.js +15 -18
  15. package/dist/commands/archive/archive.js.map +1 -1
  16. package/dist/commands/archive/plan/contracts/asyncapi.js +27 -41
  17. package/dist/commands/archive/plan/contracts/asyncapi.js.map +1 -1
  18. package/dist/commands/archive/plan/contracts/consumers.js +56 -0
  19. package/dist/commands/archive/plan/contracts/consumers.js.map +1 -0
  20. package/dist/commands/archive/plan/contracts/openapi.js +25 -42
  21. package/dist/commands/archive/plan/contracts/openapi.js.map +1 -1
  22. package/dist/commands/archive/plan/contracts/verdict-lines.js +41 -0
  23. package/dist/commands/archive/plan/contracts/verdict-lines.js.map +1 -0
  24. package/dist/commands/archive/plan/gate.js +3 -7
  25. package/dist/commands/archive/plan/gate.js.map +1 -1
  26. package/dist/commands/archive/plan/landscape.js +4 -4
  27. package/dist/commands/archive/plan/landscape.js.map +1 -1
  28. package/dist/commands/archive/plan/refusal.js +8 -18
  29. package/dist/commands/archive/plan/refusal.js.map +1 -1
  30. package/dist/commands/archive/plan/specs.js +134 -25
  31. package/dist/commands/archive/plan/specs.js.map +1 -1
  32. package/dist/commands/archive/plan/state.js +1 -0
  33. package/dist/commands/archive/plan/state.js.map +1 -1
  34. package/dist/commands/archive/run.js +82 -33
  35. package/dist/commands/archive/run.js.map +1 -1
  36. package/dist/commands/archive/shipped.js +49 -0
  37. package/dist/commands/archive/shipped.js.map +1 -0
  38. package/dist/commands/context/context.js +4 -7
  39. package/dist/commands/context/context.js.map +1 -1
  40. package/dist/commands/context/print.js +2 -2
  41. package/dist/commands/context/print.js.map +1 -1
  42. package/dist/commands/delta/delta.js +44 -12
  43. package/dist/commands/delta/delta.js.map +1 -1
  44. package/dist/commands/delta/print.js +1 -1
  45. package/dist/commands/delta/print.js.map +1 -1
  46. package/dist/commands/dependencies.js +3 -7
  47. package/dist/commands/dependencies.js.map +1 -1
  48. package/dist/commands/diff/diff.js +20 -27
  49. package/dist/commands/diff/diff.js.map +1 -1
  50. package/dist/commands/explore.js +4 -8
  51. package/dist/commands/explore.js.map +1 -1
  52. package/dist/commands/gate/gate.js +45 -8
  53. package/dist/commands/gate/gate.js.map +1 -1
  54. package/dist/commands/gate/print.js +15 -3
  55. package/dist/commands/gate/print.js.map +1 -1
  56. package/dist/commands/gherkin/commit.js +13 -54
  57. package/dist/commands/gherkin/commit.js.map +1 -1
  58. package/dist/commands/gherkin/gherkin.js +36 -20
  59. package/dist/commands/gherkin/gherkin.js.map +1 -1
  60. package/dist/commands/gherkin/reconcile.js +10 -13
  61. package/dist/commands/gherkin/reconcile.js.map +1 -1
  62. package/dist/commands/init/first-hour.js +44 -0
  63. package/dist/commands/init/first-hour.js.map +1 -1
  64. package/dist/commands/init/init.js +18 -22
  65. package/dist/commands/init/init.js.map +1 -1
  66. package/dist/commands/list/campaign/campaign.js +4 -6
  67. package/dist/commands/list/campaign/campaign.js.map +1 -1
  68. package/dist/commands/list/json.js +0 -4
  69. package/dist/commands/list/json.js.map +1 -1
  70. package/dist/commands/list/list.js +38 -23
  71. package/dist/commands/list/list.js.map +1 -1
  72. package/dist/commands/list/print.js +38 -6
  73. package/dist/commands/list/print.js.map +1 -1
  74. package/dist/commands/list/suites/suites.js +140 -0
  75. package/dist/commands/list/suites/suites.js.map +1 -0
  76. package/dist/commands/list/views.js +28 -33
  77. package/dist/commands/list/views.js.map +1 -1
  78. package/dist/commands/mcp/dispatch.js +91 -36
  79. package/dist/commands/mcp/dispatch.js.map +1 -1
  80. package/dist/commands/mcp/mcp.js +56 -15
  81. package/dist/commands/mcp/mcp.js.map +1 -1
  82. package/dist/commands/mcp/serve.js.map +1 -1
  83. package/dist/commands/migrate-openspec/materialize/active.js +27 -22
  84. package/dist/commands/migrate-openspec/materialize/active.js.map +1 -1
  85. package/dist/commands/migrate-openspec/materialize/stage.js +4 -3
  86. package/dist/commands/migrate-openspec/materialize/stage.js.map +1 -1
  87. package/dist/commands/migrate-openspec/materialize/target.js +2 -2
  88. package/dist/commands/migrate-openspec/materialize/target.js.map +1 -1
  89. package/dist/commands/migrate-openspec/openspec/decisions.js +9 -14
  90. package/dist/commands/migrate-openspec/openspec/decisions.js.map +1 -1
  91. package/dist/commands/migrate-openspec/openspec/error.js +7 -8
  92. package/dist/commands/migrate-openspec/openspec/error.js.map +1 -1
  93. package/dist/commands/migrate-openspec/openspec/mapping.js +1 -9
  94. package/dist/commands/migrate-openspec/openspec/mapping.js.map +1 -1
  95. package/dist/commands/migrate-openspec/openspec/paths.js +3 -6
  96. package/dist/commands/migrate-openspec/openspec/paths.js.map +1 -1
  97. package/dist/commands/new/capability-template.js +118 -0
  98. package/dist/commands/new/capability-template.js.map +1 -0
  99. package/dist/commands/new/commit.js +8 -22
  100. package/dist/commands/new/commit.js.map +1 -1
  101. package/dist/commands/new/modifies.js +206 -0
  102. package/dist/commands/new/modifies.js.map +1 -0
  103. package/dist/commands/new/new.js +59 -14
  104. package/dist/commands/new/new.js.map +1 -1
  105. package/dist/commands/new/templates.js +48 -124
  106. package/dist/commands/new/templates.js.map +1 -1
  107. package/dist/commands/open.js +3 -7
  108. package/dist/commands/open.js.map +1 -1
  109. package/dist/commands/policy/gate.js +27 -0
  110. package/dist/commands/policy/gate.js.map +1 -1
  111. package/dist/commands/rebase/plan.js +2 -2
  112. package/dist/commands/rebase/plan.js.map +1 -1
  113. package/dist/commands/rebase/rebase.js +60 -35
  114. package/dist/commands/rebase/rebase.js.map +1 -1
  115. package/dist/commands/seed/commit.js +55 -26
  116. package/dist/commands/seed/commit.js.map +1 -1
  117. package/dist/commands/seed/plan.js +64 -13
  118. package/dist/commands/seed/plan.js.map +1 -1
  119. package/dist/commands/seed/seed.js +6 -9
  120. package/dist/commands/seed/seed.js.map +1 -1
  121. package/dist/commands/show/show.js +3 -7
  122. package/dist/commands/show/show.js.map +1 -1
  123. package/dist/commands/status/print.js +13 -4
  124. package/dist/commands/status/print.js.map +1 -1
  125. package/dist/commands/status/status.js +3 -7
  126. package/dist/commands/status/status.js.map +1 -1
  127. package/dist/commands/steps/steps.js +3 -7
  128. package/dist/commands/steps/steps.js.map +1 -1
  129. package/dist/commands/subsystem/edit.js +7 -7
  130. package/dist/commands/subsystem/edit.js.map +1 -1
  131. package/dist/commands/subsystem/move.js +60 -25
  132. package/dist/commands/subsystem/move.js.map +1 -1
  133. package/dist/commands/subsystem/query.js +2 -4
  134. package/dist/commands/subsystem/query.js.map +1 -1
  135. package/dist/commands/subsystem/subsystem.js +4 -7
  136. package/dist/commands/subsystem/subsystem.js.map +1 -1
  137. package/dist/commands/subsystem/sync.js +141 -71
  138. package/dist/commands/subsystem/sync.js.map +1 -1
  139. package/dist/commands/subsystem/txn/report.js +55 -5
  140. package/dist/commands/subsystem/txn/report.js.map +1 -1
  141. package/dist/commands/subsystem/txn/txn.js +121 -45
  142. package/dist/commands/subsystem/txn/txn.js.map +1 -1
  143. package/dist/commands/subsystem/txn/views.js +82 -12
  144. package/dist/commands/subsystem/txn/views.js.map +1 -1
  145. package/dist/commands/tasks/render.js +116 -0
  146. package/dist/commands/tasks/render.js.map +1 -0
  147. package/dist/commands/tasks/tasks.js +113 -0
  148. package/dist/commands/tasks/tasks.js.map +1 -0
  149. package/dist/commands/unarchive/manifest.js +6 -9
  150. package/dist/commands/unarchive/manifest.js.map +1 -1
  151. package/dist/commands/unarchive/restore.js +17 -28
  152. package/dist/commands/unarchive/restore.js.map +1 -1
  153. package/dist/commands/unarchive/unarchive.js +22 -30
  154. package/dist/commands/unarchive/unarchive.js.map +1 -1
  155. package/dist/commands/validate/arch-coverage.js +6 -15
  156. package/dist/commands/validate/arch-coverage.js.map +1 -1
  157. package/dist/commands/validate/checks/fleet-shape.js +4 -49
  158. package/dist/commands/validate/checks/fleet-shape.js.map +1 -1
  159. package/dist/commands/validate/checks/health-deps.js +9 -6
  160. package/dist/commands/validate/checks/health-deps.js.map +1 -1
  161. package/dist/commands/validate/checks/requirements.js +18 -8
  162. package/dist/commands/validate/checks/requirements.js.map +1 -1
  163. package/dist/commands/validate/checks/sources.js +6 -2
  164. package/dist/commands/validate/checks/sources.js.map +1 -1
  165. package/dist/commands/validate/feature.js +23 -19
  166. package/dist/commands/validate/feature.js.map +1 -1
  167. package/dist/commands/validate/fleet/census.js +26 -3
  168. package/dist/commands/validate/fleet/census.js.map +1 -1
  169. package/dist/commands/validate/fleet/landscape.js +35 -32
  170. package/dist/commands/validate/fleet/landscape.js.map +1 -1
  171. package/dist/commands/validate/fleet/map/attest.js +7 -12
  172. package/dist/commands/validate/fleet/map/attest.js.map +1 -1
  173. package/dist/commands/validate/fleet/map/bindings.js +16 -5
  174. package/dist/commands/validate/fleet/map/bindings.js.map +1 -1
  175. package/dist/commands/validate/fleet/map/consumers.js +43 -122
  176. package/dist/commands/validate/fleet/map/consumers.js.map +1 -1
  177. package/dist/commands/validate/fleet/map/usecases.js +5 -11
  178. package/dist/commands/validate/fleet/map/usecases.js.map +1 -1
  179. package/dist/commands/validate/fleet/obligations.js +1 -5
  180. package/dist/commands/validate/fleet/obligations.js.map +1 -1
  181. package/dist/commands/validate/fleet/scorecard/print.js +5 -1
  182. package/dist/commands/validate/fleet/scorecard/print.js.map +1 -1
  183. package/dist/commands/validate/fleet/scorecard/scorecard.js +17 -11
  184. package/dist/commands/validate/fleet/scorecard/scorecard.js.map +1 -1
  185. package/dist/commands/validate/fleet/usecases/usecases.js +6 -4
  186. package/dist/commands/validate/fleet/usecases/usecases.js.map +1 -1
  187. package/dist/commands/validate/fleet/views/fleet-project.js +1 -1
  188. package/dist/commands/validate/fleet/views/fleet-project.js.map +1 -1
  189. package/dist/commands/validate/fleet/views/ids.js +33 -7
  190. package/dist/commands/validate/fleet/views/ids.js.map +1 -1
  191. package/dist/commands/validate/fleet/views/root-documents.js +17 -35
  192. package/dist/commands/validate/fleet/views/root-documents.js.map +1 -1
  193. package/dist/commands/validate/fleet/views/stale.js +31 -14
  194. package/dist/commands/validate/fleet/views/stale.js.map +1 -1
  195. package/dist/commands/validate/links/corpus.js +1 -4
  196. package/dist/commands/validate/links/corpus.js.map +1 -1
  197. package/dist/commands/validate/links/glossary.js.map +1 -1
  198. package/dist/commands/validate/report.js +5 -4
  199. package/dist/commands/validate/report.js.map +1 -1
  200. package/dist/commands/validate/scope.js +113 -0
  201. package/dist/commands/validate/scope.js.map +1 -0
  202. package/dist/commands/validate/service/api.js +16 -104
  203. package/dist/commands/validate/service/api.js.map +1 -1
  204. package/dist/commands/validate/service/contracts/generated.js +134 -0
  205. package/dist/commands/validate/service/contracts/generated.js.map +1 -0
  206. package/dist/commands/validate/service/events/events.js +1 -1
  207. package/dist/commands/validate/service/events/events.js.map +1 -1
  208. package/dist/commands/validate/service/events/message-producers.js +1 -1
  209. package/dist/commands/validate/service/events/message-producers.js.map +1 -1
  210. package/dist/commands/validate/service/evidence-pins.js +56 -10
  211. package/dist/commands/validate/service/evidence-pins.js.map +1 -1
  212. package/dist/commands/validate/service/service.js +16 -26
  213. package/dist/commands/validate/service/service.js.map +1 -1
  214. package/dist/commands/validate/service/specs.js +31 -38
  215. package/dist/commands/validate/service/specs.js.map +1 -1
  216. package/dist/commands/validate/service/spine.js +8 -11
  217. package/dist/commands/validate/service/spine.js.map +1 -1
  218. package/dist/commands/validate/service/usecases/usecases.js +3 -3
  219. package/dist/commands/validate/service/usecases/usecases.js.map +1 -1
  220. package/dist/commands/validate/validate.js +44 -26
  221. package/dist/commands/validate/validate.js.map +1 -1
  222. package/dist/commands/verify/cross/diff.js +2 -6
  223. package/dist/commands/verify/cross/diff.js.map +1 -1
  224. package/dist/commands/verify/evidence/contract.js +1 -1
  225. package/dist/commands/verify/evidence/contract.js.map +1 -1
  226. package/dist/commands/verify/evidence/read.js +12 -3
  227. package/dist/commands/verify/evidence/read.js.map +1 -1
  228. package/dist/commands/verify/frozen.js +45 -23
  229. package/dist/commands/verify/frozen.js.map +1 -1
  230. package/dist/commands/verify/record.js +69 -17
  231. package/dist/commands/verify/record.js.map +1 -1
  232. package/dist/commands/verify/report.js +27 -44
  233. package/dist/commands/verify/report.js.map +1 -1
  234. package/dist/commands/verify/results.js +112 -30
  235. package/dist/commands/verify/results.js.map +1 -1
  236. package/dist/commands/verify/verify.js +54 -51
  237. package/dist/commands/verify/verify.js.map +1 -1
  238. package/dist/commands/vouch/pack/pack.js +2 -2
  239. package/dist/commands/vouch/pack/pack.js.map +1 -1
  240. package/dist/commands/vouch/pack/print.js +1 -6
  241. package/dist/commands/vouch/pack/print.js.map +1 -1
  242. package/dist/commands/vouch/pack/sections.js +1 -2
  243. package/dist/commands/vouch/pack/sections.js.map +1 -1
  244. package/dist/commands/vouch/run.js +26 -81
  245. package/dist/commands/vouch/run.js.map +1 -1
  246. package/dist/commands/vouch/sample/plan.js +20 -34
  247. package/dist/commands/vouch/sample/plan.js.map +1 -1
  248. package/dist/commands/vouch/vet/verify.js +39 -7
  249. package/dist/commands/vouch/vet/verify.js.map +1 -1
  250. package/dist/commands/vouch/vouch.js +10 -17
  251. package/dist/commands/vouch/vouch.js.map +1 -1
  252. package/dist/core/agent/agents-md/command-map.js +57 -102
  253. package/dist/core/agent/agents-md/command-map.js.map +1 -1
  254. package/dist/core/agent/agents-md/map/explain.js +4 -3
  255. package/dist/core/agent/agents-md/map/explain.js.map +1 -1
  256. package/dist/core/agent/agents-md/map/lenses/context.js +4 -3
  257. package/dist/core/agent/agents-md/map/lenses/context.js.map +1 -1
  258. package/dist/core/agent/agents-md/map/lenses/diff.js +33 -20
  259. package/dist/core/agent/agents-md/map/lenses/diff.js.map +1 -1
  260. package/dist/core/agent/agents-md/map/lenses/gate.js +13 -5
  261. package/dist/core/agent/agents-md/map/lenses/gate.js.map +1 -1
  262. package/dist/core/agent/agents-md/map/mcp.js +10 -7
  263. package/dist/core/agent/agents-md/map/mcp.js.map +1 -1
  264. package/dist/core/agent/agents-md/map/status.js +9 -3
  265. package/dist/core/agent/agents-md/map/status.js.map +1 -1
  266. package/dist/core/agent/agents-md/map/subsystem.js +31 -17
  267. package/dist/core/agent/agents-md/map/subsystem.js.map +1 -1
  268. package/dist/core/agent/agents-md/map/usecases.js +24 -6
  269. package/dist/core/agent/agents-md/map/usecases.js.map +1 -1
  270. package/dist/core/agent/agents-md/refusals.js +37 -21
  271. package/dist/core/agent/agents-md/refusals.js.map +1 -1
  272. package/dist/core/agent/agents-md.js +25 -10
  273. package/dist/core/agent/agents-md.js.map +1 -1
  274. package/dist/core/agent/agents-stamp.js +10 -0
  275. package/dist/core/agent/agents-stamp.js.map +1 -1
  276. package/dist/core/agent/scaffold.js +10 -15
  277. package/dist/core/agent/scaffold.js.map +1 -1
  278. package/dist/core/agent/tools/dialects.js +1 -0
  279. package/dist/core/agent/tools/dialects.js.map +1 -1
  280. package/dist/core/agent/tools/registry.js +41 -76
  281. package/dist/core/agent/tools/registry.js.map +1 -1
  282. package/dist/core/agent/workflows/adopt.js +5 -3
  283. package/dist/core/agent/workflows/adopt.js.map +1 -1
  284. package/dist/core/agent/workflows/check.js +25 -22
  285. package/dist/core/agent/workflows/check.js.map +1 -1
  286. package/dist/core/agent/workflows/closing.js +54 -21
  287. package/dist/core/agent/workflows/closing.js.map +1 -1
  288. package/dist/core/agent/workflows/feature.js +79 -11
  289. package/dist/core/agent/workflows/feature.js.map +1 -1
  290. package/dist/core/agent/workflows/implement.js +91 -13
  291. package/dist/core/agent/workflows/implement.js.map +1 -1
  292. package/dist/core/agent/workflows/reference/authoring.js +3 -1
  293. package/dist/core/agent/workflows/reference/authoring.js.map +1 -1
  294. package/dist/core/agent/workflows/reference/codes.js +8 -6
  295. package/dist/core/agent/workflows/reference/codes.js.map +1 -1
  296. package/dist/core/agent/workflows/reference/done-check.js +37 -15
  297. package/dist/core/agent/workflows/reference/done-check.js.map +1 -1
  298. package/dist/core/agent/workflows/reference/reference.js.map +1 -1
  299. package/dist/core/agent/workflows/reference/spine.js +62 -24
  300. package/dist/core/agent/workflows/reference/spine.js.map +1 -1
  301. package/dist/core/asyncapi/baseline/plan.js +14 -81
  302. package/dist/core/asyncapi/baseline/plan.js.map +1 -1
  303. package/dist/core/asyncapi/digest.js +30 -25
  304. package/dist/core/asyncapi/digest.js.map +1 -1
  305. package/dist/core/asyncapi/merge/components.js +5 -4
  306. package/dist/core/asyncapi/merge/components.js.map +1 -1
  307. package/dist/core/asyncapi/merge/error.js +7 -2
  308. package/dist/core/asyncapi/merge/error.js.map +1 -1
  309. package/dist/core/asyncapi/merge/markers.js +30 -50
  310. package/dist/core/asyncapi/merge/markers.js.map +1 -1
  311. package/dist/core/asyncapi/merge/merge.js +31 -53
  312. package/dist/core/asyncapi/merge/merge.js.map +1 -1
  313. package/dist/core/asyncapi/merge/pin.js +10 -36
  314. package/dist/core/asyncapi/merge/pin.js.map +1 -1
  315. package/dist/core/asyncapi/model.js.map +1 -1
  316. package/dist/core/asyncapi/read.js +36 -12
  317. package/dist/core/asyncapi/read.js.map +1 -1
  318. package/dist/core/brief/brief.js +30 -25
  319. package/dist/core/brief/brief.js.map +1 -1
  320. package/dist/core/brief/landscape.js +8 -12
  321. package/dist/core/brief/landscape.js.map +1 -1
  322. package/dist/core/brief/map/extend.js +8 -5
  323. package/dist/core/brief/map/extend.js.map +1 -1
  324. package/dist/core/brief/map/owed.js +8 -26
  325. package/dist/core/brief/map/owed.js.map +1 -1
  326. package/dist/core/brief/targets.js +79 -5
  327. package/dist/core/brief/targets.js.map +1 -1
  328. package/dist/core/brief/unchecked.js +1 -1
  329. package/dist/core/brief/unchecked.js.map +1 -1
  330. package/dist/core/c4/likec4.js +147 -16
  331. package/dist/core/c4/likec4.js.map +1 -1
  332. package/dist/core/c4/locate/unlocated.js +150 -0
  333. package/dist/core/c4/locate/unlocated.js.map +1 -0
  334. package/dist/core/c4/parsed/values.js +54 -1
  335. package/dist/core/c4/parsed/values.js.map +1 -1
  336. package/dist/core/c4/prefetch/fleet.js +1 -9
  337. package/dist/core/c4/prefetch/fleet.js.map +1 -1
  338. package/dist/core/c4/project/architecture.js +31 -9
  339. package/dist/core/c4/project/architecture.js.map +1 -1
  340. package/dist/core/c4/project/documents.js +36 -10
  341. package/dist/core/c4/project/documents.js.map +1 -1
  342. package/dist/core/c4/project/load.js +14 -21
  343. package/dist/core/c4/project/load.js.map +1 -1
  344. package/dist/core/c4/project/staged.js +7 -3
  345. package/dist/core/c4/project/staged.js.map +1 -1
  346. package/dist/core/c4/resolve/external.js +51 -0
  347. package/dist/core/c4/resolve/external.js.map +1 -0
  348. package/dist/core/c4/resolve/service.js +25 -1
  349. package/dist/core/c4/resolve/service.js.map +1 -1
  350. package/dist/core/c4/seed/template.js +15 -1
  351. package/dist/core/c4/seed/template.js.map +1 -1
  352. package/dist/core/c4/service-model/shape.js +2 -22
  353. package/dist/core/c4/service-model/shape.js.map +1 -1
  354. package/dist/core/c4/source-mask.js +288 -4
  355. package/dist/core/c4/source-mask.js.map +1 -1
  356. package/dist/core/c4/source-scan.js +203 -147
  357. package/dist/core/c4/source-scan.js.map +1 -1
  358. package/dist/core/c4/splice/authored-source.js +19 -0
  359. package/dist/core/c4/splice/authored-source.js.map +1 -1
  360. package/dist/core/c4/splice/delta-blocks.js +5 -18
  361. package/dist/core/c4/splice/delta-blocks.js.map +1 -1
  362. package/dist/core/c4/splice/landscape-merge.js +13 -8
  363. package/dist/core/c4/splice/landscape-merge.js.map +1 -1
  364. package/dist/core/c4/splice/model/merge.js +10 -6
  365. package/dist/core/c4/splice/model/merge.js.map +1 -1
  366. package/dist/core/c4/splice/placement.js +108 -18
  367. package/dist/core/c4/splice/placement.js.map +1 -1
  368. package/dist/core/c4/workspace.js +13 -22
  369. package/dist/core/c4/workspace.js.map +1 -1
  370. package/dist/core/capabilities/capabilities.js +6 -6
  371. package/dist/core/capabilities/capabilities.js.map +1 -1
  372. package/dist/core/capabilities/delta/doc.js +7 -10
  373. package/dist/core/capabilities/delta/doc.js.map +1 -1
  374. package/dist/core/capabilities/findings.js +15 -20
  375. package/dist/core/capabilities/findings.js.map +1 -1
  376. package/dist/core/capabilities/realizes/findings.js +12 -19
  377. package/dist/core/capabilities/realizes/findings.js.map +1 -1
  378. package/dist/core/capabilities/realizes/join.js +0 -20
  379. package/dist/core/capabilities/realizes/join.js.map +1 -1
  380. package/dist/core/capabilities/rollup.js +6 -0
  381. package/dist/core/capabilities/rollup.js.map +1 -1
  382. package/dist/core/capabilities/tree.js +6 -28
  383. package/dist/core/capabilities/tree.js.map +1 -1
  384. package/dist/core/capabilities/usecase-join.js +3 -13
  385. package/dist/core/capabilities/usecase-join.js.map +1 -1
  386. package/dist/core/coherence/authoring/scaffold.js +11 -3
  387. package/dist/core/coherence/authoring/scaffold.js.map +1 -1
  388. package/dist/core/coherence/authoring/sentinels.js +2 -1
  389. package/dist/core/coherence/authoring/sentinels.js.map +1 -1
  390. package/dist/core/coherence/coherence.js +30 -16
  391. package/dist/core/coherence/coherence.js.map +1 -1
  392. package/dist/core/coherence/consumed/operations.js +70 -0
  393. package/dist/core/coherence/consumed/operations.js.map +1 -0
  394. package/dist/core/coherence/consumed/refusal.js +38 -0
  395. package/dist/core/coherence/consumed/refusal.js.map +1 -0
  396. package/dist/core/coherence/declared.js +60 -34
  397. package/dist/core/coherence/declared.js.map +1 -1
  398. package/dist/core/coherence/events/declared.js +44 -59
  399. package/dist/core/coherence/events/declared.js.map +1 -1
  400. package/dist/core/coherence/events/events.js +119 -8
  401. package/dist/core/coherence/events/events.js.map +1 -1
  402. package/dist/core/coherence/events/grades.js +31 -8
  403. package/dist/core/coherence/events/grades.js.map +1 -1
  404. package/dist/core/coherence/events/lookups.js +14 -82
  405. package/dist/core/coherence/events/lookups.js.map +1 -1
  406. package/dist/core/coherence/lookups.js +18 -78
  407. package/dist/core/coherence/lookups.js.map +1 -1
  408. package/dist/core/coherence/retired/archived.js +285 -0
  409. package/dist/core/coherence/retired/archived.js.map +1 -0
  410. package/dist/core/coherence/retired/event-pair.js +62 -0
  411. package/dist/core/coherence/retired/event-pair.js.map +1 -0
  412. package/dist/core/coherence/retired/merged.js +79 -0
  413. package/dist/core/coherence/retired/merged.js.map +1 -0
  414. package/dist/core/coherence/retired/retirement.js +49 -0
  415. package/dist/core/coherence/retired/retirement.js.map +1 -0
  416. package/dist/core/coherence/retired/revival/arrivals.js +131 -0
  417. package/dist/core/coherence/retired/revival/arrivals.js.map +1 -0
  418. package/dist/core/coherence/retired/revival/revived.js +297 -0
  419. package/dist/core/coherence/retired/revival/revived.js.map +1 -0
  420. package/dist/core/consumers/after.js +113 -0
  421. package/dist/core/consumers/after.js.map +1 -0
  422. package/dist/core/consumers/consumers.js +296 -0
  423. package/dist/core/consumers/consumers.js.map +1 -0
  424. package/dist/core/consumers/current.js +211 -0
  425. package/dist/core/consumers/current.js.map +1 -0
  426. package/dist/core/consumers/scan.js +46 -0
  427. package/dist/core/consumers/scan.js.map +1 -0
  428. package/dist/core/consumers/state.js +27 -0
  429. package/dist/core/consumers/state.js.map +1 -0
  430. package/dist/core/delta/delta.js +1 -1
  431. package/dist/core/delta/delta.js.map +1 -1
  432. package/dist/core/deployment/delta.js +15 -16
  433. package/dist/core/deployment/delta.js.map +1 -1
  434. package/dist/core/diff/base-git.js +94 -12
  435. package/dist/core/diff/base-git.js.map +1 -1
  436. package/dist/core/diff/base-state.js +28 -16
  437. package/dist/core/diff/base-state.js.map +1 -1
  438. package/dist/core/diff/joins.js +136 -0
  439. package/dist/core/diff/joins.js.map +1 -0
  440. package/dist/core/diff/scope/changed-paths.js +22 -6
  441. package/dist/core/diff/scope/changed-paths.js.map +1 -1
  442. package/dist/core/diff/scope/edges.js +82 -0
  443. package/dist/core/diff/scope/edges.js.map +1 -0
  444. package/dist/core/diff/semantic.js +100 -31
  445. package/dist/core/diff/semantic.js.map +1 -1
  446. package/dist/core/doctor/agents.js +34 -18
  447. package/dist/core/doctor/agents.js.map +1 -1
  448. package/dist/core/doctor/report.js.map +1 -1
  449. package/dist/core/document/apply.js +10 -2
  450. package/dist/core/document/apply.js.map +1 -1
  451. package/dist/core/document/frontmatter.js +55 -0
  452. package/dist/core/document/frontmatter.js.map +1 -1
  453. package/dist/core/document/parse.js +29 -6
  454. package/dist/core/document/parse.js.map +1 -1
  455. package/dist/core/document/scenarios.js +17 -0
  456. package/dist/core/document/scenarios.js.map +1 -1
  457. package/dist/core/document/spec.js +4 -11
  458. package/dist/core/document/spec.js.map +1 -1
  459. package/dist/core/envelope/config.js +10 -0
  460. package/dist/core/envelope/config.js.map +1 -1
  461. package/dist/core/envelope/json.js +34 -0
  462. package/dist/core/envelope/json.js.map +1 -1
  463. package/dist/core/explain/families.js +17 -12
  464. package/dist/core/explain/families.js.map +1 -1
  465. package/dist/core/explain/refusals.js +3 -3
  466. package/dist/core/explain/refusals.js.map +1 -1
  467. package/dist/core/explain/terms.js +18 -9
  468. package/dist/core/explain/terms.js.map +1 -1
  469. package/dist/core/explore/explore.js +2 -7
  470. package/dist/core/explore/explore.js.map +1 -1
  471. package/dist/core/fleet-context.js +34 -95
  472. package/dist/core/fleet-context.js.map +1 -1
  473. package/dist/core/gate/checks.js +10 -3
  474. package/dist/core/gate/checks.js.map +1 -1
  475. package/dist/core/gate/partners.js +64 -19
  476. package/dist/core/gate/partners.js.map +1 -1
  477. package/dist/core/gate/report.js.map +1 -1
  478. package/dist/core/gate/verification.js +75 -12
  479. package/dist/core/gate/verification.js.map +1 -1
  480. package/dist/core/gherkin/stale.js +13 -37
  481. package/dist/core/gherkin/stale.js.map +1 -1
  482. package/dist/core/glossary/tree.js +6 -19
  483. package/dist/core/glossary/tree.js.map +1 -1
  484. package/dist/core/kernel/concurrency.js +19 -0
  485. package/dist/core/kernel/concurrency.js.map +1 -1
  486. package/dist/core/kernel/records.js +11 -0
  487. package/dist/core/kernel/records.js.map +1 -1
  488. package/dist/core/links/backlinks.js +1 -3
  489. package/dist/core/links/backlinks.js.map +1 -1
  490. package/dist/core/links/corpus.js +5 -36
  491. package/dist/core/links/corpus.js.map +1 -1
  492. package/dist/core/mcp/argv.js +101 -0
  493. package/dist/core/mcp/argv.js.map +1 -1
  494. package/dist/core/mcp/author-tools.js +2 -1
  495. package/dist/core/mcp/author-tools.js.map +1 -1
  496. package/dist/core/mcp/protocol.js +2 -2
  497. package/dist/core/mcp/protocol.js.map +1 -1
  498. package/dist/core/mcp/tools.js +43 -33
  499. package/dist/core/mcp/tools.js.map +1 -1
  500. package/dist/core/openapi/baseline/gate.js +53 -12
  501. package/dist/core/openapi/baseline/gate.js.map +1 -1
  502. package/dist/core/openapi/baseline/plan.js +22 -8
  503. package/dist/core/openapi/baseline/plan.js.map +1 -1
  504. package/dist/core/openapi/baseline/record.js +0 -1
  505. package/dist/core/openapi/baseline/record.js.map +1 -1
  506. package/dist/core/openapi/contract-text.js +33 -0
  507. package/dist/core/openapi/contract-text.js.map +1 -0
  508. package/dist/core/openapi/contract-tree.js +56 -0
  509. package/dist/core/openapi/contract-tree.js.map +1 -0
  510. package/dist/core/openapi/depth.js +38 -24
  511. package/dist/core/openapi/depth.js.map +1 -1
  512. package/dist/core/openapi/digest.js +52 -2
  513. package/dist/core/openapi/digest.js.map +1 -1
  514. package/dist/core/openapi/doc.js +12 -4
  515. package/dist/core/openapi/doc.js.map +1 -1
  516. package/dist/core/openapi/merge/components.js +25 -60
  517. package/dist/core/openapi/merge/components.js.map +1 -1
  518. package/dist/core/openapi/merge/error.js +3 -13
  519. package/dist/core/openapi/merge/error.js.map +1 -1
  520. package/dist/core/openapi/merge/markers.js +26 -30
  521. package/dist/core/openapi/merge/markers.js.map +1 -1
  522. package/dist/core/openapi/merge/merge.js +26 -52
  523. package/dist/core/openapi/merge/merge.js.map +1 -1
  524. package/dist/core/openapi/merge/pin.js +15 -35
  525. package/dist/core/openapi/merge/pin.js.map +1 -1
  526. package/dist/core/openspec/decide/verdict.js.map +1 -1
  527. package/dist/core/openspec/inventory.js +4 -5
  528. package/dist/core/openspec/inventory.js.map +1 -1
  529. package/dist/core/openspec/model/mapping.js +30 -28
  530. package/dist/core/openspec/model/mapping.js.map +1 -1
  531. package/dist/core/openspec/model/model.js +12 -7
  532. package/dist/core/openspec/model/model.js.map +1 -1
  533. package/dist/core/openspec/scan/changes.js +10 -4
  534. package/dist/core/openspec/scan/changes.js.map +1 -1
  535. package/dist/core/openspec/scan/config.js +7 -16
  536. package/dist/core/openspec/scan/config.js.map +1 -1
  537. package/dist/core/openspec/scan/shape.js +63 -19
  538. package/dist/core/openspec/scan/shape.js.map +1 -1
  539. package/dist/core/openspec/scan/walk.js +21 -38
  540. package/dist/core/openspec/scan/walk.js.map +1 -1
  541. package/dist/core/pack/living.js +2 -16
  542. package/dist/core/pack/living.js.map +1 -1
  543. package/dist/core/provenance/findings.js +48 -12
  544. package/dist/core/provenance/findings.js.map +1 -1
  545. package/dist/core/provenance/git.js +33 -57
  546. package/dist/core/provenance/git.js.map +1 -1
  547. package/dist/core/provenance/gitq/moves.js +71 -114
  548. package/dist/core/provenance/gitq/moves.js.map +1 -1
  549. package/dist/core/provenance/gitq/vouched-ancestor.js +2 -2
  550. package/dist/core/provenance/gitq/vouched-ancestor.js.map +1 -1
  551. package/dist/core/provenance/sources.js +23 -6
  552. package/dist/core/provenance/sources.js.map +1 -1
  553. package/dist/core/provenance/stamp.js +5 -17
  554. package/dist/core/provenance/stamp.js.map +1 -1
  555. package/dist/core/repo/entries.js.map +1 -1
  556. package/dist/core/repo/paths.js +34 -29
  557. package/dist/core/repo/paths.js.map +1 -1
  558. package/dist/core/repo/repo.js +24 -14
  559. package/dist/core/repo/repo.js.map +1 -1
  560. package/dist/core/repo/tree/find.js +12 -3
  561. package/dist/core/repo/tree/find.js.map +1 -1
  562. package/dist/core/repo/tree/fs.js +27 -1
  563. package/dist/core/repo/tree/fs.js.map +1 -1
  564. package/dist/core/repo/tree/render/body.js +45 -6
  565. package/dist/core/repo/tree/render/body.js.map +1 -1
  566. package/dist/core/repo/tree/render/service/header.js +125 -0
  567. package/dist/core/repo/tree/render/service/header.js.map +1 -0
  568. package/dist/core/repo/tree/render/service/peers.js +28 -0
  569. package/dist/core/repo/tree/render/service/peers.js.map +1 -0
  570. package/dist/core/repo/tree/render/service/view-id.js +67 -0
  571. package/dist/core/repo/tree/render/service/view-id.js.map +1 -0
  572. package/dist/core/repo/tree/render/service/views.js +78 -0
  573. package/dist/core/repo/tree/render/service/views.js.map +1 -0
  574. package/dist/core/repo/tree/render/stale.js +19 -2
  575. package/dist/core/repo/tree/render/stale.js.map +1 -1
  576. package/dist/core/repo/tree/render/views.js +102 -33
  577. package/dist/core/repo/tree/render/views.js.map +1 -1
  578. package/dist/core/repo/tree/walk.js +8 -30
  579. package/dist/core/repo/tree/walk.js.map +1 -1
  580. package/dist/core/results.js +47 -12
  581. package/dist/core/results.js.map +1 -1
  582. package/dist/core/staging/commit.js +10 -12
  583. package/dist/core/staging/commit.js.map +1 -1
  584. package/dist/core/staging/lock.js +74 -12
  585. package/dist/core/staging/lock.js.map +1 -1
  586. package/dist/core/staging/recovery/intent.js +2 -5
  587. package/dist/core/staging/recovery/intent.js.map +1 -1
  588. package/dist/core/staging/recovery/recover.js +60 -1
  589. package/dist/core/staging/recovery/recover.js.map +1 -1
  590. package/dist/core/staging/snapshot/manifest.js +152 -0
  591. package/dist/core/staging/snapshot/manifest.js.map +1 -0
  592. package/dist/core/staging/{snapshot.js → snapshot/snapshot.js} +10 -34
  593. package/dist/core/staging/snapshot/snapshot.js.map +1 -0
  594. package/dist/core/status/actions/execution.js +11 -0
  595. package/dist/core/status/actions/execution.js.map +1 -1
  596. package/dist/core/status/feature/artifacts.js +2 -2
  597. package/dist/core/status/feature/artifacts.js.map +1 -1
  598. package/dist/core/status/feature/feature.js +5 -11
  599. package/dist/core/status/feature/feature.js.map +1 -1
  600. package/dist/core/status/fleet/fleet.js +6 -2
  601. package/dist/core/status/fleet/fleet.js.map +1 -1
  602. package/dist/core/status/fleet/next.js +26 -3
  603. package/dist/core/status/fleet/next.js.map +1 -1
  604. package/dist/core/status/report.js.map +1 -1
  605. package/dist/core/status/verification.js +30 -15
  606. package/dist/core/status/verification.js.map +1 -1
  607. package/dist/core/tasks/packet.js +174 -0
  608. package/dist/core/tasks/packet.js.map +1 -0
  609. package/dist/core/tasks/record.js +43 -0
  610. package/dist/core/tasks/record.js.map +1 -0
  611. package/dist/core/tasks/sources.js +181 -0
  612. package/dist/core/tasks/sources.js.map +1 -0
  613. package/dist/core/tasks/stamps.js +76 -0
  614. package/dist/core/tasks/stamps.js.map +1 -0
  615. package/dist/core/tasks/unit.js +0 -0
  616. package/dist/core/tasks/unit.js.map +1 -0
  617. package/dist/core/usecases/capability.js +11 -14
  618. package/dist/core/usecases/capability.js.map +1 -1
  619. package/dist/core/usecases/delta/flows.js +5 -7
  620. package/dist/core/usecases/delta/flows.js.map +1 -1
  621. package/dist/core/usecases/fleet.js +178 -31
  622. package/dist/core/usecases/fleet.js.map +1 -1
  623. package/dist/core/usecases/operations.js +5 -4
  624. package/dist/core/usecases/operations.js.map +1 -1
  625. package/dist/core/usecases/service/flows.js +9 -6
  626. package/dist/core/usecases/service/flows.js.map +1 -1
  627. package/dist/core/usecases/suites/participants.js +83 -0
  628. package/dist/core/usecases/suites/participants.js.map +1 -0
  629. package/dist/core/usecases/suites/suites.js +45 -0
  630. package/dist/core/usecases/suites/suites.js.map +1 -0
  631. package/dist/core/verify/answers.js +12 -5
  632. package/dist/core/verify/answers.js.map +1 -1
  633. package/dist/core/verify/build.js +102 -82
  634. package/dist/core/verify/build.js.map +1 -1
  635. package/dist/core/verify/checklist.js +45 -10
  636. package/dist/core/verify/checklist.js.map +1 -1
  637. package/dist/core/verify/location.js +67 -0
  638. package/dist/core/verify/location.js.map +1 -0
  639. package/dist/core/verify/pins/lint.js +3 -2
  640. package/dist/core/verify/pins/lint.js.map +1 -1
  641. package/dist/core/verify/pins/pin.js +1 -1
  642. package/dist/core/verify/pins/pin.js.map +1 -1
  643. package/dist/core/verify/read/file.js +224 -0
  644. package/dist/core/verify/read/file.js.map +1 -0
  645. package/dist/core/verify/{file.js → read/shape.js} +16 -104
  646. package/dist/core/verify/read/shape.js.map +1 -0
  647. package/dist/core/verify/read/union.js +105 -0
  648. package/dist/core/verify/read/union.js.map +1 -0
  649. package/dist/core/verify/record.js +35 -12
  650. package/dist/core/verify/record.js.map +1 -1
  651. package/dist/core/verify/store/commit.js +40 -30
  652. package/dist/core/verify/store/commit.js.map +1 -1
  653. package/dist/core/verify/store/render.js +8 -4
  654. package/dist/core/verify/store/render.js.map +1 -1
  655. package/dist/core/vocabulary/issue.js +1 -0
  656. package/dist/core/vocabulary/issue.js.map +1 -1
  657. package/dist/core/vocabulary/maturity.js +53 -3
  658. package/dist/core/vocabulary/maturity.js.map +1 -1
  659. package/examples/README.md +28 -9
  660. package/examples/docs/architecture/landscape.likec4 +21 -7
  661. package/examples/docs/architecture/services.likec4 +70 -0
  662. package/examples/docs/architecture/subsystems.likec4 +3 -0
  663. package/examples/docs/architecture/usecases/order-notification.likec4 +6 -2
  664. package/examples/docs/features/FEAT-101-payment-splitting/specs/payment-service/asyncapi.yaml +11 -8
  665. package/examples/docs/features/FEAT-101-payment-splitting/specs/payment-split-service/openapi.yaml +6 -6
  666. package/examples/docs/features/archive/FEAT-088-refunds/specs/payment-service/openapi.yaml +13 -10
  667. package/examples/docs/services/order-service/asyncapi.yaml +3 -2
  668. package/examples/docs/services/order-service/model.likec4 +10 -8
  669. package/examples/docs/services/payment-service/model.likec4 +6 -4
  670. package/examples/docs/services/platform/identity-service/model.likec4 +9 -7
  671. package/examples/docs/services/platform/notification-service/asyncapi.yaml +2 -1
  672. package/examples/docs/services/platform/notification-service/model.likec4 +4 -5
  673. package/package.json +1 -1
  674. package/dist/commands/validate/checks/vocabulary.js +0 -16
  675. package/dist/commands/validate/checks/vocabulary.js.map +0 -1
  676. package/dist/core/agent/agents-md/artifacts.js +0 -221
  677. package/dist/core/agent/agents-md/artifacts.js.map +0 -1
  678. package/dist/core/agent/agents-md/cycle.js +0 -180
  679. package/dist/core/agent/agents-md/cycle.js.map +0 -1
  680. package/dist/core/agent/agents-md/shipped/archive-gate.js +0 -98
  681. package/dist/core/agent/agents-md/shipped/archive-gate.js.map +0 -1
  682. package/dist/core/agent/agents-md/spine.js +0 -40
  683. package/dist/core/agent/agents-md/spine.js.map +0 -1
  684. package/dist/core/coherence/events/merged.js +0 -40
  685. package/dist/core/coherence/events/merged.js.map +0 -1
  686. package/dist/core/diff/current-state.js +0 -96
  687. package/dist/core/diff/current-state.js.map +0 -1
  688. package/dist/core/diff/victims.js +0 -256
  689. package/dist/core/diff/victims.js.map +0 -1
  690. package/dist/core/staging/snapshot.js.map +0 -1
  691. package/dist/core/verify/file.js.map +0 -1
@@ -12,35 +12,48 @@
12
12
  * meaning, the severity and the fix. See ../../command-map.ts's header for why
13
13
  * the gloss left.
14
14
  *
15
- * Same assembly contract as every section: ../../../agents-md.ts concatenates
16
- * with NO join separator, so this string starts at the first character of its
17
- * opening line and ends with the newline that closes its last one.
15
+ * Same assembly contract as every part of the `loam-codes` page:
16
+ * ../../../workflows/reference/codes.ts concatenates with NO join separator,
17
+ * so this string starts at the first character of its opening line and ends
18
+ * with the newline that closes its last one.
18
19
  */
19
20
  export const DIFF_COMMAND = `- \`loam diff --base <ref>\` reports the fleet-meaningful changes between the
20
21
  living docs and a base git ref of the DOCS repo (a branch, \`origin/main\`, a
21
22
  commit sha) — the review lens for a docs-repo PR. Read-only: the base state
22
23
  is read with read-only git questions (\`rev-parse\`/\`ls-tree\`/\`show\`), no
23
24
  checkout, nothing written. \`validate --all\` stays the fleet gate; diff says
24
- what a branch CHANGES, and names who currently depends on every removal.
25
+ what a branch CHANGES, and names the authored consumers of every removal,
26
+ deprecation and modification.
25
27
  Codes, per service and grouped by the artifact they are computed over:
26
28
  \`diff.service-added\` and \`diff.service-removed\` over the \`services/<id>/\`
27
29
  directory; \`diff.requirement-added\`, \`diff.requirement-removed\` and
28
30
  \`diff.requirement-modified\` over spec.md's living requirements;
29
- \`diff.op-added\`, \`diff.op-removed\`, \`diff.op-removed-consumed\` and
30
- \`diff.op-deprecated\` over the OpenAPI contract; \`diff.message-added\`,
31
- \`diff.message-removed\` and \`diff.message-removed-consumed\` over the AsyncAPI
32
- contract; and \`diff.consumer-added\` / \`diff.consumer-removed\` over the
33
- cross-service joins — another service's requirement naming this service's
34
- operation or message. The two \`-consumed\` codes are the errors: they are the
35
- removals something in the fleet still names, with the victims in
36
- \`details[]\`. Exit 0 = diff computed, nothing breaking, everything readable;
37
- exit 1 = a refusal, any error finding (\`breaking: true\` in \`--json\`), or a
38
- subject whose artifact could not be read on either side — those axes are
39
- SUSPENDED and reported (\`unreadable\` in the payload and the summary), never
40
- graded as "nothing changed" or "everything added". Refusals reuse existing
41
- codes: \`repository-unavailable\` when the docs repo has no git history to ask,
42
- and \`unknown-target\` when \`--base\` resolves to no commit there. For the
43
- byte-level OpenAPI breaking-change catalogue, run oasdiff on the two states
44
- of one contract instead — loam deliberately does not reimplement it.
31
+ \`diff.op-added\`, \`diff.op-removed\`, \`diff.op-removed-consumed\`,
32
+ \`diff.op-deprecated\` and \`diff.op-modified\` over the OpenAPI contract;
33
+ \`diff.message-added\`, \`diff.message-removed\`,
34
+ \`diff.message-removed-consumed\` and \`diff.message-modified\` over the
35
+ AsyncAPI contract; and \`diff.consumer-added\` / \`diff.consumer-removed\`
36
+ over the cross-service joins — another service's requirement naming this
37
+ service's operation or message. The two \`-consumed\` codes are the errors:
38
+ they are the removals something in the fleet still names, with the victims
39
+ in \`details[]\` — the same consumers \`loam archive\` refuses a removal on
40
+ (edges of the \`architecture/\` project, both spec files, use-case hops; a
41
+ line naming its own service's operation of the same id is no victim). The two contract \`-modified\` codes are warnings whoever
42
+ is joined: the operation or message changed — its own node or anything its
43
+ \`$ref\`s reach — and \`details[]\` names who to check it against, but loam
44
+ does not grade whether the change breaks them. A landscape edge into the
45
+ provider drawn with no \`metadata { op }\` is listed as a consumer nobody
46
+ could check, never dropped. Exit 0 = diff computed, nothing breaking,
47
+ everything readable; exit 1 = a refusal, any error finding
48
+ (\`breaking: true\` in \`--json\`), or a subject whose artifact could not be
49
+ read on either side — those axes are SUSPENDED and reported (\`unreadable\`
50
+ in the payload and the summary), never graded as "nothing changed" or
51
+ "everything added". An unreadable openapi.yaml or asyncapi.yaml whose bytes
52
+ the base holds identically is skipped instead: the branch did not touch it.
53
+ Refusals reuse existing codes: \`repository-unavailable\`
54
+ when the docs repo has no git history to ask, and \`unknown-target\` when
55
+ \`--base\` resolves to no commit there. For the byte-level breaking-change
56
+ catalogue, run oasdiff (OpenAPI) or \`asyncapi diff\` (AsyncAPI) on the two
57
+ states of one contract instead — loam deliberately does not reimplement it.
45
58
  `;
46
59
  //# sourceMappingURL=diff.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"diff.js","sourceRoot":"","sources":["../../../../../../src/core/agent/agents-md/map/lenses/diff.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;CA0B3B,CAAC","sourcesContent":["/**\n * The `loam diff` entry of the command map — the PR-review lens of this\n * package, split out for `./context.ts`'s exact reason: command-map.ts sat\n * against the file-line limit, so the branch-diff surface's documentation\n * lives down here and is concatenated after the map. It is also the\n * documentation home of the whole `diff.*` code vocabulary, which\n * codes-drift requires.\n *\n * The codes are grouped by the ARTIFACT they are computed over and not\n * glossed: that grouping is what nothing else says, while\n * `loam explain diff.op-removed-consumed` (and every sibling) carries the\n * meaning, the severity and the fix. See ../../command-map.ts's header for why\n * the gloss left.\n *\n * Same assembly contract as every section: ../../../agents-md.ts concatenates\n * with NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n */\nexport const DIFF_COMMAND = `- \\`loam diff --base <ref>\\` reports the fleet-meaningful changes between the\n living docs and a base git ref of the DOCS repo (a branch, \\`origin/main\\`, a\n commit sha) — the review lens for a docs-repo PR. Read-only: the base state\n is read with read-only git questions (\\`rev-parse\\`/\\`ls-tree\\`/\\`show\\`), no\n checkout, nothing written. \\`validate --all\\` stays the fleet gate; diff says\n what a branch CHANGES, and names who currently depends on every removal.\n Codes, per service and grouped by the artifact they are computed over:\n \\`diff.service-added\\` and \\`diff.service-removed\\` over the \\`services/<id>/\\`\n directory; \\`diff.requirement-added\\`, \\`diff.requirement-removed\\` and\n \\`diff.requirement-modified\\` over spec.md's living requirements;\n \\`diff.op-added\\`, \\`diff.op-removed\\`, \\`diff.op-removed-consumed\\` and\n \\`diff.op-deprecated\\` over the OpenAPI contract; \\`diff.message-added\\`,\n \\`diff.message-removed\\` and \\`diff.message-removed-consumed\\` over the AsyncAPI\n contract; and \\`diff.consumer-added\\` / \\`diff.consumer-removed\\` over the\n cross-service joins — another service's requirement naming this service's\n operation or message. The two \\`-consumed\\` codes are the errors: they are the\n removals something in the fleet still names, with the victims in\n \\`details[]\\`. Exit 0 = diff computed, nothing breaking, everything readable;\n exit 1 = a refusal, any error finding (\\`breaking: true\\` in \\`--json\\`), or a\n subject whose artifact could not be read on either side — those axes are\n SUSPENDED and reported (\\`unreadable\\` in the payload and the summary), never\n graded as \"nothing changed\" or \"everything added\". Refusals reuse existing\n codes: \\`repository-unavailable\\` when the docs repo has no git history to ask,\n and \\`unknown-target\\` when \\`--base\\` resolves to no commit there. For the\n byte-level OpenAPI breaking-change catalogue, run oasdiff on the two states\n of one contract instead — loam deliberately does not reimplement it.\n`;\n"]}
1
+ {"version":3,"file":"diff.js","sourceRoot":"","sources":["../../../../../../src/core/agent/agents-md/map/lenses/diff.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsC3B,CAAC","sourcesContent":["/**\n * The `loam diff` entry of the command map — the PR-review lens of this\n * package, split out for `./context.ts`'s exact reason: command-map.ts sat\n * against the file-line limit, so the branch-diff surface's documentation\n * lives down here and is concatenated after the map. It is also the\n * documentation home of the whole `diff.*` code vocabulary, which\n * codes-drift requires.\n *\n * The codes are grouped by the ARTIFACT they are computed over and not\n * glossed: that grouping is what nothing else says, while\n * `loam explain diff.op-removed-consumed` (and every sibling) carries the\n * meaning, the severity and the fix. See ../../command-map.ts's header for why\n * the gloss left.\n *\n * Same assembly contract as every part of the `loam-codes` page:\n * ../../../workflows/reference/codes.ts concatenates with NO join separator,\n * so this string starts at the first character of its opening line and ends\n * with the newline that closes its last one.\n */\nexport const DIFF_COMMAND = `- \\`loam diff --base <ref>\\` reports the fleet-meaningful changes between the\n living docs and a base git ref of the DOCS repo (a branch, \\`origin/main\\`, a\n commit sha) — the review lens for a docs-repo PR. Read-only: the base state\n is read with read-only git questions (\\`rev-parse\\`/\\`ls-tree\\`/\\`show\\`), no\n checkout, nothing written. \\`validate --all\\` stays the fleet gate; diff says\n what a branch CHANGES, and names the authored consumers of every removal,\n deprecation and modification.\n Codes, per service and grouped by the artifact they are computed over:\n \\`diff.service-added\\` and \\`diff.service-removed\\` over the \\`services/<id>/\\`\n directory; \\`diff.requirement-added\\`, \\`diff.requirement-removed\\` and\n \\`diff.requirement-modified\\` over spec.md's living requirements;\n \\`diff.op-added\\`, \\`diff.op-removed\\`, \\`diff.op-removed-consumed\\`,\n \\`diff.op-deprecated\\` and \\`diff.op-modified\\` over the OpenAPI contract;\n \\`diff.message-added\\`, \\`diff.message-removed\\`,\n \\`diff.message-removed-consumed\\` and \\`diff.message-modified\\` over the\n AsyncAPI contract; and \\`diff.consumer-added\\` / \\`diff.consumer-removed\\`\n over the cross-service joins — another service's requirement naming this\n service's operation or message. The two \\`-consumed\\` codes are the errors:\n they are the removals something in the fleet still names, with the victims\n in \\`details[]\\` — the same consumers \\`loam archive\\` refuses a removal on\n (edges of the \\`architecture/\\` project, both spec files, use-case hops; a\n line naming its own service's operation of the same id is no victim). The two contract \\`-modified\\` codes are warnings whoever\n is joined: the operation or message changed — its own node or anything its\n \\`$ref\\`s reach — and \\`details[]\\` names who to check it against, but loam\n does not grade whether the change breaks them. A landscape edge into the\n provider drawn with no \\`metadata { op }\\` is listed as a consumer nobody\n could check, never dropped. Exit 0 = diff computed, nothing breaking,\n everything readable; exit 1 = a refusal, any error finding\n (\\`breaking: true\\` in \\`--json\\`), or a subject whose artifact could not be\n read on either side — those axes are SUSPENDED and reported (\\`unreadable\\`\n in the payload and the summary), never graded as \"nothing changed\" or\n \"everything added\". An unreadable openapi.yaml or asyncapi.yaml whose bytes\n the base holds identically is skipped instead: the branch did not touch it.\n Refusals reuse existing codes: \\`repository-unavailable\\`\n when the docs repo has no git history to ask, and \\`unknown-target\\` when\n \\`--base\\` resolves to no commit there. For the byte-level breaking-change\n catalogue, run oasdiff (OpenAPI) or \\`asyncapi diff\\` (AsyncAPI) on the two\n states of one contract instead — loam deliberately does not reimplement it.\n`;\n"]}
@@ -11,11 +11,12 @@
11
11
  * the meaning, the conditional severity and the fix. See ../../command-map.ts's
12
12
  * header for why the gloss left.
13
13
  *
14
- * Same assembly contract as every section: ../../../agents-md.ts concatenates
15
- * with NO join separator, so this string starts at the first character of its
16
- * opening line and ends with the newline that closes its last one.
14
+ * Same assembly contract as every part of the `loam-codes` page:
15
+ * ../../../workflows/reference/codes.ts concatenates with NO join separator,
16
+ * so this string starts at the first character of its opening line and ends
17
+ * with the newline that closes its last one.
17
18
  */
18
- export const GATE_COMMAND = `- \`loam gate [--service <id>]\` is the DEPLOY-pipeline question — can this
19
+ export const GATE_COMMAND = `- \`loam gate [--service <id>] [--since <ref>]\` is the DEPLOY-pipeline question — can this
19
20
  service deploy, as far as recorded evidence can say — asked as a pure query:
20
21
  it executes nothing, writes nothing, takes no lock, and deliberately changes
21
22
  nothing about what gates \`loam archive\` (verify still never gates the
@@ -40,6 +41,12 @@ export const GATE_COMMAND = `- \`loam gate [--service <id>]\` is the DEPLOY-pipe
40
41
  \`verification\` covers every ACTIVE feature carrying a specs/ delta for the
41
42
  service, through the verification record's own verdicts:
42
43
  \`gate.feature-unverified\` and the reused \`verify.scenario-attested\`.
44
+ Without \`--since\` that is in-flight features only — a feature leaves the
45
+ check the moment it is archived. \`--since <ref>\` (a docs-repo git ref: the
46
+ docs commit the last deploy recorded) also grades every feature archived
47
+ after it, under the same codes, its \`features[]\` row carrying
48
+ \`archived: true\`; it reads git as \`loam diff --base <ref>\` does and refuses
49
+ the same way when git cannot answer.
43
50
  \`interrupted\` reuses \`docs.commit-interrupted\`: a \`.loam-commit\` journal
44
51
  means the docs may be half-written, so nothing graded from them describes one
45
52
  state. One unreadable sibling artifact degrades that ONE subject as
@@ -47,7 +54,8 @@ export const GATE_COMMAND = `- \`loam gate [--service <id>]\` is the DEPLOY-pipe
47
54
  Exit semantics are validate's: any error fails (exit 1, \`verdict: "fail"\`),
48
55
  warnings are advisory (exit 0, \`verdict: "pass"\`), and \`--strict\` is the CI
49
56
  lever that fails warnings too — the report and the \`--json\` payload do not
50
- change under it. The payload carries \`landscape\`
57
+ change under it. The payload carries \`since\` (\`{ ref, commit }\` or
58
+ null), \`landscape\`
51
59
  (\`read\`/\`absent\`/\`invalid\`), \`partners[]\` (each with its maturity
52
60
  rung, role and joins), \`features[]\` (the per-record tallies) and
53
61
  \`checks[]\` (the findings, by check), so a pipeline that wants a stricter
@@ -1 +1 @@
1
- {"version":3,"file":"gate.js","sourceRoot":"","sources":["../../../../../../src/core/agent/agents-md/map/lenses/gate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsC3B,CAAC","sourcesContent":["/**\n * The `loam gate` entry of the command map — the deploy-pipeline lens of this\n * package, split out for `./context.ts`'s exact reason: command-map.ts sat\n * against the file-line limit, so the deploy gate's documentation lives down\n * here and is concatenated after the map. Its four `gate.*` codes are what\n * test/codes-drift.test.ts finds here.\n *\n * The codes are grouped by CHECK and not glossed: which check raises what is\n * the payload's own `checks[]` shape and is the unique thing this section\n * says, while `loam explain gate.partners-unknown` (and every sibling) carries\n * the meaning, the conditional severity and the fix. See ../../command-map.ts's\n * header for why the gloss left.\n *\n * Same assembly contract as every section: ../../../agents-md.ts concatenates\n * with NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n */\nexport const GATE_COMMAND = `- \\`loam gate [--service <id>]\\` is the DEPLOY-pipeline question — can this\n service deploy, as far as recorded evidence can say — asked as a pure query:\n it executes nothing, writes nothing, takes no lock, and deliberately changes\n nothing about what gates \\`loam archive\\` (verify still never gates the\n merge; gate's verdict is advice to a pipeline loam does not own). In a bound\n service repo the invocation is literally \\`loam gate --json\\`; \\`--service\\`\n names any other adopted service, and one nobody adopted refuses\n \\`unknown-service\\` — recorded evidence cannot answer for it. Four checks, and\n the code tells you which one spoke. \\`partners\\` derives the direct joins from\n the LIVING landscape: \\`gate.service-undocumented\\`,\n \\`gate.partner-undocumented\\` and \\`gate.partners-unknown\\` — the last one\n severity-splits on why the map could not answer, so read\n \\`loam explain gate.partners-unknown\\` before treating it as advisory. A\n partner tagged \\`#external\\` is exempt from the middle one on purpose — its\n docs are somebody else's — but an ADOPTED service is never exempt, whatever\n zone the map draws it inside.\n \\`freshness\\` re-reports two staleness findings \\`validate\\` already owns,\n \\`content.stale\\` and \\`sources.stale\\`, over the gated service and its\n documented partners, plus the one integrity error that makes freshness\n unjudgeable, \\`frontmatter.malformed\\`; it decodes the spec bytes itself, so a\n UTF-16 spec.md is a \\`service.unreadable\\` error naming the file, never a quiet\n pass. The rest of provenance stays \\`validate\\`'s report to make.\n \\`verification\\` covers every ACTIVE feature carrying a specs/ delta for the\n service, through the verification record's own verdicts:\n \\`gate.feature-unverified\\` and the reused \\`verify.scenario-attested\\`.\n \\`interrupted\\` reuses \\`docs.commit-interrupted\\`: a \\`.loam-commit\\` journal\n means the docs may be half-written, so nothing graded from them describes one\n state. One unreadable sibling artifact degrades that ONE subject as\n \\`service.unreadable\\` / \\`feature.unreadable\\` instead of killing the report.\n Exit semantics are validate's: any error fails (exit 1, \\`verdict: \"fail\"\\`),\n warnings are advisory (exit 0, \\`verdict: \"pass\"\\`), and \\`--strict\\` is the CI\n lever that fails warnings too — the report and the \\`--json\\` payload do not\n change under it. The payload carries \\`landscape\\`\n (\\`read\\`/\\`absent\\`/\\`invalid\\`), \\`partners[]\\` (each with its maturity\n rung, role and joins), \\`features[]\\` (the per-record tallies) and\n \\`checks[]\\` (the findings, by check), so a pipeline that wants a stricter\n bar — \\`vouched\\` partners, no attested scenarios — branches on the data\n rather than waiting for a flag.\n`;\n"]}
1
+ {"version":3,"file":"gate.js","sourceRoot":"","sources":["../../../../../../src/core/agent/agents-md/map/lenses/gate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6C3B,CAAC","sourcesContent":["/**\n * The `loam gate` entry of the command map — the deploy-pipeline lens of this\n * package, split out for `./context.ts`'s exact reason: command-map.ts sat\n * against the file-line limit, so the deploy gate's documentation lives down\n * here and is concatenated after the map. Its four `gate.*` codes are what\n * test/codes-drift.test.ts finds here.\n *\n * The codes are grouped by CHECK and not glossed: which check raises what is\n * the payload's own `checks[]` shape and is the unique thing this section\n * says, while `loam explain gate.partners-unknown` (and every sibling) carries\n * the meaning, the conditional severity and the fix. See ../../command-map.ts's\n * header for why the gloss left.\n *\n * Same assembly contract as every part of the `loam-codes` page:\n * ../../../workflows/reference/codes.ts concatenates with NO join separator,\n * so this string starts at the first character of its opening line and ends\n * with the newline that closes its last one.\n */\nexport const GATE_COMMAND = `- \\`loam gate [--service <id>] [--since <ref>]\\` is the DEPLOY-pipeline question — can this\n service deploy, as far as recorded evidence can say — asked as a pure query:\n it executes nothing, writes nothing, takes no lock, and deliberately changes\n nothing about what gates \\`loam archive\\` (verify still never gates the\n merge; gate's verdict is advice to a pipeline loam does not own). In a bound\n service repo the invocation is literally \\`loam gate --json\\`; \\`--service\\`\n names any other adopted service, and one nobody adopted refuses\n \\`unknown-service\\` — recorded evidence cannot answer for it. Four checks, and\n the code tells you which one spoke. \\`partners\\` derives the direct joins from\n the LIVING landscape: \\`gate.service-undocumented\\`,\n \\`gate.partner-undocumented\\` and \\`gate.partners-unknown\\` — the last one\n severity-splits on why the map could not answer, so read\n \\`loam explain gate.partners-unknown\\` before treating it as advisory. A\n partner tagged \\`#external\\` is exempt from the middle one on purpose — its\n docs are somebody else's — but an ADOPTED service is never exempt, whatever\n zone the map draws it inside.\n \\`freshness\\` re-reports two staleness findings \\`validate\\` already owns,\n \\`content.stale\\` and \\`sources.stale\\`, over the gated service and its\n documented partners, plus the one integrity error that makes freshness\n unjudgeable, \\`frontmatter.malformed\\`; it decodes the spec bytes itself, so a\n UTF-16 spec.md is a \\`service.unreadable\\` error naming the file, never a quiet\n pass. The rest of provenance stays \\`validate\\`'s report to make.\n \\`verification\\` covers every ACTIVE feature carrying a specs/ delta for the\n service, through the verification record's own verdicts:\n \\`gate.feature-unverified\\` and the reused \\`verify.scenario-attested\\`.\n Without \\`--since\\` that is in-flight features only — a feature leaves the\n check the moment it is archived. \\`--since <ref>\\` (a docs-repo git ref: the\n docs commit the last deploy recorded) also grades every feature archived\n after it, under the same codes, its \\`features[]\\` row carrying\n \\`archived: true\\`; it reads git as \\`loam diff --base <ref>\\` does and refuses\n the same way when git cannot answer.\n \\`interrupted\\` reuses \\`docs.commit-interrupted\\`: a \\`.loam-commit\\` journal\n means the docs may be half-written, so nothing graded from them describes one\n state. One unreadable sibling artifact degrades that ONE subject as\n \\`service.unreadable\\` / \\`feature.unreadable\\` instead of killing the report.\n Exit semantics are validate's: any error fails (exit 1, \\`verdict: \"fail\"\\`),\n warnings are advisory (exit 0, \\`verdict: \"pass\"\\`), and \\`--strict\\` is the CI\n lever that fails warnings too — the report and the \\`--json\\` payload do not\n change under it. The payload carries \\`since\\` (\\`{ ref, commit }\\` or\n null), \\`landscape\\`\n (\\`read\\`/\\`absent\\`/\\`invalid\\`), \\`partners[]\\` (each with its maturity\n rung, role and joins), \\`features[]\\` (the per-record tallies) and\n \\`checks[]\\` (the findings, by check), so a pipeline that wants a stricter\n bar — \\`vouched\\` partners, no attested scenarios — branches on the data\n rather than waiting for a flag.\n`;\n"]}
@@ -5,9 +5,10 @@
5
5
  * concatenated after the map. It introduces no codes of its own: every tool
6
6
  * result is an existing envelope, which is the point of the section.
7
7
  *
8
- * Same assembly contract as every section: ../../agents-md.ts concatenates
9
- * with NO join separator, so this string starts at the first character of its
10
- * opening line and ends with the newline that closes its last one.
8
+ * Same assembly contract as every part of the `loam-codes` page:
9
+ * ../../workflows/reference/codes.ts concatenates with NO join separator, so this
10
+ * string starts at the first character of its opening line and ends with
11
+ * the newline that closes its last one.
11
12
  *
12
13
  * The command names in the roster below are HAND-LISTED: importing
13
14
  * core/mcp/tools.ts from here would close a package cycle (tools.ts reads
@@ -15,9 +16,9 @@
15
16
  * sources). test/mcp-protocol.test.ts pins this string against MCP_TOOLS
16
17
  * instead: a tool added to the table without its name here fails there.
17
18
  */
18
- export const MCP_COMMAND = `- \`loam mcp\` serves the fourteen base read commands — validate, status, list, show,
19
- delta, diff, explore, dependencies, doctor, context, gate, steps, explain,
20
- instructions — as MCP tools over stdio (JSON-RPC 2.0), for hosts that reach
19
+ export const MCP_COMMAND = `- \`loam mcp\` serves the sixteen base read commands — validate, status, list, show,
20
+ delta, tasks, diff, explore, dependencies, doctor, context, adopt, gate, steps,
21
+ explain, instructions — as MCP tools over stdio (JSON-RPC 2.0), for hosts that reach
21
22
  tools through MCP rather than a shell:
22
23
  configure the host to launch \`loam mcp\` in the repository the tools should
23
24
  answer for, or run \`loam init --mcp\` there and let it write the \`.mcp.json\`
@@ -33,7 +34,9 @@ export const MCP_COMMAND = `- \`loam mcp\` serves the fourteen base read command
33
34
  \`instructions\`, are served so an MCP-only host can reach them BEFORE this
34
35
  repository is wired: the first line of every generated skill is
35
36
  \`loam instructions <workflow>\`, and a host that could not run it could not
36
- fetch the protocol its own skill points at. An explicit \`mcp --author\` adds
37
+ fetch the protocol its own skill points at. \`adopt\` is served because it
38
+ writes nothing: the loam-adopt protocol opens by running it, and its brief is
39
+ what the agent then writes from. An explicit \`mcp --author\` adds
37
40
  \`new\`, \`rebase\`, \`gherkin\` and an archive dry-run. It never exposes
38
41
  \`vouch\`, evidence recording or a committing archive; those stay in the CLI,
39
42
  where the permission flow is yours.
@@ -1 +1 @@
1
- {"version":3,"file":"mcp.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG;;;;;;;;;;;;;;;;;;;;;;CAsB1B,CAAC","sourcesContent":["/**\n * The `loam mcp` entry of the command map — its own section module for\n * `./lenses/gate.ts`'s exact reason: command-map.ts sat against the file-line limit,\n * so the MCP facade's documentation lives one package down and is\n * concatenated after the map. It introduces no codes of its own: every tool\n * result is an existing envelope, which is the point of the section.\n *\n * Same assembly contract as every section: ../../agents-md.ts concatenates\n * with NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n *\n * The command names in the roster below are HAND-LISTED: importing\n * core/mcp/tools.ts from here would close a package cycle (tools.ts reads\n * core/explain/terms.ts, which reads this package's siblings for its pin\n * sources). test/mcp-protocol.test.ts pins this string against MCP_TOOLS\n * instead: a tool added to the table without its name here fails there.\n */\nexport const MCP_COMMAND = `- \\`loam mcp\\` serves the fourteen base read commands — validate, status, list, show,\n delta, diff, explore, dependencies, doctor, context, gate, steps, explain,\n instructions — as MCP tools over stdio (JSON-RPC 2.0), for hosts that reach\n tools through MCP rather than a shell:\n configure the host to launch \\`loam mcp\\` in the repository the tools should\n answer for, or run \\`loam init --mcp\\` there and let it write the \\`.mcp.json\\`\n every host reads. Like every other file \\`init\\` lays down, an existing one is\n reported and never merged into. Every tool result carries the same \\`--json\\` envelope the CLI\n prints, verbatim, so everything above about codes and envelopes applies\n unchanged — branch on \\`ok\\` and \\`error.code\\` exactly as you would reading\n the command's stdout. The orientation and instruction pages are MCP resources,\n and every tool declares the envelope output schema. Every base tool is advertised with\n \\`annotations.readOnlyHint: true\\` — the machine signal a host needs to\n approve a call without prompting, and the reason the table stays read-only\n by construction. The two that read no config, \\`explain\\` and\n \\`instructions\\`, are served so an MCP-only host can reach them BEFORE this\n repository is wired: the first line of every generated skill is\n \\`loam instructions <workflow>\\`, and a host that could not run it could not\n fetch the protocol its own skill points at. An explicit \\`mcp --author\\` adds\n \\`new\\`, \\`rebase\\`, \\`gherkin\\` and an archive dry-run. It never exposes\n \\`vouch\\`, evidence recording or a committing archive; those stay in the CLI,\n where the permission flow is yours.\n`;\n"]}
1
+ {"version":3,"file":"mcp.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG;;;;;;;;;;;;;;;;;;;;;;;;CAwB1B,CAAC","sourcesContent":["/**\n * The `loam mcp` entry of the command map — its own section module for\n * `./lenses/gate.ts`'s exact reason: command-map.ts sat against the file-line limit,\n * so the MCP facade's documentation lives one package down and is\n * concatenated after the map. It introduces no codes of its own: every tool\n * result is an existing envelope, which is the point of the section.\n *\n * Same assembly contract as every part of the `loam-codes` page:\n * ../../workflows/reference/codes.ts concatenates with NO join separator, so this\n * string starts at the first character of its opening line and ends with\n * the newline that closes its last one.\n *\n * The command names in the roster below are HAND-LISTED: importing\n * core/mcp/tools.ts from here would close a package cycle (tools.ts reads\n * core/explain/terms.ts, which reads this package's siblings for its pin\n * sources). test/mcp-protocol.test.ts pins this string against MCP_TOOLS\n * instead: a tool added to the table without its name here fails there.\n */\nexport const MCP_COMMAND = `- \\`loam mcp\\` serves the sixteen base read commands — validate, status, list, show,\n delta, tasks, diff, explore, dependencies, doctor, context, adopt, gate, steps,\n explain, instructions — as MCP tools over stdio (JSON-RPC 2.0), for hosts that reach\n tools through MCP rather than a shell:\n configure the host to launch \\`loam mcp\\` in the repository the tools should\n answer for, or run \\`loam init --mcp\\` there and let it write the \\`.mcp.json\\`\n every host reads. Like every other file \\`init\\` lays down, an existing one is\n reported and never merged into. Every tool result carries the same \\`--json\\` envelope the CLI\n prints, verbatim, so everything above about codes and envelopes applies\n unchanged — branch on \\`ok\\` and \\`error.code\\` exactly as you would reading\n the command's stdout. The orientation and instruction pages are MCP resources,\n and every tool declares the envelope output schema. Every base tool is advertised with\n \\`annotations.readOnlyHint: true\\` — the machine signal a host needs to\n approve a call without prompting, and the reason the table stays read-only\n by construction. The two that read no config, \\`explain\\` and\n \\`instructions\\`, are served so an MCP-only host can reach them BEFORE this\n repository is wired: the first line of every generated skill is\n \\`loam instructions <workflow>\\`, and a host that could not run it could not\n fetch the protocol its own skill points at. \\`adopt\\` is served because it\n writes nothing: the loam-adopt protocol opens by running it, and its brief is\n what the agent then writes from. An explicit \\`mcp --author\\` adds\n \\`new\\`, \\`rebase\\`, \\`gherkin\\` and an archive dry-run. It never exposes\n \\`vouch\\`, evidence recording or a committing archive; those stay in the CLI,\n where the permission flow is yours.\n`;\n"]}
@@ -35,7 +35,11 @@ export const STATUS_COMMAND = `- \`loam status [<FEAT>]\` is the orientation sur
35
35
  never elided: a \`.loam-commit\` journal says a writer was killed mid-commit, so
36
36
  some of the files everything else is derived from may be half-written.
37
37
  Fleet-wide the rest are \`next.adopt-bound\`, \`next.adopt\`,
38
- \`next.complete-service\`, \`next.feature\`, \`next.archive\`, \`next.fleet-clean\`,
38
+ \`next.complete-service\`, \`next.revouch\` (a vouched document's words moved
39
+ under its stamp — \`content.stale\`; its \`execution\` is a human review, never
40
+ yours to run: prepare \`loam vouch --pack --service <id>\` and hand the vouch
41
+ to a person),
42
+ \`next.feature\`, \`next.archive\`, \`next.fleet-clean\`,
39
43
  \`next.elided\` (the fleet list hit its cap and says how many steps of the same
40
44
  kinds it left out — it is ordered most-unblocking first, so work down it and
41
45
  re-run) and \`next.fleet-gate\`, always last while anything is outstanding:
@@ -56,7 +60,9 @@ export const STATUS_COMMAND = `- \`loam status [<FEAT>]\` is the orientation sur
56
60
  so it may be more pessimistic than either and can never be greener than both.
57
61
  \`verification\` carries \`verdict\` (\`verified\` | \`attested\` | \`unverified\`)
58
62
  and \`attested\` (how many scenario claims rest on an agent's word) beside the
59
- recounted totals, and \`checks.issues[]\` carries \`gates\` and \`details\` on every
60
- finding.
63
+ recounted totals, plus \`answered\` (the confirmed claims per \`answered_by\`:
64
+ \`runner\`, \`external-runner\`, \`agent\` — a \`verified\` record can still rest
65
+ partly on an agent's word about kinds the verdict does not turn on), and
66
+ \`checks.issues[]\` carries \`gates\` and \`details\` on every finding.
61
67
  `;
62
68
  //# sourceMappingURL=status.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"status.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/status.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAwC7B,CAAC","sourcesContent":["/**\n * The `loam status` entry of the command map — its own section module for\n * `./mcp.ts`'s exact reason: command-map.ts sat against the file-line limit,\n * so the orientation surface's documentation lives one package down. Unlike\n * its siblings it is not concatenated AFTER the map: status is deliberately\n * the map's FIRST bullet, so ../command-map.ts composes it into COMMAND_MAP\n * between the preamble and the validate entries. The `next.*` fleet and\n * feature codes are what test/codes-drift.test.ts finds here.\n *\n * The `next.*` codes are LISTED, not glossed: `loam explain next.adopt` (and\n * every sibling) answers what a step means and what to run, out of the binary\n * rather than out of this file. See ../command-map.ts's header for why the\n * gloss left. What survives here is what `explain` cannot say — that the list\n * splits fleet-wide from per-feature, and that `next.recover-commit` outranks\n * everything in both forms.\n *\n * Same assembly contract as every section: the composition concatenates with\n * NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n */\nexport const STATUS_COMMAND = `- \\`loam status [<FEAT>]\\` is the orientation surface — the question you have when\n you join a repository halfway, or come back having lost the session, and the one\n every other command assumed you could already answer. It writes nothing and\n stores nothing: there is no state file, every answer is re-derived from the\n files, so a document someone edited in another window is visible on the next run\n with nothing to invalidate. Artifacts come back as \\`missing\\` (owed, nothing in\n the way — write it now), \\`blocked\\` (not written and not writable yet; the entry\n names what comes first), \\`draft\\` (on disk, and the shared checks report an error\n against it — what exists is wrong), \\`ready\\` (on disk and clean, but something\n outside the documents — code, a test run, a recording — still has to answer it)\n or \\`done\\`. The payload's reason to exist is \\`next[]\\`: ordered, first entry\n first, each carrying a code and the literal command to run — so a step needs no\n gloss here, and \\`loam explain <code>\\` has the long form of any of them.\n \\`next.recover-commit\\` outranks every other step in both forms below and is\n never elided: a \\`.loam-commit\\` journal says a writer was killed mid-commit, so\n some of the files everything else is derived from may be half-written.\n Fleet-wide the rest are \\`next.adopt-bound\\`, \\`next.adopt\\`,\n \\`next.complete-service\\`, \\`next.feature\\`, \\`next.archive\\`, \\`next.fleet-clean\\`,\n \\`next.elided\\` (the fleet list hit its cap and says how many steps of the same\n kinds it left out — it is ordered most-unblocking first, so work down it and\n re-run) and \\`next.fleet-gate\\`, always last while anything is outstanding:\n \\`loam validate --all\\` is what CI runs, and the fleet form grades nothing\n itself. A docs repo with no services and no features instead gets the\n first-hour ladder — \\`next.author-landscape\\`, \\`next.bind-service\\`,\n \\`next.adopt-first\\` — which the \\`/loam-adopt\\` body walks.\n On one feature: \\`next.author-intent\\`, \\`next.touch-service\\`,\n \\`next.author-spec\\`, \\`next.author-openapi\\`, \\`next.author-scenarios\\`,\n \\`next.rebase\\`, \\`next.archive-first\\`, \\`next.fix-coherence\\`,\n \\`next.generate-tests\\`, \\`next.verify\\`, \\`next.verify-unconfirmed\\`,\n \\`next.attest-service\\` (this repo IS one of the services that owes an answer,\n so the step is bound to this commit), \\`next.verify-attested\\` — see\n \"The done-check\" for what attested costs — \\`next.archive\\`, and\n \\`next.archived\\` for one that shipped.\n It grades nothing of its own: the verdict is the one \\`loam validate --feature\\`\n and \\`loam archive\\` compute — status takes the UNION of what both of them refuse,\n so it may be more pessimistic than either and can never be greener than both.\n \\`verification\\` carries \\`verdict\\` (\\`verified\\` | \\`attested\\` | \\`unverified\\`)\n and \\`attested\\` (how many scenario claims rest on an agent's word) beside the\n recounted totals, and \\`checks.issues[]\\` carries \\`gates\\` and \\`details\\` on every\n finding.\n`;\n"]}
1
+ {"version":3,"file":"status.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/status.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8C7B,CAAC","sourcesContent":["/**\n * The `loam status` entry of the command map — its own section module for\n * `./mcp.ts`'s exact reason: command-map.ts sat against the file-line limit,\n * so the orientation surface's documentation lives one package down. Unlike\n * its siblings it is not concatenated AFTER the map: status is deliberately\n * the map's FIRST bullet, so ../command-map.ts composes it into COMMAND_MAP\n * between the preamble and the validate entries. The `next.*` fleet and\n * feature codes are what test/codes-drift.test.ts finds here.\n *\n * The `next.*` codes are LISTED, not glossed: `loam explain next.adopt` (and\n * every sibling) answers what a step means and what to run, out of the binary\n * rather than out of this file. See ../command-map.ts's header for why the\n * gloss left. What survives here is what `explain` cannot say — that the list\n * splits fleet-wide from per-feature, and that `next.recover-commit` outranks\n * everything in both forms.\n *\n * Same assembly contract as every section: the composition concatenates with\n * NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n */\nexport const STATUS_COMMAND = `- \\`loam status [<FEAT>]\\` is the orientation surface — the question you have when\n you join a repository halfway, or come back having lost the session, and the one\n every other command assumed you could already answer. It writes nothing and\n stores nothing: there is no state file, every answer is re-derived from the\n files, so a document someone edited in another window is visible on the next run\n with nothing to invalidate. Artifacts come back as \\`missing\\` (owed, nothing in\n the way — write it now), \\`blocked\\` (not written and not writable yet; the entry\n names what comes first), \\`draft\\` (on disk, and the shared checks report an error\n against it — what exists is wrong), \\`ready\\` (on disk and clean, but something\n outside the documents — code, a test run, a recording — still has to answer it)\n or \\`done\\`. The payload's reason to exist is \\`next[]\\`: ordered, first entry\n first, each carrying a code and the literal command to run — so a step needs no\n gloss here, and \\`loam explain <code>\\` has the long form of any of them.\n \\`next.recover-commit\\` outranks every other step in both forms below and is\n never elided: a \\`.loam-commit\\` journal says a writer was killed mid-commit, so\n some of the files everything else is derived from may be half-written.\n Fleet-wide the rest are \\`next.adopt-bound\\`, \\`next.adopt\\`,\n \\`next.complete-service\\`, \\`next.revouch\\` (a vouched document's words moved\n under its stamp — \\`content.stale\\`; its \\`execution\\` is a human review, never\n yours to run: prepare \\`loam vouch --pack --service <id>\\` and hand the vouch\n to a person),\n \\`next.feature\\`, \\`next.archive\\`, \\`next.fleet-clean\\`,\n \\`next.elided\\` (the fleet list hit its cap and says how many steps of the same\n kinds it left out — it is ordered most-unblocking first, so work down it and\n re-run) and \\`next.fleet-gate\\`, always last while anything is outstanding:\n \\`loam validate --all\\` is what CI runs, and the fleet form grades nothing\n itself. A docs repo with no services and no features instead gets the\n first-hour ladder — \\`next.author-landscape\\`, \\`next.bind-service\\`,\n \\`next.adopt-first\\` — which the \\`/loam-adopt\\` body walks.\n On one feature: \\`next.author-intent\\`, \\`next.touch-service\\`,\n \\`next.author-spec\\`, \\`next.author-openapi\\`, \\`next.author-scenarios\\`,\n \\`next.rebase\\`, \\`next.archive-first\\`, \\`next.fix-coherence\\`,\n \\`next.generate-tests\\`, \\`next.verify\\`, \\`next.verify-unconfirmed\\`,\n \\`next.attest-service\\` (this repo IS one of the services that owes an answer,\n so the step is bound to this commit), \\`next.verify-attested\\` — see\n \"The done-check\" for what attested costs — \\`next.archive\\`, and\n \\`next.archived\\` for one that shipped.\n It grades nothing of its own: the verdict is the one \\`loam validate --feature\\`\n and \\`loam archive\\` compute — status takes the UNION of what both of them refuse,\n so it may be more pessimistic than either and can never be greener than both.\n \\`verification\\` carries \\`verdict\\` (\\`verified\\` | \\`attested\\` | \\`unverified\\`)\n and \\`attested\\` (how many scenario claims rest on an agent's word) beside the\n recounted totals, plus \\`answered\\` (the confirmed claims per \\`answered_by\\`:\n \\`runner\\`, \\`external-runner\\`, \\`agent\\` — a \\`verified\\` record can still rest\n partly on an agent's word about kinds the verdict does not turn on), and\n \\`checks.issues[]\\` carries \\`gates\\` and \\`details\\` on every finding.\n`;\n"]}
@@ -4,9 +4,10 @@
4
4
  * package against the five-file cap, so the tree surface's documentation
5
5
  * lives one package down and is concatenated after the map.
6
6
  *
7
- * Same assembly contract as every section: ../agents-md.ts concatenates with
8
- * NO join separator, so this string starts at the first character of its
9
- * opening line and ends with the newline that closes its last one.
7
+ * Same assembly contract as every part of the `loam-codes` page:
8
+ * ../../workflows/reference/codes.ts concatenates with NO join separator, so this
9
+ * string starts at the first character of its opening line and ends with
10
+ * the newline that closes its last one.
10
11
  */
11
12
  export const SUBSYSTEM_COMMANDS = `- \`loam subsystem <verb>\` manages the grouping tree under \`services/\` — the
12
13
  navigable tree no identity depends on: a service id stays its leaf directory
@@ -15,8 +16,8 @@ export const SUBSYSTEM_COMMANDS = `- \`loam subsystem <verb>\` manages the group
15
16
  [--owner]\` creates a group (an empty one is legal — its \`subsystem.yaml\` is a
16
17
  marker, never a member list); \`move <name>... --into <sub|.>\` relocates
17
18
  services and whole subtrees in ONE journaled transaction over the renames
18
- plus the regenerated views file (\`--into .\` unfiles; the renames and the
19
- regenerated views file are staged in git without committing, where git answers); \`rename <old> <new>\` renames a
19
+ plus BOTH regenerated views files (\`--into .\` unfiles; the renames and the
20
+ regenerated views files are staged in git without committing, where git answers); \`rename <old> <new>\` renames a
20
21
  group through the same transaction (services are never renamed — the id is
21
22
  the identity); \`rm <name>\` removes an EMPTY group; \`list\` shows the tree
22
23
  with member counts and the unfiled count (unfiled is permanent and normal —
@@ -24,9 +25,12 @@ export const SUBSYSTEM_COMMANDS = `- \`loam subsystem <verb>\` manages the group
24
25
  additive keys \`services[].subsystem\`, \`subsystems[]\` and
25
26
  \`unfiledServices\`); \`history <name>\` asks git how a service or subsystem
26
27
  moved and answers nothing — exit 0, no finding — when git will not say;
27
- \`sync\` regenerates \`architecture/subsystems.likec4\`, the one repair for
28
- \`subsystem.views-stale\`, and also maintains the RENDERER's wiring for the
29
- service models. Which wiring a model needs is decided by the file's own
28
+ \`sync\` regenerates BOTH generated views files —
29
+ \`architecture/subsystems.likec4\` (one view per subsystem) and
30
+ \`architecture/services.likec4\` (one overview view per service the fleet map
31
+ draws) — the one repair for \`subsystem.views-stale\`, which grades each file
32
+ separately and names the one that drifted. It also maintains the RENDERER's
33
+ wiring for the service models. Which wiring a model needs is decided by the file's own
30
34
  grammar, never by a config key: a model that declares its own
31
35
  \`specification { element … }\` block STANDS ALONE — it cannot share a project
32
36
  with the fleet map, since every kind it declares would be a duplicate there —
@@ -58,16 +62,24 @@ export const SUBSYSTEM_COMMANDS = `- \`loam subsystem <verb>\` manages the group
58
62
  (\`build\` and \`export\` take every project). A view id claimed twice inside one
59
63
  project — the landscape and an extending model both minting it, or either
60
64
  claiming a generated one — is
61
- \`subsystem.view-id-collision\`. Each generated view is titled by its PATH —
65
+ \`subsystem.view-id-collision\` — ids beginning \`subsystem_\` or \`service_\` are
66
+ loam's to mint. Each generated view is titled by its PATH —
62
67
  every marked ancestor's label and its own, which the renderer reads as
63
68
  folders — where a label is the marker's \`title\` or the directory name; the
64
- marker's \`description\` rides along. So editing \`subsystem.yaml\` changes
69
+ marker's \`description\` rides along. A per-service view is titled
70
+ \`<subsystem path> / <service id>\`, so it lands in the same folder as its
71
+ group, and a \`dynamic view\` you write under
72
+ \`services/<…>/<id>/usecases/\` titled \`<subsystem path> / <service id> / <use
73
+ case>\` lands beside it. So editing \`subsystem.yaml\` changes
65
74
  what the renderer LABELS the group, a parent's title changes every view
66
- beneath it, and either makes the file stale until the next \`sync\`. The
67
- generated file is NEVER part of the fleet-project load
75
+ beneath it, and either makes both files stale until the next \`sync\`. Neither
76
+ generated file is part of the fleet-project load
68
77
  (\`c4.fleet-project-invalid\` reads every other \`.likec4\` the root project holds);
69
- \`subsystem.views-stale\` is the only check that reads it, by byte comparison.
70
- Each view
78
+ \`subsystem.views-stale\` is the only check that reads them, by content
79
+ comparison against the deterministic re-render, never by reading what a view
80
+ shows. Each per-service view is declared \`of\` its service's element, which is
81
+ what makes every other view — the fleet map, its subsystem view, its peers'
82
+ views — drill into it with no authored link. Each subsystem view
71
83
  carries \`global style subsystems\` — written after its title, the one line
72
84
  LikeC4 gives a view for borrowing a palette — exactly when the \`architecture/\`
73
85
  project declares a global style with that id (\`global { styleGroup subsystems
@@ -79,10 +91,12 @@ export const SUBSYSTEM_COMMANDS = `- \`loam subsystem <verb>\` manages the group
79
91
  names only, the file opens with one comment line naming them and saying none is
80
92
  \`subsystems\`, and the views carry the renderer's defaults — so declaring a group
81
93
  under ANY name restales the file, because that comment is part of the bytes.
82
- \`sync\` refuses to rewrite it at all while \`architecture/\` does not parse
83
- (\`action: "blocked"\`): fix the map first. It is generated wholesale:
94
+ \`architecture/services.likec4\` reads a group named \`services\` the same way.
95
+ \`sync\` refuses to rewrite either file while \`architecture/\` does not parse
96
+ (\`action: "blocked"\`): fix the map first. Both are generated wholesale:
84
97
  an authored diagram of the same services belongs in the landscape or in a
85
- file of your own name, never here. \`loam adopt --subsystem <name>\` briefs a new
98
+ file of your own name, never here. \`--json\` reports the subsystem file as
99
+ \`path\`/\`action\` and the per-service one as \`serviceViews\`. \`loam adopt --subsystem <name>\` briefs a new
86
100
  service's baseline directly into a group, so adoption need not land unfiled.
87
101
  `;
88
102
  //# sourceMappingURL=subsystem.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"subsystem.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/subsystem.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA4EjC,CAAC","sourcesContent":["/**\n * The `loam subsystem` half of the command map — its own section module\n * because command-map.ts sat against the file-line limit and the agents-md\n * package against the five-file cap, so the tree surface's documentation\n * lives one package down and is concatenated after the map.\n *\n * Same assembly contract as every section: ../agents-md.ts concatenates with\n * NO join separator, so this string starts at the first character of its\n * opening line and ends with the newline that closes its last one.\n */\nexport const SUBSYSTEM_COMMANDS = `- \\`loam subsystem <verb>\\` manages the grouping tree under \\`services/\\` — the\n navigable tree no identity depends on: a service id stays its leaf directory\n name, every join key is byte-identical before and after a move, and the tree\n carries no policy. Verbs: \\`new <name> [--under <sub>] [--title] [--description]\n [--owner]\\` creates a group (an empty one is legal — its \\`subsystem.yaml\\` is a\n marker, never a member list); \\`move <name>... --into <sub|.>\\` relocates\n services and whole subtrees in ONE journaled transaction over the renames\n plus the regenerated views file (\\`--into .\\` unfiles; the renames and the\n regenerated views file are staged in git without committing, where git answers); \\`rename <old> <new>\\` renames a\n group through the same transaction (services are never renamed — the id is\n the identity); \\`rm <name>\\` removes an EMPTY group; \\`list\\` shows the tree\n with member counts and the unfiled count (unfiled is permanent and normal —\n a count, never a finding; \\`loam list --json\\` carries the same facts as\n additive keys \\`services[].subsystem\\`, \\`subsystems[]\\` and\n \\`unfiledServices\\`); \\`history <name>\\` asks git how a service or subsystem\n moved and answers nothing — exit 0, no finding — when git will not say;\n \\`sync\\` regenerates \\`architecture/subsystems.likec4\\`, the one repair for\n \\`subsystem.views-stale\\`, and also maintains the RENDERER's wiring for the\n service models. Which wiring a model needs is decided by the file's own\n grammar, never by a config key: a model that declares its own\n \\`specification { element … }\\` block STANDS ALONE — it cannot share a project\n with the fleet map, since every kind it declares would be a duplicate there —\n and a model with no such block EXTENDS the map with\n \\`extend <fully-qualified id> { … }\\` and parses only INSIDE the root project.\n So \\`sync\\` writes one create-only \\`services/<…>/<id>/likec4.config.json\\` per\n STANDALONE model (never rewritten; the team may edit it; commit\n the new files before a \\`move\\`, which refuses over untracked paths), DELETES one\n sitting beside an EXTENDING model (that nested project claims the model out of\n the root project, so \\`likec4 validate .\\` refuses without \\`--project\\` and,\n wherever that project claims the model, \\`export json --project fleet\\` loses\n the service's containers; \\`--json\\` lists what it removed as \\`projects.removed\\`), and rewrites\n the root \\`likec4.config.json\\`'s \\`exclude\\` to hold \\`services/<tree>/**\\` for\n exactly those models, keeping every entry that is not about \\`services/\\` in the\n order the team wrote it. It rewrites that list when at least one extending model\n exists, or when a standalone model's directory is not covered — an older repo\n whose models all stand alone behind \\`services/**\\` is never touched. \\`--json\\`\n carries the result as \\`projects.exclude\\`, and the text view prints one line when\n it rewrote. Between them these repair four warnings:\n \\`service.likec4-config-missing\\` (a standalone model with no project file),\n \\`service.likec4-config-stray\\` (a project file beside an extending model),\n \\`service.model-excluded\\` (an extending model the root \\`exclude\\` hides from the\n renderer) and \\`service.model-unexcluded\\` (a standalone model it does not hide,\n which blanks the whole root project). A flat fleet with no subsystems still owes\n this run: the verb is the tree's, the files are the renderer's. A fleet whose\n models all extend the map ends with ONE project and one picker entry, and\n \\`likec4 validate\\` at the docs root needs no flag; each standalone model adds a\n project, and with more than one \\`likec4 validate\\` needs \\`--project <name>\\`\n (\\`build\\` and \\`export\\` take every project). A view id claimed twice inside one\n project — the landscape and an extending model both minting it, or either\n claiming a generated one — is\n \\`subsystem.view-id-collision\\`. Each generated view is titled by its PATH —\n every marked ancestor's label and its own, which the renderer reads as\n folders — where a label is the marker's \\`title\\` or the directory name; the\n marker's \\`description\\` rides along. So editing \\`subsystem.yaml\\` changes\n what the renderer LABELS the group, a parent's title changes every view\n beneath it, and either makes the file stale until the next \\`sync\\`. The\n generated file is NEVER part of the fleet-project load\n (\\`c4.fleet-project-invalid\\` reads every other \\`.likec4\\` the root project holds);\n \\`subsystem.views-stale\\` is the only check that reads it, by byte comparison.\n Each view\n carries \\`global style subsystems\\` — written after its title, the one line\n LikeC4 gives a view for borrowing a palette — exactly when the \\`architecture/\\`\n project declares a global style with that id (\\`global { styleGroup subsystems\n { style element.tag = #external { color gray } } }\\`, in the landscape or in\n ANY \\`.likec4\\` under \\`architecture/\\` the root \\`exclude\\` does not cover — a\n \\`palette.likec4\\` beside the map counts); nothing otherwise, and loam never reads\n what the group says. Declaring it is the whole opt-in and makes the file stale\n once, until the next \\`sync\\`. When the project declares style groups under other\n names only, the file opens with one comment line naming them and saying none is\n \\`subsystems\\`, and the views carry the renderer's defaults — so declaring a group\n under ANY name restales the file, because that comment is part of the bytes.\n \\`sync\\` refuses to rewrite it at all while \\`architecture/\\` does not parse\n (\\`action: \"blocked\"\\`): fix the map first. It is generated wholesale:\n an authored diagram of the same services belongs in the landscape or in a\n file of your own name, never here. \\`loam adopt --subsystem <name>\\` briefs a new\n service's baseline directly into a group, so adoption need not land unfiled.\n`;\n"]}
1
+ {"version":3,"file":"subsystem.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/subsystem.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyFjC,CAAC","sourcesContent":["/**\n * The `loam subsystem` half of the command map — its own section module\n * because command-map.ts sat against the file-line limit and the agents-md\n * package against the five-file cap, so the tree surface's documentation\n * lives one package down and is concatenated after the map.\n *\n * Same assembly contract as every part of the `loam-codes` page:\n * ../../workflows/reference/codes.ts concatenates with NO join separator, so this\n * string starts at the first character of its opening line and ends with\n * the newline that closes its last one.\n */\nexport const SUBSYSTEM_COMMANDS = `- \\`loam subsystem <verb>\\` manages the grouping tree under \\`services/\\` — the\n navigable tree no identity depends on: a service id stays its leaf directory\n name, every join key is byte-identical before and after a move, and the tree\n carries no policy. Verbs: \\`new <name> [--under <sub>] [--title] [--description]\n [--owner]\\` creates a group (an empty one is legal — its \\`subsystem.yaml\\` is a\n marker, never a member list); \\`move <name>... --into <sub|.>\\` relocates\n services and whole subtrees in ONE journaled transaction over the renames\n plus BOTH regenerated views files (\\`--into .\\` unfiles; the renames and the\n regenerated views files are staged in git without committing, where git answers); \\`rename <old> <new>\\` renames a\n group through the same transaction (services are never renamed — the id is\n the identity); \\`rm <name>\\` removes an EMPTY group; \\`list\\` shows the tree\n with member counts and the unfiled count (unfiled is permanent and normal —\n a count, never a finding; \\`loam list --json\\` carries the same facts as\n additive keys \\`services[].subsystem\\`, \\`subsystems[]\\` and\n \\`unfiledServices\\`); \\`history <name>\\` asks git how a service or subsystem\n moved and answers nothing — exit 0, no finding — when git will not say;\n \\`sync\\` regenerates BOTH generated views files —\n \\`architecture/subsystems.likec4\\` (one view per subsystem) and\n \\`architecture/services.likec4\\` (one overview view per service the fleet map\n draws) — the one repair for \\`subsystem.views-stale\\`, which grades each file\n separately and names the one that drifted. It also maintains the RENDERER's\n wiring for the service models. Which wiring a model needs is decided by the file's own\n grammar, never by a config key: a model that declares its own\n \\`specification { element … }\\` block STANDS ALONE — it cannot share a project\n with the fleet map, since every kind it declares would be a duplicate there —\n and a model with no such block EXTENDS the map with\n \\`extend <fully-qualified id> { … }\\` and parses only INSIDE the root project.\n So \\`sync\\` writes one create-only \\`services/<…>/<id>/likec4.config.json\\` per\n STANDALONE model (never rewritten; the team may edit it; commit\n the new files before a \\`move\\`, which refuses over untracked paths), DELETES one\n sitting beside an EXTENDING model (that nested project claims the model out of\n the root project, so \\`likec4 validate .\\` refuses without \\`--project\\` and,\n wherever that project claims the model, \\`export json --project fleet\\` loses\n the service's containers; \\`--json\\` lists what it removed as \\`projects.removed\\`), and rewrites\n the root \\`likec4.config.json\\`'s \\`exclude\\` to hold \\`services/<tree>/**\\` for\n exactly those models, keeping every entry that is not about \\`services/\\` in the\n order the team wrote it. It rewrites that list when at least one extending model\n exists, or when a standalone model's directory is not covered — an older repo\n whose models all stand alone behind \\`services/**\\` is never touched. \\`--json\\`\n carries the result as \\`projects.exclude\\`, and the text view prints one line when\n it rewrote. Between them these repair four warnings:\n \\`service.likec4-config-missing\\` (a standalone model with no project file),\n \\`service.likec4-config-stray\\` (a project file beside an extending model),\n \\`service.model-excluded\\` (an extending model the root \\`exclude\\` hides from the\n renderer) and \\`service.model-unexcluded\\` (a standalone model it does not hide,\n which blanks the whole root project). A flat fleet with no subsystems still owes\n this run: the verb is the tree's, the files are the renderer's. A fleet whose\n models all extend the map ends with ONE project and one picker entry, and\n \\`likec4 validate\\` at the docs root needs no flag; each standalone model adds a\n project, and with more than one \\`likec4 validate\\` needs \\`--project <name>\\`\n (\\`build\\` and \\`export\\` take every project). A view id claimed twice inside one\n project — the landscape and an extending model both minting it, or either\n claiming a generated one — is\n \\`subsystem.view-id-collision\\` — ids beginning \\`subsystem_\\` or \\`service_\\` are\n loam's to mint. Each generated view is titled by its PATH —\n every marked ancestor's label and its own, which the renderer reads as\n folders — where a label is the marker's \\`title\\` or the directory name; the\n marker's \\`description\\` rides along. A per-service view is titled\n \\`<subsystem path> / <service id>\\`, so it lands in the same folder as its\n group, and a \\`dynamic view\\` you write under\n \\`services/<…>/<id>/usecases/\\` titled \\`<subsystem path> / <service id> / <use\n case>\\` lands beside it. So editing \\`subsystem.yaml\\` changes\n what the renderer LABELS the group, a parent's title changes every view\n beneath it, and either makes both files stale until the next \\`sync\\`. Neither\n generated file is part of the fleet-project load\n (\\`c4.fleet-project-invalid\\` reads every other \\`.likec4\\` the root project holds);\n \\`subsystem.views-stale\\` is the only check that reads them, by content\n comparison against the deterministic re-render, never by reading what a view\n shows. Each per-service view is declared \\`of\\` its service's element, which is\n what makes every other view — the fleet map, its subsystem view, its peers'\n views — drill into it with no authored link. Each subsystem view\n carries \\`global style subsystems\\` — written after its title, the one line\n LikeC4 gives a view for borrowing a palette — exactly when the \\`architecture/\\`\n project declares a global style with that id (\\`global { styleGroup subsystems\n { style element.tag = #external { color gray } } }\\`, in the landscape or in\n ANY \\`.likec4\\` under \\`architecture/\\` the root \\`exclude\\` does not cover — a\n \\`palette.likec4\\` beside the map counts); nothing otherwise, and loam never reads\n what the group says. Declaring it is the whole opt-in and makes the file stale\n once, until the next \\`sync\\`. When the project declares style groups under other\n names only, the file opens with one comment line naming them and saying none is\n \\`subsystems\\`, and the views carry the renderer's defaults — so declaring a group\n under ANY name restales the file, because that comment is part of the bytes.\n \\`architecture/services.likec4\\` reads a group named \\`services\\` the same way.\n \\`sync\\` refuses to rewrite either file while \\`architecture/\\` does not parse\n (\\`action: \"blocked\"\\`): fix the map first. Both are generated wholesale:\n an authored diagram of the same services belongs in the landscape or in a\n file of your own name, never here. \\`--json\\` reports the subsystem file as\n \\`path\\`/\\`action\\` and the per-service one as \\`serviceViews\\`. \\`loam adopt --subsystem <name>\\` briefs a new\n service's baseline directly into a group, so adoption need not land unfiled.\n`;\n"]}
@@ -12,9 +12,10 @@
12
12
  * describes. What stays is what `explain` does not say — how to opt a view in,
13
13
  * and that an untagged dynamic view is never graded at all.
14
14
  *
15
- * Same assembly contract as every section: ../../agents-md.ts concatenates with
16
- * NO join separator, so this string starts at the first character of its opening
17
- * line and ends with the newline that closes its last one.
15
+ * Same assembly contract as every part of the `loam-codes` page:
16
+ * ../../workflows/reference/codes.ts concatenates with NO join separator, so this
17
+ * string starts at the first character of its opening line and ends with
18
+ * the newline that closes its last one.
18
19
  */
19
20
  export const USECASE_VIEWS = `- Business use cases are \`dynamic view\`s, and \`loam validate --all\` grades the
20
21
  ones that opt in. Write the flow in a file of its own —
@@ -29,13 +30,15 @@ export const USECASE_VIEWS = `- Business use cases are \`dynamic view\`s, and \`
29
30
  naming a container that a service's extending model declares resolves in the
30
31
  renderer's wider root project and is \`landscape.invalid\` for loam, which takes
31
32
  the whole fleet map down. Container-level flows live beside the model that
32
- declares them (below). EITHER reserved prefix
33
+ declares them (below). ANY reserved prefix
33
34
  opts a view in — a view carrying only \`#req-<requirement>\` is graded too, and
34
35
  earns \`usecase.requirement-unresolved\` for the \`#cap-\` tag it is missing
35
- rather than silence. An UNTAGGED dynamic view is somebody's hand-drawn diagram
36
+ rather than silence; so is a view carrying only \`#suite-<name>\` (below). An
37
+ UNTAGGED dynamic view is somebody's hand-drawn diagram
36
38
  and is never graded — that opt-in is what lets a fleet full of existing
37
39
  diagrams upgrade without turning red, and \`loam validate\`, \`loam diff\`,
38
- \`loam delta\`, \`loam status\`, \`loam context\` and \`loam list capabilities\` all
40
+ \`loam delta\`, \`loam status\`, \`loam context\`, \`loam list capabilities\` and
41
+ \`loam list suites\` all
39
42
  read the same opt-in, so a flow one of them sees is a flow all of them see. On a tagged
40
43
  view: \`usecase.capability-unresolved\`, \`usecase.step-unbacked\`,
41
44
  \`usecase.step-contested\` and \`usecase.step-unlinked\`. The first is silent
@@ -44,6 +47,21 @@ export const USECASE_VIEWS = `- Business use cases are \`dynamic view\`s, and \`
44
47
  hop written \`a <- b\` is attributed to the call it answers, so spell replies
45
48
  that way rather than as fresh hops. Every message names the file the view was
46
49
  written in, never the landscape.
50
+ - A fleet flow says which test SUITES it runs in with \`#suite-<name>\` tags —
51
+ a separate prefix from \`#cap-\`, many-to-many (one view may carry several),
52
+ each declared as a \`tag suite-<name>\` in the landscape's \`specification\` so a
53
+ typo is a parse error. Tagging is the opt-in: a view carrying ONLY \`#suite-\`
54
+ tags is a use case and its hops are graded like any other's. To answer "which
55
+ services must be up for suite X", run \`loam list suites smoke --json\` (or
56
+ \`loam list suites --json\` for every suite): \`suites[]\` carries each suite's
57
+ \`views[]\` (\`id\`, \`file\`), \`services[]\` (enumerated service ids, through the
58
+ same element→service join the step grades use) and \`unresolved[]\` (\`element\`,
59
+ \`external\`) — participants no service stands for, never dropped, so a stand
60
+ that needs a double for them says so; \`ungrouped[]\` names the use cases in no
61
+ suite, and \`useCases.state\` is \`absent\`, \`ok\` or \`unreadable\` (with
62
+ \`error\`; \`suites\`/\`ungrouped\` are then absent, not empty). An unknown suite
63
+ name refuses \`unknown-target\` with close names. Only the fleet map's flows
64
+ are listed.
47
65
  - A flow behind ONE service's own requirement — the hop sequence over its
48
66
  containers that an arch.spec.md \`Covers:\` names — lives in that service's own
49
67
  LikeC4 project: any \`.likec4\` beside \`services/<…>/<svc>/model.likec4\`
@@ -1 +1 @@
1
- {"version":3,"file":"usecases.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/usecases.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkF5B,CAAC","sourcesContent":["/**\n * The use-case axis of the command map — its own section module for\n * `./subsystem.ts`'s exact reason: command-map.ts sat against the file-line\n * limit and the agents-md package against the five-file cap, so a family added\n * to the `validate --all` cross-check documents itself one package down and is\n * concatenated after the map. The four `usecase.*` codes are what\n * test/codes-drift.test.ts finds here.\n *\n * They are LISTED and not glossed: their fix rows live in the /loam-check\n * table and `loam explain usecase.step-unbacked` prints them, so writing the\n * meanings out again here is the duplication ../../command-map.ts's header\n * describes. What stays is what `explain` does not say — how to opt a view in,\n * and that an untagged dynamic view is never graded at all.\n *\n * Same assembly contract as every section: ../../agents-md.ts concatenates with\n * NO join separator, so this string starts at the first character of its opening\n * line and ends with the newline that closes its last one.\n */\nexport const USECASE_VIEWS = `- Business use cases are \\`dynamic view\\`s, and \\`loam validate --all\\` grades the\n ones that opt in. Write the flow in a file of its own —\n \\`architecture/usecases/<name>.likec4\\`, a \\`views { }\\` block over the landscape's\n elements, which loam reads as ONE LikeC4 project together with the map — and\n tag the view \\`#cap-<capability>\\` to have it graded. The tag spells a declared\n capability id with every \\`/\\` flattened to \\`-\\` (a LikeC4 tag name cannot carry a\n slash), and it must be declared as a \\`tag\\` in the one \\`specification\\` block the\n \\`architecture/\\` project has, since LikeC4 refuses an undeclared tag. loam grades\n the fleet map as THAT project and nothing else — the landscape plus its\n siblings, never a service model — so a hop here names SERVICE elements: a step\n naming a container that a service's extending model declares resolves in the\n renderer's wider root project and is \\`landscape.invalid\\` for loam, which takes\n the whole fleet map down. Container-level flows live beside the model that\n declares them (below). EITHER reserved prefix\n opts a view in — a view carrying only \\`#req-<requirement>\\` is graded too, and\n earns \\`usecase.requirement-unresolved\\` for the \\`#cap-\\` tag it is missing\n rather than silence. An UNTAGGED dynamic view is somebody's hand-drawn diagram\n and is never graded — that opt-in is what lets a fleet full of existing\n diagrams upgrade without turning red, and \\`loam validate\\`, \\`loam diff\\`,\n \\`loam delta\\`, \\`loam status\\`, \\`loam context\\` and \\`loam list capabilities\\` all\n read the same opt-in, so a flow one of them sees is a flow all of them see. On a tagged\n view: \\`usecase.capability-unresolved\\`, \\`usecase.step-unbacked\\`,\n \\`usecase.step-contested\\` and \\`usecase.step-unlinked\\`. The first is silent\n while architecture/capabilities.yaml is absent or unreadable, like the rest of\n the capability axis; the three step codes are about the model, and a return\n hop written \\`a <- b\\` is attributed to the call it answers, so spell replies\n that way rather than as fresh hops. Every message names the file the view was\n written in, never the landscape.\n- A flow behind ONE service's own requirement — the hop sequence over its\n containers that an arch.spec.md \\`Covers:\\` names — lives in that service's own\n LikeC4 project: any \\`.likec4\\` beside \\`services/<…>/<svc>/model.likec4\\`\n (\\`usecases/<name>.likec4\\` by convention, or \\`views.likec4\\`), or a \\`dynamic view\\`\n inside model.likec4 itself; loam reads exactly what the renderer's per-service\n project reads. Never \\`architecture/usecases/\\`, which cannot resolve a container\n and turns the whole fleet \\`landscape.invalid\\`. Tag it \\`#req-<Requirement-ID>\\`\n (the id flattened as above). The tag has to be DECLARED where that project can\n see it: in model.likec4's own \\`specification\\` block when the model declares one\n and therefore stands alone; in \\`architecture/landscape.likec4\\`'s block when the\n model EXTENDS the map, or in a tags-only \\`specification { tag req-… }\\` beside\n the \\`extend\\`, which is legal and lands the tag in the project's specification.\n Declaring it in BOTH is a duplicate, and the code is the one that lands where\n the second declaration's FILE is: \\`c4.invalid\\` (an error, and the model's\n grading is suspended behind it) when the tags-only block is in model.likec4,\n \\`usecase.flow-invalid\\` when it is in a sibling. \\`c4.fleet-project-invalid\\` is\n the fleet-scope class one step out — two SERVICES each declaring the same tag\n locally, which no per-service project sees.\n Then \\`loam validate --service <svc>\\` grades it — under\n \\`--all\\`, per service: \\`usecase.step-unbacked\\` and \\`usecase.step-contested\\`\n against model.likec4, \\`usecase.requirement-unresolved\\` against THIS service's\n spec.md and arch.spec.md ids, and \\`usecase.flow-invalid\\` when a sibling file\n breaks the project (model.likec4 is still graded alone). \\`usecase.step-unlinked\\`\n never fires on a hop whose caller and provider resolve to the same service — a\n service owes no operationId to itself — while a hop from such a flow into another\n service's element (a stand-in the model declares for a sibling, with no\n \\`metadata { op }\\`) still warns, exactly as on the fleet map. A \\`#cap-\\` tag on\n such a flow is \\`usecase.capability-unresolved\\`: a capability is claimed on the\n fleet map, never inside one service. A resolved service-local \\`#req-\\` keeps its\n own grade and nothing else — it is not \\`keptBy\\`, not \\`Covers:\\`, and no feature\n carries one yet.\n- A FEATURE brings a flow the way it brings every other axis: write it at\n \\`features/<FEAT>/usecases/<name>.likec4\\` — the same views-only document, in the\n feature's own directory — and \\`loam archive\\` copies it into\n \\`architecture/usecases/\\` while \\`loam unarchive\\` takes it back. That is what lets\n an analyst add a cross-service requirement and an architect answer it with the\n flow that keeps it IN ONE CHANGE: the \\`#req-\\` tag resolves against this\n feature's own \\`capabilities/<cap>/spec.md\\` delta as well as the living tree, and\n \\`capability.uncovered\\` counts the flow as cover. The flow is graded against the\n map the same merge would leave behind, so a hop may name a service this\n feature's \\`delta.likec4\\` adds. Two refusals guard it, and \\`--approve\\` moves\n neither: \\`usecase.flow-exists\\` (the living \\`architecture/usecases/\\` already has\n that file — the merge is a whole-file copy, so edit the living one directly\n instead) and \\`usecase.flow-invalid\\` (loam could not read the flows against that\n post-merge map — most often a hop naming an element neither the living\n landscape nor the delta declares; the merge preview stages no service model, so\n a container an extending model declares is not among them either). Do NOT put a\n \\`dynamic view\\` inside\n \\`delta.likec4\\`: that document re-declares the landscape's own identifiers and\n carries its own \\`specification\\` block, so it cannot be read beside the map, and\n the archive refuses it by name. A feature's \\`delta.likec4\\` keeps that shape\n whatever shape the service models take — \\`features/**\\` stays excluded from the\n root LikeC4 project, and the delta is pointed at alone\n (\\`npx likec4 start features/<FEAT>\\`).\n`;\n"]}
1
+ {"version":3,"file":"usecases.js","sourceRoot":"","sources":["../../../../../src/core/agent/agents-md/map/usecases.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmG5B,CAAC","sourcesContent":["/**\n * The use-case axis of the command map — its own section module for\n * `./subsystem.ts`'s exact reason: command-map.ts sat against the file-line\n * limit and the agents-md package against the five-file cap, so a family added\n * to the `validate --all` cross-check documents itself one package down and is\n * concatenated after the map. The four `usecase.*` codes are what\n * test/codes-drift.test.ts finds here.\n *\n * They are LISTED and not glossed: their fix rows live in the /loam-check\n * table and `loam explain usecase.step-unbacked` prints them, so writing the\n * meanings out again here is the duplication ../../command-map.ts's header\n * describes. What stays is what `explain` does not say — how to opt a view in,\n * and that an untagged dynamic view is never graded at all.\n *\n * Same assembly contract as every part of the `loam-codes` page:\n * ../../workflows/reference/codes.ts concatenates with NO join separator, so this\n * string starts at the first character of its opening line and ends with\n * the newline that closes its last one.\n */\nexport const USECASE_VIEWS = `- Business use cases are \\`dynamic view\\`s, and \\`loam validate --all\\` grades the\n ones that opt in. Write the flow in a file of its own —\n \\`architecture/usecases/<name>.likec4\\`, a \\`views { }\\` block over the landscape's\n elements, which loam reads as ONE LikeC4 project together with the map — and\n tag the view \\`#cap-<capability>\\` to have it graded. The tag spells a declared\n capability id with every \\`/\\` flattened to \\`-\\` (a LikeC4 tag name cannot carry a\n slash), and it must be declared as a \\`tag\\` in the one \\`specification\\` block the\n \\`architecture/\\` project has, since LikeC4 refuses an undeclared tag. loam grades\n the fleet map as THAT project and nothing else — the landscape plus its\n siblings, never a service model — so a hop here names SERVICE elements: a step\n naming a container that a service's extending model declares resolves in the\n renderer's wider root project and is \\`landscape.invalid\\` for loam, which takes\n the whole fleet map down. Container-level flows live beside the model that\n declares them (below). ANY reserved prefix\n opts a view in — a view carrying only \\`#req-<requirement>\\` is graded too, and\n earns \\`usecase.requirement-unresolved\\` for the \\`#cap-\\` tag it is missing\n rather than silence; so is a view carrying only \\`#suite-<name>\\` (below). An\n UNTAGGED dynamic view is somebody's hand-drawn diagram\n and is never graded — that opt-in is what lets a fleet full of existing\n diagrams upgrade without turning red, and \\`loam validate\\`, \\`loam diff\\`,\n \\`loam delta\\`, \\`loam status\\`, \\`loam context\\`, \\`loam list capabilities\\` and\n \\`loam list suites\\` all\n read the same opt-in, so a flow one of them sees is a flow all of them see. On a tagged\n view: \\`usecase.capability-unresolved\\`, \\`usecase.step-unbacked\\`,\n \\`usecase.step-contested\\` and \\`usecase.step-unlinked\\`. The first is silent\n while architecture/capabilities.yaml is absent or unreadable, like the rest of\n the capability axis; the three step codes are about the model, and a return\n hop written \\`a <- b\\` is attributed to the call it answers, so spell replies\n that way rather than as fresh hops. Every message names the file the view was\n written in, never the landscape.\n- A fleet flow says which test SUITES it runs in with \\`#suite-<name>\\` tags —\n a separate prefix from \\`#cap-\\`, many-to-many (one view may carry several),\n each declared as a \\`tag suite-<name>\\` in the landscape's \\`specification\\` so a\n typo is a parse error. Tagging is the opt-in: a view carrying ONLY \\`#suite-\\`\n tags is a use case and its hops are graded like any other's. To answer \"which\n services must be up for suite X\", run \\`loam list suites smoke --json\\` (or\n \\`loam list suites --json\\` for every suite): \\`suites[]\\` carries each suite's\n \\`views[]\\` (\\`id\\`, \\`file\\`), \\`services[]\\` (enumerated service ids, through the\n same element→service join the step grades use) and \\`unresolved[]\\` (\\`element\\`,\n \\`external\\`) — participants no service stands for, never dropped, so a stand\n that needs a double for them says so; \\`ungrouped[]\\` names the use cases in no\n suite, and \\`useCases.state\\` is \\`absent\\`, \\`ok\\` or \\`unreadable\\` (with\n \\`error\\`; \\`suites\\`/\\`ungrouped\\` are then absent, not empty). An unknown suite\n name refuses \\`unknown-target\\` with close names. Only the fleet map's flows\n are listed.\n- A flow behind ONE service's own requirement — the hop sequence over its\n containers that an arch.spec.md \\`Covers:\\` names — lives in that service's own\n LikeC4 project: any \\`.likec4\\` beside \\`services/<…>/<svc>/model.likec4\\`\n (\\`usecases/<name>.likec4\\` by convention, or \\`views.likec4\\`), or a \\`dynamic view\\`\n inside model.likec4 itself; loam reads exactly what the renderer's per-service\n project reads. Never \\`architecture/usecases/\\`, which cannot resolve a container\n and turns the whole fleet \\`landscape.invalid\\`. Tag it \\`#req-<Requirement-ID>\\`\n (the id flattened as above). The tag has to be DECLARED where that project can\n see it: in model.likec4's own \\`specification\\` block when the model declares one\n and therefore stands alone; in \\`architecture/landscape.likec4\\`'s block when the\n model EXTENDS the map, or in a tags-only \\`specification { tag req-… }\\` beside\n the \\`extend\\`, which is legal and lands the tag in the project's specification.\n Declaring it in BOTH is a duplicate, and the code is the one that lands where\n the second declaration's FILE is: \\`c4.invalid\\` (an error, and the model's\n grading is suspended behind it) when the tags-only block is in model.likec4,\n \\`usecase.flow-invalid\\` when it is in a sibling. \\`c4.fleet-project-invalid\\` is\n the fleet-scope class one step out — two SERVICES each declaring the same tag\n locally, which no per-service project sees.\n Then \\`loam validate --service <svc>\\` grades it — under\n \\`--all\\`, per service: \\`usecase.step-unbacked\\` and \\`usecase.step-contested\\`\n against model.likec4, \\`usecase.requirement-unresolved\\` against THIS service's\n spec.md and arch.spec.md ids, and \\`usecase.flow-invalid\\` when a sibling file\n breaks the project (model.likec4 is still graded alone). \\`usecase.step-unlinked\\`\n never fires on a hop whose caller and provider resolve to the same service — a\n service owes no operationId to itself — while a hop from such a flow into another\n service's element (a stand-in the model declares for a sibling, with no\n \\`metadata { op }\\`) still warns, exactly as on the fleet map. A \\`#cap-\\` tag on\n such a flow is \\`usecase.capability-unresolved\\`: a capability is claimed on the\n fleet map, never inside one service. A resolved service-local \\`#req-\\` keeps its\n own grade and nothing else — it is not \\`keptBy\\`, not \\`Covers:\\`, and no feature\n carries one yet.\n- A FEATURE brings a flow the way it brings every other axis: write it at\n \\`features/<FEAT>/usecases/<name>.likec4\\` — the same views-only document, in the\n feature's own directory — and \\`loam archive\\` copies it into\n \\`architecture/usecases/\\` while \\`loam unarchive\\` takes it back. That is what lets\n an analyst add a cross-service requirement and an architect answer it with the\n flow that keeps it IN ONE CHANGE: the \\`#req-\\` tag resolves against this\n feature's own \\`capabilities/<cap>/spec.md\\` delta as well as the living tree, and\n \\`capability.uncovered\\` counts the flow as cover. The flow is graded against the\n map the same merge would leave behind, so a hop may name a service this\n feature's \\`delta.likec4\\` adds. Two refusals guard it, and \\`--approve\\` moves\n neither: \\`usecase.flow-exists\\` (the living \\`architecture/usecases/\\` already has\n that file — the merge is a whole-file copy, so edit the living one directly\n instead) and \\`usecase.flow-invalid\\` (loam could not read the flows against that\n post-merge map — most often a hop naming an element neither the living\n landscape nor the delta declares; the merge preview stages no service model, so\n a container an extending model declares is not among them either). Do NOT put a\n \\`dynamic view\\` inside\n \\`delta.likec4\\`: that document re-declares the landscape's own identifiers and\n carries its own \\`specification\\` block, so it cannot be read beside the map, and\n the archive refuses it by name. A feature's \\`delta.likec4\\` keeps that shape\n whatever shape the service models take — \\`features/**\\` stays excluded from the\n root LikeC4 project, and the delta is pointed at alone\n (\\`npx likec4 start features/<FEAT>\\`).\n`;\n"]}