@driftsys/markspec 0.10.3 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (458) hide show
  1. package/README.md +11 -2
  2. package/esm/ast/normalize.d.ts +4 -5
  3. package/esm/ast/normalize.d.ts.map +1 -1
  4. package/esm/ast/normalize.js +6 -37
  5. package/esm/collect/mod.d.ts +29 -9
  6. package/esm/collect/mod.d.ts.map +1 -1
  7. package/esm/collect/mod.js +36 -10
  8. package/esm/compiler/deserialize.d.ts +49 -0
  9. package/esm/compiler/deserialize.d.ts.map +1 -0
  10. package/esm/compiler/deserialize.js +139 -0
  11. package/esm/compiler/manifest.d.ts +3 -0
  12. package/esm/compiler/manifest.d.ts.map +1 -1
  13. package/esm/compiler/manifest.js +9 -3
  14. package/esm/compiler/mod.d.ts.map +1 -1
  15. package/esm/compiler/mod.js +18 -13
  16. package/esm/config/markspec.d.ts +40 -1
  17. package/esm/config/markspec.d.ts.map +1 -1
  18. package/esm/config/markspec.js +127 -2
  19. package/esm/config/mod.d.ts.map +1 -1
  20. package/esm/config/mod.js +143 -147
  21. package/esm/decl/duplicates.d.ts +29 -0
  22. package/esm/decl/duplicates.d.ts.map +1 -0
  23. package/esm/decl/duplicates.js +28 -0
  24. package/esm/decl/mod.d.ts +4 -2
  25. package/esm/decl/mod.d.ts.map +1 -1
  26. package/esm/decl/mod.js +2 -1
  27. package/esm/decl/surfaces.d.ts +29 -7
  28. package/esm/decl/surfaces.d.ts.map +1 -1
  29. package/esm/decl/surfaces.js +31 -18
  30. package/esm/discovery/mod.d.ts +24 -8
  31. package/esm/discovery/mod.d.ts.map +1 -1
  32. package/esm/discovery/mod.js +57 -21
  33. package/esm/discovery/projects.d.ts +109 -0
  34. package/esm/discovery/projects.d.ts.map +1 -0
  35. package/esm/discovery/projects.js +232 -0
  36. package/esm/formatter/entry_body.d.ts +86 -0
  37. package/esm/formatter/entry_body.d.ts.map +1 -0
  38. package/esm/formatter/entry_body.js +287 -0
  39. package/esm/formatter/mod.d.ts +13 -9
  40. package/esm/formatter/mod.d.ts.map +1 -1
  41. package/esm/formatter/mod.js +126 -50
  42. package/esm/gates/mod.d.ts +13 -2
  43. package/esm/gates/mod.d.ts.map +1 -1
  44. package/esm/gates/mod.js +41 -13
  45. package/esm/lint/runner.d.ts.map +1 -1
  46. package/esm/lint/runner.js +7 -5
  47. package/esm/lock/acquire_compile.d.ts +31 -0
  48. package/esm/lock/acquire_compile.d.ts.map +1 -0
  49. package/esm/lock/acquire_compile.js +83 -0
  50. package/esm/lock/cache_check.d.ts +28 -0
  51. package/esm/lock/cache_check.d.ts.map +1 -0
  52. package/esm/lock/cache_check.js +51 -0
  53. package/esm/lock/check.d.ts +14 -3
  54. package/esm/lock/check.d.ts.map +1 -1
  55. package/esm/lock/check.js +43 -4
  56. package/esm/lock/edge_drift.d.ts +2 -0
  57. package/esm/lock/edge_drift.d.ts.map +1 -1
  58. package/esm/lock/edge_drift.js +4 -0
  59. package/esm/lock/git_intent.d.ts +46 -0
  60. package/esm/lock/git_intent.d.ts.map +1 -0
  61. package/esm/lock/git_intent.js +111 -0
  62. package/esm/lock/mod.d.ts +11 -4
  63. package/esm/lock/mod.d.ts.map +1 -1
  64. package/esm/lock/mod.js +8 -2
  65. package/esm/lock/model.d.ts +24 -1
  66. package/esm/lock/model.d.ts.map +1 -1
  67. package/esm/lock/parser.d.ts.map +1 -1
  68. package/esm/lock/parser.js +32 -0
  69. package/esm/lock/pin_assurance.d.ts +20 -0
  70. package/esm/lock/pin_assurance.d.ts.map +1 -0
  71. package/esm/lock/pin_assurance.js +34 -0
  72. package/esm/lock/resolve.d.ts +8 -17
  73. package/esm/lock/resolve.d.ts.map +1 -1
  74. package/esm/lock/resolve.js +7 -67
  75. package/esm/lock/serializer.d.ts.map +1 -1
  76. package/esm/lock/serializer.js +23 -0
  77. package/esm/lock/upstream_common.d.ts +29 -0
  78. package/esm/lock/upstream_common.d.ts.map +1 -0
  79. package/esm/lock/upstream_common.js +38 -0
  80. package/esm/lock/upstream_deps.d.ts +63 -0
  81. package/esm/lock/upstream_deps.d.ts.map +1 -0
  82. package/esm/lock/upstream_deps.js +172 -0
  83. package/esm/lock/upstream_refs.d.ts +69 -0
  84. package/esm/lock/upstream_refs.d.ts.map +1 -0
  85. package/esm/lock/upstream_refs.js +238 -0
  86. package/esm/mod.d.ts +23 -11
  87. package/esm/mod.d.ts.map +1 -1
  88. package/esm/mod.js +20 -8
  89. package/esm/model/mod.d.ts +114 -28
  90. package/esm/model/mod.d.ts.map +1 -1
  91. package/esm/model/mod.js +76 -13
  92. package/esm/model/profile.d.ts +13 -0
  93. package/esm/model/profile.d.ts.map +1 -1
  94. package/esm/parser/code_regions.d.ts +29 -0
  95. package/esm/parser/code_regions.d.ts.map +1 -0
  96. package/esm/parser/code_regions.js +38 -0
  97. package/esm/parser/markdown.d.ts.map +1 -1
  98. package/esm/parser/markdown.js +110 -91
  99. package/esm/parser/mod.d.ts.map +1 -1
  100. package/esm/parser/mod.js +7 -1
  101. package/esm/parser/translate.d.ts.map +1 -1
  102. package/esm/parser/translate.js +5 -0
  103. package/esm/profile/manifest.d.ts.map +1 -1
  104. package/esm/profile/manifest.js +20 -3
  105. package/esm/profile/merge.js +7 -0
  106. package/esm/refs/mod.d.ts.map +1 -1
  107. package/esm/refs/mod.js +8 -19
  108. package/esm/reporter/mod.d.ts +11 -0
  109. package/esm/reporter/mod.d.ts.map +1 -1
  110. package/esm/reporter/mod.js +20 -9
  111. package/esm/typl/assemble.d.ts +53 -0
  112. package/esm/typl/assemble.d.ts.map +1 -0
  113. package/esm/typl/assemble.js +238 -0
  114. package/esm/typl/ast.d.ts +7 -1
  115. package/esm/typl/ast.d.ts.map +1 -1
  116. package/esm/typl/ast.js +3 -0
  117. package/esm/typl/bullet.d.ts +9 -7
  118. package/esm/typl/bullet.d.ts.map +1 -1
  119. package/esm/typl/bullet.js +6 -4
  120. package/esm/typl/citations.d.ts +27 -0
  121. package/esm/typl/citations.d.ts.map +1 -0
  122. package/esm/typl/citations.js +16 -0
  123. package/esm/typl/diagnostics.d.ts +2 -2
  124. package/esm/typl/diagnostics.d.ts.map +1 -1
  125. package/esm/typl/diagnostics.js +18 -0
  126. package/esm/typl/grammar.d.ts.map +1 -1
  127. package/esm/typl/grammar.js +6 -0
  128. package/esm/typl/lexer.d.ts.map +1 -1
  129. package/esm/typl/lexer.js +25 -4
  130. package/esm/typl/mod.d.ts +8 -2
  131. package/esm/typl/mod.d.ts.map +1 -1
  132. package/esm/typl/mod.js +5 -1
  133. package/esm/typl/recognize.js +2 -2
  134. package/esm/typl/registry.d.ts +1 -1
  135. package/esm/typl/resolve.d.ts +31 -0
  136. package/esm/typl/resolve.d.ts.map +1 -0
  137. package/esm/typl/resolve.js +27 -0
  138. package/esm/typl/table.d.ts +52 -0
  139. package/esm/typl/table.d.ts.map +1 -0
  140. package/esm/typl/table.js +69 -0
  141. package/esm/typl/validator.d.ts +24 -5
  142. package/esm/typl/validator.d.ts.map +1 -1
  143. package/esm/typl/validator.js +55 -75
  144. package/esm/upstream/mod.d.ts +45 -0
  145. package/esm/upstream/mod.d.ts.map +1 -0
  146. package/esm/upstream/mod.js +98 -0
  147. package/esm/upstream/project.d.ts +33 -0
  148. package/esm/upstream/project.d.ts.map +1 -0
  149. package/esm/upstream/project.js +38 -0
  150. package/esm/upstream/refs.d.ts +23 -0
  151. package/esm/upstream/refs.d.ts.map +1 -0
  152. package/esm/upstream/refs.js +71 -0
  153. package/esm/util/fence.d.ts +20 -29
  154. package/esm/util/fence.d.ts.map +1 -1
  155. package/esm/util/fence.js +42 -50
  156. package/esm/util/modals.d.ts +6 -0
  157. package/esm/util/modals.d.ts.map +1 -1
  158. package/esm/util/modals.js +37 -0
  159. package/esm/util/paths.d.ts +14 -0
  160. package/esm/util/paths.d.ts.map +1 -0
  161. package/esm/util/paths.js +22 -0
  162. package/esm/uxil/assemble.d.ts +38 -0
  163. package/esm/uxil/assemble.d.ts.map +1 -0
  164. package/esm/uxil/assemble.js +268 -0
  165. package/esm/uxil/ast.d.ts +63 -0
  166. package/esm/uxil/ast.d.ts.map +1 -0
  167. package/esm/uxil/ast.js +9 -0
  168. package/esm/uxil/citations.d.ts +27 -0
  169. package/esm/uxil/citations.d.ts.map +1 -0
  170. package/esm/uxil/citations.js +25 -0
  171. package/esm/uxil/diagnostics.d.ts +39 -0
  172. package/esm/uxil/diagnostics.d.ts.map +1 -0
  173. package/esm/uxil/diagnostics.js +135 -0
  174. package/esm/uxil/grammar.d.ts +72 -0
  175. package/esm/uxil/grammar.d.ts.map +1 -0
  176. package/esm/uxil/grammar.js +505 -0
  177. package/esm/uxil/lexer.d.ts +23 -0
  178. package/esm/uxil/lexer.d.ts.map +1 -0
  179. package/esm/uxil/lexer.js +58 -0
  180. package/esm/uxil/mod.d.ts +32 -0
  181. package/esm/uxil/mod.d.ts.map +1 -0
  182. package/esm/uxil/mod.js +11 -0
  183. package/esm/uxil/projection.d.ts +40 -0
  184. package/esm/uxil/projection.d.ts.map +1 -0
  185. package/esm/uxil/projection.js +41 -0
  186. package/esm/uxil/recognize.d.ts +16 -0
  187. package/esm/uxil/recognize.d.ts.map +1 -0
  188. package/esm/uxil/recognize.js +28 -0
  189. package/esm/uxil/registry.d.ts +37 -0
  190. package/esm/uxil/registry.d.ts.map +1 -0
  191. package/esm/uxil/registry.js +29 -0
  192. package/esm/uxil/surfaces.d.ts +36 -0
  193. package/esm/uxil/surfaces.d.ts.map +1 -0
  194. package/esm/uxil/surfaces.js +34 -0
  195. package/esm/uxil/validator.d.ts +36 -0
  196. package/esm/uxil/validator.d.ts.map +1 -0
  197. package/esm/uxil/validator.js +139 -0
  198. package/esm/uxil/vocab.d.ts +33 -0
  199. package/esm/uxil/vocab.d.ts.map +1 -0
  200. package/esm/uxil/vocab.js +36 -0
  201. package/esm/validator/body_blocks.d.ts +2 -1
  202. package/esm/validator/body_blocks.d.ts.map +1 -1
  203. package/esm/validator/body_blocks.js +80 -2
  204. package/esm/validator/caption_convention.d.ts +2 -1
  205. package/esm/validator/caption_convention.d.ts.map +1 -1
  206. package/esm/validator/caption_convention.js +2 -1
  207. package/esm/validator/corpus.d.ts +6 -0
  208. package/esm/validator/corpus.d.ts.map +1 -1
  209. package/esm/validator/corpus.js +55 -20
  210. package/esm/validator/discipline.d.ts +6 -4
  211. package/esm/validator/discipline.d.ts.map +1 -1
  212. package/esm/validator/discipline.js +6 -4
  213. package/esm/validator/mod.d.ts +1 -1
  214. package/esm/validator/mod.d.ts.map +1 -1
  215. package/esm/validator/mod.js +29 -16
  216. package/esm/validator/pipeline.d.ts +11 -1
  217. package/esm/validator/pipeline.d.ts.map +1 -1
  218. package/esm/validator/pipeline.js +76 -23
  219. package/esm/validator/trace_types.d.ts +9 -2
  220. package/esm/validator/trace_types.d.ts.map +1 -1
  221. package/esm/validator/trace_types.js +21 -5
  222. package/esm/validator/traceability.d.ts +15 -3
  223. package/esm/validator/traceability.d.ts.map +1 -1
  224. package/esm/validator/traceability.js +39 -4
  225. package/esm/validator/types.d.ts.map +1 -1
  226. package/esm/validator/types.js +11 -1
  227. package/esm/validator/uxil_family.d.ts +43 -0
  228. package/esm/validator/uxil_family.d.ts.map +1 -0
  229. package/esm/validator/uxil_family.js +52 -0
  230. package/package.json +1 -1
  231. package/script/ast/normalize.d.ts +4 -5
  232. package/script/ast/normalize.d.ts.map +1 -1
  233. package/script/ast/normalize.js +5 -36
  234. package/script/collect/mod.d.ts +29 -9
  235. package/script/collect/mod.d.ts.map +1 -1
  236. package/script/collect/mod.js +38 -10
  237. package/script/compiler/deserialize.d.ts +49 -0
  238. package/script/compiler/deserialize.d.ts.map +1 -0
  239. package/script/compiler/deserialize.js +144 -0
  240. package/script/compiler/manifest.d.ts +3 -0
  241. package/script/compiler/manifest.d.ts.map +1 -1
  242. package/script/compiler/manifest.js +10 -3
  243. package/script/compiler/mod.d.ts.map +1 -1
  244. package/script/compiler/mod.js +16 -11
  245. package/script/config/markspec.d.ts +40 -1
  246. package/script/config/markspec.d.ts.map +1 -1
  247. package/script/config/markspec.js +129 -3
  248. package/script/config/mod.d.ts.map +1 -1
  249. package/script/config/mod.js +143 -147
  250. package/script/decl/duplicates.d.ts +29 -0
  251. package/script/decl/duplicates.d.ts.map +1 -0
  252. package/script/decl/duplicates.js +31 -0
  253. package/script/decl/mod.d.ts +4 -2
  254. package/script/decl/mod.d.ts.map +1 -1
  255. package/script/decl/mod.js +4 -2
  256. package/script/decl/surfaces.d.ts +29 -7
  257. package/script/decl/surfaces.d.ts.map +1 -1
  258. package/script/decl/surfaces.js +32 -19
  259. package/script/discovery/mod.d.ts +24 -8
  260. package/script/discovery/mod.d.ts.map +1 -1
  261. package/script/discovery/mod.js +56 -20
  262. package/script/discovery/projects.d.ts +109 -0
  263. package/script/discovery/projects.d.ts.map +1 -0
  264. package/script/discovery/projects.js +240 -0
  265. package/script/formatter/entry_body.d.ts +86 -0
  266. package/script/formatter/entry_body.d.ts.map +1 -0
  267. package/script/formatter/entry_body.js +292 -0
  268. package/script/formatter/mod.d.ts +13 -9
  269. package/script/formatter/mod.d.ts.map +1 -1
  270. package/script/formatter/mod.js +124 -48
  271. package/script/gates/mod.d.ts +13 -2
  272. package/script/gates/mod.d.ts.map +1 -1
  273. package/script/gates/mod.js +50 -22
  274. package/script/lint/runner.d.ts.map +1 -1
  275. package/script/lint/runner.js +6 -4
  276. package/script/lock/acquire_compile.d.ts +31 -0
  277. package/script/lock/acquire_compile.d.ts.map +1 -0
  278. package/script/lock/acquire_compile.js +86 -0
  279. package/script/lock/cache_check.d.ts +28 -0
  280. package/script/lock/cache_check.d.ts.map +1 -0
  281. package/script/lock/cache_check.js +54 -0
  282. package/script/lock/check.d.ts +14 -3
  283. package/script/lock/check.d.ts.map +1 -1
  284. package/script/lock/check.js +43 -4
  285. package/script/lock/edge_drift.d.ts +2 -0
  286. package/script/lock/edge_drift.d.ts.map +1 -1
  287. package/script/lock/edge_drift.js +5 -0
  288. package/script/lock/git_intent.d.ts +46 -0
  289. package/script/lock/git_intent.d.ts.map +1 -0
  290. package/script/lock/git_intent.js +115 -0
  291. package/script/lock/mod.d.ts +11 -4
  292. package/script/lock/mod.d.ts.map +1 -1
  293. package/script/lock/mod.js +17 -2
  294. package/script/lock/model.d.ts +24 -1
  295. package/script/lock/model.d.ts.map +1 -1
  296. package/script/lock/parser.d.ts.map +1 -1
  297. package/script/lock/parser.js +32 -0
  298. package/script/lock/pin_assurance.d.ts +20 -0
  299. package/script/lock/pin_assurance.d.ts.map +1 -0
  300. package/script/lock/pin_assurance.js +37 -0
  301. package/script/lock/resolve.d.ts +8 -17
  302. package/script/lock/resolve.d.ts.map +1 -1
  303. package/script/lock/resolve.js +7 -68
  304. package/script/lock/serializer.d.ts.map +1 -1
  305. package/script/lock/serializer.js +23 -0
  306. package/script/lock/upstream_common.d.ts +29 -0
  307. package/script/lock/upstream_common.d.ts.map +1 -0
  308. package/script/lock/upstream_common.js +42 -0
  309. package/script/lock/upstream_deps.d.ts +63 -0
  310. package/script/lock/upstream_deps.d.ts.map +1 -0
  311. package/script/lock/upstream_deps.js +175 -0
  312. package/script/lock/upstream_refs.d.ts +69 -0
  313. package/script/lock/upstream_refs.d.ts.map +1 -0
  314. package/script/lock/upstream_refs.js +244 -0
  315. package/script/mod.d.ts +23 -11
  316. package/script/mod.d.ts.map +1 -1
  317. package/script/mod.js +55 -7
  318. package/script/model/mod.d.ts +114 -28
  319. package/script/model/mod.d.ts.map +1 -1
  320. package/script/model/mod.js +81 -14
  321. package/script/model/profile.d.ts +13 -0
  322. package/script/model/profile.d.ts.map +1 -1
  323. package/script/parser/code_regions.d.ts +29 -0
  324. package/script/parser/code_regions.d.ts.map +1 -0
  325. package/script/parser/code_regions.js +41 -0
  326. package/script/parser/markdown.d.ts.map +1 -1
  327. package/script/parser/markdown.js +108 -89
  328. package/script/parser/mod.d.ts.map +1 -1
  329. package/script/parser/mod.js +7 -1
  330. package/script/parser/translate.d.ts.map +1 -1
  331. package/script/parser/translate.js +5 -0
  332. package/script/profile/manifest.d.ts.map +1 -1
  333. package/script/profile/manifest.js +20 -3
  334. package/script/profile/merge.js +7 -0
  335. package/script/refs/mod.d.ts.map +1 -1
  336. package/script/refs/mod.js +7 -18
  337. package/script/reporter/mod.d.ts +11 -0
  338. package/script/reporter/mod.d.ts.map +1 -1
  339. package/script/reporter/mod.js +19 -8
  340. package/script/typl/assemble.d.ts +53 -0
  341. package/script/typl/assemble.d.ts.map +1 -0
  342. package/script/typl/assemble.js +241 -0
  343. package/script/typl/ast.d.ts +7 -1
  344. package/script/typl/ast.d.ts.map +1 -1
  345. package/script/typl/ast.js +3 -0
  346. package/script/typl/bullet.d.ts +9 -7
  347. package/script/typl/bullet.d.ts.map +1 -1
  348. package/script/typl/bullet.js +6 -4
  349. package/script/typl/citations.d.ts +27 -0
  350. package/script/typl/citations.d.ts.map +1 -0
  351. package/script/typl/citations.js +20 -0
  352. package/script/typl/diagnostics.d.ts +2 -2
  353. package/script/typl/diagnostics.d.ts.map +1 -1
  354. package/script/typl/diagnostics.js +18 -0
  355. package/script/typl/grammar.d.ts.map +1 -1
  356. package/script/typl/grammar.js +6 -0
  357. package/script/typl/lexer.d.ts.map +1 -1
  358. package/script/typl/lexer.js +25 -4
  359. package/script/typl/mod.d.ts +8 -2
  360. package/script/typl/mod.d.ts.map +1 -1
  361. package/script/typl/mod.js +14 -2
  362. package/script/typl/recognize.js +2 -2
  363. package/script/typl/registry.d.ts +1 -1
  364. package/script/typl/resolve.d.ts +31 -0
  365. package/script/typl/resolve.d.ts.map +1 -0
  366. package/script/typl/resolve.js +33 -0
  367. package/script/typl/table.d.ts +52 -0
  368. package/script/typl/table.d.ts.map +1 -0
  369. package/script/typl/table.js +75 -0
  370. package/script/typl/validator.d.ts +24 -5
  371. package/script/typl/validator.d.ts.map +1 -1
  372. package/script/typl/validator.js +55 -75
  373. package/script/upstream/mod.d.ts +45 -0
  374. package/script/upstream/mod.d.ts.map +1 -0
  375. package/script/upstream/mod.js +101 -0
  376. package/script/upstream/project.d.ts +33 -0
  377. package/script/upstream/project.d.ts.map +1 -0
  378. package/script/upstream/project.js +41 -0
  379. package/script/upstream/refs.d.ts +23 -0
  380. package/script/upstream/refs.d.ts.map +1 -0
  381. package/script/upstream/refs.js +74 -0
  382. package/script/util/fence.d.ts +20 -29
  383. package/script/util/fence.d.ts.map +1 -1
  384. package/script/util/fence.js +47 -54
  385. package/script/util/modals.d.ts +6 -0
  386. package/script/util/modals.d.ts.map +1 -1
  387. package/script/util/modals.js +38 -0
  388. package/script/util/paths.d.ts +14 -0
  389. package/script/util/paths.d.ts.map +1 -0
  390. package/script/util/paths.js +25 -0
  391. package/script/uxil/assemble.d.ts +38 -0
  392. package/script/uxil/assemble.d.ts.map +1 -0
  393. package/script/uxil/assemble.js +272 -0
  394. package/script/uxil/ast.d.ts +63 -0
  395. package/script/uxil/ast.d.ts.map +1 -0
  396. package/script/uxil/ast.js +10 -0
  397. package/script/uxil/citations.d.ts +27 -0
  398. package/script/uxil/citations.d.ts.map +1 -0
  399. package/script/uxil/citations.js +29 -0
  400. package/script/uxil/diagnostics.d.ts +39 -0
  401. package/script/uxil/diagnostics.d.ts.map +1 -0
  402. package/script/uxil/diagnostics.js +140 -0
  403. package/script/uxil/grammar.d.ts +72 -0
  404. package/script/uxil/grammar.d.ts.map +1 -0
  405. package/script/uxil/grammar.js +511 -0
  406. package/script/uxil/lexer.d.ts +23 -0
  407. package/script/uxil/lexer.d.ts.map +1 -0
  408. package/script/uxil/lexer.js +61 -0
  409. package/script/uxil/mod.d.ts +32 -0
  410. package/script/uxil/mod.d.ts.map +1 -0
  411. package/script/uxil/mod.js +37 -0
  412. package/script/uxil/projection.d.ts +40 -0
  413. package/script/uxil/projection.d.ts.map +1 -0
  414. package/script/uxil/projection.js +44 -0
  415. package/script/uxil/recognize.d.ts +16 -0
  416. package/script/uxil/recognize.d.ts.map +1 -0
  417. package/script/uxil/recognize.js +31 -0
  418. package/script/uxil/registry.d.ts +37 -0
  419. package/script/uxil/registry.d.ts.map +1 -0
  420. package/script/uxil/registry.js +32 -0
  421. package/script/uxil/surfaces.d.ts +36 -0
  422. package/script/uxil/surfaces.d.ts.map +1 -0
  423. package/script/uxil/surfaces.js +39 -0
  424. package/script/uxil/validator.d.ts +36 -0
  425. package/script/uxil/validator.d.ts.map +1 -0
  426. package/script/uxil/validator.js +142 -0
  427. package/script/uxil/vocab.d.ts +33 -0
  428. package/script/uxil/vocab.d.ts.map +1 -0
  429. package/script/uxil/vocab.js +41 -0
  430. package/script/validator/body_blocks.d.ts +2 -1
  431. package/script/validator/body_blocks.d.ts.map +1 -1
  432. package/script/validator/body_blocks.js +80 -2
  433. package/script/validator/caption_convention.d.ts +2 -1
  434. package/script/validator/caption_convention.d.ts.map +1 -1
  435. package/script/validator/caption_convention.js +2 -1
  436. package/script/validator/corpus.d.ts +6 -0
  437. package/script/validator/corpus.d.ts.map +1 -1
  438. package/script/validator/corpus.js +55 -19
  439. package/script/validator/discipline.d.ts +6 -4
  440. package/script/validator/discipline.d.ts.map +1 -1
  441. package/script/validator/discipline.js +6 -4
  442. package/script/validator/mod.d.ts +1 -1
  443. package/script/validator/mod.d.ts.map +1 -1
  444. package/script/validator/mod.js +29 -15
  445. package/script/validator/pipeline.d.ts +11 -1
  446. package/script/validator/pipeline.d.ts.map +1 -1
  447. package/script/validator/pipeline.js +75 -22
  448. package/script/validator/trace_types.d.ts +9 -2
  449. package/script/validator/trace_types.d.ts.map +1 -1
  450. package/script/validator/trace_types.js +20 -4
  451. package/script/validator/traceability.d.ts +15 -3
  452. package/script/validator/traceability.d.ts.map +1 -1
  453. package/script/validator/traceability.js +38 -3
  454. package/script/validator/types.d.ts.map +1 -1
  455. package/script/validator/types.js +10 -0
  456. package/script/validator/uxil_family.d.ts +43 -0
  457. package/script/validator/uxil_family.d.ts.map +1 -0
  458. package/script/validator/uxil_family.js +56 -0
@@ -0,0 +1,238 @@
1
+ /**
2
+ * @module lock/upstream_refs
3
+ *
4
+ * Lock-mediated resolution of org-manifest `references:` projectRefs
5
+ * (design §4.2): fetch a published compile-output snapshot over https or
6
+ * `file://`, cache it under `.markspec/cache/upstreams/<id>/`, and pin it
7
+ * as an extended `[[upstream.registry]]` lockfile row. Three flows:
8
+ * first lock (new declaration → fetch + pin), keep/restore (pin exists →
9
+ * verify cache offline, refetch only to repopulate, never move the pin),
10
+ * update (`--update` → refetch + move the pin).
11
+ *
12
+ * Pure module: network and file access only via {@linkcode UpstreamRefsIO}.
13
+ */
14
+ import { join } from "@std/path";
15
+ import { sha256Bytes } from "./hash.js";
16
+ import { upstreamNotLockable, writeCacheFiles } from "./upstream_common.js";
17
+ import { checkSnapshotSchema } from "../compiler/deserialize.js";
18
+ import { isUnsafeRelPath } from "../util/paths.js";
19
+ /**
20
+ * Root directory under which every upstream's cached snapshot is stored,
21
+ * one subdirectory per upstream id (`<root>/<id>/manifest.json`, etc.).
22
+ * Shared by `markspec lock` (the writer) and `markspec check` (the
23
+ * offline MSL-L212 prober) so the two commands can never disagree on
24
+ * where the cache lives.
25
+ */
26
+ export function upstreamCacheRoot(projectRoot) {
27
+ return join(projectRoot, ".markspec", "cache", "upstreams");
28
+ }
29
+ /** Safe upstream id — a single path segment (also enforced by the config
30
+ * loader on explicit `name:` values). */
31
+ const UPSTREAM_ID_RE = /^[A-Za-z0-9][A-Za-z0-9._-]*$/;
32
+ /**
33
+ * Derive the upstream id for a projectRef: the explicit `name`, else the
34
+ * last non-empty path segment of the URL with any `.git` suffix stripped.
35
+ * Returns `undefined` when no safe id can be derived.
36
+ */
37
+ export function deriveUpstreamId(ref) {
38
+ if (ref.name !== undefined) {
39
+ return UPSTREAM_ID_RE.test(ref.name) ? ref.name : undefined;
40
+ }
41
+ const trimmed = ref.url.replace(/\/+$/, "");
42
+ const segment = trimmed.split(/[/:]/).filter((s) => s.length > 0).pop();
43
+ if (segment === undefined)
44
+ return undefined;
45
+ const id = segment.replace(/\.git$/, "");
46
+ return UPSTREAM_ID_RE.test(id) ? id : undefined;
47
+ }
48
+ function l213(id, detail) {
49
+ return upstreamNotLockable("reference", id, detail);
50
+ }
51
+ async function fetchSnapshot(id, baseUrl, fetchUrl) {
52
+ const manifestUrl = `${baseUrl}/manifest.json`;
53
+ const manifestBytes = await fetchUrl(manifestUrl);
54
+ if ("error" in manifestBytes) {
55
+ return l213(id, `fetch of ${manifestUrl} failed (${manifestBytes.error})`);
56
+ }
57
+ let manifest;
58
+ try {
59
+ manifest = JSON.parse(new TextDecoder().decode(manifestBytes));
60
+ }
61
+ catch (err) {
62
+ return l213(id, `manifest.json is not valid JSON: ${err instanceof Error ? err.message : String(err)}`);
63
+ }
64
+ const skew = checkSnapshotSchema(manifest, manifestUrl);
65
+ if (skew)
66
+ return l213(id, skew.message);
67
+ const entriesFile = manifest.entries?.file;
68
+ if (entriesFile === undefined || isUnsafeRelPath(entriesFile)) {
69
+ return l213(id, "manifest entries block missing or names an unsafe path");
70
+ }
71
+ const files = new Map();
72
+ const dataBytes = await fetchUrl(`${baseUrl}/${entriesFile}`);
73
+ if ("error" in dataBytes) {
74
+ return l213(id, `fetch of '${entriesFile}' failed (${dataBytes.error})`);
75
+ }
76
+ files.set(entriesFile, dataBytes);
77
+ const indexFile = manifest.entries?.index;
78
+ if (manifest.entries?.format === "ndjson" && indexFile !== undefined) {
79
+ if (isUnsafeRelPath(indexFile)) {
80
+ return l213(id, "manifest entries index names an unsafe path");
81
+ }
82
+ const indexBytes = await fetchUrl(`${baseUrl}/${indexFile}`);
83
+ if ("error" in indexBytes) {
84
+ return l213(id, `fetch of '${indexFile}' failed (${indexBytes.error})`);
85
+ }
86
+ files.set(indexFile, indexBytes);
87
+ }
88
+ return {
89
+ manifestBytes,
90
+ manifest,
91
+ files,
92
+ snapshotHash: await sha256Bytes(dataBytes),
93
+ };
94
+ }
95
+ function writeCache(id, dir, fetched, io) {
96
+ const writes = [
97
+ [join(dir, "manifest.json"), fetched.manifestBytes],
98
+ ...[...fetched.files].map(([rel, bytes]) => [join(dir, rel), bytes]),
99
+ ];
100
+ return writeCacheFiles(writes, "reference", id, io.writeFile);
101
+ }
102
+ /**
103
+ * Probe whether the cached snapshot under `dir` is present and hash-intact
104
+ * against `snapshot`: `manifest.json` must exist and parse, its
105
+ * `entries.file` must name a safe relative path, and the hashed bytes of
106
+ * that file must equal `snapshot`.
107
+ *
108
+ * Shared by {@linkcode cacheIntact} (this module's keep/restore flow) and
109
+ * `verifyUpstreamCache` (`cache_check.ts`'s MSL-L212 offline cache-drift
110
+ * gate) so the two never disagree on what "cache intact" means — the
111
+ * single probe implementation, not a duplicate.
112
+ */
113
+ export async function probeCacheSnapshot(dir, snapshot, readFile) {
114
+ const manifestBytes = await readFile(join(dir, "manifest.json"));
115
+ if ("error" in manifestBytes)
116
+ return false;
117
+ let entriesFile;
118
+ try {
119
+ const manifest = JSON.parse(new TextDecoder().decode(manifestBytes));
120
+ entriesFile = manifest.entries?.file;
121
+ }
122
+ catch {
123
+ return false;
124
+ }
125
+ if (entriesFile === undefined || isUnsafeRelPath(entriesFile))
126
+ return false;
127
+ const dataBytes = await readFile(join(dir, entriesFile));
128
+ if ("error" in dataBytes)
129
+ return false;
130
+ return await sha256Bytes(dataBytes) === snapshot;
131
+ }
132
+ /** Is the cached snapshot for `row` present and hash-intact? */
133
+ async function cacheIntact(row, dir, readFile) {
134
+ if (row.snapshot === undefined)
135
+ return false;
136
+ return await probeCacheSnapshot(dir, row.snapshot, readFile);
137
+ }
138
+ function buildRow(id, baseUrl, fetched, manifestHash, lockedAt) {
139
+ const version = fetched.manifest.project?.version;
140
+ return {
141
+ kind: "registry",
142
+ id,
143
+ api: baseUrl,
144
+ resolvedManifestHash: manifestHash,
145
+ markspecSchema: fetched.manifest.markspecSchemaVersion,
146
+ ...(typeof version === "string" ? { version } : {}),
147
+ snapshot: fetched.snapshotHash,
148
+ lockedAt,
149
+ };
150
+ }
151
+ /** See module doc for the flow table. */
152
+ export async function resolveProjectReferences(opts) {
153
+ const registries = [];
154
+ const diagnostics = [];
155
+ const byId = new Map(opts.existing.map((row) => [row.id, row]));
156
+ const seen = new Set();
157
+ for (const ref of opts.references) {
158
+ const id = deriveUpstreamId(ref);
159
+ if (id === undefined) {
160
+ diagnostics.push(l213(ref.name ?? ref.url, "no safe upstream id could be derived — set an explicit 'name:'"));
161
+ continue;
162
+ }
163
+ if (seen.has(id)) {
164
+ diagnostics.push(l213(id, `duplicate upstream id (also derived for an earlier entry) — set distinct 'name:' values`));
165
+ continue;
166
+ }
167
+ seen.add(id);
168
+ const baseUrl = ref.url.replace(/\/+$/, "");
169
+ // join() at construction (#771): a template concat would mix the
170
+ // platform separator with a literal `/` — the Windows drift class
171
+ // that bit slices 2 and 4. Writer and reader must agree byte-for-byte.
172
+ const dir = join(opts.cacheRoot, id);
173
+ const existing = byId.get(id);
174
+ const selectedForUpdate = opts.update === true || opts.update === id;
175
+ if (existing !== undefined && !selectedForUpdate) {
176
+ // Keep — verify offline; restore only when the cache is broken.
177
+ if (await cacheIntact(existing, dir, opts.io.readFile)) {
178
+ registries.push(existing);
179
+ continue;
180
+ }
181
+ const fetched = await fetchSnapshot(id, baseUrl, opts.io.fetchUrl);
182
+ if ("code" in fetched) {
183
+ diagnostics.push(fetched);
184
+ registries.push(existing); // keep the pin; cache stays broken
185
+ continue;
186
+ }
187
+ // A snapshot-less existing row (representable — e.g. a hand-edited
188
+ // or pre-existing lockfile entry) has no pin to verify the fetch
189
+ // against; comparing against `undefined` would always "mismatch".
190
+ // Treat it as a first-lock/re-pin instead of MSL-L214.
191
+ if (existing.snapshot !== undefined &&
192
+ fetched.snapshotHash !== existing.snapshot) {
193
+ diagnostics.push({
194
+ code: "MSL-L214",
195
+ severity: "warning",
196
+ message: `upstream reference '${id}' restore mismatch: fetched snapshot ` +
197
+ `${fetched.snapshotHash} does not match locked ${existing.snapshot} — ` +
198
+ `the published site moved; run 'markspec lock --update=${id}' to move the pin`,
199
+ location: undefined,
200
+ });
201
+ registries.push(existing);
202
+ continue;
203
+ }
204
+ const writeError = await writeCache(id, dir, fetched, opts.io);
205
+ if (writeError) {
206
+ diagnostics.push(writeError);
207
+ registries.push(existing);
208
+ continue;
209
+ }
210
+ if (existing.snapshot === undefined) {
211
+ const manifestHash = await sha256Bytes(fetched.manifestBytes);
212
+ registries.push(buildRow(id, baseUrl, fetched, manifestHash, opts.lockedAt));
213
+ }
214
+ else {
215
+ registries.push(existing);
216
+ }
217
+ continue;
218
+ }
219
+ // First lock, or explicitly selected for update.
220
+ const fetched = await fetchSnapshot(id, baseUrl, opts.io.fetchUrl);
221
+ if ("code" in fetched) {
222
+ diagnostics.push(fetched);
223
+ if (existing !== undefined)
224
+ registries.push(existing);
225
+ continue;
226
+ }
227
+ const writeError = await writeCache(id, dir, fetched, opts.io);
228
+ if (writeError) {
229
+ diagnostics.push(writeError);
230
+ if (existing !== undefined)
231
+ registries.push(existing);
232
+ continue;
233
+ }
234
+ const manifestHash = await sha256Bytes(fetched.manifestBytes);
235
+ registries.push(buildRow(id, baseUrl, fetched, manifestHash, opts.lockedAt));
236
+ }
237
+ return { registries, diagnostics };
238
+ }
package/esm/mod.d.ts CHANGED
@@ -8,18 +8,17 @@
8
8
  * from core/mod.ts, never from internal paths.
9
9
  */
10
10
  import "./_dnt.polyfills.js";
11
- export declare const VERSION = "0.10.3";
12
- export declare const CORE_SCHEMA_VERSION = 1;
13
- export { ConfigError, CORE_DISCIPLINE_REGISTRY, CORE_KINDS, CORE_RELATIONS, DEFAULT_PROJECT_CONFIG, descendantsOf, formatEntryOrigin, KNOWN_LINK_KINDS, LOCK_EXTRA_INVERSE_KEYS, makeDisplayId, makeUlid, MIXED_DISCIPLINE, PALETTE_HUES, REFHUB_URL, } from "./model/mod.js";
14
- export type { Attribute, BodyToken, BodyTokenKind, Caption, CaptionConventions, CaptionPosition, ConfigFieldError, DeliveredDocument, Diagnostic, Directive, Discipline, DisciplineRegistry, DisplayId, EarsTrigger, EffectiveProfile, EffectiveTypeDef, EntityRefConvention, Entry, EntryOrigin, EntryShape, EntrySource, ExtractorRule, InlineRef, KindDecl, LabelConcern, LabelConcernKind, LabelValue, Link, LinkKind, LoadedProfile, ModalCase, PaletteHue, ProfileChain, ProfileConvention, ProjectConfig, ProvenancedMap, ProvenancedMapEntry, ProvenancedValue, RelationDef, Severity, SourceLocation, Ulid, } from "./model/mod.js";
11
+ export declare const VERSION = "0.12.0";
12
+ export { ConfigError, CORE_DISCIPLINE_REGISTRY, CORE_KINDS, CORE_RELATIONS, CORE_SCHEMA_VERSION, DEFAULT_PROJECT_CONFIG, descendantsOf, emittableEntries, formatEntryOrigin, isCorpusEntry, isUpstreamEntry, KNOWN_LINK_KINDS, LOCK_EXTRA_INVERSE_KEYS, makeDisplayId, makeUlid, MIXED_DISCIPLINE, PALETTE_HUES, sameOriginSource, } from "./model/mod.js";
13
+ export type { Attribute, BodyToken, BodyTokenKind, Caption, CaptionConventions, CaptionPosition, ConfigFieldError, DeliveredDocument, Diagnostic, Directive, Discipline, DisciplineRegistry, DisplayId, EarsTrigger, EffectiveProfile, EffectiveTypeDef, EntityRefConvention, Entry, EntryOrigin, EntryShape, EntrySource, ExtractorRule, InlineRef, KindDecl, LabelConcern, LabelConcernKind, LabelValue, Link, LinkKind, LoadedProfile, ModalCase, PaletteHue, ProfileChain, ProfileConvention, ProjectConfig, ProjectRef, ProvenancedMap, ProvenancedMapEntry, ProvenancedValue, RelationDef, Severity, SourceLocation, Ulid, } from "./model/mod.js";
15
14
  export { astEquivalent } from "./ast/equivalence.js";
16
15
  export { normalizeBodyAst } from "./ast/normalize.js";
17
16
  export { render } from "./ast/render.js";
18
17
  export type { AdmonitionKind, BlockquoteNode, BodyBlock, CaptionNode, CodeNode, DefinitionListNode, DefinitionPair, FeatureNode, FigureNode, InlineContent, ListItemNode, ListNode, MathNode, NoteNode, ParagraphNode, SourceRange, TableNode, UnknownNode, } from "./ast/nodes.js";
19
18
  export { discoverProjectRoot, loadConfig, parseProjectConfig, } from "./config/mod.js";
20
19
  export type { LoadConfigResult, ReadFile } from "./config/mod.js";
21
- export { addProfileSpecifier, discoverMarkspecRoot, MARKSPEC_YAML_FILENAME, parseMarkspecYaml, readMarkspecYaml, } from "./config/markspec.js";
22
- export type { MarkspecYaml, ParseMarkspecYamlResult, } from "./config/markspec.js";
20
+ export { addProfileSpecifier, DEFAULT_TOOL_CONFIG, discoverMarkspecRoot, loadToolConfig, MARKSPEC_YAML_FILENAME, parseMarkspecYaml, readMarkspecYaml, } from "./config/markspec.js";
21
+ export type { MarkspecYaml, ParseMarkspecYamlResult, ToolConfig, } from "./config/markspec.js";
23
22
  export { computeCacheKey, computeCacheLocation, defaultAppendFile, defaultRunGit, ensureCacheGitignored, loadChain, loadProfileForCommand, mergeChain, parseManifest, resolveEntryColor, resolveGitSpecifier, resolveLocalSpecifier, } from "./profile/mod.js";
24
23
  export type { AppendFile, CacheLocation, GitCacheKeyInput, LoadChainOptions, LoadChainResult, LoadProfileForCommandResult, MergeResult, ParseManifestResult, ResolvedProfileSource, ResolveGitOptions, RunGit, RunGitResult, } from "./profile/mod.js";
25
24
  export { buildEffectiveDisciplineRegistry } from "./profile/mod.js";
@@ -35,9 +34,11 @@ export { detectCaptions, detectDirectives, detectInlineRefs, isSupportedExtensio
35
34
  export type { DetectCaptionsOptions, DetectDirectivesOptions, DetectInlineRefsOptions, DocCommentBlockMeta, LanguageDocCommentSpec, LineMap, ParseFileResult, ParseOptions, ParseSourceOptions, ParseSourceResult, SupportedLanguage, } from "./parser/mod.js";
36
35
  export { format } from "./formatter/mod.js";
37
36
  export type { FormatOptions, FormatResult } from "./formatter/mod.js";
37
+ export { readEntryBody, replaceEntryBody } from "./formatter/entry_body.js";
38
+ export type { EntryBodyEdit, EntryBodyRefusal, } from "./formatter/entry_body.js";
38
39
  export { loadMarkdownFormatter, MARKSPEC_MARKDOWN_GLOBAL_CONFIG, MARKSPEC_MARKDOWN_PLUGIN_CONFIG, } from "./formatter/dprint.js";
39
40
  export type { ProseFormatOptions, ProseFormatter } from "./formatter/dprint.js";
40
- export { attributeCorpusDiagnostics, classifyEntriesStage, classifyEntry, compileDisplayIdPattern, detectCorpusCollisions, effectiveScope, effectiveTraceRules, matchesAnyTarget, normalizeListValues, runPipeline, suppressDeclaredAttrR010, validate, validateAttributesForEntry, validateListingDocuments, validateTraceabilityForEntry, validateValue, } from "./validator/mod.js";
41
+ export { applyCorpusPostPass, attributeCorpusDiagnostics, classifyEntriesStage, classifyEntry, compileDisplayIdPattern, detectCorpusCollisions, effectiveScope, effectiveTraceRules, matchesAnyTarget, normalizeListValues, runPipeline, suppressDeclaredAttrR010, validate, validateAttributesForEntry, validateListingDocuments, validateTraceabilityForEntry, validateValue, } from "./validator/mod.js";
41
42
  export type { ClassifyResult, ClassifyStageResult, CorpusCollisionResult, EffectiveAttrScope, ListingFileContext, ListingKind, PipelineOptions, PipelineResult, ValidateResult, ValueValidator, } from "./validator/mod.js";
42
43
  export { compile, generateInverses, serializeCompileResult, } from "./compiler/mod.js";
43
44
  export type { CompileOptions, CompileResult, GenerateInversesResult, SerializedCompileResult, SerializedEntry, SerializedTypeRegistry, } from "./compiler/mod.js";
@@ -50,18 +51,29 @@ export type { ReportFormat, ReportKind, ReportOptions, } from "./reporter/mod.js
50
51
  export { ANTI_PATTERN_NOTE, computeScoreRollup, isProseScope, runLint, } from "./lint/mod.js";
51
52
  export type { EntryScore, LintDiagnostic, LintOptions, LintResult, RuleContribution, ScoreRollup, } from "./lint/mod.js";
52
53
  export * as typl from "./typl/mod.js";
53
- export { canonicalEdgeJson, checkDrift, detectOfflineEdgeDrift, extractEdgeLedger, extractEdgeQuads, hashCanonicalEdges, isBelowFloor, LOCKFILE_SCHEMA_VERSION, parseLockfile, resolveBoundEntries, resolveProfileChain, resolveReferences, resolveRegistries, resolveUpstreams, serializeLockfile, sha256Bytes, sha256String, } from "./lock/mod.js";
54
- export type { BoundEntry as LockBoundEntry, BoundEntryBinding as LockBinding, EdgeQuad, FetchUrl, GeneratedCache, LockedAttributes, LockEdge, Lockfile, LockfileMeta, LockfileToolchain, OfflineEdgeDrift, ParseLockfileResult, ReadFile as LockReadFile, ResolvedBoundEntry, ResolvedProfile, ResolvedReference, ResolvedRegistry, ResolvedUpstreams, ResolveUpstreamsOptions, Upstream, UpstreamProfile, UpstreamReference, UpstreamRegistry, } from "./lock/mod.js";
54
+ export { uxilDeclaringTypes, validateUxilFamily, } from "./validator/uxil_family.js";
55
+ export * as uxil from "./uxil/mod.js";
56
+ export { canonicalEdgeJson, checkDrift, compileAcquiredTree, dependencyPinAssurance, deriveUpstreamId, detectOfflineEdgeDrift, extractEdgeLedger, extractEdgeQuads, formatEdgeDriftMessage, hashCanonicalEdges, isBelowFloor, LOCKFILE_SCHEMA_VERSION, parseLockfile, parseLsRemote, resolveBoundEntries, resolveIntent, resolveProfileChain, resolveProjectDependencies, resolveProjectReferences, resolveReferences, resolveUpstreams, serializeLockfile, sha256Bytes, sha256String, upstreamCacheRoot, verifyUpstreamCache, } from "./lock/mod.js";
57
+ export type { AcquireCompileIO, BoundEntry as LockBoundEntry, BoundEntryBinding as LockBinding, CompiledSnapshot, EdgeQuad, FetchUrl, GeneratedCache, GitIO, GitRef, LockedAttributes, LockEdge, Lockfile, LockfileMeta, LockfileToolchain, OfflineEdgeDrift, ParseLockfileResult, ReadFile as LockReadFile, RefList, ResolvedBoundEntry, ResolvedIntent, ResolvedProfile, ResolvedReference, ResolvedUpstreams, ResolveProjectDependenciesOptions, ResolveProjectDependenciesResult, ResolveProjectReferencesOptions, ResolveProjectReferencesResult, ResolveUpstreamsOptions, Upstream, UpstreamDependency, UpstreamDepsIO, UpstreamProfile, UpstreamReference, UpstreamRefsIO, UpstreamRegistry, } from "./lock/mod.js";
55
58
  export { buildRefIndex, canonicalizeRefs, TRACE_ATTRIBUTE_KEYS, } from "./refs/mod.js";
56
59
  export type { RefIndex } from "./refs/mod.js";
57
60
  export { fmtDriftGate, lockfileDriftGate, proseLintGate } from "./gates/mod.js";
58
- export { FENCE_RE, isLineFenced, walkProseLines } from "./util/fence.js";
61
+ export { FENCE_RE, fencedCodeLines, isLineFenced, walkProseLines, } from "./util/fence.js";
59
62
  export type { ProseLineCallback } from "./util/fence.js";
63
+ export { isUnsafeRelPath } from "./util/paths.js";
60
64
  export { aggregateStatusByState, encodeLogLine, inferLockedAttributes, parseLogLine, parseMapping, validateMappings, } from "./sync/mod.js";
61
65
  export type { AttributeMapping, BoundEntryStatus, ConflictPolicy, Direction as SyncDirection, Mapping, ParseMappingResult, RemoteState, SyncLogEntry, } from "./sync/mod.js";
62
66
  export { type Arch as SelfUpgradeArch, assertTrustedReleaseUrl, classifyInstallPath, type ClassifyResult as SelfUpgradeClassifyResult, compareVersions, type Comparison, DEFAULT_RELEASES_API, DEFAULT_RELEASES_DOWNLOAD_BASE, detectTarget, type InstallSource, type Os as SelfUpgradeOs, parseSha256Line, type Platform as SelfUpgradePlatform, platformFromBuild, type ReleaseAssets, releaseAssets, type ReleaseEndpoints, type ResolveEndpointsInput, resolveReleaseEndpoints, type Target as SelfUpgradeTarget, } from "./self_upgrade/mod.js";
63
67
  export { discoverFiles, isIgnored, MARKDOWN_EXTENSIONS, parseGitignore, RELEVANT_EXTENSIONS, SOURCE_EXTENSIONS, } from "./discovery/mod.js";
64
68
  export type { DiscoverOptions, DiscoveryDirEntry, DiscoveryIO, GitignoreRule, } from "./discovery/mod.js";
65
- export { collectProjectEntries } from "./collect/mod.js";
69
+ export { createProjectRootResolver, discoverProjectRoots, findNestedProjectRoots, isWithin, nearestRoot, resolveConfigRoot, } from "./discovery/projects.js";
70
+ export type { ProjectDiscoveryOptions, ProjectRootResolver, } from "./discovery/projects.js";
71
+ export { collectProjectEntries, UnreadableProjectFileError, } from "./collect/mod.js";
66
72
  export type { CollectOptions } from "./collect/mod.js";
73
+ export { checkSnapshotSchema, deserializeEntry, extractSerializedEntries, } from "./compiler/deserialize.js";
74
+ export type { ExtractedEntries } from "./compiler/deserialize.js";
75
+ export { loadUpstreamCorpus } from "./upstream/mod.js";
76
+ export type { LoadUpstreamCorpusResult, UpstreamSnapshotRef, } from "./upstream/mod.js";
77
+ export { upstreamRefsFromLockfile } from "./upstream/refs.js";
78
+ export { loadProjectUpstreams } from "./upstream/project.js";
67
79
  //# sourceMappingURL=mod.d.ts.map
package/esm/mod.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../src/mod.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,qBAAqB,CAAC;AAG7B,eAAO,MAAM,OAAO,WAAW,CAAC;AAChC,eAAO,MAAM,mBAAmB,IAAI,CAAC;AAGrC,OAAO,EACL,WAAW,EACX,wBAAwB,EACxB,UAAU,EACV,cAAc,EACd,sBAAsB,EACtB,aAAa,EACb,iBAAiB,EACjB,gBAAgB,EAChB,uBAAuB,EACvB,aAAa,EACb,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,UAAU,GACX,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,SAAS,EACT,SAAS,EACT,aAAa,EACb,OAAO,EACP,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,UAAU,EACV,SAAS,EACT,UAAU,EACV,kBAAkB,EAClB,SAAS,EACT,WAAW,EACX,gBAAgB,EAChB,gBAAgB,EAChB,mBAAmB,EACnB,KAAK,EACL,WAAW,EACX,UAAU,EACV,WAAW,EACX,aAAa,EACb,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,gBAAgB,EAChB,UAAU,EACV,IAAI,EACJ,QAAQ,EACR,aAAa,EACb,SAAS,EACT,UAAU,EACV,YAAY,EACZ,iBAAiB,EACjB,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,gBAAgB,EAChB,WAAW,EACX,QAAQ,EACR,cAAc,EACd,IAAI,GACL,MAAM,gBAAgB,CAAC;AAIxB,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,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,eAAe,EACf,KAAK,UAAU,EACf,oBAAoB,EACpB,8BAA8B,EAC9B,YAAY,EACZ,KAAK,aAAa,EAClB,KAAK,EAAE,IAAI,aAAa,EACxB,eAAe,EACf,KAAK,QAAQ,IAAI,mBAAmB,EACpC,iBAAiB,EACjB,KAAK,aAAa,EAClB,aAAa,EACb,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,uBAAuB,EACvB,KAAK,MAAM,IAAI,iBAAiB,GACjC,MAAM,uBAAuB,CAAC;AAG/B,OAAO,EACL,aAAa,EACb,SAAS,EACT,mBAAmB,EACnB,cAAc,EACd,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,oBAAoB,CAAC;AAC5B,YAAY,EACV,eAAe,EACf,iBAAiB,EACjB,WAAW,EACX,aAAa,GACd,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AACzD,YAAY,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC"}
1
+ {"version":3,"file":"mod.d.ts","sourceRoot":"","sources":["../src/mod.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,OAAO,qBAAqB,CAAC;AAG7B,eAAO,MAAM,OAAO,WAAW,CAAC;AAGhC,OAAO,EACL,WAAW,EACX,wBAAwB,EACxB,UAAU,EACV,cAAc,EACd,mBAAmB,EACnB,sBAAsB,EACtB,aAAa,EACb,gBAAgB,EAChB,iBAAiB,EACjB,aAAa,EACb,eAAe,EACf,gBAAgB,EAChB,uBAAuB,EACvB,aAAa,EACb,QAAQ,EACR,gBAAgB,EAChB,YAAY,EACZ,gBAAgB,GACjB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,SAAS,EACT,SAAS,EACT,aAAa,EACb,OAAO,EACP,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,UAAU,EACV,SAAS,EACT,UAAU,EACV,kBAAkB,EAClB,SAAS,EACT,WAAW,EACX,gBAAgB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,EACf,KAAK,QAAQ,IAAI,mBAAmB,EACpC,iBAAiB,EACjB,KAAK,aAAa,EAClB,aAAa,EACb,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,uBAAuB,EACvB,KAAK,MAAM,IAAI,iBAAiB,GACjC,MAAM,uBAAuB,CAAC;AAG/B,OAAO,EACL,aAAa,EACb,SAAS,EACT,mBAAmB,EACnB,cAAc,EACd,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,oBAAoB,CAAC;AAC5B,YAAY,EACV,eAAe,EACf,iBAAiB,EACjB,WAAW,EACX,aAAa,GACd,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,yBAAyB,EACzB,oBAAoB,EACpB,sBAAsB,EACtB,QAAQ,EACR,WAAW,EACX,iBAAiB,GAClB,MAAM,yBAAyB,CAAC;AACjC,YAAY,EACV,uBAAuB,EACvB,mBAAmB,GACpB,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EACL,qBAAqB,EACrB,0BAA0B,GAC3B,MAAM,kBAAkB,CAAC;AAC1B,YAAY,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAGvD,OAAO,EACL,mBAAmB,EACnB,gBAAgB,EAChB,wBAAwB,GACzB,MAAM,2BAA2B,CAAC;AACnC,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAGlE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,YAAY,EACV,wBAAwB,EACxB,mBAAmB,GACpB,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAG9D,OAAO,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC"}
package/esm/mod.js CHANGED
@@ -8,10 +8,9 @@
8
8
  * from core/mod.ts, never from internal paths.
9
9
  */
10
10
  import "./_dnt.polyfills.js";
11
- export const VERSION = "0.10.3";
12
- export const CORE_SCHEMA_VERSION = 1;
11
+ export const VERSION = "0.12.0";
13
12
  // Model types
14
- export { ConfigError, CORE_DISCIPLINE_REGISTRY, CORE_KINDS, CORE_RELATIONS, DEFAULT_PROJECT_CONFIG, descendantsOf, formatEntryOrigin, KNOWN_LINK_KINDS, LOCK_EXTRA_INVERSE_KEYS, makeDisplayId, makeUlid, MIXED_DISCIPLINE, PALETTE_HUES, REFHUB_URL, } from "./model/mod.js";
13
+ export { ConfigError, CORE_DISCIPLINE_REGISTRY, CORE_KINDS, CORE_RELATIONS, CORE_SCHEMA_VERSION, DEFAULT_PROJECT_CONFIG, descendantsOf, emittableEntries, formatEntryOrigin, isCorpusEntry, isUpstreamEntry, KNOWN_LINK_KINDS, LOCK_EXTRA_INVERSE_KEYS, makeDisplayId, makeUlid, MIXED_DISCIPLINE, PALETTE_HUES, sameOriginSource, } from "./model/mod.js";
15
14
  // AST (canonical body-AST — spec docs/specs/markspec-core-data-model.md §2)
16
15
  // SourceRange is body-relative (no `file`); use SourceLocation for file-absolute positions.
17
16
  export { astEquivalent } from "./ast/equivalence.js";
@@ -19,7 +18,7 @@ export { normalizeBodyAst } from "./ast/normalize.js";
19
18
  export { render } from "./ast/render.js";
20
19
  // Config
21
20
  export { discoverProjectRoot, loadConfig, parseProjectConfig, } from "./config/mod.js";
22
- export { addProfileSpecifier, discoverMarkspecRoot, MARKSPEC_YAML_FILENAME, parseMarkspecYaml, readMarkspecYaml, } from "./config/markspec.js";
21
+ export { addProfileSpecifier, DEFAULT_TOOL_CONFIG, discoverMarkspecRoot, loadToolConfig, MARKSPEC_YAML_FILENAME, parseMarkspecYaml, readMarkspecYaml, } from "./config/markspec.js";
23
22
  // Profile system (ADR-008)
24
23
  export { computeCacheKey, computeCacheLocation, defaultAppendFile, defaultRunGit, ensureCacheGitignored, loadChain, loadProfileForCommand, mergeChain, parseManifest, resolveEntryColor, resolveGitSpecifier, resolveLocalSpecifier, } from "./profile/mod.js";
25
24
  export { buildEffectiveDisciplineRegistry } from "./profile/mod.js";
@@ -34,9 +33,10 @@ export { buildCorpusIndex, corpusOriginLabel, deliveredPathIsContained, loadDeli
34
33
  export { detectCaptions, detectDirectives, detectInlineRefs, isSupportedExtension, loadGrammar, parse, parseFile, parseSource, } from "./parser/mod.js";
35
34
  // Formatter
36
35
  export { format } from "./formatter/mod.js";
36
+ export { readEntryBody, replaceEntryBody } from "./formatter/entry_body.js";
37
37
  export { loadMarkdownFormatter, MARKSPEC_MARKDOWN_GLOBAL_CONFIG, MARKSPEC_MARKDOWN_PLUGIN_CONFIG, } from "./formatter/dprint.js";
38
38
  // Validator
39
- export { attributeCorpusDiagnostics, classifyEntriesStage, classifyEntry, compileDisplayIdPattern, detectCorpusCollisions, effectiveScope, effectiveTraceRules, matchesAnyTarget, normalizeListValues, runPipeline, suppressDeclaredAttrR010, validate, validateAttributesForEntry, validateListingDocuments, validateTraceabilityForEntry, validateValue, } from "./validator/mod.js";
39
+ export { applyCorpusPostPass, attributeCorpusDiagnostics, classifyEntriesStage, classifyEntry, compileDisplayIdPattern, detectCorpusCollisions, effectiveScope, effectiveTraceRules, matchesAnyTarget, normalizeListValues, runPipeline, suppressDeclaredAttrR010, validate, validateAttributesForEntry, validateListingDocuments, validateTraceabilityForEntry, validateValue, } from "./validator/mod.js";
40
40
  // Compiler
41
41
  export { compile, generateInverses, serializeCompileResult, } from "./compiler/mod.js";
42
42
  export { buildManifest } from "./compiler/manifest.js";
@@ -46,19 +46,31 @@ export { report } from "./reporter/mod.js";
46
46
  // Lint (prose-analysis)
47
47
  export { ANTI_PATTERN_NOTE, computeScoreRollup, isProseScope, runLint, } from "./lint/mod.js";
48
48
  export * as typl from "./typl/mod.js";
49
+ export { uxilDeclaringTypes, validateUxilFamily, } from "./validator/uxil_family.js";
50
+ export * as uxil from "./uxil/mod.js";
49
51
  // ── Lockfile (ADR-022) ───────────────────────────────────────────────────
50
- export { canonicalEdgeJson, checkDrift, detectOfflineEdgeDrift, extractEdgeLedger, extractEdgeQuads, hashCanonicalEdges, isBelowFloor, LOCKFILE_SCHEMA_VERSION, parseLockfile, resolveBoundEntries, resolveProfileChain, resolveReferences, resolveRegistries, resolveUpstreams, serializeLockfile, sha256Bytes, sha256String, } from "./lock/mod.js";
52
+ export { canonicalEdgeJson, checkDrift, compileAcquiredTree, dependencyPinAssurance, deriveUpstreamId, detectOfflineEdgeDrift, extractEdgeLedger, extractEdgeQuads, formatEdgeDriftMessage, hashCanonicalEdges, isBelowFloor, LOCKFILE_SCHEMA_VERSION, parseLockfile, parseLsRemote, resolveBoundEntries, resolveIntent, resolveProfileChain, resolveProjectDependencies, resolveProjectReferences, resolveReferences, resolveUpstreams, serializeLockfile, sha256Bytes, sha256String, upstreamCacheRoot, verifyUpstreamCache, } from "./lock/mod.js";
51
53
  // ── Trace-reference canonicalisation + heal (issue #593, Slice 4) ────────
52
54
  export { buildRefIndex, canonicalizeRefs, TRACE_ATTRIBUTE_KEYS, } from "./refs/mod.js";
53
55
  // ── Composite-`check` gate stages (ADR-027, #659) ─────────────────────────
54
56
  export { fmtDriftGate, lockfileDriftGate, proseLintGate } from "./gates/mod.js";
55
57
  // ── Fenced-code-block detection (#668/#679/#680) ──────────────────────────
56
- export { FENCE_RE, isLineFenced, walkProseLines } from "./util/fence.js";
58
+ export { FENCE_RE, fencedCodeLines, isLineFenced, walkProseLines, } from "./util/fence.js";
59
+ export { isUnsafeRelPath } from "./util/paths.js";
57
60
  // ── External sync model (ADR-022) ────────────────────────────────────────
58
61
  export { aggregateStatusByState, encodeLogLine, inferLockedAttributes, parseLogLine, parseMapping, validateMappings, } from "./sync/mod.js";
59
62
  // ── Self-upgrade ─────────────────────────────────────────────────────────
60
63
  export { assertTrustedReleaseUrl, classifyInstallPath, compareVersions, DEFAULT_RELEASES_API, DEFAULT_RELEASES_DOWNLOAD_BASE, detectTarget, parseSha256Line, platformFromBuild, releaseAssets, resolveReleaseEndpoints, } from "./self_upgrade/mod.js";
61
64
  // ── Gitignore-aware project file discovery ───────────────────────────────
62
65
  export { discoverFiles, isIgnored, MARKDOWN_EXTENSIONS, parseGitignore, RELEVANT_EXTENSIONS, SOURCE_EXTENSIONS, } from "./discovery/mod.js";
66
+ export { createProjectRootResolver, discoverProjectRoots, findNestedProjectRoots, isWithin, nearestRoot, resolveConfigRoot, } from "./discovery/projects.js";
63
67
  // ── Project-entry collection (discover + parse → Entry[]) ────────────────
64
- export { collectProjectEntries } from "./collect/mod.js";
68
+ export { collectProjectEntries, UnreadableProjectFileError, } from "./collect/mod.js";
69
+ // ── Compiled-snapshot deserialization (federated upstream, slice 1) ──────
70
+ export { checkSnapshotSchema, deserializeEntry, extractSerializedEntries, } from "./compiler/deserialize.js";
71
+ // ── Upstream corpus loader (federated upstream, slice 1) ─────────────────
72
+ export { loadUpstreamCorpus } from "./upstream/mod.js";
73
+ // ── Lockfile → upstream-snapshot-ref mapping (federated upstream, slice 4) ──
74
+ export { upstreamRefsFromLockfile } from "./upstream/refs.js";
75
+ // ── Shared lockfile → upstream-corpus hydration (#771) ──────────────────
76
+ export { loadProjectUpstreams } from "./upstream/project.js";
@@ -3,6 +3,12 @@
3
3
  *
4
4
  * MarkSpec document model — AST types, ID types, and project configuration.
5
5
  */
6
+ /**
7
+ * Version of the core entry/graph schema. Bumped only when the compiled
8
+ * representation changes incompatibly; compared by the snapshot skew
9
+ * guard (`checkSnapshotSchema`) and printed by `--version`.
10
+ */
11
+ export declare const CORE_SCHEMA_VERSION = 1;
6
12
  import type { BodyBlock } from "../ast/nodes.js";
7
13
  import type { Discipline } from "./discipline.js";
8
14
  import type { TyplBlock } from "../typl/mod.js";
@@ -288,21 +294,78 @@ export interface EntryProperties {
288
294
  * Provenance of an entry that did not originate in the project's own files
289
295
  * (ADR-030). Absent on project-authored entries. `kind` is a discriminant so
290
296
  * future origins (e.g. ADR-011 SBOM-generated dependency entries) can reuse
291
- * the slot.
297
+ * the slot. The `upstream` member covers entries hydrated from another
298
+ * repository's traceability graph (federated-upstream epic).
292
299
  */
293
- export interface EntryOrigin {
300
+ export type EntryOrigin = {
294
301
  readonly kind: "profile";
295
302
  readonly profileId: string;
296
303
  readonly profileVersion: string;
297
- }
304
+ } | {
305
+ readonly kind: "upstream";
306
+ readonly upstreamId: string;
307
+ readonly version: string;
308
+ };
298
309
  /**
299
- * Human-facing `<profileId>@<profileVersion>` label for an entry's
300
- * delivered-corpus origin (ADR-030). The single formatter for the origin
310
+ * Whether an entry belongs to a read-only corpus: a profile-delivered
311
+ * document or a locked upstream snapshot. Project-authored entries have no
312
+ * origin. This is broader than {@linkcode isUpstreamEntry}: profile corpus
313
+ * entries remain structurally validated but are excluded from prose lint
314
+ * and project-owned gates.
315
+ */
316
+ export declare function isCorpusEntry(entry: Entry): entry is Entry & {
317
+ origin: EntryOrigin;
318
+ };
319
+ /**
320
+ * Human-facing `<profileId>@<profileVersion>` (or `<upstreamId>@<version>`)
321
+ * label for an entry's origin (ADR-030). The single formatter for the origin
301
322
  * idiom shared across the validator, reporter, CLI, LSP, and MCP surfaces.
302
323
  * Its {@linkcode DeliveredDocument} twin is `corpusOriginLabel`
303
324
  * (`core/profile/delivered.ts`) — same string shape, different input type.
304
325
  */
305
326
  export declare function formatEntryOrigin(origin: EntryOrigin): string;
327
+ /**
328
+ * Whether two origins come from the same source (same profile id or same
329
+ * upstream id), ignoring versions. Used by the corpus collision pass to
330
+ * decide "same owner" — version bumps must not split ownership.
331
+ */
332
+ export declare function sameOriginSource(a: EntryOrigin, b: EntryOrigin): boolean;
333
+ /**
334
+ * Whether an entry was hydrated from a locked upstream snapshot
335
+ * (federated-upstream epic) rather than the project's own files or a
336
+ * profile-delivered corpus (ADR-030). Upstream entries are validation-exempt
337
+ * graph citizens: every per-entry validator and lint loop skips them
338
+ * entirely (no structural, attribute, trace, or prose checks), while they
339
+ * remain resolution targets — refs FROM a project entry TO an upstream
340
+ * entry still resolve. This is distinct from `kind: "profile"` corpus
341
+ * entries, which stay fully validated and are only downgraded post-hoc.
342
+ */
343
+ export declare function isUpstreamEntry(entry: Entry): entry is Entry & {
344
+ origin: Extract<EntryOrigin, {
345
+ kind: "upstream";
346
+ }>;
347
+ };
348
+ /**
349
+ * The emit side of the federated-upstream validation partition (#771;
350
+ * ADR-031 design §4.7). Upstream entries are read-only graph citizens:
351
+ * they stay in every RESOLUTION map (so project links targeting them
352
+ * resolve) but no validation stage may EMIT diagnostics against them.
353
+ * Validators loop over this filtered list; resolution-map builders keep
354
+ * the full input list. Adding a new VALIDATOR stage? Iterate the
355
+ * emittable list — never the raw entry set.
356
+ *
357
+ * NOT for lint/gates: the prose-lint runner and the check gates apply a
358
+ * deliberately BROADER `!entry.origin` partition — profile-corpus prose
359
+ * is also lint-exempt (ADR-030 §D4), while the structural validators
360
+ * keep validating corpus entries and downgrade them post-hoc. Swapping
361
+ * their filters for this helper would re-enable prose lint on delivered
362
+ * corpus files.
363
+ *
364
+ * Lives in `core/model` (not `validator/`) because `core/typl` consumes
365
+ * it too — a validator/ home would cycle against the one-directional
366
+ * model ← validator dependency flow.
367
+ */
368
+ export declare function emittableEntries(entries: readonly Entry[]): readonly Entry[];
306
369
  /**
307
370
  * A parsed MarkSpec entry — the core AST node.
308
371
  *
@@ -375,6 +438,17 @@ export interface Entry {
375
438
  * `location.line + 1` when absent.
376
439
  */
377
440
  readonly bodyStartLine?: number;
441
+ /**
442
+ * 1-based line of the last content line of the entry's list item, from
443
+ * the mdast item position. It includes a CommonMark lazy continuation
444
+ * line and the trailer, and excludes the blank lines after the item.
445
+ * The formatter uses it to find where the item ends, which an
446
+ * indentation scan cannot tell for a lazy continuation line.
447
+ *
448
+ * Optional so test fixtures and pipeline stages that do not set it can
449
+ * remain unchanged.
450
+ */
451
+ readonly endLine?: number;
378
452
  /** Whether this came from a Markdown file or a doc comment. */
379
453
  readonly source: EntrySource;
380
454
  /**
@@ -419,10 +493,12 @@ export interface Entry {
419
493
  */
420
494
  readonly derivedDiscipline?: Discipline;
421
495
  /**
422
- * Set on entries injected from a profile-delivered corpus document
423
- * (ADR-030). Consumers treat such entries as read-only: `fmt` and rename
424
- * never touch them, and validation findings inside them are downgraded
425
- * to attributed warnings.
496
+ * Provenance of an entry not authored in the project's own files:
497
+ * injected from a profile-delivered corpus document (ADR-030,
498
+ * `kind: "profile"`) or hydrated from a locked upstream snapshot
499
+ * (`kind: "upstream"`). Consumers treat any origin-carrying entry as
500
+ * read-only: `fmt` and rename never touch them, and validation findings
501
+ * inside them are downgraded to attributed warnings.
426
502
  */
427
503
  readonly origin?: EntryOrigin;
428
504
  }
@@ -439,8 +515,6 @@ export interface Diagnostic {
439
515
  /** Source location, if applicable. */
440
516
  readonly location: SourceLocation | undefined;
441
517
  }
442
- /** Default RefHub URL used as implicit fallback for parent registries. */
443
- export declare const REFHUB_URL = "https://driftsys.github.io/refhub";
444
518
  /**
445
519
  * Caption-position convention for a specific caption keyword.
446
520
  * `"above"` — caption must appear above its block.
@@ -464,37 +538,49 @@ export type CaptionPosition = "above" | "below";
464
538
  * ```
465
539
  */
466
540
  export type CaptionConventions = Readonly<Partial<Record<string, CaptionPosition>>>;
467
- /** MarkSpec project configuration from `project.yaml`. */
541
+ /**
542
+ * Reference to an external project (org project-manifest contract,
543
+ * `driftsys/schemas` `project/v1.json` `$defs/projectRef`). Used by the
544
+ * `dependencies:` (git repositories) and `references:` (published sites)
545
+ * lists. `version` carries intent: an exact tag is a frozen baseline, a
546
+ * branch name tracks its head, absent means auto (latest semver release
547
+ * tag, else default-branch head). `name` is the upstream id used for the
548
+ * cache directory, lockfile rows, and origin badges; derived from the URL
549
+ * when absent.
550
+ */
551
+ export interface ProjectRef {
552
+ readonly url: string;
553
+ readonly version?: string;
554
+ readonly name?: string;
555
+ }
556
+ /**
557
+ * MarkSpec project configuration from `project.yaml` — the org project
558
+ * schema's closed shape (Task 8). Markspec-tool-specific config (`exclude`,
559
+ * `caption-conventions`) lives in `.markspec.yaml` — see `ToolConfig` /
560
+ * `loadToolConfig` in `core/config/markspec.ts`.
561
+ */
468
562
  export interface ProjectConfig {
469
563
  /** Project name (e.g., `io.driftsys.markspec`). */
470
564
  readonly name: string;
471
565
  /** Project version string. */
472
566
  readonly version: string;
473
- /** Allowed label vocabulary (e.g., `["ASIL-A", "ASIL-B"]`). Empty = no constraint. */
474
- readonly labels: readonly string[];
475
- /** Upstream parent registry URLs, searched in order. */
476
- readonly parents: readonly string[];
477
- /** Fallback registry URL when parents don't resolve a reference. */
478
- readonly parentFallback: string;
479
567
  /**
480
- * Per-keyword caption-position conventions (spec §4.7 MSL-C072).
481
- * When a key is present, the validator emits MSL-C072 if a caption
482
- * of that keyword appears on the wrong side of its block. An empty
483
- * or absent map means all keywords are unconstrained.
568
+ * Upstream git repositories this project depends on (org
569
+ * project-manifest contract `dependencies:`). Each entry resolves to a
570
+ * pinned snapshot in `markspec.lock`.
484
571
  */
485
- readonly captionConventions: CaptionConventions;
572
+ readonly dependencies: readonly ProjectRef[];
486
573
  /**
487
- * Gitignore-syntax patterns excluded from project file discovery,
488
- * anchored at the project root (e.g. `["skills/", "*.gen.md"]`).
489
- * Applied after `.gitignore` rules by `core/discovery`.
574
+ * Published reference sites this project cites but does not depend on
575
+ * (org project-manifest contract `references:`) — e.g. a shared RefHub.
490
576
  */
491
- readonly exclude: readonly string[];
577
+ readonly references: readonly ProjectRef[];
492
578
  }
493
579
  /** Default configuration used when no `project.yaml` is found. */
494
580
  export declare const DEFAULT_PROJECT_CONFIG: ProjectConfig;
495
581
  /** A single field-level validation error in `project.yaml`. */
496
582
  export interface ConfigFieldError {
497
- /** The YAML field path (e.g., `domain`, `parents[0]`). */
583
+ /** The YAML field path (e.g., `name`, `references[0].url`). */
498
584
  readonly field: string;
499
585
  /** Human-readable error message. */
500
586
  readonly message: string;