chaffjs 0.29.0 → 0.31.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (681) hide show
  1. package/dist/announced-count.d.ts +2 -0
  2. package/dist/announced-count.d.ts.map +1 -1
  3. package/dist/announced-count.js +4 -3
  4. package/dist/announced-count.js.map +1 -1
  5. package/dist/contacts/addresses.d.ts +21 -0
  6. package/dist/contacts/addresses.d.ts.map +1 -0
  7. package/dist/contacts/addresses.js +144 -0
  8. package/dist/contacts/addresses.js.map +1 -0
  9. package/dist/contacts/emails.d.ts +11 -0
  10. package/dist/contacts/emails.d.ts.map +1 -0
  11. package/dist/contacts/emails.js +51 -0
  12. package/dist/contacts/emails.js.map +1 -0
  13. package/dist/contacts/variants.d.ts +14 -0
  14. package/dist/contacts/variants.d.ts.map +1 -0
  15. package/dist/contacts/variants.js +25 -0
  16. package/dist/contacts/variants.js.map +1 -0
  17. package/dist/derived/battery-runtime.d.ts +85 -0
  18. package/dist/derived/battery-runtime.d.ts.map +1 -0
  19. package/dist/derived/battery-runtime.js +217 -0
  20. package/dist/derived/battery-runtime.js.map +1 -0
  21. package/dist/derived/period-counts.d.ts +48 -0
  22. package/dist/derived/period-counts.d.ts.map +1 -0
  23. package/dist/derived/period-counts.js +128 -0
  24. package/dist/derived/period-counts.js.map +1 -0
  25. package/dist/derived/session-hours.d.ts +26 -0
  26. package/dist/derived/session-hours.d.ts.map +1 -0
  27. package/dist/derived/session-hours.js +29 -0
  28. package/dist/derived/session-hours.js.map +1 -0
  29. package/dist/derived/time-lengths.d.ts +37 -0
  30. package/dist/derived/time-lengths.d.ts.map +1 -0
  31. package/dist/derived/time-lengths.js +171 -0
  32. package/dist/derived/time-lengths.js.map +1 -0
  33. package/dist/derived/unit-counts.d.ts +7 -0
  34. package/dist/derived/unit-counts.d.ts.map +1 -0
  35. package/dist/derived/unit-counts.js +13 -0
  36. package/dist/derived/unit-counts.js.map +1 -0
  37. package/dist/derived/use-interval.d.ts +33 -0
  38. package/dist/derived/use-interval.d.ts.map +1 -0
  39. package/dist/derived/use-interval.js +93 -0
  40. package/dist/derived/use-interval.js.map +1 -0
  41. package/dist/derived/working-hours.d.ts +36 -0
  42. package/dist/derived/working-hours.d.ts.map +1 -0
  43. package/dist/derived/working-hours.js +55 -0
  44. package/dist/derived/working-hours.js.map +1 -0
  45. package/dist/detectors/acronym-expansion.d.ts +1 -1
  46. package/dist/detectors/acronym-expansion.d.ts.map +1 -1
  47. package/dist/detectors/acronym-expansion.js +46 -2
  48. package/dist/detectors/acronym-expansion.js.map +1 -1
  49. package/dist/detectors/announced-count.d.ts.map +1 -1
  50. package/dist/detectors/announced-count.js +1 -0
  51. package/dist/detectors/announced-count.js.map +1 -1
  52. package/dist/detectors/capacity-runtime.d.ts +7 -0
  53. package/dist/detectors/capacity-runtime.d.ts.map +1 -0
  54. package/dist/detectors/capacity-runtime.js +98 -0
  55. package/dist/detectors/capacity-runtime.js.map +1 -0
  56. package/dist/detectors/capitalised-term.d.ts +44 -0
  57. package/dist/detectors/capitalised-term.d.ts.map +1 -0
  58. package/dist/detectors/capitalised-term.js +101 -0
  59. package/dist/detectors/capitalised-term.js.map +1 -0
  60. package/dist/detectors/contact-variant.d.ts +3 -0
  61. package/dist/detectors/contact-variant.d.ts.map +1 -0
  62. package/dist/detectors/contact-variant.js +21 -0
  63. package/dist/detectors/contact-variant.js.map +1 -0
  64. package/dist/detectors/count-over-capacity.d.ts +4 -0
  65. package/dist/detectors/count-over-capacity.d.ts.map +1 -0
  66. package/dist/detectors/count-over-capacity.js +26 -0
  67. package/dist/detectors/count-over-capacity.js.map +1 -0
  68. package/dist/detectors/date-outside-period.d.ts.map +1 -1
  69. package/dist/detectors/date-outside-period.js +5 -1
  70. package/dist/detectors/date-outside-period.js.map +1 -1
  71. package/dist/detectors/date-stamp-order.d.ts +3 -0
  72. package/dist/detectors/date-stamp-order.d.ts.map +1 -0
  73. package/dist/detectors/date-stamp-order.js +24 -0
  74. package/dist/detectors/date-stamp-order.js.map +1 -0
  75. package/dist/detectors/defined-term-form.d.ts.map +1 -1
  76. package/dist/detectors/defined-term-form.js +57 -7
  77. package/dist/detectors/defined-term-form.js.map +1 -1
  78. package/dist/detectors/definition-use.d.ts +1 -1
  79. package/dist/detectors/definition-use.d.ts.map +1 -1
  80. package/dist/detectors/definition-use.js +4 -2
  81. package/dist/detectors/definition-use.js.map +1 -1
  82. package/dist/detectors/derived-numbers.d.ts +11 -1
  83. package/dist/detectors/derived-numbers.d.ts.map +1 -1
  84. package/dist/detectors/derived-numbers.js +74 -20
  85. package/dist/detectors/derived-numbers.js.map +1 -1
  86. package/dist/detectors/due-date.d.ts.map +1 -1
  87. package/dist/detectors/due-date.js +6 -0
  88. package/dist/detectors/due-date.js.map +1 -1
  89. package/dist/detectors/en-shape.d.ts.map +1 -1
  90. package/dist/detectors/en-shape.js +7 -4
  91. package/dist/detectors/en-shape.js.map +1 -1
  92. package/dist/detectors/event-deadline.d.ts +3 -0
  93. package/dist/detectors/event-deadline.d.ts.map +1 -0
  94. package/dist/detectors/event-deadline.js +24 -0
  95. package/dist/detectors/event-deadline.js.map +1 -0
  96. package/dist/detectors/fact-consistency.d.ts +1 -1
  97. package/dist/detectors/fact-consistency.d.ts.map +1 -1
  98. package/dist/detectors/fact-consistency.js +52 -3
  99. package/dist/detectors/fact-consistency.js.map +1 -1
  100. package/dist/detectors/heading-case.d.ts +5 -2
  101. package/dist/detectors/heading-case.d.ts.map +1 -1
  102. package/dist/detectors/heading-case.js +12 -4
  103. package/dist/detectors/heading-case.js.map +1 -1
  104. package/dist/detectors/heading-echo.d.ts +5 -0
  105. package/dist/detectors/heading-echo.d.ts.map +1 -1
  106. package/dist/detectors/heading-echo.js +14 -1
  107. package/dist/detectors/heading-echo.js.map +1 -1
  108. package/dist/detectors/layout-code.d.ts +5 -0
  109. package/dist/detectors/layout-code.d.ts.map +1 -0
  110. package/dist/detectors/layout-code.js +124 -0
  111. package/dist/detectors/layout-code.js.map +1 -0
  112. package/dist/detectors/measured-facts.d.ts +8 -0
  113. package/dist/detectors/measured-facts.d.ts.map +1 -0
  114. package/dist/detectors/measured-facts.js +18 -0
  115. package/dist/detectors/measured-facts.js.map +1 -0
  116. package/dist/detectors/name-variant-model-codes.d.ts +11 -0
  117. package/dist/detectors/name-variant-model-codes.d.ts.map +1 -0
  118. package/dist/detectors/name-variant-model-codes.js +21 -0
  119. package/dist/detectors/name-variant-model-codes.js.map +1 -0
  120. package/dist/detectors/name-variant.d.ts.map +1 -1
  121. package/dist/detectors/name-variant.js +78 -10
  122. package/dist/detectors/name-variant.js.map +1 -1
  123. package/dist/detectors/orthographic-variant.d.ts.map +1 -1
  124. package/dist/detectors/orthographic-variant.js +62 -7
  125. package/dist/detectors/orthographic-variant.js.map +1 -1
  126. package/dist/detectors/orthography.d.ts.map +1 -1
  127. package/dist/detectors/orthography.js +12 -6
  128. package/dist/detectors/orthography.js.map +1 -1
  129. package/dist/detectors/party-order.d.ts +3 -0
  130. package/dist/detectors/party-order.d.ts.map +1 -0
  131. package/dist/detectors/party-order.js +46 -0
  132. package/dist/detectors/party-order.js.map +1 -0
  133. package/dist/detectors/quantity-range.d.ts +3 -0
  134. package/dist/detectors/quantity-range.d.ts.map +1 -0
  135. package/dist/detectors/quantity-range.js +35 -0
  136. package/dist/detectors/quantity-range.js.map +1 -0
  137. package/dist/detectors/range-band.d.ts +5 -0
  138. package/dist/detectors/range-band.d.ts.map +1 -0
  139. package/dist/detectors/range-band.js +80 -0
  140. package/dist/detectors/range-band.js.map +1 -0
  141. package/dist/detectors/registry/capacity-runtime-mismatch.d.ts +3 -0
  142. package/dist/detectors/registry/capacity-runtime-mismatch.d.ts.map +1 -0
  143. package/dist/detectors/registry/capacity-runtime-mismatch.js +3 -0
  144. package/dist/detectors/registry/capacity-runtime-mismatch.js.map +1 -0
  145. package/dist/detectors/registry/connection-time-short.d.ts +3 -0
  146. package/dist/detectors/registry/connection-time-short.d.ts.map +1 -0
  147. package/dist/detectors/registry/connection-time-short.js +3 -0
  148. package/dist/detectors/registry/connection-time-short.js.map +1 -0
  149. package/dist/detectors/registry/contact-variant.d.ts +3 -0
  150. package/dist/detectors/registry/contact-variant.d.ts.map +1 -0
  151. package/dist/detectors/registry/contact-variant.js +3 -0
  152. package/dist/detectors/registry/contact-variant.js.map +1 -0
  153. package/dist/detectors/registry/count-over-capacity.d.ts +3 -0
  154. package/dist/detectors/registry/count-over-capacity.d.ts.map +1 -0
  155. package/dist/detectors/registry/count-over-capacity.js +3 -0
  156. package/dist/detectors/registry/count-over-capacity.js.map +1 -0
  157. package/dist/detectors/registry/date-stamp-order.d.ts +3 -0
  158. package/dist/detectors/registry/date-stamp-order.d.ts.map +1 -0
  159. package/dist/detectors/registry/date-stamp-order.js +3 -0
  160. package/dist/detectors/registry/date-stamp-order.js.map +1 -0
  161. package/dist/detectors/registry/duration-product-mismatch.d.ts +3 -0
  162. package/dist/detectors/registry/duration-product-mismatch.d.ts.map +1 -0
  163. package/dist/detectors/registry/duration-product-mismatch.js +3 -0
  164. package/dist/detectors/registry/duration-product-mismatch.js.map +1 -0
  165. package/dist/detectors/registry/event-deadline.d.ts +3 -0
  166. package/dist/detectors/registry/event-deadline.d.ts.map +1 -0
  167. package/dist/detectors/registry/event-deadline.js +3 -0
  168. package/dist/detectors/registry/event-deadline.js.map +1 -0
  169. package/dist/detectors/registry/interval-count-mismatch.d.ts +3 -0
  170. package/dist/detectors/registry/interval-count-mismatch.d.ts.map +1 -0
  171. package/dist/detectors/registry/interval-count-mismatch.js +3 -0
  172. package/dist/detectors/registry/interval-count-mismatch.js.map +1 -0
  173. package/dist/detectors/registry/layout-code-mismatch.d.ts +3 -0
  174. package/dist/detectors/registry/layout-code-mismatch.d.ts.map +1 -0
  175. package/dist/detectors/registry/layout-code-mismatch.js +3 -0
  176. package/dist/detectors/registry/layout-code-mismatch.js.map +1 -0
  177. package/dist/detectors/registry/party-order.d.ts +3 -0
  178. package/dist/detectors/registry/party-order.d.ts.map +1 -0
  179. package/dist/detectors/registry/party-order.js +3 -0
  180. package/dist/detectors/registry/party-order.js.map +1 -0
  181. package/dist/detectors/registry/quantity-range.d.ts +3 -0
  182. package/dist/detectors/registry/quantity-range.d.ts.map +1 -0
  183. package/dist/detectors/registry/quantity-range.js +3 -0
  184. package/dist/detectors/registry/quantity-range.js.map +1 -0
  185. package/dist/detectors/registry/range-band-mismatch.d.ts +3 -0
  186. package/dist/detectors/registry/range-band-mismatch.d.ts.map +1 -0
  187. package/dist/detectors/registry/range-band-mismatch.js +3 -0
  188. package/dist/detectors/registry/range-band-mismatch.js.map +1 -0
  189. package/dist/detectors/registry/rent-multiple-mismatch.d.ts +3 -0
  190. package/dist/detectors/registry/rent-multiple-mismatch.d.ts.map +1 -0
  191. package/dist/detectors/registry/rent-multiple-mismatch.js +3 -0
  192. package/dist/detectors/registry/rent-multiple-mismatch.js.map +1 -0
  193. package/dist/detectors/registry/requirement-lists.d.ts +3 -0
  194. package/dist/detectors/registry/requirement-lists.d.ts.map +1 -0
  195. package/dist/detectors/registry/requirement-lists.js +3 -0
  196. package/dist/detectors/registry/requirement-lists.js.map +1 -0
  197. package/dist/detectors/registry/return-type.d.ts +3 -0
  198. package/dist/detectors/registry/return-type.d.ts.map +1 -0
  199. package/dist/detectors/registry/return-type.js +3 -0
  200. package/dist/detectors/registry/return-type.js.map +1 -0
  201. package/dist/detectors/registry/scaled-quantity-mismatch.d.ts +3 -0
  202. package/dist/detectors/registry/scaled-quantity-mismatch.d.ts.map +1 -0
  203. package/dist/detectors/registry/scaled-quantity-mismatch.js +3 -0
  204. package/dist/detectors/registry/scaled-quantity-mismatch.js.map +1 -0
  205. package/dist/detectors/registry/step-time-sum-mismatch.d.ts +3 -0
  206. package/dist/detectors/registry/step-time-sum-mismatch.d.ts.map +1 -0
  207. package/dist/detectors/registry/step-time-sum-mismatch.js +3 -0
  208. package/dist/detectors/registry/step-time-sum-mismatch.js.map +1 -0
  209. package/dist/detectors/registry/time-range-reversed.d.ts +3 -0
  210. package/dist/detectors/registry/time-range-reversed.d.ts.map +1 -0
  211. package/dist/detectors/registry/time-range-reversed.js +3 -0
  212. package/dist/detectors/registry/time-range-reversed.js.map +1 -0
  213. package/dist/detectors/registry/unlisted-item-used.d.ts +3 -0
  214. package/dist/detectors/registry/unlisted-item-used.d.ts.map +1 -0
  215. package/dist/detectors/registry/unlisted-item-used.js +3 -0
  216. package/dist/detectors/registry/unlisted-item-used.js.map +1 -0
  217. package/dist/detectors/registry/walk-time-distance-mismatch.d.ts +3 -0
  218. package/dist/detectors/registry/walk-time-distance-mismatch.d.ts.map +1 -0
  219. package/dist/detectors/registry/walk-time-distance-mismatch.js +3 -0
  220. package/dist/detectors/registry/walk-time-distance-mismatch.js.map +1 -0
  221. package/dist/detectors/rent-multiple-mismatch.d.ts +3 -0
  222. package/dist/detectors/rent-multiple-mismatch.d.ts.map +1 -0
  223. package/dist/detectors/rent-multiple-mismatch.js +39 -0
  224. package/dist/detectors/rent-multiple-mismatch.js.map +1 -0
  225. package/dist/detectors/requirement-lists.d.ts +3 -0
  226. package/dist/detectors/requirement-lists.d.ts.map +1 -0
  227. package/dist/detectors/requirement-lists.js +46 -0
  228. package/dist/detectors/requirement-lists.js.map +1 -0
  229. package/dist/detectors/return-type.d.ts +3 -0
  230. package/dist/detectors/return-type.d.ts.map +1 -0
  231. package/dist/detectors/return-type.js +24 -0
  232. package/dist/detectors/return-type.js.map +1 -0
  233. package/dist/detectors/scaled-quantity.d.ts +3 -0
  234. package/dist/detectors/scaled-quantity.d.ts.map +1 -0
  235. package/dist/detectors/scaled-quantity.js +37 -0
  236. package/dist/detectors/scaled-quantity.js.map +1 -0
  237. package/dist/detectors/signals.d.ts.map +1 -1
  238. package/dist/detectors/signals.js +3 -1
  239. package/dist/detectors/signals.js.map +1 -1
  240. package/dist/detectors/step-time-sum.d.ts +3 -0
  241. package/dist/detectors/step-time-sum.d.ts.map +1 -0
  242. package/dist/detectors/step-time-sum.js +46 -0
  243. package/dist/detectors/step-time-sum.js.map +1 -0
  244. package/dist/detectors/structure-tree.d.ts +2 -0
  245. package/dist/detectors/structure-tree.d.ts.map +1 -1
  246. package/dist/detectors/structure-tree.js +31 -6
  247. package/dist/detectors/structure-tree.js.map +1 -1
  248. package/dist/detectors/structure.js +1 -1
  249. package/dist/detectors/structure.js.map +1 -1
  250. package/dist/detectors/technical-docs.d.ts +5 -0
  251. package/dist/detectors/technical-docs.d.ts.map +1 -1
  252. package/dist/detectors/technical-docs.js +12 -0
  253. package/dist/detectors/technical-docs.js.map +1 -1
  254. package/dist/detectors/time-order.d.ts +2 -0
  255. package/dist/detectors/time-order.d.ts.map +1 -1
  256. package/dist/detectors/time-order.js +33 -5
  257. package/dist/detectors/time-order.js.map +1 -1
  258. package/dist/detectors/undefined-term.d.ts.map +1 -1
  259. package/dist/detectors/undefined-term.js +19 -3
  260. package/dist/detectors/undefined-term.js.map +1 -1
  261. package/dist/detectors/unit-consistency.d.ts +1 -1
  262. package/dist/detectors/unit-consistency.d.ts.map +1 -1
  263. package/dist/detectors/unit-consistency.js +46 -38
  264. package/dist/detectors/unit-consistency.js.map +1 -1
  265. package/dist/detectors/unlisted-items.d.ts +3 -0
  266. package/dist/detectors/unlisted-items.d.ts.map +1 -0
  267. package/dist/detectors/unlisted-items.js +57 -0
  268. package/dist/detectors/unlisted-items.js.map +1 -0
  269. package/dist/detectors/use-count-words.d.ts +8 -0
  270. package/dist/detectors/use-count-words.d.ts.map +1 -0
  271. package/dist/detectors/use-count-words.js +20 -0
  272. package/dist/detectors/use-count-words.js.map +1 -0
  273. package/dist/detectors/use-interval.d.ts +3 -0
  274. package/dist/detectors/use-interval.d.ts.map +1 -0
  275. package/dist/detectors/use-interval.js +39 -0
  276. package/dist/detectors/use-interval.js.map +1 -0
  277. package/dist/detectors/walk-time-distance-mismatch.d.ts +4 -0
  278. package/dist/detectors/walk-time-distance-mismatch.d.ts.map +1 -0
  279. package/dist/detectors/walk-time-distance-mismatch.js +38 -0
  280. package/dist/detectors/walk-time-distance-mismatch.js.map +1 -0
  281. package/dist/document.d.ts.map +1 -1
  282. package/dist/document.js +4 -1
  283. package/dist/document.js.map +1 -1
  284. package/dist/facts/approximate-tolerance.d.ts +7 -0
  285. package/dist/facts/approximate-tolerance.d.ts.map +1 -0
  286. package/dist/facts/approximate-tolerance.js +16 -0
  287. package/dist/facts/approximate-tolerance.js.map +1 -0
  288. package/dist/facts/item-amounts.d.ts +18 -0
  289. package/dist/facts/item-amounts.d.ts.map +1 -0
  290. package/dist/facts/item-amounts.js +67 -0
  291. package/dist/facts/item-amounts.js.map +1 -0
  292. package/dist/facts/labelled-facts.d.ts +4 -0
  293. package/dist/facts/labelled-facts.d.ts.map +1 -1
  294. package/dist/facts/labelled-facts.js +21 -6
  295. package/dist/facts/labelled-facts.js.map +1 -1
  296. package/dist/facts/measure-units.d.ts +5 -0
  297. package/dist/facts/measure-units.d.ts.map +1 -0
  298. package/dist/facts/measure-units.js +28 -0
  299. package/dist/facts/measure-units.js.map +1 -0
  300. package/dist/facts/measures.d.ts +23 -4
  301. package/dist/facts/measures.d.ts.map +1 -1
  302. package/dist/facts/measures.js +68 -19
  303. package/dist/facts/measures.js.map +1 -1
  304. package/dist/facts/retention-periods.d.ts +51 -0
  305. package/dist/facts/retention-periods.d.ts.map +1 -0
  306. package/dist/facts/retention-periods.js +148 -0
  307. package/dist/facts/retention-periods.js.map +1 -0
  308. package/dist/facts/table-facts.d.ts +2 -0
  309. package/dist/facts/table-facts.d.ts.map +1 -1
  310. package/dist/facts/table-facts.js +2 -0
  311. package/dist/facts/table-facts.js.map +1 -1
  312. package/dist/facts/unit-conflicts.d.ts +3 -2
  313. package/dist/facts/unit-conflicts.d.ts.map +1 -1
  314. package/dist/facts/unit-conflicts.js +15 -7
  315. package/dist/facts/unit-conflicts.js.map +1 -1
  316. package/dist/facts/unit-equivalents.d.ts +13 -0
  317. package/dist/facts/unit-equivalents.d.ts.map +1 -0
  318. package/dist/facts/unit-equivalents.js +56 -0
  319. package/dist/facts/unit-equivalents.js.map +1 -0
  320. package/dist/facts/unit-tolerance.d.ts +4 -0
  321. package/dist/facts/unit-tolerance.d.ts.map +1 -0
  322. package/dist/facts/unit-tolerance.js +13 -0
  323. package/dist/facts/unit-tolerance.js.map +1 -0
  324. package/dist/facts/unit-word.d.ts +8 -0
  325. package/dist/facts/unit-word.d.ts.map +1 -0
  326. package/dist/facts/unit-word.js +34 -0
  327. package/dist/facts/unit-word.js.map +1 -0
  328. package/dist/facts/written-precision.d.ts +10 -0
  329. package/dist/facts/written-precision.d.ts.map +1 -0
  330. package/dist/facts/written-precision.js +20 -0
  331. package/dist/facts/written-precision.js.map +1 -0
  332. package/dist/kana-spelling.d.ts +12 -0
  333. package/dist/kana-spelling.d.ts.map +1 -1
  334. package/dist/kana-spelling.js +23 -0
  335. package/dist/kana-spelling.js.map +1 -1
  336. package/dist/model-codes.d.ts +23 -0
  337. package/dist/model-codes.d.ts.map +1 -0
  338. package/dist/model-codes.js +81 -0
  339. package/dist/model-codes.js.map +1 -0
  340. package/dist/name-spelling-chars.d.ts +16 -0
  341. package/dist/name-spelling-chars.d.ts.map +1 -0
  342. package/dist/name-spelling-chars.js +14 -0
  343. package/dist/name-spelling-chars.js.map +1 -0
  344. package/dist/name-variants.d.ts +8 -2
  345. package/dist/name-variants.d.ts.map +1 -1
  346. package/dist/name-variants.js +72 -7
  347. package/dist/name-variants.js.map +1 -1
  348. package/dist/name-word-order.d.ts +49 -0
  349. package/dist/name-word-order.d.ts.map +1 -0
  350. package/dist/name-word-order.js +114 -0
  351. package/dist/name-word-order.js.map +1 -0
  352. package/dist/phone-numbers.d.ts.map +1 -1
  353. package/dist/phone-numbers.js +22 -5
  354. package/dist/phone-numbers.js.map +1 -1
  355. package/dist/place-names.d.ts +12 -5
  356. package/dist/place-names.d.ts.map +1 -1
  357. package/dist/place-names.js +34 -14
  358. package/dist/place-names.js.map +1 -1
  359. package/dist/plugin.d.ts +12 -0
  360. package/dist/plugin.d.ts.map +1 -1
  361. package/dist/preamble-paragraphs.d.ts +2 -1
  362. package/dist/preamble-paragraphs.d.ts.map +1 -1
  363. package/dist/preamble-paragraphs.js +16 -1
  364. package/dist/preamble-paragraphs.js.map +1 -1
  365. package/dist/profile/parse.d.ts.map +1 -1
  366. package/dist/profile/parse.js +11 -0
  367. package/dist/profile/parse.js.map +1 -1
  368. package/dist/return-type.d.ts +33 -0
  369. package/dist/return-type.d.ts.map +1 -0
  370. package/dist/return-type.js +302 -0
  371. package/dist/return-type.js.map +1 -0
  372. package/dist/spacing-code.d.ts +6 -0
  373. package/dist/spacing-code.d.ts.map +1 -0
  374. package/dist/spacing-code.js +16 -0
  375. package/dist/spacing-code.js.map +1 -0
  376. package/dist/structure/amount-range.d.ts +2 -2
  377. package/dist/structure/amount-range.d.ts.map +1 -1
  378. package/dist/structure/amount-range.js +12 -5
  379. package/dist/structure/amount-range.js.map +1 -1
  380. package/dist/structure/capacity-count.d.ts +59 -0
  381. package/dist/structure/capacity-count.d.ts.map +1 -0
  382. package/dist/structure/capacity-count.js +118 -0
  383. package/dist/structure/capacity-count.js.map +1 -0
  384. package/dist/structure/connection-times.d.ts +56 -0
  385. package/dist/structure/connection-times.d.ts.map +1 -0
  386. package/dist/structure/connection-times.js +165 -0
  387. package/dist/structure/connection-times.js.map +1 -0
  388. package/dist/structure/counted-amounts.d.ts +6 -0
  389. package/dist/structure/counted-amounts.d.ts.map +1 -1
  390. package/dist/structure/counted-amounts.js +4 -4
  391. package/dist/structure/counted-amounts.js.map +1 -1
  392. package/dist/structure/date-order-tie.d.ts +13 -0
  393. package/dist/structure/date-order-tie.d.ts.map +1 -0
  394. package/dist/structure/date-order-tie.js +61 -0
  395. package/dist/structure/date-order-tie.js.map +1 -0
  396. package/dist/structure/date-order.d.ts +2 -2
  397. package/dist/structure/date-order.d.ts.map +1 -1
  398. package/dist/structure/date-order.js +26 -9
  399. package/dist/structure/date-order.js.map +1 -1
  400. package/dist/structure/date-outside-period.d.ts +8 -0
  401. package/dist/structure/date-outside-period.d.ts.map +1 -1
  402. package/dist/structure/date-outside-period.js +52 -3
  403. package/dist/structure/date-outside-period.js.map +1 -1
  404. package/dist/structure/date-range.d.ts +6 -2
  405. package/dist/structure/date-range.d.ts.map +1 -1
  406. package/dist/structure/date-range.js +37 -9
  407. package/dist/structure/date-range.js.map +1 -1
  408. package/dist/structure/deadline-after-event.d.ts +23 -0
  409. package/dist/structure/deadline-after-event.d.ts.map +1 -0
  410. package/dist/structure/deadline-after-event.js +42 -0
  411. package/dist/structure/deadline-after-event.js.map +1 -0
  412. package/dist/structure/definition-use.d.ts +1 -1
  413. package/dist/structure/definition-use.d.ts.map +1 -1
  414. package/dist/structure/definition-use.js +55 -2
  415. package/dist/structure/definition-use.js.map +1 -1
  416. package/dist/structure/due-date.d.ts.map +1 -1
  417. package/dist/structure/due-date.js +5 -27
  418. package/dist/structure/due-date.js.map +1 -1
  419. package/dist/structure/labelled-date-order.d.ts +38 -0
  420. package/dist/structure/labelled-date-order.d.ts.map +1 -0
  421. package/dist/structure/labelled-date-order.js +41 -0
  422. package/dist/structure/labelled-date-order.js.map +1 -0
  423. package/dist/structure/layout-codes.d.ts +68 -0
  424. package/dist/structure/layout-codes.d.ts.map +1 -0
  425. package/dist/structure/layout-codes.js +161 -0
  426. package/dist/structure/layout-codes.js.map +1 -0
  427. package/dist/structure/leg-times.d.ts +2 -0
  428. package/dist/structure/leg-times.d.ts.map +1 -1
  429. package/dist/structure/leg-times.js +13 -0
  430. package/dist/structure/leg-times.js.map +1 -1
  431. package/dist/structure/measured-amounts.d.ts +17 -0
  432. package/dist/structure/measured-amounts.d.ts.map +1 -0
  433. package/dist/structure/measured-amounts.js +110 -0
  434. package/dist/structure/measured-amounts.js.map +1 -0
  435. package/dist/structure/party-order.d.ts +33 -0
  436. package/dist/structure/party-order.d.ts.map +1 -0
  437. package/dist/structure/party-order.js +79 -0
  438. package/dist/structure/party-order.js.map +1 -0
  439. package/dist/structure/quantity-range.d.ts +8 -0
  440. package/dist/structure/quantity-range.d.ts.map +1 -0
  441. package/dist/structure/quantity-range.js +36 -0
  442. package/dist/structure/quantity-range.js.map +1 -0
  443. package/dist/structure/range-bands.d.ts +75 -0
  444. package/dist/structure/range-bands.d.ts.map +1 -0
  445. package/dist/structure/range-bands.js +244 -0
  446. package/dist/structure/range-bands.js.map +1 -0
  447. package/dist/structure/rent-multiple.d.ts +76 -0
  448. package/dist/structure/rent-multiple.d.ts.map +1 -0
  449. package/dist/structure/rent-multiple.js +186 -0
  450. package/dist/structure/rent-multiple.js.map +1 -0
  451. package/dist/structure/requirement-lists.d.ts +37 -0
  452. package/dist/structure/requirement-lists.d.ts.map +1 -0
  453. package/dist/structure/requirement-lists.js +89 -0
  454. package/dist/structure/requirement-lists.js.map +1 -0
  455. package/dist/structure/scaled-quantities.d.ts +50 -0
  456. package/dist/structure/scaled-quantities.d.ts.map +1 -0
  457. package/dist/structure/scaled-quantities.js +153 -0
  458. package/dist/structure/scaled-quantities.js.map +1 -0
  459. package/dist/structure/stamp-order.d.ts +16 -0
  460. package/dist/structure/stamp-order.d.ts.map +1 -0
  461. package/dist/structure/stamp-order.js +78 -0
  462. package/dist/structure/stamp-order.js.map +1 -0
  463. package/dist/structure/step-times.d.ts +49 -0
  464. package/dist/structure/step-times.d.ts.map +1 -0
  465. package/dist/structure/step-times.js +128 -0
  466. package/dist/structure/step-times.js.map +1 -0
  467. package/dist/structure/term-deadline.d.ts +19 -0
  468. package/dist/structure/term-deadline.d.ts.map +1 -0
  469. package/dist/structure/term-deadline.js +28 -0
  470. package/dist/structure/term-deadline.js.map +1 -0
  471. package/dist/structure/time-order.d.ts +21 -0
  472. package/dist/structure/time-order.d.ts.map +1 -1
  473. package/dist/structure/time-order.js +5 -6
  474. package/dist/structure/time-order.js.map +1 -1
  475. package/dist/structure/time-range.d.ts +16 -0
  476. package/dist/structure/time-range.d.ts.map +1 -0
  477. package/dist/structure/time-range.js +57 -0
  478. package/dist/structure/time-range.js.map +1 -0
  479. package/dist/structure/total-line.d.ts +16 -0
  480. package/dist/structure/total-line.d.ts.map +1 -0
  481. package/dist/structure/total-line.js +44 -0
  482. package/dist/structure/total-line.js.map +1 -0
  483. package/dist/structure/total.d.ts +7 -1
  484. package/dist/structure/total.d.ts.map +1 -1
  485. package/dist/structure/total.js +28 -5
  486. package/dist/structure/total.js.map +1 -1
  487. package/dist/structure/unlisted-items.d.ts +70 -0
  488. package/dist/structure/unlisted-items.d.ts.map +1 -0
  489. package/dist/structure/unlisted-items.js +152 -0
  490. package/dist/structure/unlisted-items.js.map +1 -0
  491. package/dist/structure/version-order.d.ts +2 -0
  492. package/dist/structure/version-order.d.ts.map +1 -1
  493. package/dist/structure/version-order.js +10 -0
  494. package/dist/structure/version-order.js.map +1 -1
  495. package/dist/structure/walk-time.d.ts +87 -0
  496. package/dist/structure/walk-time.d.ts.map +1 -0
  497. package/dist/structure/walk-time.js +195 -0
  498. package/dist/structure/walk-time.js.map +1 -0
  499. package/dist/surname-near.d.ts +6 -0
  500. package/dist/surname-near.d.ts.map +1 -0
  501. package/dist/surname-near.js +31 -0
  502. package/dist/surname-near.js.map +1 -0
  503. package/dist/table-cells.d.ts +13 -0
  504. package/dist/table-cells.d.ts.map +1 -0
  505. package/dist/table-cells.js +36 -0
  506. package/dist/table-cells.js.map +1 -0
  507. package/dist/table-names.d.ts +42 -0
  508. package/dist/table-names.d.ts.map +1 -0
  509. package/dist/table-names.js +94 -0
  510. package/dist/table-names.js.map +1 -0
  511. package/package.json +3 -3
  512. package/profiles/listing.yaml +20 -0
  513. package/rules/announced-count-mismatch.yaml +2 -2
  514. package/rules/capacity-runtime-mismatch.yaml +66 -0
  515. package/rules/connection-time-short.yaml +52 -0
  516. package/rules/contact-variant.yaml +76 -0
  517. package/rules/count-over-capacity.yaml +55 -0
  518. package/rules/date-outside-period.yaml +4 -4
  519. package/rules/date-stamp-order.yaml +82 -0
  520. package/rules/deadline-after-event.yaml +67 -0
  521. package/rules/defined-name-repeated.yaml +2 -2
  522. package/rules/due-before-issue.yaml +11 -7
  523. package/rules/duration-mismatch.yaml +7 -4
  524. package/rules/duration-product-mismatch.yaml +73 -0
  525. package/rules/fact-conflict.yaml +9 -4
  526. package/rules/heading-echo.yaml +2 -2
  527. package/rules/interval-count-mismatch.yaml +54 -0
  528. package/rules/latin-spacing.yaml +2 -2
  529. package/rules/layout-code-mismatch.yaml +68 -0
  530. package/rules/name-variant.yaml +14 -2
  531. package/rules/no-em-dash.yaml +2 -2
  532. package/rules/party-order.yaml +84 -0
  533. package/rules/preamble-length.yaml +2 -2
  534. package/rules/quantity-range-reversed.yaml +53 -0
  535. package/rules/range-band-mismatch.yaml +70 -0
  536. package/rules/rent-multiple-mismatch.yaml +61 -0
  537. package/rules/required-listed-as-preferred.yaml +102 -0
  538. package/rules/return-type-mismatch.yaml +79 -0
  539. package/rules/scaled-quantity-mismatch.yaml +69 -0
  540. package/rules/step-time-sum-mismatch.yaml +65 -0
  541. package/rules/time-range-reversed.yaml +48 -0
  542. package/rules/title-case-consistency.yaml +2 -2
  543. package/rules/total-mismatch.yaml +2 -2
  544. package/rules/undefined-term.yaml +21 -7
  545. package/rules/unit-mismatch.yaml +12 -4
  546. package/rules/unlisted-item-used.yaml +90 -0
  547. package/rules/unused-definition.yaml +2 -2
  548. package/rules/use-before-definition.yaml +2 -2
  549. package/rules/walk-time-distance-mismatch.yaml +55 -0
  550. package/src/announced-count.ts +6 -3
  551. package/src/contacts/addresses.ts +179 -0
  552. package/src/contacts/emails.ts +63 -0
  553. package/src/contacts/variants.ts +33 -0
  554. package/src/derived/battery-runtime.ts +284 -0
  555. package/src/derived/period-counts.ts +178 -0
  556. package/src/derived/session-hours.ts +62 -0
  557. package/src/derived/time-lengths.ts +229 -0
  558. package/src/derived/unit-counts.ts +18 -0
  559. package/src/derived/use-interval.ts +151 -0
  560. package/src/derived/working-hours.ts +97 -0
  561. package/src/detectors/acronym-expansion.ts +57 -2
  562. package/src/detectors/announced-count.ts +1 -0
  563. package/src/detectors/capacity-runtime.ts +128 -0
  564. package/src/detectors/capitalised-term.ts +147 -0
  565. package/src/detectors/contact-variant.ts +24 -0
  566. package/src/detectors/count-over-capacity.ts +37 -0
  567. package/src/detectors/date-outside-period.ts +5 -1
  568. package/src/detectors/date-stamp-order.ts +28 -0
  569. package/src/detectors/defined-term-form.ts +63 -7
  570. package/src/detectors/definition-use.ts +6 -2
  571. package/src/detectors/derived-numbers.ts +97 -24
  572. package/src/detectors/due-date.ts +10 -2
  573. package/src/detectors/en-shape.ts +11 -4
  574. package/src/detectors/event-deadline.ts +29 -0
  575. package/src/detectors/fact-consistency.ts +64 -3
  576. package/src/detectors/heading-case.ts +13 -4
  577. package/src/detectors/heading-echo.ts +17 -1
  578. package/src/detectors/layout-code.ts +174 -0
  579. package/src/detectors/measured-facts.ts +20 -0
  580. package/src/detectors/name-variant-model-codes.ts +27 -0
  581. package/src/detectors/name-variant.ts +99 -15
  582. package/src/detectors/orthographic-variant.ts +78 -9
  583. package/src/detectors/orthography.ts +16 -6
  584. package/src/detectors/party-order.ts +50 -0
  585. package/src/detectors/quantity-range.ts +47 -0
  586. package/src/detectors/range-band.ts +125 -0
  587. package/src/detectors/registry/capacity-runtime-mismatch.ts +4 -0
  588. package/src/detectors/registry/connection-time-short.ts +4 -0
  589. package/src/detectors/registry/contact-variant.ts +4 -0
  590. package/src/detectors/registry/count-over-capacity.ts +4 -0
  591. package/src/detectors/registry/date-stamp-order.ts +4 -0
  592. package/src/detectors/registry/duration-product-mismatch.ts +4 -0
  593. package/src/detectors/registry/event-deadline.ts +4 -0
  594. package/src/detectors/registry/interval-count-mismatch.ts +4 -0
  595. package/src/detectors/registry/layout-code-mismatch.ts +4 -0
  596. package/src/detectors/registry/party-order.ts +4 -0
  597. package/src/detectors/registry/quantity-range.ts +4 -0
  598. package/src/detectors/registry/range-band-mismatch.ts +4 -0
  599. package/src/detectors/registry/rent-multiple-mismatch.ts +4 -0
  600. package/src/detectors/registry/requirement-lists.ts +4 -0
  601. package/src/detectors/registry/return-type.ts +4 -0
  602. package/src/detectors/registry/scaled-quantity-mismatch.ts +4 -0
  603. package/src/detectors/registry/step-time-sum-mismatch.ts +4 -0
  604. package/src/detectors/registry/time-range-reversed.ts +4 -0
  605. package/src/detectors/registry/unlisted-item-used.ts +4 -0
  606. package/src/detectors/registry/walk-time-distance-mismatch.ts +4 -0
  607. package/src/detectors/rent-multiple-mismatch.ts +56 -0
  608. package/src/detectors/requirement-lists.ts +65 -0
  609. package/src/detectors/return-type.ts +30 -0
  610. package/src/detectors/scaled-quantity.ts +49 -0
  611. package/src/detectors/signals.ts +3 -1
  612. package/src/detectors/step-time-sum.ts +55 -0
  613. package/src/detectors/structure-tree.ts +42 -6
  614. package/src/detectors/structure.ts +1 -1
  615. package/src/detectors/technical-docs.ts +12 -0
  616. package/src/detectors/time-order.ts +45 -6
  617. package/src/detectors/undefined-term.ts +20 -3
  618. package/src/detectors/unit-consistency.ts +50 -38
  619. package/src/detectors/unlisted-items.ts +72 -0
  620. package/src/detectors/use-count-words.ts +32 -0
  621. package/src/detectors/use-interval.ts +51 -0
  622. package/src/detectors/walk-time-distance-mismatch.ts +45 -0
  623. package/src/document.ts +4 -1
  624. package/src/facts/approximate-tolerance.ts +19 -0
  625. package/src/facts/item-amounts.ts +94 -0
  626. package/src/facts/labelled-facts.ts +29 -7
  627. package/src/facts/measure-units.ts +31 -0
  628. package/src/facts/measures.ts +113 -25
  629. package/src/facts/retention-periods.ts +216 -0
  630. package/src/facts/table-facts.ts +3 -0
  631. package/src/facts/unit-conflicts.ts +22 -9
  632. package/src/facts/unit-equivalents.ts +70 -0
  633. package/src/facts/unit-tolerance.ts +17 -0
  634. package/src/facts/unit-word.ts +35 -0
  635. package/src/facts/written-precision.ts +23 -0
  636. package/src/kana-spelling.ts +25 -0
  637. package/src/model-codes.ts +104 -0
  638. package/src/name-spelling-chars.ts +34 -0
  639. package/src/name-variants.ts +83 -7
  640. package/src/name-word-order.ts +149 -0
  641. package/src/phone-numbers.ts +26 -6
  642. package/src/place-names.ts +53 -14
  643. package/src/plugin.ts +7 -0
  644. package/src/preamble-paragraphs.ts +21 -2
  645. package/src/profile/parse.ts +10 -0
  646. package/src/return-type.ts +361 -0
  647. package/src/spacing-code.ts +26 -0
  648. package/src/structure/amount-range.ts +16 -7
  649. package/src/structure/capacity-count.ts +196 -0
  650. package/src/structure/connection-times.ts +226 -0
  651. package/src/structure/counted-amounts.ts +5 -4
  652. package/src/structure/date-order-tie.ts +86 -0
  653. package/src/structure/date-order.ts +41 -14
  654. package/src/structure/date-outside-period.ts +77 -7
  655. package/src/structure/date-range.ts +45 -9
  656. package/src/structure/deadline-after-event.ts +67 -0
  657. package/src/structure/definition-use.ts +59 -2
  658. package/src/structure/due-date.ts +8 -32
  659. package/src/structure/labelled-date-order.ts +84 -0
  660. package/src/structure/layout-codes.ts +210 -0
  661. package/src/structure/leg-times.ts +15 -0
  662. package/src/structure/measured-amounts.ts +138 -0
  663. package/src/structure/party-order.ts +115 -0
  664. package/src/structure/quantity-range.ts +54 -0
  665. package/src/structure/range-bands.ts +316 -0
  666. package/src/structure/rent-multiple.ts +277 -0
  667. package/src/structure/requirement-lists.ts +145 -0
  668. package/src/structure/scaled-quantities.ts +225 -0
  669. package/src/structure/stamp-order.ts +100 -0
  670. package/src/structure/step-times.ts +169 -0
  671. package/src/structure/term-deadline.ts +35 -0
  672. package/src/structure/time-order.ts +8 -7
  673. package/src/structure/time-range.ts +64 -0
  674. package/src/structure/total-line.ts +63 -0
  675. package/src/structure/total.ts +41 -6
  676. package/src/structure/unlisted-items.ts +207 -0
  677. package/src/structure/version-order.ts +10 -0
  678. package/src/structure/walk-time.ts +285 -0
  679. package/src/surname-near.ts +31 -0
  680. package/src/table-cells.ts +41 -0
  681. package/src/table-names.ts +113 -0
@@ -0,0 +1,47 @@
1
+ // quantity-range-reversed: a range of measured quantities whose upper end is below its lower end (5–2 kg, 30〜10 cm,
2
+ // 40〜-10℃), decided by structure/amount-range.ts as amount-range-reversed is. The quantities are read with the unit
3
+ // lexicons (unit-length, unit-mass, …); the joints are range-connector, range-opener, range-closer and quantity-range-word;
4
+ // quantity-change-word (its lead group: a word right before the range) and quantity-bound-label say what makes a pair a
5
+ // change and what labels a bound.
6
+ import type { Detector, Finding, ProseDocument } from "../plugin.ts";
7
+ import { measuredValues } from "../facts/measures.ts";
8
+ import { measureUnitsOf } from "../facts/measure-units.ts";
9
+ import { reversedAmountRanges, type AmountRangeWords } from "../structure/amount-range.ts";
10
+ import { quantityRangeEnds, unledRanges } from "../structure/quantity-range.ts";
11
+ import { AMOUNT } from "./currency-notation.ts";
12
+ import { proseAndTablesOf } from "../table-text.ts";
13
+ import { quoteAround } from "./quote-around.ts";
14
+
15
+ /** A bare end may carry a minus sign (-10〜-40℃); a hyphen right after a digit or a letter is a range mark (5-10 kg). */
16
+ const SIGNED_NUMBER = `(?:[-−-](?=[0-90-9]))?${AMOUNT}`;
17
+
18
+ const patternsOf = (doc: ProseDocument, lexicon: string, group?: string): string[] =>
19
+ (doc.lexicons[lexicon] ?? []).filter((entry) => group === undefined || entry.group === group).map((entry) => entry.pattern);
20
+
21
+ const ungroupedOf = (doc: ProseDocument, lexicon: string): string[] =>
22
+ (doc.lexicons[lexicon] ?? []).filter((entry) => entry.group === undefined).map((entry) => entry.pattern);
23
+
24
+ const wordsOf = (doc: ProseDocument): AmountRangeWords => ({
25
+ connectors: [...patternsOf(doc, "range-connector"), ...patternsOf(doc, "quantity-range-word")],
26
+ openers: patternsOf(doc, "range-opener"),
27
+ closers: patternsOf(doc, "range-closer"),
28
+ changes: ungroupedOf(doc, "quantity-change-word"),
29
+ lowers: patternsOf(doc, "quantity-bound-label", "lower"),
30
+ uppers: patternsOf(doc, "quantity-bound-label", "upper"),
31
+ links: patternsOf(doc, "quantity-bound-label", "link"),
32
+ scales: [],
33
+ number: SIGNED_NUMBER,
34
+ });
35
+
36
+ export const quantityRange: Detector = (doc): Finding[] => {
37
+ const text = proseAndTablesOf(doc);
38
+ const reversed = reversedAmountRanges(text, quantityRangeEnds(text, measuredValues(text, measureUnitsOf(doc))), wordsOf(doc));
39
+ return unledRanges(text, reversed, patternsOf(doc, "quantity-change-word", "lead")).map((issue) => ({
40
+ rule: "quantity-range-reversed",
41
+ severity: "warning",
42
+ line: 0,
43
+ column: 0,
44
+ quote: quoteAround(text, issue.offset),
45
+ values: { ...issue.values, offset: issue.offset },
46
+ }));
47
+ };
@@ -0,0 +1,125 @@
1
+ // range-band-mismatch: neighbouring bands of one table column or one list that overlap or leave a gap (structure/range-bands.ts).
2
+ // The words that bound a band are range-band-word's, the units range-band-unit's, and the column headings that say what bare
3
+ // numbers count range-band-heading's.
4
+ import type { Detector, Finding, ProseDocument } from "../plugin.ts";
5
+ import { cellsOf, tablesOf } from "../facts/table-facts.ts";
6
+ import { linesOf } from "../structure/lines.ts";
7
+ import {
8
+ bandSlips,
9
+ headingOf,
10
+ parseBand,
11
+ runKindOf,
12
+ type BandMarker,
13
+ type BandSlip,
14
+ type BandWords,
15
+ type PlacedBand,
16
+ type UnitKind,
17
+ } from "../structure/range-bands.ts";
18
+ import { quoteAt } from "./structure-tree.ts";
19
+
20
+ const MARKER_GROUPS: Readonly<Record<string, Pick<BandMarker, "side" | "kind">>> = {
21
+ "lower-inclusive": { side: "low", kind: "inclusive" },
22
+ "lower-exclusive": { side: "low", kind: "exclusive" },
23
+ "upper-inclusive": { side: "high", kind: "inclusive" },
24
+ "upper-exclusive": { side: "high", kind: "exclusive" },
25
+ };
26
+
27
+ const isUnitKind = (group: string | undefined): group is UnitKind => group === "integer" || group === "continuous";
28
+
29
+ export const bandWordsOf = (lexicons: ProseDocument["lexicons"]): BandWords => {
30
+ const words = lexicons["range-band-word"] ?? [];
31
+ const patterns = (group: string): string[] => words.filter((entry) => entry.group === group).map((entry) => entry.pattern);
32
+ return {
33
+ connectors: patterns("connector"),
34
+ openers: words.filter((entry) => entry.group === "connector" && entry.position === "before").map((entry) => entry.pattern),
35
+ leads: patterns("lead"),
36
+ markers: words.flatMap((entry) => {
37
+ const marker = MARKER_GROUPS[entry.group ?? ""];
38
+ return marker === undefined ? [] : [{ pattern: entry.pattern, ...marker, position: entry.position ?? "after" }];
39
+ }),
40
+ units: (lexicons["range-band-unit"] ?? []).flatMap((entry) =>
41
+ isUnitKind(entry.group) ? [{ pattern: entry.pattern, kind: entry.group, position: entry.position ?? "after" }] : [],
42
+ ),
43
+ headings: (lexicons["range-band-heading"] ?? []).flatMap((entry) => (isUnitKind(entry.group) ? [{ pattern: entry.pattern, kind: entry.group }] : [])),
44
+ };
45
+ };
46
+
47
+ type Slot = { readonly text: string; readonly start: number; readonly end: number };
48
+
49
+ /** Runs of consecutive slots that each state a band. A slot that is not one (合計, a blank) ends the run. */
50
+ const bandRuns = (slots: readonly (Slot | undefined)[], words: BandWords): PlacedBand[][] =>
51
+ slots
52
+ .reduce<PlacedBand[][]>(
53
+ (runs, slot) => {
54
+ const band = slot === undefined ? undefined : parseBand(slot.text, words);
55
+ if (slot === undefined || band === undefined) return [...runs, []];
56
+ const last = runs.at(-1) ?? [];
57
+ return [...runs.slice(0, -1), [...last, { band, start: slot.start, end: slot.end, text: slot.text.trim() }]];
58
+ },
59
+ [[]],
60
+ )
61
+ .filter((run) => run.length > 1);
62
+
63
+ const slipsOfRuns = (runs: readonly PlacedBand[][], heading: ReturnType<typeof headingOf>, words: BandWords): BandSlip[] =>
64
+ runs.flatMap((run) => {
65
+ const kind = runKindOf(
66
+ run.map((placed) => placed.band),
67
+ heading,
68
+ words,
69
+ );
70
+ return kind === undefined ? [] : bandSlips(run, kind);
71
+ });
72
+
73
+ const trimmedSlot = (text: string, start: number): Slot => {
74
+ const lead = text.length - text.trimStart().length;
75
+ return { text: text.trim(), start: start + lead, end: start + lead + text.trim().length };
76
+ };
77
+
78
+ const tableSlips = (source: string, words: BandWords): BandSlip[] =>
79
+ tablesOf(linesOf(source)).flatMap((table) => {
80
+ const headings = cellsOf(table.header);
81
+ const rows = table.rows.map(cellsOf);
82
+ return headings.flatMap((heading, column) =>
83
+ slipsOfRuns(
84
+ bandRuns(
85
+ rows.map((cells) => {
86
+ const cell = cells[column];
87
+ return cell === undefined ? undefined : trimmedSlot(cell.text, cell.start);
88
+ }),
89
+ words,
90
+ ),
91
+ headingOf(heading.text, words),
92
+ words,
93
+ ),
94
+ );
95
+ });
96
+
97
+ const LIST_MARKER = /^\s*(?:[-*+]|\d+[.)])\s+/u;
98
+ /** Where the band at the head of a list item ends: a colon, a comma, a bracket, or a dash set off by spaces. */
99
+ const ITEM_HEAD_END = /[::、,,((]|\s[-–—]\s|\t/u;
100
+
101
+ const listSlips = (doc: ProseDocument, words: BandWords): BandSlip[] =>
102
+ doc.lists.flatMap((list) => {
103
+ const heads = list.itemSpans.map((span): Slot | undefined => {
104
+ const item = doc.source.slice(span.start, span.end).split("\n")[0] ?? "";
105
+ const marker = LIST_MARKER.exec(item)?.[0];
106
+ if (marker === undefined) return undefined;
107
+ const body = item.slice(marker.length);
108
+ const end = ITEM_HEAD_END.exec(body)?.index ?? body.length;
109
+ return trimmedSlot(body.slice(0, end), span.start + marker.length);
110
+ });
111
+ return slipsOfRuns(bandRuns(heads, words), undefined, words);
112
+ });
113
+
114
+ export const rangeBand: Detector = (doc): Finding[] => {
115
+ const words = bandWordsOf(doc.lexicons);
116
+ return [...tableSlips(doc.source, words), ...listSlips(doc, words)].map((slip) => ({
117
+ rule: "range-band-mismatch",
118
+ severity: "warning",
119
+ line: 0,
120
+ column: 0,
121
+ quote: quoteAt(doc.source, slip.later.start),
122
+ ...(slip.kind === "gap" ? { variant: "gap" } : {}),
123
+ values: { earlier: slip.earlier.text, later: slip.later.text, offset: slip.later.start },
124
+ }));
125
+ };
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { capacityRuntime } from "../capacity-runtime.ts";
3
+
4
+ export const detector: Detector = capacityRuntime;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { connectionTimeShort } from "../time-order.ts";
3
+
4
+ export const detector: Detector = connectionTimeShort;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { contactVariant } from "../contact-variant.ts";
3
+
4
+ export const detector: Detector = contactVariant;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { countOverCapacity } from "../count-over-capacity.ts";
3
+
4
+ export const detector: Detector = countOverCapacity;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { dateStampOrder } from "../date-stamp-order.ts";
3
+
4
+ export const detector: Detector = dateStampOrder;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { durationProductMismatch } from "../derived-numbers.ts";
3
+
4
+ export const detector: Detector = durationProductMismatch;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { eventDeadline } from "../event-deadline.ts";
3
+
4
+ export const detector: Detector = eventDeadline;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { intervalCountMismatch } from "../use-interval.ts";
3
+
4
+ export const detector: Detector = intervalCountMismatch;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { layoutCode } from "../layout-code.ts";
3
+
4
+ export const detector: Detector = layoutCode;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { partyOrder } from "../party-order.ts";
3
+
4
+ export const detector: Detector = partyOrder;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { quantityRange } from "../quantity-range.ts";
3
+
4
+ export const detector: Detector = quantityRange;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { rangeBand } from "../range-band.ts";
3
+
4
+ export const detector: Detector = rangeBand;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { rentMultipleMismatch } from "../rent-multiple-mismatch.ts";
3
+
4
+ export const detector: Detector = rentMultipleMismatch;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { requirementLists } from "../requirement-lists.ts";
3
+
4
+ export const detector: Detector = requirementLists;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { returnType } from "../return-type.ts";
3
+
4
+ export const detector: Detector = returnType;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { scaledQuantityMismatch } from "../scaled-quantity.ts";
3
+
4
+ export const detector: Detector = scaledQuantityMismatch;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { stepTimeSumMismatch } from "../step-time-sum.ts";
3
+
4
+ export const detector: Detector = stepTimeSumMismatch;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { timeRangeReversed } from "../time-order.ts";
3
+
4
+ export const detector: Detector = timeRangeReversed;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { unlistedItemUsed } from "../unlisted-items.ts";
3
+
4
+ export const detector: Detector = unlistedItemUsed;
@@ -0,0 +1,4 @@
1
+ import type { Detector } from "../../plugin.ts";
2
+ import { walkTimeDistanceMismatch } from "../walk-time-distance-mismatch.ts";
3
+
4
+ export const detector: Detector = walkTimeDistanceMismatch;
@@ -0,0 +1,56 @@
1
+ // rent-multiple-mismatch: a deposit or key money given in months of rent beside an amount that is not that many months of
2
+ // the rent (structure/rent-multiple.ts). The amounts are currency-notation's, read with amount-multiplier's words of scale;
3
+ // the labels are rent-label and rent-multiple-label, the words rent-multiple-word, the counts number-word (digit), and a
4
+ // range of rent is joined by range-connector or amount-range-word.
5
+ import type { Detector, Finding, ProseDocument } from "../plugin.ts";
6
+ import { rentMultipleMismatches, type RentAmount, type RentMultipleWords } from "../structure/rent-multiple.ts";
7
+ import { scaledAmountOf, scaleWordsOf } from "./amount-scale.ts";
8
+ import { amountsIn, formsOf } from "./currency-notation.ts";
9
+ import { proseAndTablesOf } from "../table-text.ts";
10
+ import { quoteAround } from "./quote-around.ts";
11
+
12
+ const patternsOf = (doc: ProseDocument, lexicon: string, group?: string): string[] =>
13
+ (doc.lexicons[lexicon] ?? []).filter((entry) => group === undefined || entry.group === group).map((entry) => entry.pattern);
14
+
15
+ const numberWordsOf = (doc: ProseDocument): RentMultipleWords["numberWords"] =>
16
+ (doc.lexicons["number-word"] ?? []).flatMap((entry) =>
17
+ entry.group === "digit" && entry.weight !== undefined ? [{ word: entry.pattern, value: entry.weight }] : [],
18
+ );
19
+
20
+ const wordsOf = (doc: ProseDocument): RentMultipleWords => ({
21
+ rents: patternsOf(doc, "rent-label", "rent"),
22
+ fees: patternsOf(doc, "rent-label", "fee"),
23
+ multiples: patternsOf(doc, "rent-multiple-label"),
24
+ months: patternsOf(doc, "rent-multiple-word", "month"),
25
+ links: patternsOf(doc, "rent-multiple-word", "link"),
26
+ periods: patternsOf(doc, "rent-multiple-word", "period"),
27
+ skips: patternsOf(doc, "rent-multiple-word", "skip"),
28
+ connectors: [...patternsOf(doc, "range-connector"), ...patternsOf(doc, "amount-range-word")],
29
+ numberWords: numberWordsOf(doc),
30
+ });
31
+
32
+ const amountsOf = (text: string, doc: ProseDocument): RentAmount[] => {
33
+ const scales = scaleWordsOf(doc);
34
+ return amountsIn(
35
+ text,
36
+ formsOf(doc),
37
+ scales.map((scale) => scale.word),
38
+ ).flatMap((amount) => {
39
+ const read = scaledAmountOf(text, amount, scales);
40
+ return read === undefined
41
+ ? []
42
+ : [{ offset: read.offset, end: amount.offset + amount.written.length, currency: read.currency, value: read.value, scale: read.unit }];
43
+ });
44
+ };
45
+
46
+ export const rentMultipleMismatch: Detector = (doc): Finding[] => {
47
+ const text = proseAndTablesOf(doc);
48
+ return rentMultipleMismatches(text, amountsOf(text, doc), wordsOf(doc)).map((issue) => ({
49
+ rule: "rent-multiple-mismatch",
50
+ severity: "warning",
51
+ line: 0,
52
+ column: 0,
53
+ quote: quoteAround(text, issue.offset),
54
+ values: { ...issue.values, offset: issue.offset },
55
+ }));
56
+ };
@@ -0,0 +1,65 @@
1
+ // required-listed-as-preferred: the same skill under a required heading or label and again under a preferred one
2
+ // (structure/requirement-lists.ts). The headings and labels are requirement-heading's; the length of experience is read
3
+ // with requirement-length-unit, requirement-length-word and number-word; requirement-item-ending ends an item.
4
+ import type { Detector, Finding, ProseDocument, Span } from "../plugin.ts";
5
+ import { requiredListedAsPreferred, type RequirementBlock, type RequirementWords, type ValuedWord } from "../structure/requirement-lists.ts";
6
+ import { quoteAround } from "./quote-around.ts";
7
+
8
+ const patternsOf = (doc: ProseDocument, lexicon: string, group?: string): string[] =>
9
+ (doc.lexicons[lexicon] ?? []).filter((entry) => group === undefined || entry.group === group).map((entry) => entry.pattern);
10
+
11
+ const valuedOf = (doc: ProseDocument, lexicon: string, group?: string): ValuedWord[] =>
12
+ (doc.lexicons[lexicon] ?? []).flatMap((entry) =>
13
+ entry.weight === undefined || (group !== undefined && entry.group !== group) ? [] : [{ word: entry.pattern, value: entry.weight }],
14
+ );
15
+
16
+ const wordsOf = (doc: ProseDocument): RequirementWords => ({
17
+ required: patternsOf(doc, "requirement-heading", "required"),
18
+ preferred: patternsOf(doc, "requirement-heading", "preferred"),
19
+ units: valuedOf(doc, "requirement-length-unit"),
20
+ before: patternsOf(doc, "requirement-length-word", "before"),
21
+ after: patternsOf(doc, "requirement-length-word", "after"),
22
+ numbers: valuedOf(doc, "number-word", "digit"),
23
+ endings: patternsOf(doc, "requirement-item-ending"),
24
+ });
25
+
26
+ const LIST_MARKER = /^\s*(?:[-*+・•]|\d+[.).)])\s+(?:\[[ xX]\]\s+)?/u;
27
+
28
+ const headingsOf = (doc: ProseDocument): RequirementBlock[] =>
29
+ doc.sections
30
+ .filter((section) => section.depth > 0)
31
+ .map((section) => ({ kind: "heading", depth: section.depth, text: section.heading, offset: section.span.start }));
32
+
33
+ /** An item's own lines, joined, without its marker: the lines it wraps onto, up to a nested item. */
34
+ const itemText = (written: string): string => {
35
+ const [first = "", ...rest] = written.split("\n");
36
+ const nested = rest.findIndex((line) => LIST_MARKER.test(line));
37
+ return [first.replace(LIST_MARKER, ""), ...(nested === -1 ? rest : rest.slice(0, nested))].map((line) => line.trim()).join(" ");
38
+ };
39
+
40
+ const itemsOf = (doc: ProseDocument): RequirementBlock[] =>
41
+ doc.lists.flatMap((list) => list.itemSpans.map((span) => ({ kind: "item", text: itemText(doc.source.slice(span.start, span.end)), offset: span.start })));
42
+
43
+ const inside = (offset: number, spans: readonly Span[]): boolean => spans.some((span) => offset >= span.start && offset < span.end);
44
+
45
+ /** The lines outside lists, with code, headings and emphasis marks blanked out: the places a label (必須:) stands alone. */
46
+ const linesOf = (doc: ProseDocument): RequirementBlock[] => {
47
+ const prose = doc.prose ?? doc.source;
48
+ const starts = [0, ...[...prose.matchAll(/\n/gu)].map((match) => match.index + 1)];
49
+ return starts.flatMap((start) => {
50
+ const line = prose.slice(start, prose.indexOf("\n", start) === -1 ? prose.length : prose.indexOf("\n", start));
51
+ return line.trim() === "" || inside(start, doc.listSpans) ? [] : [{ kind: "line", text: line, offset: start }];
52
+ });
53
+ };
54
+
55
+ export const requirementLists: Detector = (doc): Finding[] => {
56
+ const blocks = [...headingsOf(doc), ...linesOf(doc), ...itemsOf(doc)].toSorted((left, right) => left.offset - right.offset);
57
+ return requiredListedAsPreferred(blocks, wordsOf(doc)).map((issue) => ({
58
+ rule: "required-listed-as-preferred",
59
+ severity: "warning",
60
+ line: 0,
61
+ column: 0,
62
+ quote: quoteAround(doc.source, issue.offset),
63
+ values: { ...issue.values, offset: issue.offset },
64
+ }));
65
+ };
@@ -0,0 +1,30 @@
1
+ // return-type-mismatch: one function's return type stated two ways on a page, the signature against a "Returns:" line, a
2
+ // table's return column or a sentence (return-type.ts). The words come from the return-label, return-verb, return-subject,
3
+ // return-type-word, return-clause and return-item lexicons.
4
+ import { quoteAt } from "./structure-tree.ts";
5
+ import { returnTypeClashes, type ReturnWords } from "../return-type.ts";
6
+ import type { Detector, Finding, Lexicon } from "../plugin.ts";
7
+
8
+ const patterns = (lexicon: Lexicon | undefined): string[] => (lexicon ?? []).map((entry) => entry.pattern);
9
+
10
+ const kindsOf = (lexicon: Lexicon | undefined): Map<string, string> =>
11
+ new Map((lexicon ?? []).flatMap((entry): [string, string][] => (entry.group === undefined ? [] : [[entry.pattern, entry.group]])));
12
+
13
+ const wordsOf = (lexicons: Readonly<Record<string, Lexicon>>): ReturnWords => ({
14
+ labels: patterns(lexicons["return-label"]),
15
+ verbs: patterns(lexicons["return-verb"]),
16
+ subjects: patterns(lexicons["return-subject"]),
17
+ kinds: kindsOf(lexicons["return-type-word"]),
18
+ clauses: patterns(lexicons["return-clause"]),
19
+ items: patterns(lexicons["return-item"]),
20
+ });
21
+
22
+ export const returnType: Detector = (doc): Finding[] =>
23
+ returnTypeClashes(doc.source, wordsOf(doc.lexicons)).map((clash) => ({
24
+ rule: "return-type-mismatch",
25
+ severity: "warning",
26
+ line: 0,
27
+ column: 0,
28
+ quote: quoteAt(doc.source, clash.offset),
29
+ values: { function: clash.fn, stated: clash.stated, signature: clash.signature, offset: clash.offset },
30
+ }));
@@ -0,0 +1,49 @@
1
+ // One row of a servings table (4人分 / 8人分, Serves 4 / Serves 8) that does not scale by the columns' ratio while the other rows
2
+ // do. The column marks, the amounts left to the cook and the spellings of one unit come from the language packages.
3
+ import { scaleSlips, type ScaleWords } from "../structure/scaled-quantities.ts";
4
+ import type { MeasureUnit } from "../facts/measures.ts";
5
+ import { quoteAt } from "./structure-tree.ts";
6
+ import type { Detector, Finding, ProseDocument } from "../plugin.ts";
7
+
8
+ const DIMENSIONS = ["unit-mass", "unit-volume"] as const;
9
+
10
+ const measuresOf = (doc: ProseDocument): MeasureUnit[] =>
11
+ DIMENSIONS.flatMap((dimension) =>
12
+ (doc.lexicons[dimension] ?? []).flatMap((entry) =>
13
+ entry.weight === undefined
14
+ ? []
15
+ : [{ pattern: entry.pattern, dimension, factors: [entry.weight], zero: 0, before: entry.position === "before", context: [] }],
16
+ ),
17
+ );
18
+
19
+ const wordsOf = (doc: ProseDocument): ScaleWords => ({
20
+ columns: (doc.lexicons["servings-column"] ?? []).map((entry) => ({ pattern: entry.pattern, position: entry.position })),
21
+ unscaled: (doc.lexicons["unscaled-amount"] ?? []).map((entry) => entry.pattern),
22
+ unitForms: (doc.lexicons["scaled-unit-form"] ?? []).map((entry) => ({ pattern: entry.pattern, group: entry.group ?? entry.pattern })),
23
+ measures: measuresOf(doc),
24
+ });
25
+
26
+ const DECIMALS = 1000;
27
+ const shown = (amount: number): string => String(Math.round(amount * DECIMALS) / DECIMALS);
28
+
29
+ export const scaledQuantityMismatch: Detector = (doc): Finding[] =>
30
+ scaleSlips(doc.source, wordsOf(doc)).map((slip) => {
31
+ const offset = slip.cell.start + (slip.cell.text.length - slip.cell.text.trimStart().length);
32
+ return {
33
+ rule: "scaled-quantity-mismatch",
34
+ severity: "warning",
35
+ line: 0,
36
+ column: 0,
37
+ quote: quoteAt(doc.source, offset),
38
+ values: {
39
+ item: slip.item.text.trim(),
40
+ written: slip.cell.text.trim(),
41
+ column: slip.heading,
42
+ other: slip.other.text.trim(),
43
+ otherColumn: slip.otherHeading,
44
+ expected: shown(slip.expected),
45
+ scaledRows: slip.scaledRows,
46
+ offset,
47
+ },
48
+ };
49
+ });
@@ -371,7 +371,9 @@ export const concreteEvidence: Detector = (doc, options): Finding[] => {
371
371
  * ダッシュの多用。英語では正当な用法が多いが、2026 年時点で最も知られた生成文のシグナルでもある。
372
372
  * 日本語の組版ではそもそも扱いが難しい。どちらが正しいかは severity の言語別指定で分ける。spec §12.4。
373
373
  */
374
- const DASH = /[\u2014\u2015\u2013]/gu;
374
+ // An en dash between two digits (45–58, 10:00–10:15) is a range mark, the typographer's correct choice, not a dash that
375
+ // sets off words.
376
+ const DASH = /[\u2014\u2015]|(?<!\p{Nd})\u2013|\u2013(?!\p{Nd})/gu;
375
377
 
376
378
  export const dashDensity: Detector = (doc, options): Finding[] => {
377
379
  const hits = findIn(doc, DASH);
@@ -0,0 +1,55 @@
1
+ // A stated total time (所要時間:60分, Total time: 1 hr) that is not the sum of the times written in the numbered steps. The
2
+ // units, the total labels, the rough-figure marks and the marks of a time that is not a step's own come from the language packages.
3
+ import { stepTimeSlip, type StepTimeWords } from "../structure/step-times.ts";
4
+ import type { Mark } from "../structure/time-marks.ts";
5
+ import { quoteAt } from "./structure-tree.ts";
6
+ import type { Detector, Finding, ProseDocument } from "../plugin.ts";
7
+
8
+ const SECONDS_PER_HOUR = 3600;
9
+ const SECONDS_PER_MINUTE = 60;
10
+
11
+ const patternsOf = (doc: ProseDocument, id: string): string[] => (doc.lexicons[id] ?? []).map((entry) => entry.pattern);
12
+
13
+ const marksOf = (doc: ProseDocument, id: string): Mark[] =>
14
+ (doc.lexicons[id] ?? []).map((entry) => ({ pattern: entry.pattern, position: entry.position, group: entry.group }));
15
+
16
+ const unitsWeighing = (doc: ProseDocument, seconds: number): string[] =>
17
+ (doc.lexicons["unit-time"] ?? []).filter((entry) => entry.weight === seconds).map((entry) => entry.pattern);
18
+
19
+ const RANGE_GROUP = "range";
20
+
21
+ const wordsOf = (doc: ProseDocument): StepTimeWords => {
22
+ const notOwn = marksOf(doc, "step-time-not-own");
23
+ return {
24
+ lengths: {
25
+ hourUnits: unitsWeighing(doc, SECONDS_PER_HOUR),
26
+ minuteUnits: unitsWeighing(doc, SECONDS_PER_MINUTE),
27
+ halves: patternsOf(doc, "length-half"),
28
+ numberWords: patternsOf(doc, "count-number"),
29
+ },
30
+ totals: marksOf(doc, "step-time-total"),
31
+ approximate: marksOf(doc, "approximate-marker"),
32
+ notOwn: notOwn.filter((mark) => mark.group !== RANGE_GROUP),
33
+ rangeJoiners: notOwn.filter((mark) => mark.group === RANGE_GROUP).map((mark) => mark.pattern),
34
+ };
35
+ };
36
+
37
+ export const stepTimeSumMismatch: Detector = (doc): Finding[] => {
38
+ const slip = stepTimeSlip(doc.source, wordsOf(doc));
39
+ if (slip === undefined) return [];
40
+ return [
41
+ {
42
+ rule: "step-time-sum-mismatch",
43
+ severity: "warning",
44
+ line: 0,
45
+ column: 0,
46
+ quote: quoteAt(doc.source, slip.total.start),
47
+ values: {
48
+ written: doc.source.slice(slip.total.start, slip.total.end),
49
+ sum: slip.sum,
50
+ steps: slip.steps,
51
+ offset: slip.total.start,
52
+ },
53
+ },
54
+ ];
55
+ };