@dialecte/core 0.7.0 → 0.8.1

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 (696) hide show
  1. package/dist/assets/hub.worker-B1HcVDhn.js +2 -0
  2. package/dist/diagnostics/diagnostics.d.ts +4 -0
  3. package/dist/diagnostics/diagnostics.d.ts.map +1 -1
  4. package/dist/diagnostics/types.d.ts +6 -1
  5. package/dist/diagnostics/types.d.ts.map +1 -1
  6. package/dist/dialecte/create-dialecte-project.d.ts +11 -0
  7. package/dist/dialecte/create-dialecte-project.d.ts.map +1 -0
  8. package/dist/dialecte/create-project-factory.d.ts +14 -0
  9. package/dist/dialecte/create-project-factory.d.ts.map +1 -0
  10. package/dist/dialecte/define-dialecte.d.ts +12 -0
  11. package/dist/dialecte/define-dialecte.d.ts.map +1 -0
  12. package/dist/dialecte/dialecte.constants.d.ts +4 -0
  13. package/dist/dialecte/dialecte.constants.d.ts.map +1 -0
  14. package/dist/dialecte/dialecte.types.d.ts +75 -0
  15. package/dist/dialecte/dialecte.types.d.ts.map +1 -0
  16. package/dist/dialecte/index.d.ts +4 -0
  17. package/dist/dialecte/index.d.ts.map +1 -0
  18. package/dist/{project-DIKdMMHx.js → dialecte-gIPrRzni.js} +8031 -8457
  19. package/dist/document/bind-extensions.d.ts +4 -1
  20. package/dist/document/bind-extensions.d.ts.map +1 -1
  21. package/dist/document/document.d.ts +58 -5
  22. package/dist/document/document.d.ts.map +1 -1
  23. package/dist/document/progress/progress.types.d.ts +21 -4
  24. package/dist/document/progress/progress.types.d.ts.map +1 -1
  25. package/dist/document/query/find/ancestor/find-ancestor.d.ts +2 -0
  26. package/dist/document/query/find/ancestor/find-ancestor.d.ts.map +1 -1
  27. package/dist/document/query/find/by-attribute/find-by-attributes.d.ts +4 -0
  28. package/dist/document/query/find/by-attribute/find-by-attributes.d.ts.map +1 -1
  29. package/dist/document/query/find/descendant/find-descendant.d.ts +2 -0
  30. package/dist/document/query/find/descendant/find-descendant.d.ts.map +1 -1
  31. package/dist/document/query/get/attribute/get-attribute.d.ts +4 -0
  32. package/dist/document/query/get/attribute/get-attribute.d.ts.map +1 -1
  33. package/dist/document/query/get/attribute/get-attributes.d.ts +4 -0
  34. package/dist/document/query/get/attribute/get-attributes.d.ts.map +1 -1
  35. package/dist/document/query/get/definition/get-definition.d.ts +2 -0
  36. package/dist/document/query/get/definition/get-definition.d.ts.map +1 -1
  37. package/dist/document/query/get/record/get-child.d.ts +2 -0
  38. package/dist/document/query/get/record/get-child.d.ts.map +1 -1
  39. package/dist/document/query/get/record/get-children.d.ts +2 -0
  40. package/dist/document/query/get/record/get-children.d.ts.map +1 -1
  41. package/dist/document/query/get/record/get-record.d.ts +2 -0
  42. package/dist/document/query/get/record/get-record.d.ts.map +1 -1
  43. package/dist/document/query/get/record/get-records-by-tagname.d.ts +2 -0
  44. package/dist/document/query/get/record/get-records-by-tagname.d.ts.map +1 -1
  45. package/dist/document/query/get/record/get-records.d.ts +2 -0
  46. package/dist/document/query/get/record/get-records.d.ts.map +1 -1
  47. package/dist/document/query/get/record/load-live-records.d.ts +2 -0
  48. package/dist/document/query/get/record/load-live-records.d.ts.map +1 -1
  49. package/dist/document/query/get/record/resolve-record.d.ts +2 -0
  50. package/dist/document/query/get/record/resolve-record.d.ts.map +1 -1
  51. package/dist/document/query/get/record/staged-lookup.d.ts +4 -0
  52. package/dist/document/query/get/record/staged-lookup.d.ts.map +1 -1
  53. package/dist/document/query/get/tree/get-tree.d.ts +6 -0
  54. package/dist/document/query/get/tree/get-tree.d.ts.map +1 -1
  55. package/dist/document/query/main.d.ts +50 -15
  56. package/dist/document/query/main.d.ts.map +1 -1
  57. package/dist/document/query/snapshot/collect-snapshot.d.ts +2 -0
  58. package/dist/document/query/snapshot/collect-snapshot.d.ts.map +1 -1
  59. package/dist/document/query/snapshot/get-snapshot.d.ts +2 -0
  60. package/dist/document/query/snapshot/get-snapshot.d.ts.map +1 -1
  61. package/dist/document/query/snapshot/records-to-tree.d.ts +2 -0
  62. package/dist/document/query/snapshot/records-to-tree.d.ts.map +1 -1
  63. package/dist/document/query/tree-filter/omit.d.ts +8 -0
  64. package/dist/document/query/tree-filter/omit.d.ts.map +1 -1
  65. package/dist/document/query/tree-filter/order.d.ts +5 -2
  66. package/dist/document/query/tree-filter/order.d.ts.map +1 -1
  67. package/dist/document/query/tree-filter/unwrap.d.ts +2 -0
  68. package/dist/document/query/tree-filter/unwrap.d.ts.map +1 -1
  69. package/dist/document/staged-operations.d.ts +5 -1
  70. package/dist/document/staged-operations.d.ts.map +1 -1
  71. package/dist/document/transaction/clone/clone.d.ts +2 -0
  72. package/dist/document/transaction/clone/clone.d.ts.map +1 -1
  73. package/dist/document/transaction/commit/commit.d.ts.map +1 -1
  74. package/dist/document/transaction/commit/merge-operations.d.ts +1 -1
  75. package/dist/document/transaction/commit/merge-operations.d.ts.map +1 -1
  76. package/dist/document/transaction/commit/summarize-operations.d.ts +16 -0
  77. package/dist/document/transaction/commit/summarize-operations.d.ts.map +1 -0
  78. package/dist/document/transaction/commit/summarize-operations.types.d.ts +17 -0
  79. package/dist/document/transaction/commit/summarize-operations.types.d.ts.map +1 -0
  80. package/dist/document/transaction/create/create.d.ts +2 -0
  81. package/dist/document/transaction/create/create.d.ts.map +1 -1
  82. package/dist/document/transaction/guard.d.ts +5 -0
  83. package/dist/document/transaction/guard.d.ts.map +1 -1
  84. package/dist/document/transaction/index.d.ts +2 -0
  85. package/dist/document/transaction/index.d.ts.map +1 -1
  86. package/dist/document/transaction/main.d.ts +46 -16
  87. package/dist/document/transaction/main.d.ts.map +1 -1
  88. package/dist/document/transaction/stage-operations.d.ts.map +1 -1
  89. package/dist/document/transaction/update/update.d.ts +2 -0
  90. package/dist/document/transaction/update/update.d.ts.map +1 -1
  91. package/dist/document/types.d.ts +3 -5
  92. package/dist/document/types.d.ts.map +1 -1
  93. package/dist/document/types.extensions.d.ts.map +1 -1
  94. package/dist/engine-store-CIEqgPUb.js +348 -0
  95. package/dist/engine.constants-DBMjMmV9.js +98 -0
  96. package/dist/engine.d.ts +9 -0
  97. package/dist/engine.d.ts.map +1 -0
  98. package/dist/engine.js +15805 -0
  99. package/dist/errors/codes.d.ts +451 -0
  100. package/dist/errors/codes.d.ts.map +1 -1
  101. package/dist/errors/errors.constants.d.ts +3 -0
  102. package/dist/errors/errors.constants.d.ts.map +1 -0
  103. package/dist/errors/errors.d.ts +10 -0
  104. package/dist/errors/errors.d.ts.map +1 -1
  105. package/dist/errors/types.d.ts +14 -0
  106. package/dist/errors/types.d.ts.map +1 -1
  107. package/dist/helpers/assert-fixed.d.ts +3 -1
  108. package/dist/helpers/assert-fixed.d.ts.map +1 -1
  109. package/dist/helpers/assert-xml-characters.d.ts +35 -0
  110. package/dist/helpers/assert-xml-characters.d.ts.map +1 -0
  111. package/dist/helpers/assert-xml-characters.types.d.ts +26 -0
  112. package/dist/helpers/assert-xml-characters.types.d.ts.map +1 -0
  113. package/dist/helpers/assert-xsi-type.d.ts +4 -0
  114. package/dist/helpers/assert-xsi-type.d.ts.map +1 -1
  115. package/dist/helpers/converter.d.ts +21 -6
  116. package/dist/helpers/converter.d.ts.map +1 -1
  117. package/dist/helpers/evaluate-expectations.d.ts +21 -0
  118. package/dist/helpers/evaluate-expectations.d.ts.map +1 -0
  119. package/dist/helpers/evaluate-expectations.types.d.ts +31 -0
  120. package/dist/helpers/evaluate-expectations.types.d.ts.map +1 -0
  121. package/dist/helpers/guard.d.ts +24 -4
  122. package/dist/helpers/guard.d.ts.map +1 -1
  123. package/dist/helpers/index.d.ts +2 -0
  124. package/dist/helpers/index.d.ts.map +1 -1
  125. package/dist/helpers/merge-extensions.d.ts +2 -0
  126. package/dist/helpers/merge-extensions.d.ts.map +1 -1
  127. package/dist/helpers/read-attributes.d.ts +4 -0
  128. package/dist/helpers/read-attributes.d.ts.map +1 -1
  129. package/dist/helpers/standardizing.d.ts +10 -0
  130. package/dist/helpers/standardizing.d.ts.map +1 -1
  131. package/dist/helpers/strip-attributes.d.ts +2 -0
  132. package/dist/helpers/strip-attributes.d.ts.map +1 -1
  133. package/dist/helpers-DVShv41E.js +489 -0
  134. package/dist/helpers.js +3 -439
  135. package/dist/in-process-link-DBeAOZRp.js +2791 -0
  136. package/dist/index.d.ts +1 -0
  137. package/dist/index.d.ts.map +1 -1
  138. package/dist/index.js +13 -12
  139. package/dist/perf/create-perf.d.ts +8 -1
  140. package/dist/perf/create-perf.d.ts.map +1 -1
  141. package/dist/perf/index.d.ts +1 -1
  142. package/dist/perf/index.d.ts.map +1 -1
  143. package/dist/perf/noop-perf.d.ts.map +1 -1
  144. package/dist/perf/perf.types.d.ts +65 -6
  145. package/dist/perf/perf.types.d.ts.map +1 -1
  146. package/dist/project/index.d.ts +7 -5
  147. package/dist/project/index.d.ts.map +1 -1
  148. package/dist/project/io/export-blob.d.ts +5 -2
  149. package/dist/project/io/export-blob.d.ts.map +1 -1
  150. package/dist/project/io/export-document.d.ts +5 -4
  151. package/dist/project/io/export-document.d.ts.map +1 -1
  152. package/dist/project/io/index.d.ts +1 -1
  153. package/dist/project/io/index.d.ts.map +1 -1
  154. package/dist/project/io/init-empty-document.d.ts +2 -0
  155. package/dist/project/io/init-empty-document.d.ts.map +1 -1
  156. package/dist/project/io/run-export.d.ts +19 -0
  157. package/dist/project/io/run-export.d.ts.map +1 -0
  158. package/dist/project/io/run-export.types.d.ts +45 -0
  159. package/dist/project/io/run-export.types.d.ts.map +1 -0
  160. package/dist/project/io/run-import.d.ts +15 -0
  161. package/dist/project/io/run-import.d.ts.map +1 -0
  162. package/dist/project/io/run-import.types.d.ts +19 -0
  163. package/dist/project/io/run-import.types.d.ts.map +1 -0
  164. package/dist/project/io/store-runtime.constants.d.ts +6 -0
  165. package/dist/project/io/store-runtime.constants.d.ts.map +1 -0
  166. package/dist/project/io/store-runtime.d.ts +12 -0
  167. package/dist/project/io/store-runtime.d.ts.map +1 -0
  168. package/dist/project/io/store-runtime.types.d.ts +18 -0
  169. package/dist/project/io/store-runtime.types.d.ts.map +1 -0
  170. package/dist/project/project-channel.d.ts +11 -0
  171. package/dist/project/project-channel.d.ts.map +1 -0
  172. package/dist/project/project.constants.d.ts +12 -0
  173. package/dist/project/project.constants.d.ts.map +1 -0
  174. package/dist/project/project.d.ts +315 -31
  175. package/dist/project/project.d.ts.map +1 -1
  176. package/dist/project/state/document-lifecycle.d.ts +0 -12
  177. package/dist/project/state/document-lifecycle.d.ts.map +1 -1
  178. package/dist/project/state/document-state.d.ts +4 -0
  179. package/dist/project/state/document-state.d.ts.map +1 -1
  180. package/dist/project/types.d.ts +126 -60
  181. package/dist/project/types.d.ts.map +1 -1
  182. package/dist/project-key-Ch34EtFa.js +1435 -0
  183. package/dist/rolldown-runtime-CYdcPHCu.js +12 -0
  184. package/dist/running-operations-vnijBvn7.js +76 -0
  185. package/dist/same-json-value-C6kUaoyt.js +1603 -0
  186. package/dist/sqlite.d.ts +5 -0
  187. package/dist/sqlite.d.ts.map +1 -0
  188. package/dist/sqlite.js +2671 -0
  189. package/dist/sqlite3.wasm +0 -0
  190. package/dist/store/apply-record-patch.d.ts +13 -0
  191. package/dist/store/apply-record-patch.d.ts.map +1 -0
  192. package/dist/store/closing-connections.d.ts +7 -0
  193. package/dist/store/closing-connections.d.ts.map +1 -0
  194. package/dist/store/closing-connections.types.d.ts +13 -0
  195. package/dist/store/closing-connections.types.d.ts.map +1 -0
  196. package/dist/store/commit-progress.d.ts +10 -0
  197. package/dist/store/commit-progress.d.ts.map +1 -0
  198. package/dist/store/compare-by-id.d.ts +10 -0
  199. package/dist/store/compare-by-id.d.ts.map +1 -0
  200. package/dist/store/document-path.constants.d.ts +20 -0
  201. package/dist/store/document-path.constants.d.ts.map +1 -0
  202. package/dist/store/document-path.d.ts +75 -0
  203. package/dist/store/document-path.d.ts.map +1 -0
  204. package/dist/store/document-path.types.d.ts +11 -0
  205. package/dist/store/document-path.types.d.ts.map +1 -0
  206. package/dist/store/engine/client/check-engine-wire.d.ts +8 -0
  207. package/dist/store/engine/client/check-engine-wire.d.ts.map +1 -0
  208. package/dist/store/engine/client/client.constants.d.ts +30 -0
  209. package/dist/store/engine/client/client.constants.d.ts.map +1 -0
  210. package/dist/store/engine/client/client.types.d.ts +200 -0
  211. package/dist/store/engine/client/client.types.d.ts.map +1 -0
  212. package/dist/store/engine/client/engine-client.d.ts +15 -0
  213. package/dist/store/engine/client/engine-client.d.ts.map +1 -0
  214. package/dist/store/engine/client/engine-control.d.ts +16 -0
  215. package/dist/store/engine/client/engine-control.d.ts.map +1 -0
  216. package/dist/store/engine/client/heartbeat-watch.d.ts +17 -0
  217. package/dist/store/engine/client/heartbeat-watch.d.ts.map +1 -0
  218. package/dist/store/engine/client/hub-connector.d.ts +11 -0
  219. package/dist/store/engine/client/hub-connector.d.ts.map +1 -0
  220. package/dist/store/engine/client/hub-connector.types.d.ts +25 -0
  221. package/dist/store/engine/client/hub-connector.types.d.ts.map +1 -0
  222. package/dist/store/engine/client/worker-connector.d.ts +32 -0
  223. package/dist/store/engine/client/worker-connector.d.ts.map +1 -0
  224. package/dist/store/engine/creation-refusal.d.ts +10 -0
  225. package/dist/store/engine/creation-refusal.d.ts.map +1 -0
  226. package/dist/store/engine/dialecte-refusal.d.ts +18 -0
  227. package/dist/store/engine/dialecte-refusal.d.ts.map +1 -0
  228. package/dist/store/engine/engine-store.d.ts +163 -0
  229. package/dist/store/engine/engine-store.d.ts.map +1 -0
  230. package/dist/store/engine/engine-store.types.d.ts +53 -0
  231. package/dist/store/engine/engine-store.types.d.ts.map +1 -0
  232. package/dist/store/engine/engine.constants.d.ts +14 -0
  233. package/dist/store/engine/engine.constants.d.ts.map +1 -0
  234. package/dist/store/engine/engine.types.d.ts +165 -0
  235. package/dist/store/engine/engine.types.d.ts.map +1 -0
  236. package/dist/store/engine/host/engine-wire.d.ts +19 -0
  237. package/dist/store/engine/host/engine-wire.d.ts.map +1 -0
  238. package/dist/store/engine/host/heartbeat.d.ts +33 -0
  239. package/dist/store/engine/host/heartbeat.d.ts.map +1 -0
  240. package/dist/store/engine/host/host.constants.d.ts +13 -0
  241. package/dist/store/engine/host/host.constants.d.ts.map +1 -0
  242. package/dist/store/engine/host/host.types.d.ts +65 -0
  243. package/dist/store/engine/host/host.types.d.ts.map +1 -0
  244. package/dist/store/engine/host/store-events.d.ts +14 -0
  245. package/dist/store/engine/host/store-events.d.ts.map +1 -0
  246. package/dist/store/engine/hub/hub-client.constants.d.ts +27 -0
  247. package/dist/store/engine/hub/hub-client.constants.d.ts.map +1 -0
  248. package/dist/store/engine/hub/hub-client.d.ts +46 -0
  249. package/dist/store/engine/hub/hub-client.d.ts.map +1 -0
  250. package/dist/store/engine/hub/hub-client.types.d.ts +208 -0
  251. package/dist/store/engine/hub/hub-client.types.d.ts.map +1 -0
  252. package/dist/store/engine/hub/hub-protocol.types.d.ts +193 -0
  253. package/dist/store/engine/hub/hub-protocol.types.d.ts.map +1 -0
  254. package/dist/store/engine/hub/hub-router.d.ts +9 -0
  255. package/dist/store/engine/hub/hub-router.d.ts.map +1 -0
  256. package/dist/store/engine/hub/hub-shell.d.ts +13 -0
  257. package/dist/store/engine/hub/hub-shell.d.ts.map +1 -0
  258. package/dist/store/engine/hub/hub-shell.types.d.ts +64 -0
  259. package/dist/store/engine/hub/hub-shell.types.d.ts.map +1 -0
  260. package/dist/store/engine/hub/hub.constants.d.ts +33 -0
  261. package/dist/store/engine/hub/hub.constants.d.ts.map +1 -0
  262. package/dist/store/engine/hub/hub.types.d.ts +305 -0
  263. package/dist/store/engine/hub/hub.types.d.ts.map +1 -0
  264. package/dist/store/engine/hub/hub.worker.d.ts +2 -0
  265. package/dist/store/engine/hub/hub.worker.d.ts.map +1 -0
  266. package/dist/store/engine/hub/realm-host.d.ts +10 -0
  267. package/dist/store/engine/hub/realm-host.d.ts.map +1 -0
  268. package/dist/store/engine/hub/realm-host.types.d.ts +78 -0
  269. package/dist/store/engine/hub/realm-host.types.d.ts.map +1 -0
  270. package/dist/store/engine/project-key.d.ts +15 -0
  271. package/dist/store/engine/project-key.d.ts.map +1 -0
  272. package/dist/store/engine/wire/error-envelope.d.ts +25 -0
  273. package/dist/store/engine/wire/error-envelope.d.ts.map +1 -0
  274. package/dist/store/engine/wire/wire-values.d.ts +33 -0
  275. package/dist/store/engine/wire/wire-values.d.ts.map +1 -0
  276. package/dist/store/engine/wire/wire.constants.d.ts +116 -0
  277. package/dist/store/engine/wire/wire.constants.d.ts.map +1 -0
  278. package/dist/store/engine/wire/wire.types.d.ts +119 -0
  279. package/dist/store/engine/wire/wire.types.d.ts.map +1 -0
  280. package/dist/store/hub-public.d.ts +33 -0
  281. package/dist/store/hub-public.d.ts.map +1 -0
  282. package/dist/store/ignore-destroy-outcome.d.ts +6 -0
  283. package/dist/store/ignore-destroy-outcome.d.ts.map +1 -0
  284. package/dist/store/in-memory/in-memory-state.d.ts +46 -0
  285. package/dist/store/in-memory/in-memory-state.d.ts.map +1 -0
  286. package/dist/store/in-memory/in-memory-store.constants.d.ts +7 -0
  287. package/dist/store/in-memory/in-memory-store.constants.d.ts.map +1 -0
  288. package/dist/store/in-memory/in-memory-store.d.ts +105 -17
  289. package/dist/store/in-memory/in-memory-store.d.ts.map +1 -1
  290. package/dist/store/in-memory/types.d.ts +55 -1
  291. package/dist/store/in-memory/types.d.ts.map +1 -1
  292. package/dist/store/index.d.ts +8 -2
  293. package/dist/store/index.d.ts.map +1 -1
  294. package/dist/store/json-values.constants.d.ts +18 -0
  295. package/dist/store/json-values.constants.d.ts.map +1 -0
  296. package/dist/store/json-values.d.ts +40 -0
  297. package/dist/store/json-values.d.ts.map +1 -0
  298. package/dist/store/json-values.types.d.ts +18 -0
  299. package/dist/store/json-values.types.d.ts.map +1 -0
  300. package/dist/store/local/dexie-store.constants.d.ts +20 -0
  301. package/dist/store/local/dexie-store.constants.d.ts.map +1 -0
  302. package/dist/store/local/dexie-store.d.ts +134 -5
  303. package/dist/store/local/dexie-store.d.ts.map +1 -1
  304. package/dist/store/local/types.d.ts +6 -0
  305. package/dist/store/local/types.d.ts.map +1 -1
  306. package/dist/store/lost-write.d.ts +32 -0
  307. package/dist/store/lost-write.d.ts.map +1 -0
  308. package/dist/store/lost-write.types.d.ts +4 -0
  309. package/dist/store/lost-write.types.d.ts.map +1 -0
  310. package/dist/store/open-connections.d.ts +4 -0
  311. package/dist/store/open-connections.d.ts.map +1 -0
  312. package/dist/store/open-connections.types.d.ts +17 -0
  313. package/dist/store/open-connections.types.d.ts.map +1 -0
  314. package/dist/store/own-import.d.ts +10 -0
  315. package/dist/store/own-import.d.ts.map +1 -0
  316. package/dist/store/project-name.d.ts +10 -0
  317. package/dist/store/project-name.d.ts.map +1 -0
  318. package/dist/store/resolve-store.d.ts +28 -4
  319. package/dist/store/resolve-store.d.ts.map +1 -1
  320. package/dist/store/running-operations.d.ts +7 -0
  321. package/dist/store/running-operations.d.ts.map +1 -0
  322. package/dist/store/running-operations.types.d.ts +10 -0
  323. package/dist/store/running-operations.types.d.ts.map +1 -0
  324. package/dist/store/same-json-value.d.ts +9 -0
  325. package/dist/store/same-json-value.d.ts.map +1 -0
  326. package/dist/store/sqlite/adapter/in-process-link.d.ts +20 -0
  327. package/dist/store/sqlite/adapter/in-process-link.d.ts.map +1 -0
  328. package/dist/store/sqlite/adapter/in-process-link.types.d.ts +21 -0
  329. package/dist/store/sqlite/adapter/in-process-link.types.d.ts.map +1 -0
  330. package/dist/store/sqlite/adapter/realm-storage.d.ts +10 -0
  331. package/dist/store/sqlite/adapter/realm-storage.d.ts.map +1 -0
  332. package/dist/store/sqlite/adapter/sqlite-connector.d.ts +14 -0
  333. package/dist/store/sqlite/adapter/sqlite-connector.d.ts.map +1 -0
  334. package/dist/store/sqlite/adapter/sqlite-engine-settings.d.ts +4 -0
  335. package/dist/store/sqlite/adapter/sqlite-engine-settings.d.ts.map +1 -0
  336. package/dist/store/sqlite/adapter/sqlite-hub-spawner.d.ts +8 -0
  337. package/dist/store/sqlite/adapter/sqlite-hub-spawner.d.ts.map +1 -0
  338. package/dist/store/sqlite/adapter/sqlite-hub-spawner.types.d.ts +5 -0
  339. package/dist/store/sqlite/adapter/sqlite-hub-spawner.types.d.ts.map +1 -0
  340. package/dist/store/sqlite/adapter/sqlite-worker-connector.d.ts +8 -0
  341. package/dist/store/sqlite/adapter/sqlite-worker-connector.d.ts.map +1 -0
  342. package/dist/store/sqlite/adapter/sqlite-worker-connector.types.d.ts +5 -0
  343. package/dist/store/sqlite/adapter/sqlite-worker-connector.types.d.ts.map +1 -0
  344. package/dist/store/sqlite/engine/blobs.d.ts +55 -0
  345. package/dist/store/sqlite/engine/blobs.d.ts.map +1 -0
  346. package/dist/store/sqlite/engine/bulk-insert.d.ts +31 -0
  347. package/dist/store/sqlite/engine/bulk-insert.d.ts.map +1 -0
  348. package/dist/store/sqlite/engine/commit.d.ts +20 -0
  349. package/dist/store/sqlite/engine/commit.d.ts.map +1 -0
  350. package/dist/store/sqlite/engine/device-cache.d.ts +13 -0
  351. package/dist/store/sqlite/engine/device-cache.d.ts.map +1 -0
  352. package/dist/store/sqlite/engine/engine-errors.d.ts +26 -0
  353. package/dist/store/sqlite/engine/engine-errors.d.ts.map +1 -0
  354. package/dist/store/sqlite/engine/engine.constants.d.ts +144 -0
  355. package/dist/store/sqlite/engine/engine.constants.d.ts.map +1 -0
  356. package/dist/store/sqlite/engine/engine.types.d.ts +361 -0
  357. package/dist/store/sqlite/engine/engine.types.d.ts.map +1 -0
  358. package/dist/store/sqlite/engine/history.d.ts +114 -0
  359. package/dist/store/sqlite/engine/history.d.ts.map +1 -0
  360. package/dist/store/sqlite/engine/import-queue.d.ts +7 -0
  361. package/dist/store/sqlite/engine/import-queue.d.ts.map +1 -0
  362. package/dist/store/sqlite/engine/import-target.d.ts +23 -0
  363. package/dist/store/sqlite/engine/import-target.d.ts.map +1 -0
  364. package/dist/store/sqlite/engine/import-window.d.ts +23 -0
  365. package/dist/store/sqlite/engine/import-window.d.ts.map +1 -0
  366. package/dist/store/sqlite/engine/reclaim.d.ts +13 -0
  367. package/dist/store/sqlite/engine/reclaim.d.ts.map +1 -0
  368. package/dist/store/sqlite/engine/records.d.ts +117 -0
  369. package/dist/store/sqlite/engine/records.d.ts.map +1 -0
  370. package/dist/store/sqlite/engine/registry.d.ts +76 -0
  371. package/dist/store/sqlite/engine/registry.d.ts.map +1 -0
  372. package/dist/store/sqlite/engine/schema.d.ts +57 -0
  373. package/dist/store/sqlite/engine/schema.d.ts.map +1 -0
  374. package/dist/store/sqlite/engine/sqlite-engine.d.ts +14 -0
  375. package/dist/store/sqlite/engine/sqlite-engine.d.ts.map +1 -0
  376. package/dist/store/sqlite/engine/transaction.d.ts +12 -0
  377. package/dist/store/sqlite/engine/transaction.d.ts.map +1 -0
  378. package/dist/store/sqlite/list-projects.constants.d.ts +12 -0
  379. package/dist/store/sqlite/list-projects.constants.d.ts.map +1 -0
  380. package/dist/store/sqlite/list-projects.d.ts +22 -0
  381. package/dist/store/sqlite/list-projects.d.ts.map +1 -0
  382. package/dist/store/sqlite/list-projects.types.d.ts +28 -0
  383. package/dist/store/sqlite/list-projects.types.d.ts.map +1 -0
  384. package/dist/store/sqlite/load-sqlite.d.ts +11 -0
  385. package/dist/store/sqlite/load-sqlite.d.ts.map +1 -0
  386. package/dist/store/sqlite/runtime/close-engine.d.ts +18 -0
  387. package/dist/store/sqlite/runtime/close-engine.d.ts.map +1 -0
  388. package/dist/store/sqlite/runtime/install-pool.d.ts +94 -0
  389. package/dist/store/sqlite/runtime/install-pool.d.ts.map +1 -0
  390. package/dist/store/sqlite/runtime/pool-header.d.ts +13 -0
  391. package/dist/store/sqlite/runtime/pool-header.d.ts.map +1 -0
  392. package/dist/store/sqlite/runtime/progress-beat.d.ts +13 -0
  393. package/dist/store/sqlite/runtime/progress-beat.d.ts.map +1 -0
  394. package/dist/store/sqlite/runtime/runtime.constants.d.ts +57 -0
  395. package/dist/store/sqlite/runtime/runtime.constants.d.ts.map +1 -0
  396. package/dist/store/sqlite/runtime/runtime.types.d.ts +56 -0
  397. package/dist/store/sqlite/runtime/runtime.types.d.ts.map +1 -0
  398. package/dist/store/sqlite/runtime/serve-dialecte-engine.d.ts +16 -0
  399. package/dist/store/sqlite/runtime/serve-dialecte-engine.d.ts.map +1 -0
  400. package/dist/store/sqlite/sqlite-store-of.d.ts +7 -0
  401. package/dist/store/sqlite/sqlite-store-of.d.ts.map +1 -0
  402. package/dist/store/sqlite/sqlite-text.d.ts +20 -0
  403. package/dist/store/sqlite/sqlite-text.d.ts.map +1 -0
  404. package/dist/store/sqlite/sqlite-wasm-url.d.ts +9 -0
  405. package/dist/store/sqlite/sqlite-wasm-url.d.ts.map +1 -0
  406. package/dist/store/sqlite/sqlite.constants.d.ts +15 -0
  407. package/dist/store/sqlite/sqlite.constants.d.ts.map +1 -0
  408. package/dist/store/sqlite/sqlite.types.d.ts +36 -0
  409. package/dist/store/sqlite/sqlite.types.d.ts.map +1 -0
  410. package/dist/store/sqlite-storage.constants.d.ts +14 -0
  411. package/dist/store/sqlite-storage.constants.d.ts.map +1 -0
  412. package/dist/store/sqlite-storage.d.ts +22 -0
  413. package/dist/store/sqlite-storage.d.ts.map +1 -0
  414. package/dist/store/sqlite-storage.types.d.ts +24 -0
  415. package/dist/store/sqlite-storage.types.d.ts.map +1 -0
  416. package/dist/store/store-errors.d.ts +51 -0
  417. package/dist/store/store-errors.d.ts.map +1 -0
  418. package/dist/store/store.constants.d.ts +15 -3
  419. package/dist/store/store.constants.d.ts.map +1 -1
  420. package/dist/store/store.types.d.ts +280 -16
  421. package/dist/store/store.types.d.ts.map +1 -1
  422. package/dist/store/stored-record.d.ts +16 -0
  423. package/dist/store/stored-record.d.ts.map +1 -0
  424. package/dist/store/unfinished-imports.d.ts +15 -0
  425. package/dist/store/unfinished-imports.d.ts.map +1 -0
  426. package/dist/store/write-outcome.d.ts +34 -0
  427. package/dist/store/write-outcome.d.ts.map +1 -0
  428. package/dist/test/assert-valid-xml/assert-valid-xml.constants.d.ts +7 -0
  429. package/dist/test/assert-valid-xml/assert-valid-xml.constants.d.ts.map +1 -0
  430. package/dist/test/assert-valid-xml/assert-valid-xml.d.ts +19 -18
  431. package/dist/test/assert-valid-xml/assert-valid-xml.d.ts.map +1 -1
  432. package/dist/test/assert-valid-xml/assert-valid-xml.types.d.ts +8 -4
  433. package/dist/test/assert-valid-xml/assert-valid-xml.types.d.ts.map +1 -1
  434. package/dist/test/assert-xml/assert-xml.constants.d.ts +25 -0
  435. package/dist/test/assert-xml/assert-xml.constants.d.ts.map +1 -0
  436. package/dist/test/assert-xml/assert-xml.d.ts +23 -34
  437. package/dist/test/assert-xml/assert-xml.d.ts.map +1 -1
  438. package/dist/test/assert-xml/assert-xml.types.d.ts +48 -0
  439. package/dist/test/assert-xml/assert-xml.types.d.ts.map +1 -0
  440. package/dist/test/assert-xml/describe-nearby.d.ts +16 -0
  441. package/dist/test/assert-xml/describe-nearby.d.ts.map +1 -0
  442. package/dist/test/assert-xml/describe-node-place.d.ts +15 -0
  443. package/dist/test/assert-xml/describe-node-place.d.ts.map +1 -0
  444. package/dist/test/assert-xml/index.d.ts +1 -1
  445. package/dist/test/assert-xml/index.d.ts.map +1 -1
  446. package/dist/test/assert-xml/query-failure-message.d.ts +24 -0
  447. package/dist/test/assert-xml/query-failure-message.d.ts.map +1 -0
  448. package/dist/test/assert-xml/read-xpath-step.d.ts +8 -0
  449. package/dist/test/assert-xml/read-xpath-step.d.ts.map +1 -0
  450. package/dist/test/assert-xml/xpath-parser.d.ts +2 -1
  451. package/dist/test/assert-xml/xpath-parser.d.ts.map +1 -1
  452. package/dist/test/config.d.ts +5 -0
  453. package/dist/test/config.d.ts.map +1 -1
  454. package/dist/test/constant.d.ts +2 -0
  455. package/dist/test/constant.d.ts.map +1 -1
  456. package/dist/test/create-test-dialecte.d.ts +32 -37
  457. package/dist/test/create-test-dialecte.d.ts.map +1 -1
  458. package/dist/test/create-test-dialecte.types.d.ts +99 -0
  459. package/dist/test/create-test-dialecte.types.d.ts.map +1 -0
  460. package/dist/test/create-test-helpers-internal.types.d.ts +19 -0
  461. package/dist/test/create-test-helpers-internal.types.d.ts.map +1 -0
  462. package/dist/test/create-test-helpers.d.ts +13 -0
  463. package/dist/test/create-test-helpers.d.ts.map +1 -0
  464. package/dist/test/create-test-helpers.types.d.ts +50 -0
  465. package/dist/test/create-test-helpers.types.d.ts.map +1 -0
  466. package/dist/test/fixtures/test-entry-scan-constraint.d.ts +3 -0
  467. package/dist/test/fixtures/test-entry-scan-constraint.d.ts.map +1 -0
  468. package/dist/test/fixtures/test-entry-scan-edges.types.d.ts +10 -0
  469. package/dist/test/fixtures/test-entry-scan-edges.types.d.ts.map +1 -0
  470. package/dist/test/fixtures/test-entry-scan-recursive.d.ts +4 -0
  471. package/dist/test/fixtures/test-entry-scan-recursive.d.ts.map +1 -0
  472. package/dist/test/fixtures/test-entry-scan-recursive.types.d.ts +15 -0
  473. package/dist/test/fixtures/test-entry-scan-recursive.types.d.ts.map +1 -0
  474. package/dist/test/fixtures/test-entry-scan-shapes.d.ts +14 -0
  475. package/dist/test/fixtures/test-entry-scan-shapes.d.ts.map +1 -0
  476. package/dist/test/fixtures/test-entry-scan-shapes.types.d.ts +14 -0
  477. package/dist/test/fixtures/test-entry-scan-shapes.types.d.ts.map +1 -0
  478. package/dist/test/fixtures/test-entry-scan-tree.d.ts +3 -0
  479. package/dist/test/fixtures/test-entry-scan-tree.d.ts.map +1 -0
  480. package/dist/test/fixtures/test-entry-scan.d.ts +5 -0
  481. package/dist/test/fixtures/test-entry-scan.d.ts.map +1 -0
  482. package/dist/test/fixtures/test-entry-scan.types.d.ts +5 -0
  483. package/dist/test/fixtures/test-entry-scan.types.d.ts.map +1 -0
  484. package/dist/test/generated/definition.generated.d.ts +5 -0
  485. package/dist/test/generated/definition.generated.d.ts.map +1 -1
  486. package/dist/test/in-memory-storage.setup.d.ts +2 -0
  487. package/dist/test/in-memory-storage.setup.d.ts.map +1 -0
  488. package/dist/test/index.d.ts +6 -0
  489. package/dist/test/index.d.ts.map +1 -1
  490. package/dist/test/normalize-uuids.constants.d.ts +3 -0
  491. package/dist/test/normalize-uuids.constants.d.ts.map +1 -0
  492. package/dist/test/normalize-uuids.d.ts +12 -0
  493. package/dist/test/normalize-uuids.d.ts.map +1 -1
  494. package/dist/test/run-test-cases.d.ts +30 -11
  495. package/dist/test/run-test-cases.d.ts.map +1 -1
  496. package/dist/test/run-test-cases.type.d.ts +16 -0
  497. package/dist/test/run-test-cases.type.d.ts.map +1 -1
  498. package/dist/test/sqlite-storage.setup.d.ts +1 -0
  499. package/dist/test/sqlite-storage.setup.d.ts.map +1 -0
  500. package/dist/test/test-dialecte-setup.d.ts +31 -0
  501. package/dist/test/test-dialecte-setup.d.ts.map +1 -0
  502. package/dist/test/test-dialecte-setup.types.d.ts +29 -0
  503. package/dist/test/test-dialecte-setup.types.d.ts.map +1 -0
  504. package/dist/test/test-dialecte.d.ts +2722 -0
  505. package/dist/test/test-dialecte.d.ts.map +1 -0
  506. package/dist/test/test-dialecte.types.d.ts +3 -0
  507. package/dist/test/test-dialecte.types.d.ts.map +1 -0
  508. package/dist/test/test-dialecte.worker.d.ts +2 -0
  509. package/dist/test/test-dialecte.worker.d.ts.map +1 -0
  510. package/dist/test/test-entry-environment.constants.d.ts +27 -0
  511. package/dist/test/test-entry-environment.constants.d.ts.map +1 -0
  512. package/dist/test/test-record.d.ts +49 -1
  513. package/dist/test/test-record.d.ts.map +1 -1
  514. package/dist/test/test-storage/index.d.ts +5 -0
  515. package/dist/test/test-storage/index.d.ts.map +1 -0
  516. package/dist/test/test-storage/read-test-storage.d.ts +4 -0
  517. package/dist/test/test-storage/read-test-storage.d.ts.map +1 -0
  518. package/dist/test/test-storage/resolve-test-storage.d.ts +9 -0
  519. package/dist/test/test-storage/resolve-test-storage.d.ts.map +1 -0
  520. package/dist/test/test-storage/test-storage.constants.d.ts +9 -0
  521. package/dist/test/test-storage/test-storage.constants.d.ts.map +1 -0
  522. package/dist/test/test-storage/test-storage.types.d.ts +15 -0
  523. package/dist/test/test-storage/test-storage.types.d.ts.map +1 -0
  524. package/dist/test/test-storage/test-store-for.d.ts +19 -0
  525. package/dist/test/test-storage/test-store-for.d.ts.map +1 -0
  526. package/dist/test/test-storage/use-test-storage.d.ts +14 -0
  527. package/dist/test/test-storage/use-test-storage.d.ts.map +1 -0
  528. package/dist/test/test-timing.constants.d.ts +15 -0
  529. package/dist/test/test-timing.constants.d.ts.map +1 -0
  530. package/dist/test/xml/engine-console.d.ts +6 -0
  531. package/dist/test/xml/engine-console.d.ts.map +1 -0
  532. package/dist/test/xml/engine.d.ts +3 -0
  533. package/dist/test/xml/engine.d.ts.map +1 -0
  534. package/dist/test/xml/index.d.ts +8 -0
  535. package/dist/test/xml/index.d.ts.map +1 -0
  536. package/dist/test/xml/malformed-xml-error.d.ts +5 -0
  537. package/dist/test/xml/malformed-xml-error.d.ts.map +1 -0
  538. package/dist/test/xml/print-node.d.ts +7 -0
  539. package/dist/test/xml/print-node.d.ts.map +1 -0
  540. package/dist/test/xml/select-nodes.d.ts +14 -0
  541. package/dist/test/xml/select-nodes.d.ts.map +1 -0
  542. package/dist/test/xml/with-xml-document.constants.d.ts +7 -0
  543. package/dist/test/xml/with-xml-document.constants.d.ts.map +1 -0
  544. package/dist/test/xml/with-xml-document.d.ts +14 -0
  545. package/dist/test/xml/with-xml-document.d.ts.map +1 -0
  546. package/dist/test/xml/xml-query-refused-error.d.ts +13 -0
  547. package/dist/test/xml/xml-query-refused-error.d.ts.map +1 -0
  548. package/dist/test/xml/xml.constants.d.ts +16 -0
  549. package/dist/test/xml/xml.constants.d.ts.map +1 -0
  550. package/dist/test/xml/xml.types.d.ts +31 -0
  551. package/dist/test/xml/xml.types.d.ts.map +1 -0
  552. package/dist/test/xsd/test-ext.xsd +226 -0
  553. package/dist/test/xsd/test.xsd +528 -0
  554. package/dist/test.js +3427 -406
  555. package/dist/types/dialecte-config.d.ts +6 -0
  556. package/dist/types/dialecte-config.d.ts.map +1 -1
  557. package/dist/types/io.d.ts +5 -0
  558. package/dist/types/io.d.ts.map +1 -1
  559. package/dist/utils/attribute-rules.d.ts +16 -1
  560. package/dist/utils/attribute-rules.d.ts.map +1 -1
  561. package/dist/utils/child-occurrences.constants.d.ts +4 -0
  562. package/dist/utils/child-occurrences.constants.d.ts.map +1 -0
  563. package/dist/utils/child-occurrences.d.ts +17 -0
  564. package/dist/utils/child-occurrences.d.ts.map +1 -0
  565. package/dist/utils/child-occurrences.types.d.ts +6 -0
  566. package/dist/utils/child-occurrences.types.d.ts.map +1 -0
  567. package/dist/utils/datatype.d.ts +4 -0
  568. package/dist/utils/datatype.d.ts.map +1 -1
  569. package/dist/utils/format-xml.d.ts +4 -0
  570. package/dist/utils/format-xml.d.ts.map +1 -1
  571. package/dist/utils/index.d.ts +5 -1
  572. package/dist/utils/index.d.ts.map +1 -1
  573. package/dist/utils/invariant.d.ts +2 -0
  574. package/dist/utils/invariant.d.ts.map +1 -1
  575. package/dist/utils/namespaces.d.ts +15 -1
  576. package/dist/utils/namespaces.d.ts.map +1 -1
  577. package/dist/utils/order-children.d.ts +14 -3
  578. package/dist/utils/order-children.d.ts.map +1 -1
  579. package/dist/utils/order-children.types.d.ts +10 -0
  580. package/dist/utils/order-children.types.d.ts.map +1 -0
  581. package/dist/utils/particle-occurrences.d.ts +4 -0
  582. package/dist/utils/particle-occurrences.d.ts.map +1 -0
  583. package/dist/utils/required-choices.d.ts +17 -0
  584. package/dist/utils/required-choices.d.ts.map +1 -0
  585. package/dist/utils/required-choices.types.d.ts +15 -0
  586. package/dist/utils/required-choices.types.d.ts.map +1 -0
  587. package/dist/utils/resolve-definition.d.ts +4 -0
  588. package/dist/utils/resolve-definition.d.ts.map +1 -1
  589. package/dist/utils/save-to-disk.constants.d.ts +3 -0
  590. package/dist/utils/save-to-disk.constants.d.ts.map +1 -0
  591. package/dist/utils/save-to-disk.d.ts +17 -5
  592. package/dist/utils/save-to-disk.d.ts.map +1 -1
  593. package/dist/utils/save-to-disk.types.d.ts +17 -0
  594. package/dist/utils/save-to-disk.types.d.ts.map +1 -0
  595. package/dist/utils/seeded-uuid.constants.d.ts +5 -0
  596. package/dist/utils/seeded-uuid.constants.d.ts.map +1 -0
  597. package/dist/utils/seeded-uuid.d.ts +15 -0
  598. package/dist/utils/seeded-uuid.d.ts.map +1 -0
  599. package/dist/utils/seeded-uuid.types.d.ts +8 -0
  600. package/dist/utils/seeded-uuid.types.d.ts.map +1 -0
  601. package/dist/utils/tell-listener.constants.d.ts +9 -0
  602. package/dist/utils/tell-listener.constants.d.ts.map +1 -0
  603. package/dist/utils/tell-listener.d.ts +24 -0
  604. package/dist/utils/tell-listener.d.ts.map +1 -0
  605. package/dist/utils/xml-characters.constants.d.ts +9 -0
  606. package/dist/utils/xml-characters.constants.d.ts.map +1 -0
  607. package/dist/utils/xml-characters.d.ts +8 -0
  608. package/dist/utils/xml-characters.d.ts.map +1 -0
  609. package/dist/utils/xml-whitespace.constants.d.ts +8 -0
  610. package/dist/utils/xml-whitespace.constants.d.ts.map +1 -0
  611. package/dist/utils/xml-whitespace.d.ts +19 -0
  612. package/dist/utils/xml-whitespace.d.ts.map +1 -0
  613. package/dist/utils/xsi-type.d.ts +4 -0
  614. package/dist/utils/xsi-type.d.ts.map +1 -1
  615. package/dist/utils/yield-to-queue.d.ts +6 -0
  616. package/dist/utils/yield-to-queue.d.ts.map +1 -0
  617. package/dist/utils-USNkj4sT.js +1275 -0
  618. package/dist/utils.js +1 -2
  619. package/dist/xml/build/document-root.d.ts +7 -0
  620. package/dist/xml/build/document-root.d.ts.map +1 -0
  621. package/dist/xml/build/index.d.ts +0 -5
  622. package/dist/xml/build/index.d.ts.map +1 -1
  623. package/dist/xml/build/record-element.d.ts +15 -0
  624. package/dist/xml/build/record-element.d.ts.map +1 -0
  625. package/dist/xml/build/record-element.types.d.ts +12 -0
  626. package/dist/xml/build/record-element.types.d.ts.map +1 -0
  627. package/dist/xml/build/write-xml-records.d.ts +7 -0
  628. package/dist/xml/build/write-xml-records.d.ts.map +1 -0
  629. package/dist/xml/build/write-xml-records.types.d.ts +11 -0
  630. package/dist/xml/build/write-xml-records.types.d.ts.map +1 -0
  631. package/dist/xml/build/xml-element.d.ts +79 -0
  632. package/dist/xml/build/xml-element.d.ts.map +1 -0
  633. package/dist/xml/build/xml-element.types.d.ts +34 -0
  634. package/dist/xml/build/xml-element.types.d.ts.map +1 -0
  635. package/dist/xml/build/xml-writer.constants.d.ts +24 -0
  636. package/dist/xml/build/xml-writer.constants.d.ts.map +1 -0
  637. package/dist/xml/build/xml-writer.d.ts +40 -0
  638. package/dist/xml/build/xml-writer.d.ts.map +1 -0
  639. package/dist/xml/build/xml-writer.types.d.ts +34 -0
  640. package/dist/xml/build/xml-writer.types.d.ts.map +1 -0
  641. package/dist/xml/dom/index.d.ts +3 -0
  642. package/dist/xml/dom/index.d.ts.map +1 -0
  643. package/dist/xml/dom/xml-document-from-file.d.ts +10 -0
  644. package/dist/xml/dom/xml-document-from-file.d.ts.map +1 -0
  645. package/dist/xml/dom/xml-document-from-file.types.d.ts +5 -0
  646. package/dist/xml/dom/xml-document-from-file.types.d.ts.map +1 -0
  647. package/dist/xml/index.d.ts +1 -0
  648. package/dist/xml/index.d.ts.map +1 -1
  649. package/dist/xml/inspect-xml.d.ts +2 -0
  650. package/dist/xml/inspect-xml.d.ts.map +1 -1
  651. package/dist/xml/parse/index.d.ts +1 -1
  652. package/dist/xml/parse/index.d.ts.map +1 -1
  653. package/dist/xml/parse/parse-xml-document.constants.d.ts +5 -0
  654. package/dist/xml/parse/parse-xml-document.constants.d.ts.map +1 -0
  655. package/dist/xml/parse/parse-xml-document.d.ts +13 -2
  656. package/dist/xml/parse/parse-xml-document.d.ts.map +1 -1
  657. package/dist/xml/parse/parse-xml-document.types.d.ts +7 -2
  658. package/dist/xml/parse/parse-xml-document.types.d.ts.map +1 -1
  659. package/dist/xml/parse/parser.constants.d.ts +7 -0
  660. package/dist/xml/parse/parser.constants.d.ts.map +1 -0
  661. package/dist/xml/parse/parser.d.ts.map +1 -1
  662. package/package.json +88 -10
  663. package/skills/dialecte/SKILL.md +345 -0
  664. package/skills/dialecte/references/api.json +1830 -0
  665. package/skills/dialecte/references/api.md +557 -0
  666. package/skills/dialecte/references/core-api.md +205 -0
  667. package/skills/dialecte/references/testing.md +116 -0
  668. package/skills/dialecte-contributing/SKILL.md +374 -0
  669. package/skills/dialecte-contributing/references/code-rules.md +115 -0
  670. package/skills/dialecte-contributing/references/landing-changes.md +87 -0
  671. package/skills/dialecte-contributing/references/lot-in-a-package.md +45 -0
  672. package/skills/dialecte-contributing/references/perf.md +40 -0
  673. package/skills/dialecte-contributing/references/traps.md +109 -0
  674. package/skills/dialecte-lot/SKILL.md +526 -0
  675. package/skills/dialecte-lot/references/briefs.md +161 -0
  676. package/skills/dialecte-lot/references/model-tiers.md +52 -0
  677. package/skills/dialecte-lot/references/retro.md +51 -0
  678. package/skills/dialecte-lot/references/standard-check.md +45 -0
  679. package/skills/dialecte-lot/references/stations.md +110 -0
  680. package/dist/project/io/import-document.d.ts +0 -7
  681. package/dist/project/io/import-document.d.ts.map +0 -1
  682. package/dist/test/assert-xml/types.d.ts +0 -2
  683. package/dist/test/assert-xml/types.d.ts.map +0 -1
  684. package/dist/utils-DJN0Md0v.js +0 -624
  685. package/dist/xml/build/build-xml-document.d.ts +0 -10
  686. package/dist/xml/build/build-xml-document.d.ts.map +0 -1
  687. package/dist/xml/build/build-xml-document.types.d.ts +0 -22
  688. package/dist/xml/build/build-xml-document.types.d.ts.map +0 -1
  689. package/dist/xml/build/download-file.d.ts +0 -7
  690. package/dist/xml/build/download-file.d.ts.map +0 -1
  691. package/dist/xml/build/formatter.d.ts +0 -2
  692. package/dist/xml/build/formatter.d.ts.map +0 -1
  693. package/dist/xml/build/serialize.d.ts +0 -11
  694. package/dist/xml/build/serialize.d.ts.map +0 -1
  695. package/dist/xml/build/serialize.types.d.ts +0 -12
  696. package/dist/xml/build/serialize.types.d.ts.map +0 -1
@@ -0,0 +1,374 @@
1
+ ---
2
+ name: dialecte-contributing
3
+ description: Change Dialecte itself - @dialecte/core, a dialecte package, the generator (create) or the type-perf CLI (cli). Covers how the repos are split, the placement decision (core vs dialecte hook vs dialecte extension vs helper vs consumer code), the red-first table-driven workflow, the Definition of Done gates (check, format, build, test, doc:build, docs + CHANGELOG), mutation testing and its survivors (`dialecte mutants`), the team code rules, the verification traps that give false greens, and how a change is handed over (a commit-by-lots hand-over the user runs, never pushed by the agent). Use it whenever the working directory is inside a dialecte repo, the task says "add to core", "new hook", "new extension method", "fix dialecte", "bump core in a dialecte package", or a consumer feature is blocked on a missing dialecte capability. Load the dialecte skill too for the API map; for a dialecte's own schema knowledge also load its skill (dialecte-<id>).
4
+ license: MIT
5
+ metadata:
6
+ author: dialecte
7
+ version: '0.1.0'
8
+ audience: contributor
9
+ ---
10
+
11
+ <!-- dialecte-skills workspace -->
12
+
13
+ # Dialecte (changing it)
14
+
15
+ Read the `dialecte` skill first: its layer model and reuse ladder apply here even more, because
16
+ in the repo you can see everything and are tempted to write a new primitive next to an old one.
17
+
18
+ Dialecte is treated as **greenfield**: internal and public APIs may change for clarity or speed.
19
+ When you see something that can be cleaner, faster or shared, do it in the same change rather than
20
+ leaving a note. A **breaking** change to public API or behaviour is always allowed as an option,
21
+ but it is proposed to the maintainer first (what breaks, why, alternatives) - never slipped in,
22
+ never avoided out of caution.
23
+
24
+ ## The repos
25
+
26
+ Each package is its own git repo; work with them checked out side by side (one folder,
27
+ optionally `$DIALECTE_ROOT`).
28
+
29
+ | Repo | Role | Notes |
30
+ | ------------------- | --------------------------------------------- | ----------------------------------------------------------------------------------------- |
31
+ | `core` | schema-agnostic engine | no domain knowledge, ever; tests run on a dummy test schema |
32
+ | `scl`, `nsd`, `plc` | dialecte packages | `src/<version>/` = generated `definition/` + hand-written config, hooks, extensions, test |
33
+ | `create` | XSD → definition generator + package template | Python XSD reader (via Pyodide) + TS derivation; `npm create @dialecte` |
34
+ | `cli` | `dialecte` dev CLI | type coverage, type bench, narrowing, readability audit |
35
+ | `playground` | Vue/Monaco sandbox | run a script against a document; `DIALECTE_LOCAL=../x npm run dev` |
36
+
37
+ All of them are **npm** projects formatted with **oxfmt**, linted with **oxlint**, tested with
38
+ **vitest**: in core, in Node on the in-memory store, and in Playwright Chromium for the tests that
39
+ need a browser ([Test tiers](#test-tiers)). Never run pnpm or prettier inside them.
40
+
41
+ Inside a dialecte package (`src/<version>/`):
42
+
43
+ ```
44
+ definition/*.generated.ts DEFINITION, constants, types - generated by create, never hand-edited
45
+ config/ dialecte config, namespaces, `namespace <Name>` hydrated types
46
+ constants/ domain registries and literals repeated in several places
47
+ errors/ defineErrors catalogue, import warning catalogue
48
+ helpers/ pure record readers
49
+ hooks/<hook-name>/ one sub-file per concern, merged into that hook's result
50
+ hooks/shared/ logic shared by several hooks and by import
51
+ hooks/io/ two-pass import session (collect, then resolve)
52
+ extensions/<ns>/{query,transaction}/<verb>.ts business verbs, one per file
53
+ extensions/<ns>/public.ts constants/guards/types offered to consumers
54
+ test/ run<Name>TestCases, fixture validators
55
+ ```
56
+
57
+ ## Where does the change go? Decide and say it before coding
58
+
59
+ Walk it top-down, stop at the first yes:
60
+
61
+ 1. **Does it already exist?** Run the reuse ladder from the `dialecte` skill across core AND the
62
+ dialecte package (grep `extensions/*/{query,transaction}/index.ts`, `hooks/*`, `hooks/shared`,
63
+ core `helpers/index.ts`, `utils/index.ts`). Test tooling and fixtures included.
64
+ 2. **Must it happen on every write or import, whoever writes?** → a **hook** in the dialecte
65
+ package (`hooks/<hook>/<concern>.ts`). Coherence (ids, names derived from references, cleanup of
66
+ orphans) is a hook, not a verb the caller must remember.
67
+ 3. **Is it a domain verb every consumer of this schema could use?** → an **extension** in the
68
+ dialecte package (`extensions/<ns>/query|transaction/<verb>.ts`).
69
+ 4. **Is it schema-agnostic engine behaviour** (traversal, mutation, IO, store, a missing hook
70
+ point)? → **core**. Typed against the generic record model, tested on the dummy test schema.
71
+ 5. **Only this app needs it?** → consumer code (custom extension in the app), not a dialecte change.
72
+
73
+ Two smells: a domain rule in core; a query whose only job is to feed a transaction (let the
74
+ transaction read the definition directly).
75
+
76
+ **Standard vs custom rule** (for a dialecte that implements a standard): the engine implements what
77
+ the standard says, and that is the default. A rule an expert wants that the standard does not
78
+ require is a consumer choice (an option on the verb or a policy hook, default = the standard). A
79
+ rule that contradicts the standard stays out of the engine (consumer override).
80
+
81
+ ## Reading the standard
82
+
83
+ The standard check is part of every lot: `dialecte-lot` references/standard-check.md (markdown first, the
84
+ converted text kept private, the cross-check for a decision that changes what the engine does or accepts, and
85
+ what the station records for the hand-over card).
86
+
87
+ ## The workflow
88
+
89
+ 1. **Orient**: read the nearest existing example of what you build (an extension in the same
90
+ package, a hook sub-file, its test) and the package's `doc/` page for the surface. Copy shapes,
91
+ don't invent them. A new extension verb starts from `npx dialecte new verb <namespace>
92
+ <query|transaction> <name>`: it writes the function, its `.types.ts`, a red table case marked
93
+ `only`, the barrel export and the namespace registration, and lists the `FILL:` placeholders
94
+ (`skills check` refuses them until written).
95
+ 2. **Red first, proven by the cli**: the tests come first, from the spec, before any production code:
96
+ a test written after the code can be shaped to please it. Write the table cases (the `dialecte`
97
+ skill's references/testing.md); where the code does not exist yet, a stub with its real type whose body
98
+ throws `new Error('not implemented: <name>')`, called inside an `expect(...)` a matcher completes.
99
+ Remove every focus marker (`.only`, `only: true`) **before** the red: `tdd red` refuses a file holding
100
+ one, and removing it after would be an edit after red. Then `npx dialecte tdd red`: each new or changed
101
+ case must fail on an assertion (or the stub's error inside `expect`); a pass, a missing export, a type
102
+ or syntax error, a timeout is refused with its kind - fix the test. Then the minimum code, the test code
103
+ untouched (tests, helpers, fixtures, snapshots), until `npx dialecte tdd green` (test code edited after
104
+ its red is refused there; snapshots are never written by the run: write a snapshot test's snapshot
105
+ before the red). `npx dialecte tdd status` shows where each case stands. With sub-agents, the test, the
106
+ test review and the code are three agents (`dialecte-lot`, Station 1). Tests share a loaded machine: a
107
+ test owns its temporary folder, and a time bound carries slack and never counts a worker's start; a test
108
+ that reads the disk, spawns a process or measures time carries an explicit bound, named
109
+ (`SOURCE_SCAN_TIMEOUT_MS` in core's `src/test/test-timing.constants.ts`) and several times what the test
110
+ takes on a quiet machine; the test review and the review check that every such test has one. A suite that
111
+ spawns git clears the inherited `GIT_*` variables before any test (a setup file in the `setupFiles` of
112
+ every vitest project that runs the suite - read the config, add one when none does it), for the code
113
+ under test as much as for its own calls: under a commit hook in a worktree they point at the outer repository
114
+ ([references/traps.md](references/traps.md), Tests).
115
+ 3. **Implement under the code rules**: [references/code-rules.md](references/code-rules.md).
116
+ Read it before writing the first line; most review comments come from it. `npx dialecte rules`
117
+ checks them on the changed files.
118
+ 4. **Gates** (below): `gate --fast` and `npx dialecte rules` per step (fix every `rules` error before the
119
+ review), `gate --full` once per lot, then `dialecte contrib` (`@dialecte/cli` 0.3.0); docs + CHANGELOG if the
120
+ surface changed.
121
+ 5. **Independent review**: have a fresh reviewer (a sub-agent with only the spec, the diff and
122
+ these rules, or a human) read the diff against the previous version before hand-over. Self-review
123
+ re-reads your own intent and misses weakened assertions and unusable types.
124
+ 6. **Hand over** through `npx dialecte handover <lots.json>`: the agent writes only the lots file, the
125
+ command writes the hand-over folder and prints the card the user gets
126
+ ([references/landing-changes.md](references/landing-changes.md)). The agent never commits or pushes.
127
+
128
+ Run as a `dialecte-lot` lot, each station gains the package's own steps: [references/lot-in-a-package.md](references/lot-in-a-package.md)
129
+ (the mutation switch, `dialecte rules`, `dialecte contrib`, `mutants status`, merges onto a moved main).
130
+
131
+ ## Test tiers
132
+
133
+ In a package whose vitest config has a `node` project (core), a test runs in one of two tiers.
134
+
135
+ - **Node by default.** Every test file runs in the `node` project, on the in-memory store, unless it is
136
+ declared browser-only. Iterate with `npx vitest run --project node <path>`. The files of
137
+ `NODE_STORE_CONTRACT_TEST_FILES` (the store contract, the IndexedDB-specific tests) run in the
138
+ `node-indexeddb` project instead, on fake-indexeddb: `npx vitest run --project node-indexeddb <path>`.
139
+ A new IndexedDB-specific test goes in that list AND in `BROWSER_ONLY_TEST_FILES` (real IndexedDB
140
+ once per lot).
141
+ - **Browser only for a browser API** (`navigator.storage`, OPFS, a worker, real IndexedDB, the page's
142
+ `DOMParser`, the save dialog or a download link): add the file to `BROWSER_ONLY_TEST_FILES` in
143
+ `vitest.config.constants.ts`, `{ path, why }`, the `why` naming that API. Iterate with
144
+ `npx vitest run --project browser <path>`. A file that reads the package from disk or starts node goes
145
+ to `NODE_ONLY_TEST_FILES` the same way. The config refuses a listed path that names no file.
146
+ - **A difference between the tiers is a bug**, of the store or of the assertion. Never move a test to
147
+ the browser list to hide it, never retry it beyond the one serial rerun every failing run gets (a case that
148
+ fails in one tier only after that rerun is a difference, not a flake). Reproduce it with `--project node`, pin it with a red
149
+ case first: in the store contract (`src/store/contract`) when a store answers differently, beside
150
+ core's assertion helper (`src/test/assert-xml`) when it reads the XML differently between tiers.
151
+ Then fix it. When the test's own assertion depends on something no store promises (an XPath `[1]`
152
+ relying on an order the contract leaves open), fix that assertion in the test instead, with the
153
+ reason in a comment. Then run the file in both tiers (`--project node` and `--project browser-all`).
154
+ - **No test names its store**: the runner's `useTestStorage` chooses (the `node` project's setup file
155
+ sets the in-memory store, the browser keeps the local one). See the `dialecte` skill's
156
+ references/testing.md for the assertions: XML text, XPath for small output, record expectations for
157
+ big files.
158
+
159
+ ## Definition of Done - every change, in the changed package
160
+
161
+ Run it with `npx dialecte gate --fast` while iterating and `npx dialecte gate --full` once per lot,
162
+ from the package root; before the branch merges, also the whole suite in the browser (step 4
163
+ below). The gate runs each step below unfiltered and judges it on its exit code and on the counts
164
+ the step printed (a test step that counts no test fails), prints one line per step,
165
+ restores the generated docs the package declares after the docs build, and refuses to run while a
166
+ hand-over script holds the repository. With `--fast`, a change that touches no test (a doc edit)
167
+ passes the tests step with the note "no test file is affected by the change"; any other run that
168
+ counts no test fails. Paste its lines in your report: they are the real counts. A gate of the same
169
+ mode on a tree it already passed, with the same lock, linked dependencies and steps, runs its hygiene and `tdd`
170
+ step, then answers the rest from that record (`reused`, from cli 0.2.0). `--no-reuse` forces a run: only when the
171
+ person asks, or when something outside the key changed (an edit, a lock or a linked dependency already makes a
172
+ new key).
173
+
174
+ Both modes run a **`tdd` step** after the hygiene: every new or changed test case holds a red receipt and a
175
+ later green one (`dialecte tdd red` / `green`), and the test code (helpers, fixtures, snapshots included)
176
+ is as the last red run froze it; a lot that changes no behaviour (wording, rename, docs) is declared
177
+ exempt by the orchestrator in `.dialecte/lot.json` (`{ "tdd": "exempt: <reason>" }`, never committed),
178
+ and the gate prints how many production and test files the change still touches.
179
+
180
+ `--fast` starts with the worktree's **hygiene**: nothing staged, no stash entry pushed on this
181
+ worktree's branch since `dialecte worktree add` made it (other branches' entries are only noted), and
182
+ every new file declared (`--declare <path>`, one per new file or folder; an undeclared one is a
183
+ warning). A failure names what changed and the read-only commands
184
+ to look at it.
185
+
186
+ **Test runs use the runner's defaults**: full parallelism, no `nice`, no `--maxWorkers`, no
187
+ `--no-file-parallelism`, no lock and no waiting on other sessions' runs or on the load - the machine is shared,
188
+ and that is the user's to manage: when they ask you to limit (to leave room for other sessions), do it for the
189
+ time they say. A run that fails is rerun **once, serially, on its failing files**: the same command, its
190
+ `--project` flags kept so the rerun stays in the failing tier, with the failing files and `--no-file-parallelism`
191
+ added (through an npm script, after `--`). Failing there too, it is a real failure; passing there, it is **flaky in
192
+ parallel** - a defect of the test or the code, reported with its files and fixed at its cause (a wall-clock bound
193
+ tuned on a quiet machine, a shared temporary folder, port or build output, browser state, an inherited environment
194
+ variable), never answered by throttling the next runs. The gate does this rerun itself on a vitest test step: a
195
+ step that passes on it is green and its line says `flaky in parallel` with one `flaky <file>` line per file - read
196
+ the flag on a green gate; one that fails again says `real failure`. A failing step line that says neither comes
197
+ from a cli without the rerun: rerun its files by hand. Such a cli may still hold a machine lock around `--full`,
198
+ its heavy steps and `tdd`: let it wait.
199
+
200
+ **Waiting on a long run** (`gate --full`, a mutation run, a bench): start it in the background with its output in
201
+ a log - your harness's background run, or `cmd > "$log" 2>&1 & echo $! > "$pidfile"` - then wait for the
202
+ harness's completion notice or on that PID (`while kill -0 "$(cat "$pidfile")" 2>/dev/null; do sleep 5; done`),
203
+ with an upper bound tied to the run's expected duration; at the bound, report "timed out" with the log's tail.
204
+ Never wait with `pgrep -f "<text>"` when that text is in your own wait command: the loop finds itself and never
205
+ ends (`pgrep -f "[v]itest run"` if it is unavoidable). When the wait ends, read the exit code and the log's
206
+ summary line: "no process found" is not a pass.
207
+
208
+ Read the step list in the package's `package.json` (`"dialecte": { "gate" }`) when it overrides the
209
+ defaults. The gate, `rules`, `new verb`, `handover` and the `skills` check of step 6 come with `@dialecte/cli`
210
+ 0.2.0 or later. Read the package's pin first (`npm ls @dialecte/cli`): with an older one, every such command
211
+ runs as `npx @dialecte/cli@^0.2.0 <command>` - never `@latest`, which can be older than 0.2.0 and lacks them -
212
+ or the steps by hand:
213
+
214
+ 1. `npm run check` - type-checks sources AND tests, lint, format. Never a bare `tsc --noEmit`
215
+ (`tsconfig.json` is a solution file and checks nothing).
216
+ 2. `npx oxfmt <changed files>`.
217
+ 3. `npm run build` - runs the type-check in parallel and emits declarations (vite-plugin-dts),
218
+ which catches union-assignability errors the editor misses.
219
+ 4. The tests, by tier: `npm run test:node` per step (the fast gate runs its changed files), the
220
+ browser-only list once per lot (`npx vitest run --project browser`, in the full gate), and
221
+ `npm run test:browser:all` - the whole suite in the browser - once before the branch merges. A failing run of
222
+ any tier first gets its one serial rerun (above); a case that still fails there while it passes in the other
223
+ tier is a tier difference - a bug, never retried further, never hidden ([Test tiers](#test-tiers)). A package without a `node` project: `npx vitest run`
224
+ (`npm run test` is watch mode in some packages; create uses `npm run test:ts` + `test:py`).
225
+ One file while iterating: [Test tiers](#test-tiers).
226
+ 5. `npm run doc:build` - the VitePress docs build. From cli 0.3.0 a dialecte package
227
+ (`"dialecte": { "profile": "contributor" }`) runs it, with the type bench, the code rules and the release
228
+ check, in `npx dialecte contrib` after a green `gate --full` and before the hand-over, whose `contrib`
229
+ guard refuses a tree without a green record of it.
230
+ 6. `npm run skills:generate`, then `npm run skills:check` - every change, not only one that touches a skill:
231
+ the check fails on a name, path or script a skill cites that no longer exists, and on a public function
232
+ without its JSDoc summary and `@intent` (below). The scripts run the package's pinned cli; with a pin
233
+ older than 0.2.0 they check neither, so run `npx @dialecte/cli@^0.2.0 skills generate` and
234
+ `npx @dialecte/cli@^0.2.0 skills check` instead (it fails loudly while 0.2.0 is unpublished, never falls
235
+ back to an older cli).
236
+
237
+ If public API or user-visible behaviour changed, it is not done until you also:
238
+
239
+ - give every new public function or method a JSDoc whose first paragraph says what a caller gets, and an
240
+ `@intent` tag - comma-separated phrases naming what a caller is trying to do when they reach for it
241
+ (`@intent validate an exported file against its XSD, find what a document breaks`) - even when the
242
+ functions beside it carry none. Public means any function exported from an entry of the package's
243
+ `package.json` `exports` (every entry: the main one, `./utils`, `./helpers`, `./sqlite`, `./test` - other
244
+ packages' suites import the test entry - a dialecte's version entry) and any method reached from `project`,
245
+ `doc`, `doc.query` or `tx`. The skills' API index (`skills/dialecte/references/api.md`, `api.json`, what
246
+ `dialecte api find` answers from) is built from these two: a function without them is one the next agent
247
+ cannot find, and writes again. An export not meant for callers is tagged `@internal` instead and stays out
248
+ of the index;
249
+ - update the `doc/` page that describes that surface (types, verbs, contracts),
250
+ - add a line under `## UNRELEASED` in the package's `CHANGELOG.md`, written for the user, and
251
+ - update the package's `skills/` when the change touches what a skill describes (API, hooks,
252
+ extensions, scripts, layout, rules); `npm run skills:generate` refreshes the generated tables, and the
253
+ check runs in the gate (step 6).
254
+
255
+ Type performance: `npm run type-bench:check` compares type instantiations with
256
+ `benchmarks/types/baseline.json` (one per version folder in a dialecte package:
257
+ `benchmarks/types/<version>/baseline.json`; 5 % gate). A breach is a **think point**, not a wall: measure
258
+ and explain the growth; if it is legitimate, re-baseline with `npm run type-bench` in its own lot.
259
+ Never hand-edit `baseline.json`, never twist code to dodge the gate.
260
+
261
+ Run slow gates (create's `npm run proof`, corpora) once per lot before hand-over, not after every fix.
262
+ Fast targeted runs while iterating. Mutation testing runs beside the lot instead (below).
263
+
264
+ ## Mutation testing
265
+
266
+ In a package that declares a mutation scope (`package.json` `"dialecte": { "mutation" }`), `dialecte mutants`
267
+ (`@dialecte/cli` 0.2.0) runs StrykerJS on it and keeps every survivor in a ledger until it is handled; `dialecte
268
+ mutants` with no verb prints each verb's usage. The scripts do the bookkeeping, so your tokens go to judgment only.
269
+
270
+ - **The switch is per lot**, in `.dialecte/lot.json`: `dialecte lot mutation off|changed|audit|gate`. Without it, a
271
+ lot whose diff touches the scope runs `changed` (its changed lines), any other lot `off`. `gate` is for a
272
+ robustness lot only: its hand-over waits for a run reported on the tree it commits, so it runs again after the
273
+ last fix. `audit` mutates the whole scope.
274
+ - **Off the critical path.** Start `dialecte mutants run` as a background run of your harness (the cli has no
275
+ background flag): the run is written `running` in the store before Stryker starts, so a killed session leaves a
276
+ `died` run, never nothing. Go on working (to wait on it: Waiting on a long run, above). A hand-over does not wait
277
+ for it, except a `gate` lot's; a merge does.
278
+ - **Before every hand-over and every merge: `dialecte mutants status`.** Pending items block the card and the
279
+ `handover run` guard: `new` survivors of the package (whatever their lot), `died` runs, and a `running` run of the
280
+ branch for a merge or a `gate` lot (on a plain hand-over it is a `!`). `scheduled` survivors belong to their
281
+ follow-up lot and do not block.
282
+ - **Judge one file at a time**: `dialecte mutants judge [--file <file>] --json` gives each file's packet (code,
283
+ covering tests, a family guess). Per survivor, one of:
284
+ - a test that kills it (a `gap`: red first like any test), then run again;
285
+ - `dialecte mutants record --key <key> --family <family> --reason "<why>"`, the reason saying in 200 characters at
286
+ most why no tested behaviour changes. An `invariant-guard` or `fallback-never-taken` also gets a follow-up lot
287
+ that deletes the guard or tightens the type: `dialecte mutants schedule <follow-up lot> <key>` first, then
288
+ `record ... --removable` (a scheduled survivor keeps its follow-up when recorded; a recorded one can no longer be
289
+ scheduled);
290
+ - `dialecte mutants schedule <follow-up lot> <key>` when another lot owns it.
291
+
292
+ The families are a closed list, the words of the judgment: `invariant-guard` (a check the types, or internal
293
+ callers only, already guarantee), `fallback-never-taken` (a default no input reaches), `exhaustive-default` (the
294
+ default of a switch that covers every case), `no-op-on-empty` (a skip of work that would do nothing),
295
+ `perf-shortcut` (a cache or an early exit that only saves time), `static-init` (module-level setup),
296
+ `schema-default-read` (a read of a value the schema already defaults), `wording` (message or log text). None
297
+ fits: it is a `gap`. Judge on the standard tier; the strong tier only for a `gap` with no obvious test.
298
+
299
+ - **The cli is the only writer** of `.dialecte/mutation-records.json` and of the store under
300
+ `<git-common-dir>/dialecte-mutation/`: never edit either by hand (nor anything else under `.git`).
301
+ - **Runs**: a `died` run is rerun, or `dialecte mutants abandon <run id>`; `dialecte mutants drop <run id>` removes
302
+ only an abandoned run or a reported one the ledger took in.
303
+ - **Full audit** (`dialecte mutants run --mode audit`): before a release or on request, in the background; its
304
+ survivors are scheduled as named follow-up lots, not fixed in the release.
305
+
306
+ A lot that builds tooling with shared state or drives an external tool has its own traps (plan it as a transition
307
+ table, one real run in a scratch clone, cited third-party values): [references/traps.md](references/traps.md), Tools
308
+ with shared state.
309
+
310
+ ## Cross-package changes
311
+
312
+ A dialecte package depends on a **published** core version (an installed copy, not a symlink). A
313
+ core change is invisible to the package until you: build core → put its build where the package
314
+ resolves it (`npm install ../core` in the package, a symlink
315
+ `<package>/node_modules/@dialecte/core -> ../../../core`, or a copied `dist/`) → delete the package's
316
+ `node_modules/.vite` (vitest pre-bundles deps and keeps the old core). Before committing, the
317
+ package must depend on a released core version again; never commit the link. Release order: core
318
+ first, then the packages that pin it, each with its own bump lot.
319
+
320
+ ## Verification traps (false greens)
321
+
322
+ Read [references/traps.md](references/traps.md) before trusting any gate output. The short list:
323
+ solution tsconfig checks nothing; tests have their own tsconfig; stale `.vite` cache after a core
324
+ swap; output-compacting shell wrappers can turn a failing gate into "ok" (run verdict gates raw and
325
+ read the counts); a doc build can rewrite a generated data file (restore it before the hand-over
326
+ script is written); before `@dialecte/cli` 0.2.0, `dialecte bench --help` runs the
327
+ bench and writes the baseline; a test that passes on its first run may be green by accident.
328
+
329
+ ## Skills ship with the code
330
+
331
+ Each package carries the skills that describe it in `skills/<name>/` (published in its npm tarball):
332
+ core has `dialecte`, `dialecte-contributing` and `dialecte-lot`, create `dialecte-create`, and every dialecte
333
+ package its own `dialecte-<id>` with the knowledge of its schema. A skill changes in the same PR as the code it describes - never
334
+ in another repository afterwards. `@dialecte/cli` maintains them:
335
+
336
+ | Command | Does |
337
+ | -------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
338
+ | `dialecte skills sync` | installs the skills of the app's dependencies into `.claude/skills` + `.agents/skills` (`--agent claude,copilot,agents`, `--copy`); consumer skills only unless `--contributing` (remembered); `--from <workspace> --contributing` takes every skill from local checkouts |
339
+ | `dialecte skills generate` | rewrites the `<!-- dialecte-skills:generated ... -->` blocks (verb map, method and export index, hook files) from the source |
340
+ | `dialecte skills check` | frontmatter, links, and every API / path / npm script a page cites must exist; generated blocks must be fresh; every public function and method has a JSDoc summary and an `@intent`; `--workspace <dir>` also verifies pages that describe several repositories |
341
+
342
+ Write claims so the check can verify them: API as `query.<method>` / `tx.<ns>.<verb>`, paths
343
+ relative to a package, scripts as `npm run <script>`. A deliberate mention of something outside the package goes in
344
+ `<!-- dialecte-skills ignore: token -->`.
345
+
346
+ ## Performance work
347
+
348
+ Measure, don't guess: [references/perf.md](references/perf.md) (perf helper, node bench harness,
349
+ browser timeline, CPU profile). Classic regressions to avoid in review: per-element ancestor walks,
350
+ per-element queries without a cache, re-reading the same records in several passes, store reads
351
+ during import (import is in-memory two-pass by design, see the hooks rules in the `dialecte` skill).
352
+
353
+ ## Never
354
+
355
+ - Edit a `*.generated.ts` file (regenerate with `dialecte-create`).
356
+ - Add a domain rule to core because it was convenient.
357
+ - Restate a registry or the definition by hand (see code-rules).
358
+ - Commit, push, or touch a repo's git index while a hand-over script may be running.
359
+ - Name a tool that consumes the package in a committed file or message ([code-rules](references/code-rules.md)).
360
+ - Leave a known improvement as a "note for later" without doing it or explaining why you cannot.
361
+
362
+ ## Retro gate - before you hand over
363
+
364
+ List in your hand-over every place where this skill was wrong, missing or misleading for the task,
365
+ and every correction the user made that a skill should have prevented. Then:
366
+
367
+ - **Inside a dialecte repository**: draft each skill edit as before/after and show it to the user; an
368
+ approved edit goes in the same change (skills ship with the package that owns the code), through
369
+ the skill-creator skill (`anthropic-skills:skill-creator`) loaded - the eval case first, failing on the text
370
+ before the change, as `dialecte-lot` describes - then `npm run skills:generate` and `npm run skills:check`.
371
+ - **In an app**: draft an issue for the package that ships the skill - the statement that was wrong
372
+ or missing, the evidence (file, behaviour), the wording you propose - and show it to the user.
373
+ Post it only with their approval.
374
+ - Nothing to report: write "skill retro: nothing".
@@ -0,0 +1,115 @@
1
+ <!-- dialecte-skills workspace -->
2
+
3
+ # Code rules for dialecte repos
4
+
5
+ These are review-blocking. Each has a reason; the reason tells you what to do in a case the rule
6
+ does not name.
7
+
8
+ ## Contents
9
+
10
+ - Reuse and sources of truth
11
+ - Function shape
12
+ - Files and types
13
+ - Naming
14
+ - Comments and committed text
15
+ - Self-check before hand-over
16
+
17
+ ## Reuse and sources of truth
18
+
19
+ - **Search before every helper**, test tooling included. Grep the concern in
20
+ `extensions/*/{query,transaction}/index.ts`, `hooks/*`, `hooks/shared/`, core `helpers/` and
21
+ `utils/`. When you add a function, be ready to name the existing method that could replace it
22
+ and why it does not fit.
23
+ - **No new source of truth.** Before declaring a list (`const X = [...] as const`) look for it in
24
+ the definition (`ATTRIBUTES`, `CHILDREN`, `PARENTS`, identity fields, keyrefs) or in a registry
25
+ (its keys, its `target` tags). Declare only what neither knows, and declare it once: types derived
26
+ from the runtime list. A table that repeats registry content drifts silently.
27
+ - **Read derived views at the use site** instead of copying them; never `const LOCAL = GLOBAL` just
28
+ to rename.
29
+ - **Repeated literals and tag sets** go to the package `constants/` and are imported everywhere;
30
+ derive the union type with `(typeof LIST)[number]`.
31
+ - **Use Dialecte's attribute API**: `query.getAttributes(ref)` / `getAttribute(ref, { name })`, or
32
+ `readAttribute(s)` without a query. No `record.attributes.find(...)` helpers.
33
+ - **Accept a `query` / `tx`** in domain functions so they reuse the primitives, rather than taking
34
+ pre-fetched data and re-implementing lookups.
35
+
36
+ ## Function shape
37
+
38
+ - **Object parameters.** `fn(query, { targetParent, tagName, matchKey })`, not positional. The only
39
+ thing outside the object is a leading `query` / `tx`. A positional signature (a single obvious
40
+ `ref`, a symmetric `equals(a, b)`) is discussed with the maintainer first.
41
+ - **Named `function` declarations**, also for local helpers. Arrows only for tiny inline callbacks
42
+ (`.map`, `.filter`, `.some`). A closure over a local value becomes a module-level named function
43
+ taking that value as a parameter.
44
+ - **No `await` nested in an argument.** `const instances = await findInstances(query, {...})`,
45
+ then pass `instances`.
46
+ - **Immutable, explicit.** Return new values, no hidden state, no mutation of records you received.
47
+ - **Never `any`.** Use the `Any*` core types (`AnyDialecteConfig`, `AnyRawRecord`, ...) in core, the
48
+ hydrated domain types (`<Name>.*`) in a dialecte package. Narrow types as far as they go.
49
+ - **Extension methods** take `Core.Query<Config>` / `Core.Transaction<Config>` as first parameter
50
+ (not the hydrated `<Name>.Query`: type cycle). A sibling is called by import, passing the same
51
+ query. A helper not exported from the folder's `index.ts` is not a method.
52
+
53
+ ## Files and types
54
+
55
+ - **One function per file**, test co-located: `<name>.ts`, `<name>.test.ts`.
56
+ - **Types live in `<name>.types.ts`** next to the code - never exported or domain types inline in
57
+ the implementation file. Exception: no `.types.ts` for a one-line alias that just renames an
58
+ existing type; use the underlying type directly.
59
+ - **Module constants live in `<name>.constants.ts`** (or the extension's `constants/`).
60
+ - **Group by domain, not by technical layer.** Types folders hold only definitions.
61
+ - **Zero runtime cost** for type machinery; watch the type bench when adding generic types.
62
+
63
+ ## Naming
64
+
65
+ - Full, readable camelCase words: `attribute`, not `attr`; `(attribute) => attribute.name`, not
66
+ `(a) => a.name`. Existing API names like `ref` are fine; your own variables say what they are.
67
+
68
+ ## Comments and committed text
69
+
70
+ - Explain the behaviour so the comment stands on its own; a reader without your plan or ticket
71
+ must understand it.
72
+ - **No plan, lot, phase, ticket or acceptance-criterion tags** (a step id, a lot number, an
73
+ acceptance-criterion id, an issue number) in code, comments, tests, docs, CHANGELOG or commit messages. They belong in plans and PR
74
+ descriptions.
75
+ - **No citations of a standard** (a document name with a clause, table, annex or section number)
76
+ in any committed file, commit message, issue, PR or
77
+ review comment. Write the rule itself ("a name stays unique among its siblings"). Citations
78
+ live only in uncommitted plan notes. Naming the standard a library implements (site tagline, the
79
+ XSD it is generated from, the namespace prefixes of the schema, the schema's version ids) is not a citation. Never quote the standard's text anywhere (copyright).
80
+ - **No name of a tool that consumes the package** (an app, a pipeline or a product built on a dialecte) in
81
+ any committed file or commit message - code, comments, tests, skill text and its evals, docs, CHANGELOG. A
82
+ dialecte serves every app alike: say what the behaviour is, not who asked for it ("an app", "a consumer").
83
+ The names live on the machine only, `git config --global dialecte.consumerNames "<name>, <name>"`, never in a
84
+ repository; from cli 0.3.0, `dialecte rules` and `dialecte handover` refuse each as a whole word in a
85
+ contributor package (`consumer tool name`). A file your lot touches that already names one is refused too:
86
+ reword that line only, and list it in the hand-over.
87
+ - Do not create documentation that was not asked for, beyond the docs + CHANGELOG the Definition
88
+ of Done requires.
89
+
90
+ ## Self-check before hand-over
91
+
92
+ ```bash
93
+ npx dialecte rules # the files changed against HEAD and the new ones
94
+ npx dialecte rules <files...> # or the files you name; --json for a program
95
+ ```
96
+
97
+ It reads each file's syntax tree, not lines: an exported type outside a `*.types.ts` file, a module
98
+ constant outside a `*.constants.ts` file, a function declared as a `const`, an `await` inside an
99
+ argument, a plan or ticket tag or a standard citation (the package's own patterns included) are
100
+ errors; positional parameters beyond a leading `query` / `tx` and abbreviated names are warnings. Fix
101
+ every error; answer every warning (fix it, or say in the hand-over why the shape is right). It exits 1
102
+ on an error. A finding that is wrong is a cli bug: report it, do not work around it.
103
+
104
+ `rules` comes with `@dialecte/cli` 0.2.0 or later. Without it, the same checks as greps (not
105
+ tests/types/constants files for the first two); the last two mirror the patterns `rules` and
106
+ `handover` share (the cli's committed-text constants):
107
+
108
+ ```bash
109
+ grep -nE '^(export )?type [A-Z]|^(export )?interface ' <impl files> # inline types?
110
+ grep -nE '^const [A-Z_]+ ' <impl files> # module constants outside *.constants.ts?
111
+ grep -nE 'const [a-zA-Z]+ = (async )?\(' <files> # arrow-function declarations?
112
+ grep -nE '\((await |.*, await )' <files> # await inside an argument?
113
+ grep -nE '\blot [A-Z0-9]|\bAC[0-9]|#[0-9]{3,}\b' <files> # plan / ticket tags?
114
+ grep -nE '§ ?[0-9]|Tables? [0-9]|Annex [A-Z]|[Cc]lause [0-9]' <files> # standard citations? (a dialecte's skill adds its standard's names)
115
+ ```
@@ -0,0 +1,87 @@
1
+ <!-- dialecte-skills workspace -->
2
+
3
+ # Landing a change: commit-by-lots, human runs it
4
+
5
+ The agent prepares; a human reviews and commits. The agent never runs `git commit`, never pushes,
6
+ and never touches a repo's index (`git add`, `git checkout --`, `git stash`) while a hand-over
7
+ script may be waiting or running in the human's terminal.
8
+
9
+ ## The hand-over
10
+
11
+ The agent writes only a lots file; `npx dialecte handover <lots.json>` does the rest. One lots file per lot
12
+ group, in an uncommitted hand-over folder (for example `_commit-plan/<topic>-<yyyy-mm-dd>/lots.json` at the
13
+ workspace root, outside every repo); the hand-over files are written next to it (`--out <dir>` elsewhere):
14
+
15
+ ```json
16
+ {
17
+ "repository": "/absolute/path/to/the/repository",
18
+ "branch": "feat/the-branch",
19
+ "head": "<sha the lots go on top of>",
20
+ "gates": "the gate lines, one line, with their real counts",
21
+ "lots": [
22
+ { "paths": ["src/feature/"], "message": "feat(scope): the behaviour\n\nThe body." },
23
+ { "paths": ["CHANGELOG.md"], "message": "docs(changelog): the behaviour" }
24
+ ]
25
+ }
26
+ ```
27
+
28
+ - **Lots**: paths are files, or folders ending with `/`. Every lot is build-safe on its own (compiles,
29
+ tests green) and does not reference a later lot. Typical order: types/constants → implementation +
30
+ tests → docs → CHANGELOG → bench re-baseline (own lot) → release bump (own lot).
31
+ - **A branch lands on main through a merge lot**, in a lots file whose `repository` is the main checkout:
32
+ `{ "kind": "merge", "branch": "<branch>", "tip": "<sha>", "resolved": {}, "message": "merge: ..." }` -
33
+ a merge commit, never a fast-forward. `resolved` maps each conflicting path to the file holding its
34
+ resolution (`null` removes it). The run needs the merge's `tree`, which the rehearsal prints (`tree <sha>`):
35
+ copy it into the lot as `"tree"`, then `--rehash`.
36
+ - **Never in a lot**: generated docs data (`.vitepress/data/*`), lockfiles and version bumps (unless
37
+ the lot is the release lot), local links to sibling repos. Restore them before the hand-over
38
+ (`git checkout -- <file>` while no hand-over waits): a changed file in no lot makes `handover` refuse.
39
+ - **Interrupted?** A run stopped after staging a lot is refused at its next start with the command that
40
+ unstages those files, with its `cd`: give it to the user.
41
+ - **Guards**, checked when the folder is written (nothing is written on a refusal) and again when it
42
+ runs: the branch and HEAD, the hooks folder `core.hooksPath` names exists (a missing one makes git skip
43
+ every hook), `lots.json` as reviewed, an empty index, every changed file in exactly one lot, no plan tag, standard citation or (from cli 0.3.0) name of a
44
+ consuming tool in a lot's files (skill evals and test fixtures included) nor in its messages; when it runs, every file
45
+ against the snapshot taken when it was written, and no other file changed; and, in a contributor package (cli 0.3.0), a green `dialecte contrib` record of the tree the lots
46
+ leave (guard `contrib`; a rehearsal runs contrib in its clone when there is none).
47
+ - **The folder**: the lots file, the snapshot (`files.txt`, `files.sha256`, `files.deleted`) and a one-line
48
+ `commit.sh` that runs `npx --no-install @dialecte/cli handover run <folder>` (it re-executes itself with
49
+ bash: people run it with `sh`). Nothing per lot. The repository stays locked for `dialecte gate` until
50
+ every lot is committed.
51
+ - **The run** prints each guard with its result and time, then `lot n/N`, the hook's output behind `│`
52
+ with a heartbeat while it is silent, each commit with its stat, and the card at the end; it never
53
+ pushes. A lot whose commit fails is unstaged again; the same command resumes after the lots already
54
+ committed.
55
+ - **Rehearse** when the repository has a commit hook: `npx dialecte handover run <folder> --rehearse`
56
+ commits the lots in a scratch clone holding the working tree, the hooks folder and a copy of
57
+ `node_modules`, then removes it (`--keep` keeps it). From cli 0.2.0 it rehearses only what can find
58
+ something new and prints why per lot. A plain lot is not rehearsed when its exact tree has a green
59
+ `gate --full` (same lock, linked dependencies and command), the lot leaves the lock alone and the hook
60
+ stages no files. A merge is not rehearsed when its tree is its branch tip's (main has not moved), the
61
+ tip's tree has a green record (the branch commit's hook or a `gate --full`) and the merge leaves the lock
62
+ alone; it still prints the merge's `tree <sha>`. Anything else is rehearsed: a merge onto a moved main, a
63
+ lock change, a hook that stages files. Paste the per-lot lines with the card; `--full` forces every lot
64
+ and is for when the person asks. A heavy hook that does run is rehearsed while another suite loads the
65
+ machine, as it will be when the user commits; when that is not possible, the hand-over notes the machine's
66
+ load at rehearsal time (`uptime`). The real commit's hook always runs.
67
+ - Edited a file after the snapshot (a review fix)? `npx dialecte handover --rehash <lots.json>`.
68
+ - `npx dialecte handover list` shows every hand-over folder with its state (pending, partly committed,
69
+ committed, stale); after a merge, `npx dialecte worktree prune` lists the committed ones with the merged
70
+ worktrees and prints their removal commands: an agent hands them (or the `--yes` command, which asks on
71
+ a terminal) to the user with their `cd`.
72
+ - `handover` comes with `@dialecte/cli` 0.2.0 or later; with an older cli in the package, run
73
+ `npx @dialecte/cli@^0.2.0 handover <lots.json>` (never `@latest`, which can be older).
74
+
75
+ ## Commit messages
76
+
77
+ Conventional style (`feat(scope): ...`, `fix`, `docs`, `chore(bench)`, `chore(release)`), written
78
+ as the behaviour for a reader of the history. No plan/ticket tags, no standard citations.
79
+
80
+ ## Hand-over message
81
+
82
+ From cli 0.3.1 the message points at the hand-over, it does not carry it: `READY`, then
83
+ `cd <worktree> && npx dialecte handover show <name>` (the card recomputed from the records, current whenever
84
+ it is read) and `npx dialecte handover run <name>` (what the person runs); then what was not verified. Never
85
+ a pasted or retyped card: it goes stale as soon as a record changes. With an older cli, the message is the
86
+ card `dialecte handover` printed - repository, worktree, branch, HEAD, gates, the lots with their files and
87
+ messages, and the command to run with its absolute `cd` - pasted as printed, never retyped.
@@ -0,0 +1,45 @@
1
+ <!-- dialecte-skills workspace -->
2
+
3
+ # A lot in a dialecte package
4
+
5
+ The `dialecte-lot` stations run the same in every repository. In a dialecte package - `"dialecte": { "profile":
6
+ "contributor" }` in its `package.json`: core, a dialecte, create, cli - they gain the steps below. An app runs none
7
+ of them: its lot ends at the hand-over.
8
+
9
+ ## Station 0 - the mutation switch
10
+
11
+ - **Mutation switch** (a package that declares a mutation scope): the orchestrator sets it per lot in the worktree's
12
+ `.dialecte/lot.json` with `dialecte lot mutation <mode>` and names it in the brief - the default (`changed` when the
13
+ diff touches the scope, `off` otherwise) for most lots, `gate` only for a robustness lot (its hand-over waits for
14
+ a run reported on the tree it commits: it runs again after the last fix), `audit` on request. The implementer
15
+ starts `dialecte mutants run` in the background once green and judges the survivors as [SKILL.md](../SKILL.md)
16
+ (Mutation testing) says. Before a release, a full audit in the background;
17
+ its survivors become named follow-up lots (`dialecte mutants schedule <follow-up lot> <key>`).
18
+
19
+ ## Station 2 - `dialecte rules`
20
+
21
+ With the fast gate, run `npx dialecte rules` from the package root and fix every error before the review; answer
22
+ every warning ([code-rules.md](code-rules.md)). The implement report's `Gates:` line adds
23
+ `rules <n errors, m warnings>`.
24
+
25
+ ## Station 5 - `dialecte contrib` after the full gate
26
+
27
+ From `@dialecte/cli` 0.3.0, once `gate --full` is green, run `npx dialecte contrib`: `rules` on the files changed
28
+ against HEAD, the package's contrib steps (by default the docs build, its generated docs restored, and the type
29
+ bench), `release` (no dependency named by a local folder) and `mutation` when a scope is declared. A step the full
30
+ gate passed on the same tree and install is not run again (`reused from gate --full`). Paste its lines with the
31
+ gate's. The hand-over's `contrib` guard refuses a tree without a green record of it; a rehearsal runs it in its
32
+ scratch clone when there is none.
33
+
34
+ ## Station 6 - mutation, landing, merges
35
+
36
+ - The landing rules apply: [landing-changes.md](landing-changes.md) (lots, guards, rehearsal, merge lots).
37
+ - In a package with a mutation scope, run `dialecte mutants status`
38
+ before every hand-over and every merge: a `new` survivor or a `died` run blocks the card and the guard until it is
39
+ handled ([SKILL.md](../SKILL.md), Mutation testing); the lot's own run still running blocks only a merge or a `gate`
40
+ lot (on a plain hand-over it is a `!`).
41
+ - A merge onto a main that moved since the cut leaves a tree no check has seen: it is rehearsed. The branch's green
42
+ records say nothing about it - not its suite, nor a gate step the hook does not run (docs, skills check, the
43
+ browser suite). The rehearsal's hook runs the suite on the merged tree; run only the steps the hook does not run,
44
+ in the clone `--rehearse --keep` leaves, never a `gate --full` that would run the suite there again. A `reused`
45
+ line for such a merge is a cli bug to report, never a result to pass on.