@linked.archi/kernel 0.0.0-stage → 0.1.5

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 (365) hide show
  1. package/LICENSE +202 -0
  2. package/NOTICE +11 -0
  3. package/README.md +96 -2
  4. package/assets/arch-decision/arch-decision-metamodel.ttl +44 -0
  5. package/assets/arch-decision/arch-decision-onto.ttl +1566 -0
  6. package/assets/arch-decision/arch-decision-shapes.ttl +582 -0
  7. package/assets/arch-decision/arch-decision-tax.ttl +129 -0
  8. package/assets/arch-processes/arch-processes-metamodel.ttl +42 -0
  9. package/assets/arch-processes/arch-processes-tax.ttl +136 -0
  10. package/assets/arch-processes/archProcesses-shapes.ttl +189 -0
  11. package/assets/arch-processes/archProcesses.ttl +953 -0
  12. package/assets/archimate3/archimate3.2-element-shapes.ttl +379 -0
  13. package/assets/archimate3/archimate3.2-metamodel.ttl +205 -0
  14. package/assets/archimate3/archimate3.2-notation.ttl +1503 -0
  15. package/assets/archimate3/archimate3.2-onto.ttl +1579 -0
  16. package/assets/archimate3/archimate3.2-presentation-contexts.ttl +90 -0
  17. package/assets/archimate3/archimate3.2-principle-shapes.ttl +923 -0
  18. package/assets/archimate3/archimate3.2-questions.ttl +1125 -0
  19. package/assets/archimate3/archimate3.2-reference-data.ttl +74 -0
  20. package/assets/archimate3/archimate3.2-relationship-shapes.ttl +30956 -0
  21. package/assets/archimate3/archimate3.2-relationship-tables.ttl +5992 -0
  22. package/assets/archimate3/archimate3.2-tax.ttl +724 -0
  23. package/assets/archimate3/archimate3.2-viewpoint-shapes.ttl +59 -0
  24. package/assets/archimate3/archimate3.2-viewpoints.ttl +793 -0
  25. package/assets/archimate3/icons/and-junction.svg +3 -0
  26. package/assets/archimate3/icons/application-collaboration.svg +22 -0
  27. package/assets/archimate3/icons/application-component.svg +18 -0
  28. package/assets/archimate3/icons/application-event.svg +15 -0
  29. package/assets/archimate3/icons/application-function.svg +14 -0
  30. package/assets/archimate3/icons/application-interaction.svg +17 -0
  31. package/assets/archimate3/icons/application-interface.svg +16 -0
  32. package/assets/archimate3/icons/application-process.svg +14 -0
  33. package/assets/archimate3/icons/application-service.svg +14 -0
  34. package/assets/archimate3/icons/artifact.svg +16 -0
  35. package/assets/archimate3/icons/assessment.svg +17 -0
  36. package/assets/archimate3/icons/business-actor.svg +22 -0
  37. package/assets/archimate3/icons/business-collaboration.svg +21 -0
  38. package/assets/archimate3/icons/business-event.svg +15 -0
  39. package/assets/archimate3/icons/business-function.svg +14 -0
  40. package/assets/archimate3/icons/business-interaction.svg +18 -0
  41. package/assets/archimate3/icons/business-interface.svg +16 -0
  42. package/assets/archimate3/icons/business-object.svg +14 -0
  43. package/assets/archimate3/icons/business-process.svg +15 -0
  44. package/assets/archimate3/icons/business-role.svg +16 -0
  45. package/assets/archimate3/icons/business-service.svg +14 -0
  46. package/assets/archimate3/icons/capability.svg +40 -0
  47. package/assets/archimate3/icons/communication-network.svg +18 -0
  48. package/assets/archimate3/icons/constraint.svg +18 -0
  49. package/assets/archimate3/icons/contract.svg +13 -0
  50. package/assets/archimate3/icons/course-of-action.svg +20 -0
  51. package/assets/archimate3/icons/data-object.svg +14 -0
  52. package/assets/archimate3/icons/deliverable.svg +11 -0
  53. package/assets/archimate3/icons/device.svg +18 -0
  54. package/assets/archimate3/icons/distribution-network.svg +19 -0
  55. package/assets/archimate3/icons/driver.svg +24 -0
  56. package/assets/archimate3/icons/equipment.svg +31 -0
  57. package/assets/archimate3/icons/facility.svg +16 -0
  58. package/assets/archimate3/icons/gap.svg +22 -0
  59. package/assets/archimate3/icons/glyphs/activity.svg +3 -0
  60. package/assets/archimate3/icons/glyphs/actor.svg +14 -0
  61. package/assets/archimate3/icons/glyphs/application-component.svg +12 -0
  62. package/assets/archimate3/icons/glyphs/artifact.svg +9 -0
  63. package/assets/archimate3/icons/glyphs/assessment.svg +9 -0
  64. package/assets/archimate3/icons/glyphs/capability.svg +32 -0
  65. package/assets/archimate3/icons/glyphs/cloud-gear.svg +3 -0
  66. package/assets/archimate3/icons/glyphs/collaboration.svg +15 -0
  67. package/assets/archimate3/icons/glyphs/communication-network.svg +12 -0
  68. package/assets/archimate3/icons/glyphs/constraint.svg +10 -0
  69. package/assets/archimate3/icons/glyphs/contract.svg +5 -0
  70. package/assets/archimate3/icons/glyphs/course-of-action.svg +12 -0
  71. package/assets/archimate3/icons/glyphs/data-object.svg +4 -0
  72. package/assets/archimate3/icons/glyphs/deliverable.svg +3 -0
  73. package/assets/archimate3/icons/glyphs/device.svg +10 -0
  74. package/assets/archimate3/icons/glyphs/distribution-network.svg +11 -0
  75. package/assets/archimate3/icons/glyphs/driver.svg +16 -0
  76. package/assets/archimate3/icons/glyphs/equipment.svg +22 -0
  77. package/assets/archimate3/icons/glyphs/event.svg +6 -0
  78. package/assets/archimate3/icons/glyphs/facility.svg +7 -0
  79. package/assets/archimate3/icons/glyphs/function.svg +6 -0
  80. package/assets/archimate3/icons/glyphs/gap.svg +14 -0
  81. package/assets/archimate3/icons/glyphs/goal.svg +10 -0
  82. package/assets/archimate3/icons/glyphs/grouping.svg +4 -0
  83. package/assets/archimate3/icons/glyphs/interaction.svg +10 -0
  84. package/assets/archimate3/icons/glyphs/interface.svg +8 -0
  85. package/assets/archimate3/icons/glyphs/location.svg +6 -0
  86. package/assets/archimate3/icons/glyphs/material.svg +12 -0
  87. package/assets/archimate3/icons/glyphs/meaning.svg +3 -0
  88. package/assets/archimate3/icons/glyphs/node.svg +8 -0
  89. package/assets/archimate3/icons/glyphs/object.svg +4 -0
  90. package/assets/archimate3/icons/glyphs/outcome.svg +16 -0
  91. package/assets/archimate3/icons/glyphs/path.svg +10 -0
  92. package/assets/archimate3/icons/glyphs/person-silhouette.svg +3 -0
  93. package/assets/archimate3/icons/glyphs/plateau.svg +8 -0
  94. package/assets/archimate3/icons/glyphs/principle.svg +12 -0
  95. package/assets/archimate3/icons/glyphs/process.svg +6 -0
  96. package/assets/archimate3/icons/glyphs/product.svg +4 -0
  97. package/assets/archimate3/icons/glyphs/representation.svg +4 -0
  98. package/assets/archimate3/icons/glyphs/requirement.svg +6 -0
  99. package/assets/archimate3/icons/glyphs/resource.svg +14 -0
  100. package/assets/archimate3/icons/glyphs/role.svg +6 -0
  101. package/assets/archimate3/icons/glyphs/service.svg +6 -0
  102. package/assets/archimate3/icons/glyphs/stakeholder.svg +6 -0
  103. package/assets/archimate3/icons/glyphs/system-software.svg +14 -0
  104. package/assets/archimate3/icons/glyphs/value-stream.svg +3 -0
  105. package/assets/archimate3/icons/glyphs/value.svg +3 -0
  106. package/assets/archimate3/icons/glyphs/work-package.svg +4 -0
  107. package/assets/archimate3/icons/goal.svg +18 -0
  108. package/assets/archimate3/icons/grouping.svg +12 -0
  109. package/assets/archimate3/icons/implementation-event.svg +15 -0
  110. package/assets/archimate3/icons/location.svg +14 -0
  111. package/assets/archimate3/icons/material.svg +21 -0
  112. package/assets/archimate3/icons/meaning.svg +11 -0
  113. package/assets/archimate3/icons/node.svg +14 -0
  114. package/assets/archimate3/icons/or-junction.svg +3 -0
  115. package/assets/archimate3/icons/outcome.svg +25 -0
  116. package/assets/archimate3/icons/path.svg +18 -0
  117. package/assets/archimate3/icons/plateau.svg +16 -0
  118. package/assets/archimate3/icons/principle.svg +21 -0
  119. package/assets/archimate3/icons/product.svg +12 -0
  120. package/assets/archimate3/icons/representation.svg +12 -0
  121. package/assets/archimate3/icons/requirement.svg +14 -0
  122. package/assets/archimate3/icons/resource.svg +23 -0
  123. package/assets/archimate3/icons/stakeholder.svg +15 -0
  124. package/assets/archimate3/icons/system-software.svg +22 -0
  125. package/assets/archimate3/icons/technology-collaboration.svg +22 -0
  126. package/assets/archimate3/icons/technology-event.svg +15 -0
  127. package/assets/archimate3/icons/technology-function.svg +14 -0
  128. package/assets/archimate3/icons/technology-interaction.svg +18 -0
  129. package/assets/archimate3/icons/technology-interface.svg +16 -0
  130. package/assets/archimate3/icons/technology-process.svg +14 -0
  131. package/assets/archimate3/icons/technology-service.svg +14 -0
  132. package/assets/archimate3/icons/value-stream.svg +11 -0
  133. package/assets/archimate3/icons/value.svg +11 -0
  134. package/assets/archimate3/icons/work-package.svg +12 -0
  135. package/assets/archimate4/archimate4-element-shapes.ttl +404 -0
  136. package/assets/archimate4/archimate4-metamodel.ttl +179 -0
  137. package/assets/archimate4/archimate4-notation.ttl +1147 -0
  138. package/assets/archimate4/archimate4-onto.ttl +1559 -0
  139. package/assets/archimate4/archimate4-presentation-contexts.ttl +60 -0
  140. package/assets/archimate4/archimate4-principle-shapes.ttl +893 -0
  141. package/assets/archimate4/archimate4-questions.ttl +1224 -0
  142. package/assets/archimate4/archimate4-reference-data.ttl +56 -0
  143. package/assets/archimate4/archimate4-relationship-shapes.ttl +16920 -0
  144. package/assets/archimate4/archimate4-relationship-tables.ttl +3200 -0
  145. package/assets/archimate4/archimate4-tax.ttl +749 -0
  146. package/assets/archimate4/archimate4-viewpoint-shapes.ttl +55 -0
  147. package/assets/archimate4/archimate4-viewpoints.ttl +777 -0
  148. package/assets/archimate4/icons/and-junction.svg +3 -0
  149. package/assets/archimate4/icons/application-component.svg +18 -0
  150. package/assets/archimate4/icons/application-interface.svg +16 -0
  151. package/assets/archimate4/icons/artifact.svg +16 -0
  152. package/assets/archimate4/icons/assessment.svg +17 -0
  153. package/assets/archimate4/icons/business-actor.svg +22 -0
  154. package/assets/archimate4/icons/business-interface.svg +16 -0
  155. package/assets/archimate4/icons/business-object.svg +14 -0
  156. package/assets/archimate4/icons/capability.svg +40 -0
  157. package/assets/archimate4/icons/collaboration.svg +21 -0
  158. package/assets/archimate4/icons/communication-network.svg +18 -0
  159. package/assets/archimate4/icons/course-of-action.svg +20 -0
  160. package/assets/archimate4/icons/data-object.svg +14 -0
  161. package/assets/archimate4/icons/deliverable.svg +11 -0
  162. package/assets/archimate4/icons/device.svg +18 -0
  163. package/assets/archimate4/icons/distribution-network.svg +19 -0
  164. package/assets/archimate4/icons/driver.svg +24 -0
  165. package/assets/archimate4/icons/equipment.svg +31 -0
  166. package/assets/archimate4/icons/event.svg +15 -0
  167. package/assets/archimate4/icons/facility.svg +16 -0
  168. package/assets/archimate4/icons/function.svg +13 -0
  169. package/assets/archimate4/icons/glyphs/activity.svg +3 -0
  170. package/assets/archimate4/icons/glyphs/actor.svg +14 -0
  171. package/assets/archimate4/icons/glyphs/application-component.svg +12 -0
  172. package/assets/archimate4/icons/glyphs/artifact.svg +9 -0
  173. package/assets/archimate4/icons/glyphs/assessment.svg +9 -0
  174. package/assets/archimate4/icons/glyphs/capability.svg +32 -0
  175. package/assets/archimate4/icons/glyphs/cloud-gear.svg +3 -0
  176. package/assets/archimate4/icons/glyphs/collaboration.svg +15 -0
  177. package/assets/archimate4/icons/glyphs/communication-network.svg +12 -0
  178. package/assets/archimate4/icons/glyphs/constraint.svg +10 -0
  179. package/assets/archimate4/icons/glyphs/contract.svg +5 -0
  180. package/assets/archimate4/icons/glyphs/course-of-action.svg +12 -0
  181. package/assets/archimate4/icons/glyphs/data-object.svg +4 -0
  182. package/assets/archimate4/icons/glyphs/deliverable.svg +3 -0
  183. package/assets/archimate4/icons/glyphs/device.svg +10 -0
  184. package/assets/archimate4/icons/glyphs/distribution-network.svg +11 -0
  185. package/assets/archimate4/icons/glyphs/driver.svg +16 -0
  186. package/assets/archimate4/icons/glyphs/equipment.svg +22 -0
  187. package/assets/archimate4/icons/glyphs/event.svg +6 -0
  188. package/assets/archimate4/icons/glyphs/facility.svg +7 -0
  189. package/assets/archimate4/icons/glyphs/function.svg +6 -0
  190. package/assets/archimate4/icons/glyphs/gap.svg +14 -0
  191. package/assets/archimate4/icons/glyphs/goal.svg +10 -0
  192. package/assets/archimate4/icons/glyphs/grouping.svg +4 -0
  193. package/assets/archimate4/icons/glyphs/interaction.svg +10 -0
  194. package/assets/archimate4/icons/glyphs/interface.svg +8 -0
  195. package/assets/archimate4/icons/glyphs/location.svg +6 -0
  196. package/assets/archimate4/icons/glyphs/material.svg +12 -0
  197. package/assets/archimate4/icons/glyphs/meaning.svg +3 -0
  198. package/assets/archimate4/icons/glyphs/node.svg +8 -0
  199. package/assets/archimate4/icons/glyphs/object.svg +4 -0
  200. package/assets/archimate4/icons/glyphs/outcome.svg +16 -0
  201. package/assets/archimate4/icons/glyphs/path.svg +10 -0
  202. package/assets/archimate4/icons/glyphs/person-silhouette.svg +3 -0
  203. package/assets/archimate4/icons/glyphs/plateau.svg +8 -0
  204. package/assets/archimate4/icons/glyphs/principle.svg +12 -0
  205. package/assets/archimate4/icons/glyphs/process.svg +6 -0
  206. package/assets/archimate4/icons/glyphs/product.svg +4 -0
  207. package/assets/archimate4/icons/glyphs/representation.svg +4 -0
  208. package/assets/archimate4/icons/glyphs/requirement.svg +6 -0
  209. package/assets/archimate4/icons/glyphs/resource.svg +14 -0
  210. package/assets/archimate4/icons/glyphs/role.svg +6 -0
  211. package/assets/archimate4/icons/glyphs/service.svg +6 -0
  212. package/assets/archimate4/icons/glyphs/stakeholder.svg +6 -0
  213. package/assets/archimate4/icons/glyphs/system-software.svg +14 -0
  214. package/assets/archimate4/icons/glyphs/value-stream.svg +3 -0
  215. package/assets/archimate4/icons/glyphs/value.svg +3 -0
  216. package/assets/archimate4/icons/glyphs/work-package.svg +4 -0
  217. package/assets/archimate4/icons/goal.svg +18 -0
  218. package/assets/archimate4/icons/grouping.svg +12 -0
  219. package/assets/archimate4/icons/location.svg +14 -0
  220. package/assets/archimate4/icons/material.svg +21 -0
  221. package/assets/archimate4/icons/meaning.svg +11 -0
  222. package/assets/archimate4/icons/node.svg +14 -0
  223. package/assets/archimate4/icons/or-junction.svg +3 -0
  224. package/assets/archimate4/icons/outcome.svg +25 -0
  225. package/assets/archimate4/icons/path.svg +18 -0
  226. package/assets/archimate4/icons/plateau.svg +16 -0
  227. package/assets/archimate4/icons/principle.svg +21 -0
  228. package/assets/archimate4/icons/process.svg +15 -0
  229. package/assets/archimate4/icons/product.svg +12 -0
  230. package/assets/archimate4/icons/requirement.svg +14 -0
  231. package/assets/archimate4/icons/resource.svg +23 -0
  232. package/assets/archimate4/icons/role.svg +16 -0
  233. package/assets/archimate4/icons/service.svg +13 -0
  234. package/assets/archimate4/icons/stakeholder.svg +15 -0
  235. package/assets/archimate4/icons/system-software.svg +22 -0
  236. package/assets/archimate4/icons/technology-interface.svg +16 -0
  237. package/assets/archimate4/icons/value-stream.svg +11 -0
  238. package/assets/archimate4/icons/value.svg +11 -0
  239. package/assets/archimate4/icons/work-package.svg +12 -0
  240. package/assets/basic/basic-metamodel.ttl +100 -0
  241. package/assets/basic/basic-notation-bubble.ttl +175 -0
  242. package/assets/basic/basic-notation.ttl +172 -0
  243. package/assets/basic/basic-onto.ttl +171 -0
  244. package/assets/basic/basic-presentation-contexts.ttl +70 -0
  245. package/assets/basic/basic-tax.ttl +130 -0
  246. package/assets/basic/icons/aggregation.svg +7 -0
  247. package/assets/basic/icons/association.svg +6 -0
  248. package/assets/basic/icons/element.svg +5 -0
  249. package/assets/basic/icons/glyphs/aggregation.svg +6 -0
  250. package/assets/basic/icons/glyphs/association.svg +5 -0
  251. package/assets/basic/icons/glyphs/element.svg +5 -0
  252. package/assets/basic/icons/glyphs/relationship.svg +5 -0
  253. package/assets/basic/icons/relationship.svg +7 -0
  254. package/assets/basic/notation-bubble/icons/aggregation.svg +7 -0
  255. package/assets/basic/notation-bubble/icons/association.svg +6 -0
  256. package/assets/basic/notation-bubble/icons/element.svg +5 -0
  257. package/assets/basic/notation-bubble/icons/glyphs/aggregation.svg +6 -0
  258. package/assets/basic/notation-bubble/icons/glyphs/association.svg +5 -0
  259. package/assets/basic/notation-bubble/icons/glyphs/element.svg +5 -0
  260. package/assets/basic/notation-bubble/icons/glyphs/relationship.svg +5 -0
  261. package/assets/basic/notation-bubble/icons/relationship.svg +7 -0
  262. package/assets/catalog.ttl +7302 -0
  263. package/assets/core/core-notation.ttl +131 -0
  264. package/assets/core/core-onto.ttl +2811 -0
  265. package/assets/core/core-questions.ttl +957 -0
  266. package/assets/core/core-shapes.ttl +915 -0
  267. package/assets/core/core-vis-onto.ttl +1408 -0
  268. package/assets/core/core-vis-shapes.ttl +840 -0
  269. package/assets/core-vis/markers/circle-dot.svg +3 -0
  270. package/assets/core-vis/markers/closed-arrowhead.svg +3 -0
  271. package/assets/core-vis/markers/filled-diamond.svg +3 -0
  272. package/assets/core-vis/markers/half-arrowhead.svg +3 -0
  273. package/assets/core-vis/markers/hollow-arrowhead.svg +3 -0
  274. package/assets/core-vis/markers/hollow-diamond.svg +3 -0
  275. package/assets/core-vis/markers/open-arrowhead.svg +3 -0
  276. package/fixtures/interoperability/archimate4-demo.trig +259 -0
  277. package/fixtures/interoperability/expected-findings.json +26 -0
  278. package/fixtures/interoperability/shop-seed.ttl +225 -0
  279. package/package.json +136 -4
  280. package/scripts/sync-assets.mjs +252 -0
  281. package/src/conformance.ts +66 -0
  282. package/src/import-export/model-io.ts +426 -0
  283. package/src/index.ts +11 -0
  284. package/src/metamodel-manager/asset-sources.ts +754 -0
  285. package/src/metamodel-manager/bundled-assets.ts +599 -0
  286. package/src/metamodel-manager/catalogue.ts +114 -0
  287. package/src/metamodel-manager/class-hierarchy.ts +155 -0
  288. package/src/metamodel-manager/index.ts +65 -0
  289. package/src/metamodel-manager/interfaces.ts +422 -0
  290. package/src/metamodel-manager/metamodel-completeness.ts +162 -0
  291. package/src/metamodel-manager/metamodel-loader.ts +864 -0
  292. package/src/metamodel-manager/notation-resolver.ts +284 -0
  293. package/src/metamodel-manager/notation.ts +659 -0
  294. package/src/metamodel-manager/palette-generator.ts +882 -0
  295. package/src/metamodel-manager/property-shapes.ts +290 -0
  296. package/src/metamodel-manager/taxonomy.ts +904 -0
  297. package/src/metamodel-manager/type-guide.ts +241 -0
  298. package/src/metamodel-manager/viewpoint-manager.ts +147 -0
  299. package/src/model-manager/appearance.ts +389 -0
  300. package/src/model-manager/cascade.ts +246 -0
  301. package/src/model-manager/clipboard.ts +566 -0
  302. package/src/model-manager/context-names.ts +108 -0
  303. package/src/model-manager/custom-properties.ts +549 -0
  304. package/src/model-manager/derivations.ts +166 -0
  305. package/src/model-manager/direct-permissions.ts +182 -0
  306. package/src/model-manager/drawing-order.ts +119 -0
  307. package/src/model-manager/element-manager.ts +69 -0
  308. package/src/model-manager/element-pictures.ts +118 -0
  309. package/src/model-manager/field-names.ts +42 -0
  310. package/src/model-manager/folders.ts +354 -0
  311. package/src/model-manager/grid.ts +6 -0
  312. package/src/model-manager/index.ts +43 -0
  313. package/src/model-manager/interfaces.ts +417 -0
  314. package/src/model-manager/iri-conformance.ts +183 -0
  315. package/src/model-manager/label-expression.ts +233 -0
  316. package/src/model-manager/legacy-migration.ts +200 -0
  317. package/src/model-manager/missing-references.ts +86 -0
  318. package/src/model-manager/model-diff-text.ts +150 -0
  319. package/src/model-manager/model-diff.ts +534 -0
  320. package/src/model-manager/model-merge.ts +1160 -0
  321. package/src/model-manager/model-namespace.ts +199 -0
  322. package/src/model-manager/model-operations.ts +132 -0
  323. package/src/model-manager/model-queries.ts +616 -0
  324. package/src/model-manager/model-session.ts +759 -0
  325. package/src/model-manager/multiplicity.ts +74 -0
  326. package/src/model-manager/nested-resources.ts +145 -0
  327. package/src/model-manager/own-metamodel.ts +157 -0
  328. package/src/model-manager/placement-copy.ts +116 -0
  329. package/src/model-manager/property-catalog.ts +787 -0
  330. package/src/model-manager/proposal-order.ts +203 -0
  331. package/src/model-manager/provenance.ts +396 -0
  332. package/src/model-manager/questions.ts +470 -0
  333. package/src/model-manager/rdf-scope.ts +97 -0
  334. package/src/model-manager/relationship-graph.ts +462 -0
  335. package/src/model-manager/relationship-manager.ts +962 -0
  336. package/src/model-manager/relationship-table.ts +189 -0
  337. package/src/model-manager/relationship-validity.ts +261 -0
  338. package/src/model-manager/resource-edits.ts +28 -0
  339. package/src/model-manager/short-hash.ts +104 -0
  340. package/src/model-manager/snapshot-lines.ts +88 -0
  341. package/src/model-manager/version-history.ts +205 -0
  342. package/src/model-manager/view-from-results.ts +81 -0
  343. package/src/model-manager/view-manager.ts +1410 -0
  344. package/src/model-manager/vocabulary.ts +279 -0
  345. package/src/rdf-engine/finding-shape.ts +23 -0
  346. package/src/rdf-engine/graph-scope.ts +163 -0
  347. package/src/rdf-engine/index.ts +7 -0
  348. package/src/rdf-engine/interfaces.ts +144 -0
  349. package/src/rdf-engine/iri.ts +203 -0
  350. package/src/rdf-engine/localized-text.ts +13 -0
  351. package/src/rdf-engine/namespaces.ts +41 -0
  352. package/src/rdf-engine/observable-store.ts +631 -0
  353. package/src/rdf-engine/rdf-store.ts +508 -0
  354. package/src/rdf-engine/shacl-validator.ts +602 -0
  355. package/src/rdf-engine/shape-reach.ts +140 -0
  356. package/src/rdf-engine/shape-switches.ts +165 -0
  357. package/src/rdf-engine/single-valued.ts +219 -0
  358. package/src/rdf-engine/sparql-constraints.ts +334 -0
  359. package/src/rdf-engine/term-codec.ts +51 -0
  360. package/src/rdf-engine/ttl-parser.ts +51 -0
  361. package/src/rdf-engine/ttl-serializer.ts +79 -0
  362. package/src/rdf-engine/turtle-writer.ts +284 -0
  363. package/src/rdf-engine/validation-engine.ts +682 -0
  364. package/src/rdf-engine/validation-service.ts +184 -0
  365. package/src/rdf-engine/validation.worker.ts +47 -0
@@ -0,0 +1,42 @@
1
+ /**
2
+ * A property's name in words, as the Properties tab shows it — and the History
3
+ * tab's changes by element, and la-gram-git's (`src/cli/`), which run without
4
+ * the UI.
5
+ */
6
+
7
+ import { NAMESPACES } from '../rdf-engine/namespaces.js';
8
+ import { humanize, sentenceCase } from './vocabulary.js';
9
+
10
+ /** The name an IRI has in the loaded data, if it has one (reference data's `skos:prefLabel`). */
11
+ export type NameOf = (iri: string) => string | undefined;
12
+
13
+ /** The fields every concept has, by the names a modeller knows them by. */
14
+ const FIELD_NAMES: Record<string, string> = {
15
+ [NAMESPACES.rdf + 'type']: 'Type',
16
+ [NAMESPACES.arch + 'inModel']: 'Model',
17
+ [NAMESPACES.skos + 'prefLabel']: 'Name',
18
+ [NAMESPACES.skos + 'definition']: 'Definition',
19
+ [NAMESPACES.skos + 'altLabel']: 'Other name',
20
+ };
21
+
22
+ /** The fragment after `#`, or the last path segment. */
23
+ function lastPart(iri: string): string {
24
+ const hash = iri.lastIndexOf('#');
25
+ if (hash !== -1) return iri.slice(hash + 1);
26
+ const slash = iri.lastIndexOf('/');
27
+ return slash !== -1 ? iri.slice(slash + 1) : iri;
28
+ }
29
+
30
+ /**
31
+ * A field's name: a familiar one for the fields every concept has
32
+ * ({@link FIELD_NAMES}); else the shape's (`sh:name`) or the vocabulary's,
33
+ * when it is more than the property's local name again (`source`); else that
34
+ * local name in words (`modelRepresentsSystem` → `Model represents system`).
35
+ */
36
+ export function fieldName(predicate: string, shape?: { name?: string }, nameOf?: NameOf): string {
37
+ const familiar = FIELD_NAMES[predicate];
38
+ if (familiar) return familiar;
39
+ const local = lastPart(predicate);
40
+ const named = [shape?.name, nameOf?.(predicate)].find((name) => name && name !== local);
41
+ return named ? named.charAt(0).toUpperCase() + named.slice(1) : sentenceCase(humanize(local));
42
+ }
@@ -0,0 +1,354 @@
1
+ /**
2
+ * The model's folders: how they are laid out under the tree's three groups —
3
+ * Views, Elements, Relationships (Req 10.10) — and changed (Req 10.13–10.15): a
4
+ * folder made, renamed or deleted, concepts or a folder moved into another.
5
+ *
6
+ * **Layout.** Each kind has its own folders, as the converters keep them. A
7
+ * top folder named as a group — *Elements*, *Relationships*, *Views*:
8
+ * what la-gram writes, and the converters inside their folder for the model —
9
+ * stands for that group; what it holds directly is in no folder of the group.
10
+ * Any other folder is shown under the groups of what it holds, at any depth —
11
+ * an Archi model's layer folders under Elements, its relations folder under
12
+ * Relationships — and an empty one under its parent's, or under Elements at the
13
+ * top. Nothing depends on a tool's own folder names.
14
+ *
15
+ * Each operation works out a {@link FolderChange} — the quads to remove and to
16
+ * add — from the store, and {@link applyFolderChange} makes it, so the host runs
17
+ * it as one recorded step: undo replays the diff.
18
+ *
19
+ * A folder made here is `arch:Folder` with a `schema:name` and the
20
+ * `dcterms:isPartOf` of the folder it is in, or of the model at the top — as
21
+ * the converters write one. A membership is stated from the member's end only,
22
+ * its `dcterms:isPartOf`: the folders are read from either end, and the other
23
+ * one, the folder's `schema:itemListElement`, takes a list entry — named as the
24
+ * converters name it ({@link folderEntryIri}) — and a position, which the tree
25
+ * does not use (la-gram's design, key decision 13). Moving or deleting takes
26
+ * both ends away, so a concept a converter filed leaves its folder entirely.
27
+ */
28
+
29
+ import { DataFactory } from 'n3';
30
+ import type { NamedNode, Quad } from '@rdfjs/types';
31
+ import type { RdfStore } from '../rdf-engine/interfaces.js';
32
+ import { mintIri, partIri } from '../rdf-engine/iri.js';
33
+ import { modelNamespace } from './model-namespace.js';
34
+ import { SCHEMA_ITEM, SCHEMA_ITEM_LIST_ELEMENT, SCHEMA_NAME, readFolders, type FolderSummary, type ModelContents } from './model-queries.js';
35
+ import { keyDigest, partKey } from './short-hash.js';
36
+ import { T, dedupe, langLiteral, localName, nn, triple } from './vocabulary.js';
37
+
38
+ const MODEL_GRAPH = DataFactory.defaultGraph() as unknown as NamedNode;
39
+
40
+ /**
41
+ * The entry of a folder's list, its `schema:itemListElement`, that lists `memberIri`: `{folder}/item/{digest}`, the
42
+ * digest DD-41's ({@link keyDigest}) of the folder, `item` and the member, each written as {@link partKey} writes it.
43
+ * It is the IRI the converters give the entry (`PartIri.listItem`), so a folder imported and the same folder
44
+ * converted list a member under one resource. Named by what it lists, an entry is the same in every run, and a member
45
+ * listed twice in a folder is one entry (KReq 4.15, KD-26).
46
+ */
47
+ export function folderEntryIri(folderIri: string, memberIri: string): string {
48
+ return partIri(folderIri, 'item', keyDigest(partKey(folderIri, 'item', memberIri)));
49
+ }
50
+
51
+ /** What a folder holds: one of the tree's three groups. */
52
+ export type FolderKind = 'view' | 'element' | 'relationship';
53
+
54
+ /** The groups, in the tree's order. */
55
+ export const FOLDER_KINDS: readonly FolderKind[] = ['view', 'element', 'relationship'];
56
+
57
+ /** The name of the top folder that stands for each group — la-gram's and the converters'. */
58
+ export const KIND_FOLDER_NAMES: Readonly<Record<FolderKind, string>> = {
59
+ view: 'Views',
60
+ element: 'Elements',
61
+ relationship: 'Relationships',
62
+ };
63
+
64
+ /** The model's folders as the tree lays them out under its groups. */
65
+ export interface FolderLayout {
66
+ /** A converter's folder for the model itself, shown as the model ({@link modelFolderOf}). */
67
+ modelFolder?: FolderSummary;
68
+ /** The top folder standing for each group, where there is one. */
69
+ roots: Partial<Record<FolderKind, FolderSummary>>;
70
+ /** The groups each folder is shown under; a folder in none — a group's own, or one in a cycle — is not shown. */
71
+ kinds: Map<string, ReadonlySet<FolderKind>>;
72
+ /** The folders at the top of each group. */
73
+ top: Record<FolderKind, FolderSummary[]>;
74
+ /** The folders inside each folder. */
75
+ inside: Map<string, FolderSummary[]>;
76
+ /** Each concept's group: an unclassified concept is filed as an element. */
77
+ kindOf: Map<string, FolderKind>;
78
+ byIri: Map<string, FolderSummary>;
79
+ }
80
+
81
+ /**
82
+ * A converter's folder for the model itself: the one folder at the top, named
83
+ * as the model is — its name, or its IRI's last segment, the model id the
84
+ * converters name it by — holding folders and none of the model's concepts.
85
+ * The tree shows its folders in its place. A folder of the user's own holding
86
+ * only folders is not one: it is not named after the model.
87
+ */
88
+ export function modelFolderOf(contents: ModelContents | undefined): FolderSummary | undefined {
89
+ const folders = contents?.folders ?? [];
90
+ const known = new Set(folders.map((f) => f.iri));
91
+ const top = folders.filter((f) => !f.parentIri || !known.has(f.parentIri));
92
+ if (!contents || top.length !== 1) return undefined;
93
+ const [folder] = top;
94
+ const names = [contents.model?.label, contents.model ? localName(contents.model.iri) : undefined]
95
+ .filter((n): n is string => Boolean(n))
96
+ .map((n) => n.toLowerCase());
97
+ if (!names.includes(folder.label.toLowerCase())) return undefined;
98
+ if (!folders.some((f) => f.parentIri === folder.iri)) return undefined;
99
+ const listed = new Set(
100
+ [...contents.views, ...contents.elements, ...contents.relationships, ...contents.unclassified].map((c) => c.iri),
101
+ );
102
+ return folder.members.some((m) => listed.has(m)) ? undefined : folder;
103
+ }
104
+
105
+ /** Lay the model's folders out under the tree's groups (see the module's comment). */
106
+ export function folderLayout(contents: ModelContents): FolderLayout {
107
+ const folders = contents.folders ?? [];
108
+ const byIri = new Map(folders.map((f) => [f.iri, f]));
109
+ const inside = new Map<string, FolderSummary[]>();
110
+ const topLevel: FolderSummary[] = [];
111
+ for (const f of folders) {
112
+ if (f.parentIri && byIri.has(f.parentIri)) {
113
+ const list = inside.get(f.parentIri);
114
+ if (list) list.push(f);
115
+ else inside.set(f.parentIri, [f]);
116
+ } else topLevel.push(f);
117
+ }
118
+ const kindOf = new Map<string, FolderKind>();
119
+ for (const v of contents.views) kindOf.set(v.iri, 'view');
120
+ for (const e of contents.elements) kindOf.set(e.iri, 'element');
121
+ for (const u of contents.unclassified) kindOf.set(u.iri, 'element');
122
+ for (const r of contents.relationships) if (!r.derivation) kindOf.set(r.iri, 'relationship');
123
+
124
+ const modelFolder = modelFolderOf(contents);
125
+ const level = (modelFolder ? (inside.get(modelFolder.iri) ?? []) : topLevel).slice().sort((a, b) => a.iri.localeCompare(b.iri));
126
+ const roots: Partial<Record<FolderKind, FolderSummary>> = {};
127
+ for (const kind of FOLDER_KINDS) {
128
+ const root = level.find((f) => f.label.trim().toLowerCase() === KIND_FOLDER_NAMES[kind].toLowerCase());
129
+ if (root) roots[kind] = root;
130
+ }
131
+ const rootIris = new Set(Object.values(roots).map((f) => f.iri));
132
+
133
+ /** The groups of what a folder holds, at any depth. */
134
+ const held = new Map<string, Set<FolderKind>>();
135
+ const holds = (f: FolderSummary, trail: Set<string>): Set<FolderKind> => {
136
+ const known = held.get(f.iri);
137
+ if (known) return known;
138
+ const out = new Set<FolderKind>();
139
+ for (const m of f.members) {
140
+ const kind = kindOf.get(m);
141
+ if (kind) out.add(kind);
142
+ }
143
+ trail.add(f.iri);
144
+ for (const s of inside.get(f.iri) ?? []) if (!trail.has(s.iri)) for (const kind of holds(s, trail)) out.add(kind);
145
+ held.set(f.iri, out);
146
+ return out;
147
+ };
148
+ const kinds = new Map<string, ReadonlySet<FolderKind>>();
149
+ const place = (f: FolderSummary, around: ReadonlySet<FolderKind>, fixed: boolean): void => {
150
+ if (kinds.has(f.iri) || rootIris.has(f.iri)) return;
151
+ const own = holds(f, new Set());
152
+ const shown = fixed || own.size === 0 ? around : own;
153
+ kinds.set(f.iri, shown);
154
+ for (const s of inside.get(f.iri) ?? []) place(s, shown, fixed);
155
+ };
156
+ for (const kind of FOLDER_KINDS) {
157
+ const root = roots[kind];
158
+ if (root) for (const s of inside.get(root.iri) ?? []) place(s, new Set([kind]), true);
159
+ }
160
+ for (const f of level) place(f, new Set<FolderKind>(['element']), false);
161
+
162
+ const top = {} as Record<FolderKind, FolderSummary[]>;
163
+ for (const kind of FOLDER_KINDS) {
164
+ const root = roots[kind];
165
+ top[kind] = [...(root ? (inside.get(root.iri) ?? []) : []), ...level.filter((f) => !rootIris.has(f.iri))].filter((f) =>
166
+ kinds.get(f.iri)?.has(kind),
167
+ );
168
+ }
169
+ return { ...(modelFolder ? { modelFolder } : {}), roots, kinds, top, inside, kindOf, byIri };
170
+ }
171
+
172
+ /** The folders a folder is in, outermost first, up to its group — the names, for a path. */
173
+ export function folderPath(layout: FolderLayout, folderIri: string): string[] {
174
+ const names: string[] = [];
175
+ const seen = new Set<string>();
176
+ const stop = new Set([...Object.values(layout.roots).map((f) => f.iri), ...(layout.modelFolder ? [layout.modelFolder.iri] : [])]);
177
+ for (let at = layout.byIri.get(folderIri)?.parentIri; at && layout.byIri.has(at) && !stop.has(at) && !seen.has(at); at = layout.byIri.get(at)!.parentIri) {
178
+ seen.add(at);
179
+ names.unshift(layout.byIri.get(at)!.label);
180
+ }
181
+ return names;
182
+ }
183
+
184
+ /** Whether a folder is `iri` or inside it, by the layout's folders. */
185
+ export function folderWithin(layout: FolderLayout, folderIri: string, iri: string): boolean {
186
+ const seen = new Set<string>();
187
+ for (let at: string | undefined = folderIri; at && !seen.has(at); at = layout.byIri.get(at)?.parentIri) {
188
+ if (at === iri) return true;
189
+ seen.add(at);
190
+ }
191
+ return false;
192
+ }
193
+
194
+ /**
195
+ * The top folder standing for a group, made when the model has none — at the
196
+ * top of the model, or in a converter's folder for the model.
197
+ */
198
+ export function groupFolder(
199
+ store: RdfStore,
200
+ modelIri: string,
201
+ layout: FolderLayout,
202
+ kind: FolderKind,
203
+ ): { iri: string; change: FolderChange } {
204
+ const root = layout.roots[kind];
205
+ if (root) return { iri: root.iri, change: { remove: [], add: [] } };
206
+ return newFolder(store, modelIri, KIND_FOLDER_NAMES[kind], layout.modelFolder?.iri);
207
+ }
208
+
209
+ /** Several changes as one. */
210
+ export function combine(...changes: FolderChange[]): FolderChange {
211
+ return net({ remove: changes.flatMap((c) => c.remove), add: changes.flatMap((c) => c.add) });
212
+ }
213
+
214
+ /** What a folder operation removes and adds. */
215
+ export interface FolderChange {
216
+ remove: Quad[];
217
+ add: Quad[];
218
+ }
219
+
220
+ /** Make a folder change in the store. */
221
+ export function applyFolderChange(store: RdfStore, change: FolderChange): void {
222
+ if (change.remove.length > 0) store.removeQuads(change.remove);
223
+ if (change.add.length > 0) store.addQuads(change.add);
224
+ }
225
+
226
+ /** Whether a resource is an `arch:Folder` of the model. */
227
+ export function isFolder(store: RdfStore, iri: string): boolean {
228
+ return store.getQuads(nn(iri), T.rdfType, T.Folder, MODEL_GRAPH).length > 0;
229
+ }
230
+
231
+ /** A new folder named `name`, in the folder `parentIri` or, without one, at the top of the model. */
232
+ export function newFolder(store: RdfStore, modelIri: string, name: string, parentIri?: string): { iri: string; change: FolderChange } {
233
+ const iri = mintIri(modelNamespace(store, modelIri), 'folder');
234
+ const folder = nn(iri);
235
+ return {
236
+ iri,
237
+ change: {
238
+ remove: [],
239
+ add: [
240
+ triple(folder, T.rdfType, T.Folder),
241
+ triple(folder, SCHEMA_NAME[0], langLiteral(name)),
242
+ triple(folder, T.dctermsIsPartOf, nn(parentIri ?? modelIri)),
243
+ ],
244
+ },
245
+ };
246
+ }
247
+
248
+ /** A folder's name, `schema:name`, replaced. */
249
+ export function renameFolder(store: RdfStore, folderIri: string, name: string): FolderChange {
250
+ const folder = nn(folderIri);
251
+ return net({
252
+ remove: SCHEMA_NAME.flatMap((p) => store.getQuads(folder, p, null, MODEL_GRAPH)),
253
+ add: [triple(folder, SCHEMA_NAME[0], langLiteral(name))],
254
+ });
255
+ }
256
+
257
+ /**
258
+ * What puts `memberIri` in a folder: its `dcterms:isPartOf` a folder — a
259
+ * folder's, of the model too, which puts it at the top — and the folders' list
260
+ * entries that name it, with everything they say.
261
+ */
262
+ export function membershipQuads(store: RdfStore, memberIri: string, modelIri: string): Quad[] {
263
+ const member = nn(memberIri);
264
+ const memberIsFolder = isFolder(store, memberIri);
265
+ const quads = store
266
+ .getQuads(member, T.dctermsIsPartOf, null, MODEL_GRAPH)
267
+ .filter((q) => q.object.termType === 'NamedNode' && (isFolder(store, q.object.value) || (memberIsFolder && q.object.value === modelIri)));
268
+ for (const named of SCHEMA_ITEM.flatMap((p) => store.getQuads(null, p, member, MODEL_GRAPH))) {
269
+ // The list entry is named (`folderEntryIri`), or a blank node in a file written before DD-41: the store takes
270
+ // either as a term.
271
+ const entry = named.subject as NamedNode;
272
+ const listing = SCHEMA_ITEM_LIST_ELEMENT.flatMap((p) => store.getQuads(null, p, entry, MODEL_GRAPH)).filter((q) =>
273
+ isFolder(store, q.subject.value),
274
+ );
275
+ if (listing.length === 0) continue;
276
+ quads.push(...listing, ...store.getQuads(entry, null, null, MODEL_GRAPH));
277
+ }
278
+ return dedupe(quads);
279
+ }
280
+
281
+ /** Whether `iri` is the folder `folderIri` or inside it, at any depth. */
282
+ export function isWithin(store: RdfStore, iri: string, folderIri: string): boolean {
283
+ const parents = new Map(readFolders(store).map((f) => [f.iri, f.parentIri]));
284
+ const seen = new Set<string>();
285
+ for (let at: string | undefined = iri; at && !seen.has(at); at = parents.get(at)) {
286
+ if (at === folderIri) return true;
287
+ seen.add(at);
288
+ }
289
+ return false;
290
+ }
291
+
292
+ /**
293
+ * Move a concept or a folder into the folder `targetIri` — out of every folder
294
+ * it was in. Without a target, a concept is in no folder and a folder is at the
295
+ * top of the model, or in `topIri` when the model's top is a folder (a
296
+ * converter's folder for the model itself, which the tree shows as the model).
297
+ *
298
+ * @throws when a folder would go inside itself.
299
+ */
300
+ export function moveToFolder(
301
+ store: RdfStore,
302
+ memberIri: string,
303
+ targetIri: string | undefined,
304
+ modelIri: string,
305
+ topIri?: string,
306
+ ): FolderChange {
307
+ if (targetIri && isWithin(store, targetIri, memberIri)) throw new Error('A folder cannot go inside itself.');
308
+ const into = targetIri ?? (isFolder(store, memberIri) ? (topIri ?? modelIri) : undefined);
309
+ return net({
310
+ remove: membershipQuads(store, memberIri, modelIri),
311
+ add: into ? [triple(nn(memberIri), T.dctermsIsPartOf, nn(into))] : [],
312
+ });
313
+ }
314
+
315
+ /**
316
+ * Delete a folder and keep what it holds: its concepts and folders go to the
317
+ * folder it was in — at the top, its folders to the top of the model (or
318
+ * `topIri`) and its concepts in no folder.
319
+ */
320
+ export function deleteFolder(store: RdfStore, folderIri: string, modelIri: string, topIri?: string): FolderChange {
321
+ const folder = nn(folderIri);
322
+ const parentIri = readFolders(store).find((f) => f.iri === folderIri)?.parentIri;
323
+ const entries = SCHEMA_ITEM_LIST_ELEMENT.flatMap((p) => store.getQuads(folder, p, null, MODEL_GRAPH)).map((q) => q.object as NamedNode);
324
+ const held = new Set<string>();
325
+ for (const q of store.getQuads(null, T.dctermsIsPartOf, folder, MODEL_GRAPH)) if (q.subject.termType === 'NamedNode') held.add(q.subject.value);
326
+ for (const entry of entries) {
327
+ const item = SCHEMA_ITEM.flatMap((p) => store.getQuads(entry, p, null, MODEL_GRAPH))[0]?.object;
328
+ if (item?.termType === 'NamedNode') held.add(item.value);
329
+ }
330
+ held.delete(folderIri);
331
+
332
+ const remove: Quad[] = [
333
+ ...store.getQuads(folder, null, null, MODEL_GRAPH),
334
+ ...entries.flatMap((entry) => store.getQuads(entry, null, null, MODEL_GRAPH)),
335
+ ...membershipQuads(store, folderIri, modelIri),
336
+ ];
337
+ const add: Quad[] = [];
338
+ for (const iri of held) {
339
+ remove.push(...store.getQuads(nn(iri), T.dctermsIsPartOf, folder, MODEL_GRAPH));
340
+ const into = parentIri ?? (isFolder(store, iri) ? (topIri ?? modelIri) : undefined);
341
+ if (into) add.push(triple(nn(iri), T.dctermsIsPartOf, nn(into)));
342
+ }
343
+ return net({ remove, add });
344
+ }
345
+
346
+ /** A change without duplicates, and without what it would remove only to add back. */
347
+ function net(change: FolderChange): FolderChange {
348
+ const key = (q: Quad) => `${q.subject.termType}:${q.subject.value} ${q.predicate.value} ${q.object.termType}:${q.object.value}@${(q.object as { language?: string }).language ?? ''}`;
349
+ const remove = dedupe(change.remove);
350
+ const add = dedupe(change.add);
351
+ const removed = new Set(remove.map(key));
352
+ const added = new Set(add.map(key));
353
+ return { remove: remove.filter((q) => !added.has(key(q))), add: add.filter((q) => !removed.has(key(q))) };
354
+ }
@@ -0,0 +1,6 @@
1
+ /**
2
+ * The grid la-gram places elements on when nothing says where they go: a model that arrived with no
3
+ * geometry (`ModelSession.adopt`) and concepts pasted from the model tree (`clipboard.ts`) — six to a row,
4
+ * each at the default size unless the caller knows its notation's.
5
+ */
6
+ export const AUTO_LAYOUT = { columns: 6, dx: 170, dy: 100, x0: 40, y0: 40, width: 140, height: 60 };
@@ -0,0 +1,43 @@
1
+ // Model Manager layer — model session, element, relationship and view CRUD
2
+ export type {
3
+ ElementManager,
4
+ RelationshipManager,
5
+ ViewManager,
6
+ Bounds,
7
+ Point,
8
+ ViewInfo,
9
+ ViewKind,
10
+ NodeInfo,
11
+ LinkInfo,
12
+ RelationshipInfo,
13
+ CreateElementOptions,
14
+ CreateRelationshipRequest,
15
+ } from './interfaces.js';
16
+ export { OxigraphElementManager, resetElementCounter } from './element-manager.js';
17
+ export { OxigraphRelationshipManager, resetQrCounter } from './relationship-manager.js';
18
+ export { OxigraphViewManager, addRelationshipsToView, endsFirst } from './view-manager.js';
19
+ export {
20
+ compareDrawingOrder,
21
+ sortByDrawingOrder,
22
+ reorder,
23
+ type OrderedNode,
24
+ type DrawingOrderChange,
25
+ } from './drawing-order.js';
26
+ export { ModelOperations, resetModelCounter } from './model-operations.js';
27
+ export type { LoadModelResult } from './model-operations.js';
28
+ export { ModelSession, DEFAULT_VIEW_LABEL, type SessionEvents, type AdoptResult } from './model-session.js';
29
+ export {
30
+ readModelContents,
31
+ modelQuads,
32
+ typeClosure,
33
+ classify,
34
+ labelOf,
35
+ findModelIri,
36
+ type ModelContents,
37
+ type ConceptSummary,
38
+ type RelationshipSummary,
39
+ type ConceptKind,
40
+ type TypeClosure,
41
+ } from './model-queries.js';
42
+ export { migrateLegacyModel, type MigrationReport } from './legacy-migration.js';
43
+ export { collectElementQuads, collectRelationshipQuads } from './cascade.js';