chaffjs 0.30.0 → 0.32.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.
- package/README.ja.md +330 -0
- package/README.md +119 -257
- package/dist/announced-count.d.ts +2 -0
- package/dist/announced-count.d.ts.map +1 -1
- package/dist/announced-count.js +4 -3
- package/dist/announced-count.js.map +1 -1
- package/dist/company-kana-spelling.d.ts +31 -0
- package/dist/company-kana-spelling.d.ts.map +1 -0
- package/dist/company-kana-spelling.js +79 -0
- package/dist/company-kana-spelling.js.map +1 -0
- package/dist/company-names.d.ts +32 -1
- package/dist/company-names.d.ts.map +1 -1
- package/dist/company-names.js +129 -22
- package/dist/company-names.js.map +1 -1
- package/dist/contacts/addresses.d.ts +21 -0
- package/dist/contacts/addresses.d.ts.map +1 -0
- package/dist/contacts/addresses.js +144 -0
- package/dist/contacts/addresses.js.map +1 -0
- package/dist/contacts/emails.d.ts +11 -0
- package/dist/contacts/emails.d.ts.map +1 -0
- package/dist/contacts/emails.js +51 -0
- package/dist/contacts/emails.js.map +1 -0
- package/dist/contacts/table-rows.d.ts +7 -0
- package/dist/contacts/table-rows.d.ts.map +1 -0
- package/dist/contacts/table-rows.js +42 -0
- package/dist/contacts/table-rows.js.map +1 -0
- package/dist/contacts/variants.d.ts +14 -0
- package/dist/contacts/variants.d.ts.map +1 -0
- package/dist/contacts/variants.js +25 -0
- package/dist/contacts/variants.js.map +1 -0
- package/dist/derived/age-on-date.d.ts +53 -0
- package/dist/derived/age-on-date.d.ts.map +1 -0
- package/dist/derived/age-on-date.js +114 -0
- package/dist/derived/age-on-date.js.map +1 -0
- package/dist/derived/battery-runtime.d.ts +85 -0
- package/dist/derived/battery-runtime.d.ts.map +1 -0
- package/dist/derived/battery-runtime.js +217 -0
- package/dist/derived/battery-runtime.js.map +1 -0
- package/dist/derived/durations.d.ts +17 -2
- package/dist/derived/durations.d.ts.map +1 -1
- package/dist/derived/durations.js +61 -10
- package/dist/derived/durations.js.map +1 -1
- package/dist/derived/hours-and-minutes.d.ts +26 -0
- package/dist/derived/hours-and-minutes.d.ts.map +1 -0
- package/dist/derived/hours-and-minutes.js +24 -0
- package/dist/derived/hours-and-minutes.js.map +1 -0
- package/dist/derived/hyphenated-counts.d.ts +15 -0
- package/dist/derived/hyphenated-counts.d.ts.map +1 -0
- package/dist/derived/hyphenated-counts.js +31 -0
- package/dist/derived/hyphenated-counts.js.map +1 -0
- package/dist/derived/marked-dates.d.ts +15 -0
- package/dist/derived/marked-dates.d.ts.map +1 -0
- package/dist/derived/marked-dates.js +41 -0
- package/dist/derived/marked-dates.js.map +1 -0
- package/dist/derived/money-span.d.ts +9 -0
- package/dist/derived/money-span.d.ts.map +1 -0
- package/dist/derived/money-span.js +6 -0
- package/dist/derived/money-span.js.map +1 -0
- package/dist/derived/period-counts.d.ts +48 -0
- package/dist/derived/period-counts.d.ts.map +1 -0
- package/dist/derived/period-counts.js +128 -0
- package/dist/derived/period-counts.js.map +1 -0
- package/dist/derived/period-parts.d.ts +55 -0
- package/dist/derived/period-parts.d.ts.map +1 -0
- package/dist/derived/period-parts.js +283 -0
- package/dist/derived/period-parts.js.map +1 -0
- package/dist/derived/readable-date.d.ts +20 -0
- package/dist/derived/readable-date.d.ts.map +1 -0
- package/dist/derived/readable-date.js +50 -0
- package/dist/derived/readable-date.js.map +1 -0
- package/dist/derived/stays.d.ts +3 -1
- package/dist/derived/stays.d.ts.map +1 -1
- package/dist/derived/stays.js +3 -0
- package/dist/derived/stays.js.map +1 -1
- package/dist/derived/time-lengths.d.ts.map +1 -1
- package/dist/derived/time-lengths.js +12 -9
- package/dist/derived/time-lengths.js.map +1 -1
- package/dist/derived/timesheet-hours.d.ts +27 -0
- package/dist/derived/timesheet-hours.d.ts.map +1 -0
- package/dist/derived/timesheet-hours.js +86 -0
- package/dist/derived/timesheet-hours.js.map +1 -0
- package/dist/derived/use-interval.d.ts +33 -0
- package/dist/derived/use-interval.d.ts.map +1 -0
- package/dist/derived/use-interval.js +93 -0
- package/dist/derived/use-interval.js.map +1 -0
- package/dist/derived/use-maximum.d.ts +27 -0
- package/dist/derived/use-maximum.d.ts.map +1 -0
- package/dist/derived/use-maximum.js +104 -0
- package/dist/derived/use-maximum.js.map +1 -0
- package/dist/derived/working-hours.d.ts +4 -5
- package/dist/derived/working-hours.d.ts.map +1 -1
- package/dist/detectors/announced-count.d.ts.map +1 -1
- package/dist/detectors/announced-count.js +1 -0
- package/dist/detectors/announced-count.js.map +1 -1
- package/dist/detectors/annual-holidays-mismatch.d.ts +3 -0
- package/dist/detectors/annual-holidays-mismatch.d.ts.map +1 -0
- package/dist/detectors/annual-holidays-mismatch.js +29 -0
- package/dist/detectors/annual-holidays-mismatch.js.map +1 -0
- package/dist/detectors/annual-pay-mismatch.d.ts +3 -0
- package/dist/detectors/annual-pay-mismatch.d.ts.map +1 -0
- package/dist/detectors/annual-pay-mismatch.js +52 -0
- package/dist/detectors/annual-pay-mismatch.js.map +1 -0
- package/dist/detectors/blank-structure.d.ts +3 -1
- package/dist/detectors/blank-structure.d.ts.map +1 -1
- package/dist/detectors/blank-structure.js +45 -12
- package/dist/detectors/blank-structure.js.map +1 -1
- package/dist/detectors/bmi-mismatch.d.ts +3 -0
- package/dist/detectors/bmi-mismatch.d.ts.map +1 -0
- package/dist/detectors/bmi-mismatch.js +70 -0
- package/dist/detectors/bmi-mismatch.js.map +1 -0
- package/dist/detectors/capacity-runtime.d.ts +7 -0
- package/dist/detectors/capacity-runtime.d.ts.map +1 -0
- package/dist/detectors/capacity-runtime.js +98 -0
- package/dist/detectors/capacity-runtime.js.map +1 -0
- package/dist/detectors/change-rate.d.ts.map +1 -1
- package/dist/detectors/change-rate.js +24 -9
- package/dist/detectors/change-rate.js.map +1 -1
- package/dist/detectors/closing-balance-mismatch.d.ts +3 -0
- package/dist/detectors/closing-balance-mismatch.d.ts.map +1 -0
- package/dist/detectors/closing-balance-mismatch.js +42 -0
- package/dist/detectors/closing-balance-mismatch.js.map +1 -0
- package/dist/detectors/contact-variant.d.ts +3 -0
- package/dist/detectors/contact-variant.d.ts.map +1 -0
- package/dist/detectors/contact-variant.js +25 -0
- package/dist/detectors/contact-variant.js.map +1 -0
- package/dist/detectors/count-over-capacity.d.ts +4 -0
- package/dist/detectors/count-over-capacity.d.ts.map +1 -0
- package/dist/detectors/count-over-capacity.js +26 -0
- package/dist/detectors/count-over-capacity.js.map +1 -0
- package/dist/detectors/cumulative-below-current.d.ts +3 -0
- package/dist/detectors/cumulative-below-current.d.ts.map +1 -0
- package/dist/detectors/cumulative-below-current.js +25 -0
- package/dist/detectors/cumulative-below-current.js.map +1 -0
- package/dist/detectors/currency-column.d.ts +3 -0
- package/dist/detectors/currency-column.d.ts.map +1 -0
- package/dist/detectors/currency-column.js +32 -0
- package/dist/detectors/currency-column.js.map +1 -0
- package/dist/detectors/date-any-year.d.ts +24 -0
- package/dist/detectors/date-any-year.d.ts.map +1 -0
- package/dist/detectors/date-any-year.js +103 -0
- package/dist/detectors/date-any-year.js.map +1 -0
- package/dist/detectors/date-outside-period.d.ts.map +1 -1
- package/dist/detectors/date-outside-period.js +5 -10
- package/dist/detectors/date-outside-period.js.map +1 -1
- package/dist/detectors/date-stamp-order.d.ts +3 -0
- package/dist/detectors/date-stamp-order.d.ts.map +1 -0
- package/dist/detectors/date-stamp-order.js +25 -0
- package/dist/detectors/date-stamp-order.js.map +1 -0
- package/dist/detectors/date-year.d.ts +18 -6
- package/dist/detectors/date-year.d.ts.map +1 -1
- package/dist/detectors/date-year.js +39 -11
- package/dist/detectors/date-year.js.map +1 -1
- package/dist/detectors/deductible-exceeds-limit.d.ts +4 -0
- package/dist/detectors/deductible-exceeds-limit.d.ts.map +1 -0
- package/dist/detectors/deductible-exceeds-limit.js +46 -0
- package/dist/detectors/deductible-exceeds-limit.js.map +1 -0
- package/dist/detectors/defined-term-form.d.ts.map +1 -1
- package/dist/detectors/defined-term-form.js +45 -9
- package/dist/detectors/defined-term-form.js.map +1 -1
- package/dist/detectors/definition-use.d.ts +1 -1
- package/dist/detectors/definition-use.d.ts.map +1 -1
- package/dist/detectors/definition-use.js +4 -2
- package/dist/detectors/definition-use.js.map +1 -1
- package/dist/detectors/derived-numbers.d.ts +12 -3
- package/dist/detectors/derived-numbers.d.ts.map +1 -1
- package/dist/detectors/derived-numbers.js +45 -72
- package/dist/detectors/derived-numbers.js.map +1 -1
- package/dist/detectors/discount-rate.d.ts +3 -0
- package/dist/detectors/discount-rate.d.ts.map +1 -0
- package/dist/detectors/discount-rate.js +35 -0
- package/dist/detectors/discount-rate.js.map +1 -0
- package/dist/detectors/due-date.d.ts.map +1 -1
- package/dist/detectors/due-date.js +16 -3
- package/dist/detectors/due-date.js.map +1 -1
- package/dist/detectors/email-letter.d.ts +10 -2
- package/dist/detectors/email-letter.d.ts.map +1 -1
- package/dist/detectors/email-letter.js +24 -5
- package/dist/detectors/email-letter.js.map +1 -1
- package/dist/detectors/en-shape.d.ts.map +1 -1
- package/dist/detectors/en-shape.js +7 -4
- package/dist/detectors/en-shape.js.map +1 -1
- package/dist/detectors/event-deadline.d.ts +3 -0
- package/dist/detectors/event-deadline.d.ts.map +1 -0
- package/dist/detectors/event-deadline.js +33 -0
- package/dist/detectors/event-deadline.js.map +1 -0
- package/dist/detectors/fact-consistency.d.ts +1 -1
- package/dist/detectors/fact-consistency.d.ts.map +1 -1
- package/dist/detectors/fact-consistency.js +161 -5
- package/dist/detectors/fact-consistency.js.map +1 -1
- package/dist/detectors/gloss-year.d.ts +11 -0
- package/dist/detectors/gloss-year.d.ts.map +1 -0
- package/dist/detectors/gloss-year.js +14 -0
- package/dist/detectors/gloss-year.js.map +1 -0
- package/dist/detectors/gpa-mismatch.d.ts +3 -0
- package/dist/detectors/gpa-mismatch.d.ts.map +1 -0
- package/dist/detectors/gpa-mismatch.js +39 -0
- package/dist/detectors/gpa-mismatch.js.map +1 -0
- package/dist/detectors/heading-case.d.ts +5 -2
- package/dist/detectors/heading-case.d.ts.map +1 -1
- package/dist/detectors/heading-case.js +12 -4
- package/dist/detectors/heading-case.js.map +1 -1
- package/dist/detectors/heading-echo.d.ts +5 -0
- package/dist/detectors/heading-echo.d.ts.map +1 -1
- package/dist/detectors/heading-echo.js +14 -1
- package/dist/detectors/heading-echo.js.map +1 -1
- package/dist/detectors/impossible-date.d.ts.map +1 -1
- package/dist/detectors/impossible-date.js +22 -6
- package/dist/detectors/impossible-date.js.map +1 -1
- package/dist/detectors/installment-total-mismatch.d.ts +3 -0
- package/dist/detectors/installment-total-mismatch.d.ts.map +1 -0
- package/dist/detectors/installment-total-mismatch.js +49 -0
- package/dist/detectors/installment-total-mismatch.js.map +1 -0
- package/dist/detectors/interest.d.ts +3 -0
- package/dist/detectors/interest.d.ts.map +1 -0
- package/dist/detectors/interest.js +38 -0
- package/dist/detectors/interest.js.map +1 -0
- package/dist/detectors/lab-columns.d.ts +4 -0
- package/dist/detectors/lab-columns.d.ts.map +1 -0
- package/dist/detectors/lab-columns.js +3 -0
- package/dist/detectors/lab-columns.js.map +1 -0
- package/dist/detectors/labelled-age.d.ts +4 -0
- package/dist/detectors/labelled-age.d.ts.map +1 -0
- package/dist/detectors/labelled-age.js +110 -0
- package/dist/detectors/labelled-age.js.map +1 -0
- package/dist/detectors/layout-code.d.ts +5 -0
- package/dist/detectors/layout-code.d.ts.map +1 -0
- package/dist/detectors/layout-code.js +124 -0
- package/dist/detectors/layout-code.js.map +1 -0
- package/dist/detectors/line-amount.d.ts.map +1 -1
- package/dist/detectors/line-amount.js +45 -2
- package/dist/detectors/line-amount.js.map +1 -1
- package/dist/detectors/measured-facts.d.ts +8 -0
- package/dist/detectors/measured-facts.d.ts.map +1 -0
- package/dist/detectors/measured-facts.js +18 -0
- package/dist/detectors/measured-facts.js.map +1 -0
- package/dist/detectors/meter-usage.d.ts +3 -0
- package/dist/detectors/meter-usage.d.ts.map +1 -0
- package/dist/detectors/meter-usage.js +37 -0
- package/dist/detectors/meter-usage.js.map +1 -0
- package/dist/detectors/name-field.d.ts +13 -0
- package/dist/detectors/name-field.d.ts.map +1 -0
- package/dist/detectors/name-field.js +38 -0
- package/dist/detectors/name-field.js.map +1 -0
- package/dist/detectors/name-variant-model-codes.d.ts +11 -0
- package/dist/detectors/name-variant-model-codes.d.ts.map +1 -0
- package/dist/detectors/name-variant-model-codes.js +21 -0
- package/dist/detectors/name-variant-model-codes.js.map +1 -0
- package/dist/detectors/name-variant.d.ts.map +1 -1
- package/dist/detectors/name-variant.js +151 -16
- package/dist/detectors/name-variant.js.map +1 -1
- package/dist/detectors/net-amount-mismatch.d.ts +10 -0
- package/dist/detectors/net-amount-mismatch.d.ts.map +1 -0
- package/dist/detectors/net-amount-mismatch.js +70 -0
- package/dist/detectors/net-amount-mismatch.js.map +1 -0
- package/dist/detectors/net-gross-weight.d.ts +3 -0
- package/dist/detectors/net-gross-weight.d.ts.map +1 -0
- package/dist/detectors/net-gross-weight.js +35 -0
- package/dist/detectors/net-gross-weight.js.map +1 -0
- package/dist/detectors/nominal-step.d.ts +3 -0
- package/dist/detectors/nominal-step.d.ts.map +1 -0
- package/dist/detectors/nominal-step.js +28 -0
- package/dist/detectors/nominal-step.js.map +1 -0
- package/dist/detectors/number-style.d.ts +2 -0
- package/dist/detectors/number-style.d.ts.map +1 -1
- package/dist/detectors/number-style.js +8 -2
- package/dist/detectors/number-style.js.map +1 -1
- package/dist/detectors/order-quantity.d.ts +10 -0
- package/dist/detectors/order-quantity.d.ts.map +1 -0
- package/dist/detectors/order-quantity.js +35 -0
- package/dist/detectors/order-quantity.js.map +1 -0
- package/dist/detectors/orthographic-variant.d.ts.map +1 -1
- package/dist/detectors/orthographic-variant.js +97 -17
- package/dist/detectors/orthographic-variant.js.map +1 -1
- package/dist/detectors/orthography.d.ts.map +1 -1
- package/dist/detectors/orthography.js +21 -7
- package/dist/detectors/orthography.js.map +1 -1
- package/dist/detectors/period-label-conflict.d.ts +4 -0
- package/dist/detectors/period-label-conflict.d.ts.map +1 -0
- package/dist/detectors/period-label-conflict.js +34 -0
- package/dist/detectors/period-label-conflict.js.map +1 -0
- package/dist/detectors/period-multiple-mismatch.d.ts +3 -0
- package/dist/detectors/period-multiple-mismatch.d.ts.map +1 -0
- package/dist/detectors/period-multiple-mismatch.js +36 -0
- package/dist/detectors/period-multiple-mismatch.js.map +1 -0
- package/dist/detectors/period-part.d.ts +4 -0
- package/dist/detectors/period-part.d.ts.map +1 -0
- package/dist/detectors/period-part.js +58 -0
- package/dist/detectors/period-part.js.map +1 -0
- package/dist/detectors/quantity-range.d.ts +3 -0
- package/dist/detectors/quantity-range.d.ts.map +1 -0
- package/dist/detectors/quantity-range.js +35 -0
- package/dist/detectors/quantity-range.js.map +1 -0
- package/dist/detectors/range-band.d.ts +5 -0
- package/dist/detectors/range-band.d.ts.map +1 -0
- package/dist/detectors/range-band.js +80 -0
- package/dist/detectors/range-band.js.map +1 -0
- package/dist/detectors/range-words.d.ts +5 -0
- package/dist/detectors/range-words.d.ts.map +1 -0
- package/dist/detectors/range-words.js +14 -0
- package/dist/detectors/range-words.js.map +1 -0
- package/dist/detectors/ratio-mismatch.d.ts +7 -0
- package/dist/detectors/ratio-mismatch.d.ts.map +1 -0
- package/dist/detectors/ratio-mismatch.js +89 -0
- package/dist/detectors/ratio-mismatch.js.map +1 -0
- package/dist/detectors/readable-dates.d.ts +9 -0
- package/dist/detectors/readable-dates.d.ts.map +1 -0
- package/dist/detectors/readable-dates.js +23 -0
- package/dist/detectors/readable-dates.js.map +1 -0
- package/dist/detectors/reference-flag.d.ts +3 -0
- package/dist/detectors/reference-flag.d.ts.map +1 -0
- package/dist/detectors/reference-flag.js +31 -0
- package/dist/detectors/reference-flag.js.map +1 -0
- package/dist/detectors/reference-number-repeated.d.ts +3 -0
- package/dist/detectors/reference-number-repeated.d.ts.map +1 -0
- package/dist/detectors/reference-number-repeated.js +22 -0
- package/dist/detectors/reference-number-repeated.js.map +1 -0
- package/dist/detectors/reference-number-variant.d.ts +3 -0
- package/dist/detectors/reference-number-variant.d.ts.map +1 -0
- package/dist/detectors/reference-number-variant.js +40 -0
- package/dist/detectors/reference-number-variant.js.map +1 -0
- package/dist/detectors/reference-unit.d.ts +3 -0
- package/dist/detectors/reference-unit.d.ts.map +1 -0
- package/dist/detectors/reference-unit.js +19 -0
- package/dist/detectors/reference-unit.js.map +1 -0
- package/dist/detectors/registry/annual-holidays-mismatch.d.ts +3 -0
- package/dist/detectors/registry/annual-holidays-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/annual-holidays-mismatch.js +3 -0
- package/dist/detectors/registry/annual-holidays-mismatch.js.map +1 -0
- package/dist/detectors/registry/annual-pay-mismatch.d.ts +3 -0
- package/dist/detectors/registry/annual-pay-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/annual-pay-mismatch.js +3 -0
- package/dist/detectors/registry/annual-pay-mismatch.js.map +1 -0
- package/dist/detectors/registry/backorder-mismatch.d.ts +3 -0
- package/dist/detectors/registry/backorder-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/backorder-mismatch.js +3 -0
- package/dist/detectors/registry/backorder-mismatch.js.map +1 -0
- package/dist/detectors/registry/bmi-mismatch.d.ts +3 -0
- package/dist/detectors/registry/bmi-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/bmi-mismatch.js +3 -0
- package/dist/detectors/registry/bmi-mismatch.js.map +1 -0
- package/dist/detectors/registry/capacity-runtime-mismatch.d.ts +3 -0
- package/dist/detectors/registry/capacity-runtime-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/capacity-runtime-mismatch.js +3 -0
- package/dist/detectors/registry/capacity-runtime-mismatch.js.map +1 -0
- package/dist/detectors/registry/closing-balance-mismatch.d.ts +3 -0
- package/dist/detectors/registry/closing-balance-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/closing-balance-mismatch.js +3 -0
- package/dist/detectors/registry/closing-balance-mismatch.js.map +1 -0
- package/dist/detectors/registry/contact-variant.d.ts +3 -0
- package/dist/detectors/registry/contact-variant.d.ts.map +1 -0
- package/dist/detectors/registry/contact-variant.js +3 -0
- package/dist/detectors/registry/contact-variant.js.map +1 -0
- package/dist/detectors/registry/count-over-capacity.d.ts +3 -0
- package/dist/detectors/registry/count-over-capacity.d.ts.map +1 -0
- package/dist/detectors/registry/count-over-capacity.js +3 -0
- package/dist/detectors/registry/count-over-capacity.js.map +1 -0
- package/dist/detectors/registry/cumulative-below-current.d.ts +3 -0
- package/dist/detectors/registry/cumulative-below-current.d.ts.map +1 -0
- package/dist/detectors/registry/cumulative-below-current.js +3 -0
- package/dist/detectors/registry/cumulative-below-current.js.map +1 -0
- package/dist/detectors/registry/currency-column-mix.d.ts +3 -0
- package/dist/detectors/registry/currency-column-mix.d.ts.map +1 -0
- package/dist/detectors/registry/currency-column-mix.js +3 -0
- package/dist/detectors/registry/currency-column-mix.js.map +1 -0
- package/dist/detectors/registry/date-stamp-order.d.ts +3 -0
- package/dist/detectors/registry/date-stamp-order.d.ts.map +1 -0
- package/dist/detectors/registry/date-stamp-order.js +3 -0
- package/dist/detectors/registry/date-stamp-order.js.map +1 -0
- package/dist/detectors/registry/deductible-exceeds-limit.d.ts +3 -0
- package/dist/detectors/registry/deductible-exceeds-limit.d.ts.map +1 -0
- package/dist/detectors/registry/deductible-exceeds-limit.js +3 -0
- package/dist/detectors/registry/deductible-exceeds-limit.js.map +1 -0
- package/dist/detectors/registry/delivered-over-ordered.d.ts +3 -0
- package/dist/detectors/registry/delivered-over-ordered.d.ts.map +1 -0
- package/dist/detectors/registry/delivered-over-ordered.js +3 -0
- package/dist/detectors/registry/delivered-over-ordered.js.map +1 -0
- package/dist/detectors/registry/discount-rate.d.ts +3 -0
- package/dist/detectors/registry/discount-rate.d.ts.map +1 -0
- package/dist/detectors/registry/discount-rate.js +3 -0
- package/dist/detectors/registry/discount-rate.js.map +1 -0
- package/dist/detectors/registry/elapsed-years-mismatch.js +1 -1
- package/dist/detectors/registry/elapsed-years-mismatch.js.map +1 -1
- package/dist/detectors/registry/event-deadline.d.ts +3 -0
- package/dist/detectors/registry/event-deadline.d.ts.map +1 -0
- package/dist/detectors/registry/event-deadline.js +3 -0
- package/dist/detectors/registry/event-deadline.js.map +1 -0
- package/dist/detectors/registry/gpa-mismatch.d.ts +3 -0
- package/dist/detectors/registry/gpa-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/gpa-mismatch.js +3 -0
- package/dist/detectors/registry/gpa-mismatch.js.map +1 -0
- package/dist/detectors/registry/installment-total-mismatch.d.ts +3 -0
- package/dist/detectors/registry/installment-total-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/installment-total-mismatch.js +3 -0
- package/dist/detectors/registry/installment-total-mismatch.js.map +1 -0
- package/dist/detectors/registry/interest.d.ts +3 -0
- package/dist/detectors/registry/interest.d.ts.map +1 -0
- package/dist/detectors/registry/interest.js +3 -0
- package/dist/detectors/registry/interest.js.map +1 -0
- package/dist/detectors/registry/interval-count-mismatch.d.ts +3 -0
- package/dist/detectors/registry/interval-count-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/interval-count-mismatch.js +3 -0
- package/dist/detectors/registry/interval-count-mismatch.js.map +1 -0
- package/dist/detectors/registry/layout-code-mismatch.d.ts +3 -0
- package/dist/detectors/registry/layout-code-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/layout-code-mismatch.js +3 -0
- package/dist/detectors/registry/layout-code-mismatch.js.map +1 -0
- package/dist/detectors/registry/meter-usage.d.ts +3 -0
- package/dist/detectors/registry/meter-usage.d.ts.map +1 -0
- package/dist/detectors/registry/meter-usage.js +3 -0
- package/dist/detectors/registry/meter-usage.js.map +1 -0
- package/dist/detectors/registry/net-amount-mismatch.d.ts +3 -0
- package/dist/detectors/registry/net-amount-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/net-amount-mismatch.js +3 -0
- package/dist/detectors/registry/net-amount-mismatch.js.map +1 -0
- package/dist/detectors/registry/net-over-gross.d.ts +3 -0
- package/dist/detectors/registry/net-over-gross.d.ts.map +1 -0
- package/dist/detectors/registry/net-over-gross.js +3 -0
- package/dist/detectors/registry/net-over-gross.js.map +1 -0
- package/dist/detectors/registry/period-label-conflict.d.ts +3 -0
- package/dist/detectors/registry/period-label-conflict.d.ts.map +1 -0
- package/dist/detectors/registry/period-label-conflict.js +3 -0
- package/dist/detectors/registry/period-label-conflict.js.map +1 -0
- package/dist/detectors/registry/period-multiple-mismatch.d.ts +3 -0
- package/dist/detectors/registry/period-multiple-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/period-multiple-mismatch.js +3 -0
- package/dist/detectors/registry/period-multiple-mismatch.js.map +1 -0
- package/dist/detectors/registry/period-part-exceeds-whole.d.ts +3 -0
- package/dist/detectors/registry/period-part-exceeds-whole.d.ts.map +1 -0
- package/dist/detectors/registry/period-part-exceeds-whole.js +3 -0
- package/dist/detectors/registry/period-part-exceeds-whole.js.map +1 -0
- package/dist/detectors/registry/product-exceeds-maximum.d.ts +3 -0
- package/dist/detectors/registry/product-exceeds-maximum.d.ts.map +1 -0
- package/dist/detectors/registry/product-exceeds-maximum.js +3 -0
- package/dist/detectors/registry/product-exceeds-maximum.js.map +1 -0
- package/dist/detectors/registry/quantity-range.d.ts +3 -0
- package/dist/detectors/registry/quantity-range.d.ts.map +1 -0
- package/dist/detectors/registry/quantity-range.js +3 -0
- package/dist/detectors/registry/quantity-range.js.map +1 -0
- package/dist/detectors/registry/range-band-mismatch.d.ts +3 -0
- package/dist/detectors/registry/range-band-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/range-band-mismatch.js +3 -0
- package/dist/detectors/registry/range-band-mismatch.js.map +1 -0
- package/dist/detectors/registry/ratio-mismatch.d.ts +3 -0
- package/dist/detectors/registry/ratio-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/ratio-mismatch.js +3 -0
- package/dist/detectors/registry/ratio-mismatch.js.map +1 -0
- package/dist/detectors/registry/reference-flag-mismatch.d.ts +3 -0
- package/dist/detectors/registry/reference-flag-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/reference-flag-mismatch.js +3 -0
- package/dist/detectors/registry/reference-flag-mismatch.js.map +1 -0
- package/dist/detectors/registry/reference-number-repeated.d.ts +3 -0
- package/dist/detectors/registry/reference-number-repeated.d.ts.map +1 -0
- package/dist/detectors/registry/reference-number-repeated.js +3 -0
- package/dist/detectors/registry/reference-number-repeated.js.map +1 -0
- package/dist/detectors/registry/reference-number-variant.d.ts +3 -0
- package/dist/detectors/registry/reference-number-variant.d.ts.map +1 -0
- package/dist/detectors/registry/reference-number-variant.js +3 -0
- package/dist/detectors/registry/reference-number-variant.js.map +1 -0
- package/dist/detectors/registry/reference-unit.d.ts +3 -0
- package/dist/detectors/registry/reference-unit.d.ts.map +1 -0
- package/dist/detectors/registry/reference-unit.js +3 -0
- package/dist/detectors/registry/reference-unit.js.map +1 -0
- package/dist/detectors/registry/rent-multiple-mismatch.d.ts +3 -0
- package/dist/detectors/registry/rent-multiple-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/rent-multiple-mismatch.js +3 -0
- package/dist/detectors/registry/rent-multiple-mismatch.js.map +1 -0
- package/dist/detectors/registry/revision-direction.d.ts +3 -0
- package/dist/detectors/registry/revision-direction.d.ts.map +1 -0
- package/dist/detectors/registry/revision-direction.js +3 -0
- package/dist/detectors/registry/revision-direction.js.map +1 -0
- package/dist/detectors/registry/running-balance.d.ts +3 -0
- package/dist/detectors/registry/running-balance.d.ts.map +1 -0
- package/dist/detectors/registry/running-balance.js +3 -0
- package/dist/detectors/registry/running-balance.js.map +1 -0
- package/dist/detectors/registry/scaled-quantity-mismatch.d.ts +3 -0
- package/dist/detectors/registry/scaled-quantity-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/scaled-quantity-mismatch.js +3 -0
- package/dist/detectors/registry/scaled-quantity-mismatch.js.map +1 -0
- package/dist/detectors/registry/serial-range.d.ts +3 -0
- package/dist/detectors/registry/serial-range.d.ts.map +1 -0
- package/dist/detectors/registry/serial-range.js +3 -0
- package/dist/detectors/registry/serial-range.js.map +1 -0
- package/dist/detectors/registry/share-amount.d.ts +3 -0
- package/dist/detectors/registry/share-amount.d.ts.map +1 -0
- package/dist/detectors/registry/share-amount.js +3 -0
- package/dist/detectors/registry/share-amount.js.map +1 -0
- package/dist/detectors/registry/step-time-sum-mismatch.d.ts +3 -0
- package/dist/detectors/registry/step-time-sum-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/step-time-sum-mismatch.js +3 -0
- package/dist/detectors/registry/step-time-sum-mismatch.js.map +1 -0
- package/dist/detectors/registry/table-unit-mix.d.ts +3 -0
- package/dist/detectors/registry/table-unit-mix.d.ts.map +1 -0
- package/dist/detectors/registry/table-unit-mix.js +3 -0
- package/dist/detectors/registry/table-unit-mix.js.map +1 -0
- package/dist/detectors/registry/tier-threshold.d.ts +3 -0
- package/dist/detectors/registry/tier-threshold.d.ts.map +1 -0
- package/dist/detectors/registry/tier-threshold.js +3 -0
- package/dist/detectors/registry/tier-threshold.js.map +1 -0
- package/dist/detectors/registry/time-range-reversed.d.ts +3 -0
- package/dist/detectors/registry/time-range-reversed.d.ts.map +1 -0
- package/dist/detectors/registry/time-range-reversed.js +3 -0
- package/dist/detectors/registry/time-range-reversed.js.map +1 -0
- package/dist/detectors/registry/unlisted-item-used.d.ts +3 -0
- package/dist/detectors/registry/unlisted-item-used.d.ts.map +1 -0
- package/dist/detectors/registry/unlisted-item-used.js +3 -0
- package/dist/detectors/registry/unlisted-item-used.js.map +1 -0
- package/dist/detectors/registry/variance-mismatch.d.ts +3 -0
- package/dist/detectors/registry/variance-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/variance-mismatch.js +3 -0
- package/dist/detectors/registry/variance-mismatch.js.map +1 -0
- package/dist/detectors/registry/walk-time-distance-mismatch.d.ts +3 -0
- package/dist/detectors/registry/walk-time-distance-mismatch.d.ts.map +1 -0
- package/dist/detectors/registry/walk-time-distance-mismatch.js +3 -0
- package/dist/detectors/registry/walk-time-distance-mismatch.js.map +1 -0
- package/dist/detectors/relative-dates.d.ts.map +1 -1
- package/dist/detectors/relative-dates.js +2 -1
- package/dist/detectors/relative-dates.js.map +1 -1
- package/dist/detectors/relative-day-words.d.ts.map +1 -1
- package/dist/detectors/relative-day-words.js +2 -1
- package/dist/detectors/relative-day-words.js.map +1 -1
- package/dist/detectors/rent-multiple-mismatch.d.ts +3 -0
- package/dist/detectors/rent-multiple-mismatch.d.ts.map +1 -0
- package/dist/detectors/rent-multiple-mismatch.js +39 -0
- package/dist/detectors/rent-multiple-mismatch.js.map +1 -0
- package/dist/detectors/request-owner.d.ts +3 -1
- package/dist/detectors/request-owner.d.ts.map +1 -1
- package/dist/detectors/request-owner.js +5 -2
- package/dist/detectors/request-owner.js.map +1 -1
- package/dist/detectors/revision-direction.d.ts +3 -0
- package/dist/detectors/revision-direction.d.ts.map +1 -0
- package/dist/detectors/revision-direction.js +32 -0
- package/dist/detectors/revision-direction.js.map +1 -0
- package/dist/detectors/row-sentence-amounts.d.ts +5 -0
- package/dist/detectors/row-sentence-amounts.d.ts.map +1 -0
- package/dist/detectors/row-sentence-amounts.js +71 -0
- package/dist/detectors/row-sentence-amounts.js.map +1 -0
- package/dist/detectors/running-balance.d.ts +3 -0
- package/dist/detectors/running-balance.d.ts.map +1 -0
- package/dist/detectors/running-balance.js +26 -0
- package/dist/detectors/running-balance.js.map +1 -0
- package/dist/detectors/scaled-quantity.d.ts +3 -0
- package/dist/detectors/scaled-quantity.d.ts.map +1 -0
- package/dist/detectors/scaled-quantity.js +37 -0
- package/dist/detectors/scaled-quantity.js.map +1 -0
- package/dist/detectors/serial-range.d.ts +3 -0
- package/dist/detectors/serial-range.d.ts.map +1 -0
- package/dist/detectors/serial-range.js +29 -0
- package/dist/detectors/serial-range.js.map +1 -0
- package/dist/detectors/share-amount.d.ts +3 -0
- package/dist/detectors/share-amount.d.ts.map +1 -0
- package/dist/detectors/share-amount.js +45 -0
- package/dist/detectors/share-amount.js.map +1 -0
- package/dist/detectors/signals.d.ts.map +1 -1
- package/dist/detectors/signals.js +3 -1
- package/dist/detectors/signals.js.map +1 -1
- package/dist/detectors/step-time-sum.d.ts +3 -0
- package/dist/detectors/step-time-sum.d.ts.map +1 -0
- package/dist/detectors/step-time-sum.js +46 -0
- package/dist/detectors/step-time-sum.js.map +1 -0
- package/dist/detectors/structure-tree.d.ts +2 -0
- package/dist/detectors/structure-tree.d.ts.map +1 -1
- package/dist/detectors/structure-tree.js +58 -9
- package/dist/detectors/structure-tree.js.map +1 -1
- package/dist/detectors/structure.js +1 -1
- package/dist/detectors/structure.js.map +1 -1
- package/dist/detectors/table-scale.d.ts +3 -0
- package/dist/detectors/table-scale.d.ts.map +1 -0
- package/dist/detectors/table-scale.js +32 -0
- package/dist/detectors/table-scale.js.map +1 -0
- package/dist/detectors/tax-amount.d.ts.map +1 -1
- package/dist/detectors/tax-amount.js +34 -10
- package/dist/detectors/tax-amount.js.map +1 -1
- package/dist/detectors/technical-docs.d.ts +6 -1
- package/dist/detectors/technical-docs.d.ts.map +1 -1
- package/dist/detectors/technical-docs.js +15 -2
- package/dist/detectors/technical-docs.js.map +1 -1
- package/dist/detectors/tier-threshold.d.ts +3 -0
- package/dist/detectors/tier-threshold.d.ts.map +1 -0
- package/dist/detectors/tier-threshold.js +86 -0
- package/dist/detectors/tier-threshold.js.map +1 -0
- package/dist/detectors/time-order.d.ts +2 -0
- package/dist/detectors/time-order.d.ts.map +1 -1
- package/dist/detectors/time-order.js +45 -13
- package/dist/detectors/time-order.js.map +1 -1
- package/dist/detectors/unit-consistency.d.ts +1 -1
- package/dist/detectors/unit-consistency.d.ts.map +1 -1
- package/dist/detectors/unit-consistency.js +46 -38
- package/dist/detectors/unit-consistency.js.map +1 -1
- package/dist/detectors/unlisted-items.d.ts +3 -0
- package/dist/detectors/unlisted-items.d.ts.map +1 -0
- package/dist/detectors/unlisted-items.js +57 -0
- package/dist/detectors/unlisted-items.js.map +1 -0
- package/dist/detectors/use-count-words.d.ts +8 -0
- package/dist/detectors/use-count-words.d.ts.map +1 -0
- package/dist/detectors/use-count-words.js +20 -0
- package/dist/detectors/use-count-words.js.map +1 -0
- package/dist/detectors/use-interval.d.ts +3 -0
- package/dist/detectors/use-interval.d.ts.map +1 -0
- package/dist/detectors/use-interval.js +39 -0
- package/dist/detectors/use-interval.js.map +1 -0
- package/dist/detectors/use-maximum.d.ts +3 -0
- package/dist/detectors/use-maximum.d.ts.map +1 -0
- package/dist/detectors/use-maximum.js +32 -0
- package/dist/detectors/use-maximum.js.map +1 -0
- package/dist/detectors/variance.d.ts +3 -0
- package/dist/detectors/variance.d.ts.map +1 -0
- package/dist/detectors/variance.js +28 -0
- package/dist/detectors/variance.js.map +1 -0
- package/dist/detectors/walk-time-distance-mismatch.d.ts +4 -0
- package/dist/detectors/walk-time-distance-mismatch.d.ts.map +1 -0
- package/dist/detectors/walk-time-distance-mismatch.js +38 -0
- package/dist/detectors/walk-time-distance-mismatch.js.map +1 -0
- package/dist/detectors/whole-count-findings.d.ts +4 -0
- package/dist/detectors/whole-count-findings.d.ts.map +1 -0
- package/dist/detectors/whole-count-findings.js +38 -0
- package/dist/detectors/whole-count-findings.js.map +1 -0
- package/dist/detectors/working-hours-findings.d.ts +9 -0
- package/dist/detectors/working-hours-findings.d.ts.map +1 -0
- package/dist/detectors/working-hours-findings.js +79 -0
- package/dist/detectors/working-hours-findings.js.map +1 -0
- package/dist/facts/age-values.d.ts +22 -0
- package/dist/facts/age-values.d.ts.map +1 -0
- package/dist/facts/age-values.js +76 -0
- package/dist/facts/age-values.js.map +1 -0
- package/dist/facts/approximate-tolerance.d.ts +7 -0
- package/dist/facts/approximate-tolerance.d.ts.map +1 -0
- package/dist/facts/approximate-tolerance.js +16 -0
- package/dist/facts/approximate-tolerance.js.map +1 -0
- package/dist/facts/cell-keys.d.ts +12 -0
- package/dist/facts/cell-keys.d.ts.map +1 -0
- package/dist/facts/cell-keys.js +19 -0
- package/dist/facts/cell-keys.js.map +1 -0
- package/dist/facts/count-labels.d.ts +15 -0
- package/dist/facts/count-labels.d.ts.map +1 -0
- package/dist/facts/count-labels.js +19 -0
- package/dist/facts/count-labels.js.map +1 -0
- package/dist/facts/document-terms.d.ts +43 -0
- package/dist/facts/document-terms.d.ts.map +1 -0
- package/dist/facts/document-terms.js +74 -0
- package/dist/facts/document-terms.js.map +1 -0
- package/dist/facts/duration-scale.d.ts +11 -0
- package/dist/facts/duration-scale.d.ts.map +1 -0
- package/dist/facts/duration-scale.js +14 -0
- package/dist/facts/duration-scale.js.map +1 -0
- package/dist/facts/duration-values.d.ts +15 -0
- package/dist/facts/duration-values.d.ts.map +1 -0
- package/dist/facts/duration-values.js +29 -0
- package/dist/facts/duration-values.js.map +1 -0
- package/dist/facts/fact-values.d.ts +9 -1
- package/dist/facts/fact-values.d.ts.map +1 -1
- package/dist/facts/fact-values.js +19 -6
- package/dist/facts/fact-values.js.map +1 -1
- package/dist/facts/item-amounts.d.ts +18 -0
- package/dist/facts/item-amounts.d.ts.map +1 -0
- package/dist/facts/item-amounts.js +67 -0
- package/dist/facts/item-amounts.js.map +1 -0
- package/dist/facts/labelled-facts.d.ts +18 -0
- package/dist/facts/labelled-facts.d.ts.map +1 -1
- package/dist/facts/labelled-facts.js +71 -13
- package/dist/facts/labelled-facts.js.map +1 -1
- package/dist/facts/measure-units.d.ts +5 -0
- package/dist/facts/measure-units.d.ts.map +1 -0
- package/dist/facts/measure-units.js +43 -0
- package/dist/facts/measure-units.js.map +1 -0
- package/dist/facts/measures.d.ts +23 -4
- package/dist/facts/measures.d.ts.map +1 -1
- package/dist/facts/measures.js +71 -20
- package/dist/facts/measures.js.map +1 -1
- package/dist/facts/qualified-labels.d.ts +28 -0
- package/dist/facts/qualified-labels.d.ts.map +1 -0
- package/dist/facts/qualified-labels.js +96 -0
- package/dist/facts/qualified-labels.js.map +1 -0
- package/dist/facts/rate-values.d.ts +40 -0
- package/dist/facts/rate-values.d.ts.map +1 -0
- package/dist/facts/rate-values.js +68 -0
- package/dist/facts/rate-values.js.map +1 -0
- package/dist/facts/retention-periods.d.ts +51 -0
- package/dist/facts/retention-periods.d.ts.map +1 -0
- package/dist/facts/retention-periods.js +148 -0
- package/dist/facts/retention-periods.js.map +1 -0
- package/dist/facts/row-sentence-amounts.d.ts +51 -0
- package/dist/facts/row-sentence-amounts.d.ts.map +1 -0
- package/dist/facts/row-sentence-amounts.js +71 -0
- package/dist/facts/row-sentence-amounts.js.map +1 -0
- package/dist/facts/superscript-power.d.ts +3 -0
- package/dist/facts/superscript-power.d.ts.map +1 -0
- package/dist/facts/superscript-power.js +5 -0
- package/dist/facts/superscript-power.js.map +1 -0
- package/dist/facts/table-facts.d.ts +18 -2
- package/dist/facts/table-facts.d.ts.map +1 -1
- package/dist/facts/table-facts.js +16 -6
- package/dist/facts/table-facts.js.map +1 -1
- package/dist/facts/term-values.d.ts +34 -0
- package/dist/facts/term-values.d.ts.map +1 -0
- package/dist/facts/term-values.js +195 -0
- package/dist/facts/term-values.js.map +1 -0
- package/dist/facts/unit-conflicts.d.ts +3 -2
- package/dist/facts/unit-conflicts.d.ts.map +1 -1
- package/dist/facts/unit-conflicts.js +15 -7
- package/dist/facts/unit-conflicts.js.map +1 -1
- package/dist/facts/unit-equivalents.d.ts +13 -0
- package/dist/facts/unit-equivalents.d.ts.map +1 -0
- package/dist/facts/unit-equivalents.js +56 -0
- package/dist/facts/unit-equivalents.js.map +1 -0
- package/dist/facts/unit-tolerance.d.ts +4 -0
- package/dist/facts/unit-tolerance.d.ts.map +1 -0
- package/dist/facts/unit-tolerance.js +13 -0
- package/dist/facts/unit-tolerance.js.map +1 -0
- package/dist/facts/unit-word.d.ts +13 -0
- package/dist/facts/unit-word.d.ts.map +1 -0
- package/dist/facts/unit-word.js +43 -0
- package/dist/facts/unit-word.js.map +1 -0
- package/dist/facts/verb-quantity-facts.d.ts +22 -0
- package/dist/facts/verb-quantity-facts.d.ts.map +1 -0
- package/dist/facts/verb-quantity-facts.js +58 -0
- package/dist/facts/verb-quantity-facts.js.map +1 -0
- package/dist/facts/whole-counts.d.ts +58 -0
- package/dist/facts/whole-counts.d.ts.map +1 -0
- package/dist/facts/whole-counts.js +118 -0
- package/dist/facts/whole-counts.js.map +1 -0
- package/dist/facts/written-precision.d.ts +10 -0
- package/dist/facts/written-precision.d.ts.map +1 -0
- package/dist/facts/written-precision.js +20 -0
- package/dist/facts/written-precision.js.map +1 -0
- package/dist/kana-spelling.d.ts +12 -0
- package/dist/kana-spelling.d.ts.map +1 -1
- package/dist/kana-spelling.js +23 -0
- package/dist/kana-spelling.js.map +1 -1
- package/dist/model-codes.d.ts +23 -0
- package/dist/model-codes.d.ts.map +1 -0
- package/dist/model-codes.js +81 -0
- package/dist/model-codes.js.map +1 -0
- package/dist/name-char-reading.d.ts +16 -0
- package/dist/name-char-reading.d.ts.map +1 -0
- package/dist/name-char-reading.js +18 -0
- package/dist/name-char-reading.js.map +1 -0
- package/dist/name-line-block.d.ts +6 -0
- package/dist/name-line-block.d.ts.map +1 -0
- package/dist/name-line-block.js +35 -0
- package/dist/name-line-block.js.map +1 -0
- package/dist/name-lookalike-chars.d.ts +16 -0
- package/dist/name-lookalike-chars.d.ts.map +1 -0
- package/dist/name-lookalike-chars.js +41 -0
- package/dist/name-lookalike-chars.js.map +1 -0
- package/dist/name-neighbours.d.ts +7 -0
- package/dist/name-neighbours.d.ts.map +1 -0
- package/dist/name-neighbours.js +55 -0
- package/dist/name-neighbours.js.map +1 -0
- package/dist/name-ordinary-word.d.ts +13 -0
- package/dist/name-ordinary-word.d.ts.map +1 -0
- package/dist/name-ordinary-word.js +54 -0
- package/dist/name-ordinary-word.js.map +1 -0
- package/dist/name-person.d.ts +9 -0
- package/dist/name-person.d.ts.map +1 -0
- package/dist/name-person.js +25 -0
- package/dist/name-person.js.map +1 -0
- package/dist/name-separator.d.ts +14 -0
- package/dist/name-separator.d.ts.map +1 -0
- package/dist/name-separator.js +33 -0
- package/dist/name-separator.js.map +1 -0
- package/dist/name-spelling-chars.d.ts +16 -0
- package/dist/name-spelling-chars.d.ts.map +1 -0
- package/dist/name-spelling-chars.js +14 -0
- package/dist/name-spelling-chars.js.map +1 -0
- package/dist/name-variants.d.ts +10 -9
- package/dist/name-variants.d.ts.map +1 -1
- package/dist/name-variants.js +32 -88
- package/dist/name-variants.js.map +1 -1
- package/dist/name-weight.d.ts +10 -0
- package/dist/name-weight.d.ts.map +1 -0
- package/dist/name-weight.js +7 -0
- package/dist/name-weight.js.map +1 -0
- package/dist/person-field.d.ts +6 -0
- package/dist/person-field.d.ts.map +1 -0
- package/dist/person-field.js +40 -0
- package/dist/person-field.js.map +1 -0
- package/dist/person-full-name.d.ts +12 -0
- package/dist/person-full-name.d.ts.map +1 -0
- package/dist/person-full-name.js +52 -0
- package/dist/person-full-name.js.map +1 -0
- package/dist/phone-numbers.d.ts +23 -3
- package/dist/phone-numbers.d.ts.map +1 -1
- package/dist/phone-numbers.js +68 -23
- package/dist/phone-numbers.js.map +1 -1
- package/dist/place-names.d.ts +12 -5
- package/dist/place-names.d.ts.map +1 -1
- package/dist/place-names.js +34 -14
- package/dist/place-names.js.map +1 -1
- package/dist/plugin.d.ts +7 -0
- package/dist/plugin.d.ts.map +1 -1
- package/dist/preamble-paragraphs.d.ts +2 -1
- package/dist/preamble-paragraphs.d.ts.map +1 -1
- package/dist/preamble-paragraphs.js +16 -1
- package/dist/preamble-paragraphs.js.map +1 -1
- package/dist/product-names.d.ts +33 -0
- package/dist/product-names.d.ts.map +1 -0
- package/dist/product-names.js +74 -0
- package/dist/product-names.js.map +1 -0
- package/dist/profile/parse.d.ts.map +1 -1
- package/dist/profile/parse.js +11 -0
- package/dist/profile/parse.js.map +1 -1
- package/dist/reference-numbers.d.ts +26 -0
- package/dist/reference-numbers.d.ts.map +1 -0
- package/dist/reference-numbers.js +43 -0
- package/dist/reference-numbers.js.map +1 -0
- package/dist/spaced-person-name.d.ts +17 -0
- package/dist/spaced-person-name.d.ts.map +1 -0
- package/dist/spaced-person-name.js +82 -0
- package/dist/spaced-person-name.js.map +1 -0
- package/dist/spacing-code.d.ts +7 -0
- package/dist/spacing-code.d.ts.map +1 -0
- package/dist/spacing-code.js +30 -0
- package/dist/spacing-code.js.map +1 -0
- package/dist/structure/amount-range.d.ts +2 -2
- package/dist/structure/amount-range.d.ts.map +1 -1
- package/dist/structure/amount-range.js +12 -5
- package/dist/structure/amount-range.js.map +1 -1
- package/dist/structure/annual-holidays.d.ts +56 -0
- package/dist/structure/annual-holidays.d.ts.map +1 -0
- package/dist/structure/annual-holidays.js +159 -0
- package/dist/structure/annual-holidays.js.map +1 -0
- package/dist/structure/annual-pay.d.ts +97 -0
- package/dist/structure/annual-pay.d.ts.map +1 -0
- package/dist/structure/annual-pay.js +236 -0
- package/dist/structure/annual-pay.js.map +1 -0
- package/dist/structure/bmi.d.ts +63 -0
- package/dist/structure/bmi.d.ts.map +1 -0
- package/dist/structure/bmi.js +106 -0
- package/dist/structure/bmi.js.map +1 -0
- package/dist/structure/capacity-count.d.ts +59 -0
- package/dist/structure/capacity-count.d.ts.map +1 -0
- package/dist/structure/capacity-count.js +118 -0
- package/dist/structure/capacity-count.js.map +1 -0
- package/dist/structure/change-rate-table.d.ts +46 -0
- package/dist/structure/change-rate-table.d.ts.map +1 -0
- package/dist/structure/change-rate-table.js +110 -0
- package/dist/structure/change-rate-table.js.map +1 -0
- package/dist/structure/change-rate.d.ts +13 -1
- package/dist/structure/change-rate.d.ts.map +1 -1
- package/dist/structure/change-rate.js +51 -19
- package/dist/structure/change-rate.js.map +1 -1
- package/dist/structure/closing-balance.d.ts +24 -0
- package/dist/structure/closing-balance.d.ts.map +1 -0
- package/dist/structure/closing-balance.js +79 -0
- package/dist/structure/closing-balance.js.map +1 -0
- package/dist/structure/column-date-order.d.ts +5 -0
- package/dist/structure/column-date-order.d.ts.map +1 -0
- package/dist/structure/column-date-order.js +57 -0
- package/dist/structure/column-date-order.js.map +1 -0
- package/dist/structure/compound-hours.d.ts +5 -0
- package/dist/structure/compound-hours.d.ts.map +1 -0
- package/dist/structure/compound-hours.js +45 -0
- package/dist/structure/compound-hours.js.map +1 -0
- package/dist/structure/counted-amounts.d.ts +6 -0
- package/dist/structure/counted-amounts.d.ts.map +1 -1
- package/dist/structure/counted-amounts.js +4 -4
- package/dist/structure/counted-amounts.js.map +1 -1
- package/dist/structure/cumulative-below-current.d.ts +21 -0
- package/dist/structure/cumulative-below-current.d.ts.map +1 -0
- package/dist/structure/cumulative-below-current.js +48 -0
- package/dist/structure/cumulative-below-current.js.map +1 -0
- package/dist/structure/currency-column.d.ts +21 -0
- package/dist/structure/currency-column.d.ts.map +1 -0
- package/dist/structure/currency-column.js +74 -0
- package/dist/structure/currency-column.js.map +1 -0
- package/dist/structure/date-deadline-mark.d.ts +15 -0
- package/dist/structure/date-deadline-mark.d.ts.map +1 -0
- package/dist/structure/date-deadline-mark.js +22 -0
- package/dist/structure/date-deadline-mark.js.map +1 -0
- package/dist/structure/date-outside-period.d.ts +8 -2
- package/dist/structure/date-outside-period.d.ts.map +1 -1
- package/dist/structure/date-outside-period.js +21 -14
- package/dist/structure/date-outside-period.js.map +1 -1
- package/dist/structure/date-range.d.ts +3 -1
- package/dist/structure/date-range.d.ts.map +1 -1
- package/dist/structure/date-range.js +5 -7
- package/dist/structure/date-range.js.map +1 -1
- package/dist/structure/deadline-after-event.d.ts +56 -0
- package/dist/structure/deadline-after-event.d.ts.map +1 -0
- package/dist/structure/deadline-after-event.js +113 -0
- package/dist/structure/deadline-after-event.js.map +1 -0
- package/dist/structure/deductible-limit.d.ts +69 -0
- package/dist/structure/deductible-limit.d.ts.map +1 -0
- package/dist/structure/deductible-limit.js +191 -0
- package/dist/structure/deductible-limit.js.map +1 -0
- package/dist/structure/definition-use.d.ts +1 -1
- package/dist/structure/definition-use.d.ts.map +1 -1
- package/dist/structure/definition-use.js +55 -2
- package/dist/structure/definition-use.js.map +1 -1
- package/dist/structure/discount-rate.d.ts +35 -0
- package/dist/structure/discount-rate.d.ts.map +1 -0
- package/dist/structure/discount-rate.js +172 -0
- package/dist/structure/discount-rate.js.map +1 -0
- package/dist/structure/due-date.d.ts.map +1 -1
- package/dist/structure/due-date.js +5 -27
- package/dist/structure/due-date.js.map +1 -1
- package/dist/structure/generic-role.d.ts +2 -0
- package/dist/structure/generic-role.d.ts.map +1 -0
- package/dist/structure/generic-role.js +8 -0
- package/dist/structure/generic-role.js.map +1 -0
- package/dist/structure/gpa.d.ts +74 -0
- package/dist/structure/gpa.d.ts.map +1 -0
- package/dist/structure/gpa.js +170 -0
- package/dist/structure/gpa.js.map +1 -0
- package/dist/structure/installment-total.d.ts +110 -0
- package/dist/structure/installment-total.d.ts.map +1 -0
- package/dist/structure/installment-total.js +224 -0
- package/dist/structure/installment-total.js.map +1 -0
- package/dist/structure/interest.d.ts +22 -0
- package/dist/structure/interest.d.ts.map +1 -0
- package/dist/structure/interest.js +107 -0
- package/dist/structure/interest.js.map +1 -0
- package/dist/structure/key-value-row.d.ts +14 -0
- package/dist/structure/key-value-row.d.ts.map +1 -0
- package/dist/structure/key-value-row.js +38 -0
- package/dist/structure/key-value-row.js.map +1 -0
- package/dist/structure/lab-columns.d.ts +12 -0
- package/dist/structure/lab-columns.d.ts.map +1 -0
- package/dist/structure/lab-columns.js +11 -0
- package/dist/structure/lab-columns.js.map +1 -0
- package/dist/structure/labelled-date-order.d.ts +55 -0
- package/dist/structure/labelled-date-order.d.ts.map +1 -0
- package/dist/structure/labelled-date-order.js +49 -0
- package/dist/structure/labelled-date-order.js.map +1 -0
- package/dist/structure/labelled-order.d.ts +59 -0
- package/dist/structure/labelled-order.d.ts.map +1 -0
- package/dist/structure/labelled-order.js +65 -0
- package/dist/structure/labelled-order.js.map +1 -0
- package/dist/structure/labelled-time-order.d.ts +17 -0
- package/dist/structure/labelled-time-order.d.ts.map +1 -0
- package/dist/structure/labelled-time-order.js +79 -0
- package/dist/structure/labelled-time-order.js.map +1 -0
- package/dist/structure/layout-codes.d.ts +68 -0
- package/dist/structure/layout-codes.d.ts.map +1 -0
- package/dist/structure/layout-codes.js +161 -0
- package/dist/structure/layout-codes.js.map +1 -0
- package/dist/structure/line-amount-label.d.ts +31 -0
- package/dist/structure/line-amount-label.d.ts.map +1 -0
- package/dist/structure/line-amount-label.js +77 -0
- package/dist/structure/line-amount-label.js.map +1 -0
- package/dist/structure/line-amount-rate.d.ts +47 -0
- package/dist/structure/line-amount-rate.d.ts.map +1 -0
- package/dist/structure/line-amount-rate.js +141 -0
- package/dist/structure/line-amount-rate.js.map +1 -0
- package/dist/structure/line-amount-unit.d.ts +7 -0
- package/dist/structure/line-amount-unit.d.ts.map +1 -1
- package/dist/structure/line-amount-unit.js +11 -0
- package/dist/structure/line-amount-unit.js.map +1 -1
- package/dist/structure/line-amount.d.ts +33 -7
- package/dist/structure/line-amount.d.ts.map +1 -1
- package/dist/structure/line-amount.js +152 -42
- package/dist/structure/line-amount.js.map +1 -1
- package/dist/structure/measured-amounts.d.ts +17 -0
- package/dist/structure/measured-amounts.d.ts.map +1 -0
- package/dist/structure/measured-amounts.js +110 -0
- package/dist/structure/measured-amounts.js.map +1 -0
- package/dist/structure/meter-usage-read.d.ts +21 -0
- package/dist/structure/meter-usage-read.d.ts.map +1 -0
- package/dist/structure/meter-usage-read.js +116 -0
- package/dist/structure/meter-usage-read.js.map +1 -0
- package/dist/structure/meter-usage.d.ts +62 -0
- package/dist/structure/meter-usage.d.ts.map +1 -0
- package/dist/structure/meter-usage.js +157 -0
- package/dist/structure/meter-usage.js.map +1 -0
- package/dist/structure/net-amount.d.ts +81 -0
- package/dist/structure/net-amount.d.ts.map +1 -0
- package/dist/structure/net-amount.js +161 -0
- package/dist/structure/net-amount.js.map +1 -0
- package/dist/structure/net-gross-weight.d.ts +30 -0
- package/dist/structure/net-gross-weight.d.ts.map +1 -0
- package/dist/structure/net-gross-weight.js +79 -0
- package/dist/structure/net-gross-weight.js.map +1 -0
- package/dist/structure/order-quantity.d.ts +38 -0
- package/dist/structure/order-quantity.d.ts.map +1 -0
- package/dist/structure/order-quantity.js +104 -0
- package/dist/structure/order-quantity.js.map +1 -0
- package/dist/structure/party-role.d.ts.map +1 -1
- package/dist/structure/party-role.js +4 -1
- package/dist/structure/party-role.js.map +1 -1
- package/dist/structure/percent-sum.d.ts +2 -0
- package/dist/structure/percent-sum.d.ts.map +1 -1
- package/dist/structure/percent-sum.js +2 -0
- package/dist/structure/percent-sum.js.map +1 -1
- package/dist/structure/period-label-conflict.d.ts +52 -0
- package/dist/structure/period-label-conflict.d.ts.map +1 -0
- package/dist/structure/period-label-conflict.js +105 -0
- package/dist/structure/period-label-conflict.js.map +1 -0
- package/dist/structure/period-labels.d.ts +36 -0
- package/dist/structure/period-labels.d.ts.map +1 -0
- package/dist/structure/period-labels.js +86 -0
- package/dist/structure/period-labels.js.map +1 -0
- package/dist/structure/period-multiple.d.ts +46 -0
- package/dist/structure/period-multiple.d.ts.map +1 -0
- package/dist/structure/period-multiple.js +123 -0
- package/dist/structure/period-multiple.js.map +1 -0
- package/dist/structure/quantity-range.d.ts +8 -0
- package/dist/structure/quantity-range.d.ts.map +1 -0
- package/dist/structure/quantity-range.js +32 -0
- package/dist/structure/quantity-range.js.map +1 -0
- package/dist/structure/range-bands.d.ts +77 -0
- package/dist/structure/range-bands.d.ts.map +1 -0
- package/dist/structure/range-bands.js +244 -0
- package/dist/structure/range-bands.js.map +1 -0
- package/dist/structure/range-years.d.ts +18 -0
- package/dist/structure/range-years.d.ts.map +1 -0
- package/dist/structure/range-years.js +60 -0
- package/dist/structure/range-years.js.map +1 -0
- package/dist/structure/ratio.d.ts +136 -0
- package/dist/structure/ratio.d.ts.map +1 -0
- package/dist/structure/ratio.js +214 -0
- package/dist/structure/ratio.js.map +1 -0
- package/dist/structure/reference-flags.d.ts +55 -0
- package/dist/structure/reference-flags.d.ts.map +1 -0
- package/dist/structure/reference-flags.js +116 -0
- package/dist/structure/reference-flags.js.map +1 -0
- package/dist/structure/reference-number-repeated.d.ts +12 -0
- package/dist/structure/reference-number-repeated.d.ts.map +1 -0
- package/dist/structure/reference-number-repeated.js +43 -0
- package/dist/structure/reference-number-repeated.js.map +1 -0
- package/dist/structure/reference-unit.d.ts +24 -0
- package/dist/structure/reference-unit.d.ts.map +1 -0
- package/dist/structure/reference-unit.js +80 -0
- package/dist/structure/reference-unit.js.map +1 -0
- package/dist/structure/rent-multiple.d.ts +56 -0
- package/dist/structure/rent-multiple.d.ts.map +1 -0
- package/dist/structure/rent-multiple.js +139 -0
- package/dist/structure/rent-multiple.js.map +1 -0
- package/dist/structure/revision-direction.d.ts +51 -0
- package/dist/structure/revision-direction.d.ts.map +1 -0
- package/dist/structure/revision-direction.js +163 -0
- package/dist/structure/revision-direction.js.map +1 -0
- package/dist/structure/running-balance.d.ts +36 -0
- package/dist/structure/running-balance.d.ts.map +1 -0
- package/dist/structure/running-balance.js +126 -0
- package/dist/structure/running-balance.js.map +1 -0
- package/dist/structure/scaled-quantities.d.ts +50 -0
- package/dist/structure/scaled-quantities.d.ts.map +1 -0
- package/dist/structure/scaled-quantities.js +170 -0
- package/dist/structure/scaled-quantities.js.map +1 -0
- package/dist/structure/serial-range.d.ts +9 -0
- package/dist/structure/serial-range.d.ts.map +1 -0
- package/dist/structure/serial-range.js +41 -0
- package/dist/structure/serial-range.js.map +1 -0
- package/dist/structure/share-amount.d.ts +55 -0
- package/dist/structure/share-amount.d.ts.map +1 -0
- package/dist/structure/share-amount.js +162 -0
- package/dist/structure/share-amount.js.map +1 -0
- package/dist/structure/shift-times.d.ts +32 -0
- package/dist/structure/shift-times.d.ts.map +1 -0
- package/dist/structure/shift-times.js +112 -0
- package/dist/structure/shift-times.js.map +1 -0
- package/dist/structure/span-label.d.ts +3 -0
- package/dist/structure/span-label.d.ts.map +1 -0
- package/dist/structure/span-label.js +27 -0
- package/dist/structure/span-label.js.map +1 -0
- package/dist/structure/stamp-order.d.ts +16 -0
- package/dist/structure/stamp-order.d.ts.map +1 -0
- package/dist/structure/stamp-order.js +78 -0
- package/dist/structure/stamp-order.js.map +1 -0
- package/dist/structure/stated-multiple.d.ts +39 -0
- package/dist/structure/stated-multiple.d.ts.map +1 -0
- package/dist/structure/stated-multiple.js +49 -0
- package/dist/structure/stated-multiple.js.map +1 -0
- package/dist/structure/stated-period.d.ts +3 -2
- package/dist/structure/stated-period.d.ts.map +1 -1
- package/dist/structure/stated-period.js +17 -11
- package/dist/structure/stated-period.js.map +1 -1
- package/dist/structure/step-times.d.ts +49 -0
- package/dist/structure/step-times.d.ts.map +1 -0
- package/dist/structure/step-times.js +128 -0
- package/dist/structure/step-times.js.map +1 -0
- package/dist/structure/table-scale.d.ts +45 -0
- package/dist/structure/table-scale.d.ts.map +1 -0
- package/dist/structure/table-scale.js +188 -0
- package/dist/structure/table-scale.js.map +1 -0
- package/dist/structure/tax-price.d.ts +29 -0
- package/dist/structure/tax-price.d.ts.map +1 -0
- package/dist/structure/tax-price.js +112 -0
- package/dist/structure/tax-price.js.map +1 -0
- package/dist/structure/tax.d.ts +2 -0
- package/dist/structure/tax.d.ts.map +1 -1
- package/dist/structure/tax.js +46 -23
- package/dist/structure/tax.js.map +1 -1
- package/dist/structure/term-deadline.d.ts +19 -0
- package/dist/structure/term-deadline.d.ts.map +1 -0
- package/dist/structure/term-deadline.js +28 -0
- package/dist/structure/term-deadline.js.map +1 -0
- package/dist/structure/tier-threshold.d.ts +65 -0
- package/dist/structure/tier-threshold.d.ts.map +1 -0
- package/dist/structure/tier-threshold.js +170 -0
- package/dist/structure/tier-threshold.js.map +1 -0
- package/dist/structure/time-range.d.ts +18 -0
- package/dist/structure/time-range.d.ts.map +1 -0
- package/dist/structure/time-range.js +62 -0
- package/dist/structure/time-range.js.map +1 -0
- package/dist/structure/total-line.d.ts +48 -0
- package/dist/structure/total-line.d.ts.map +1 -0
- package/dist/structure/total-line.js +165 -0
- package/dist/structure/total-line.js.map +1 -0
- package/dist/structure/total-row-blank.d.ts +10 -0
- package/dist/structure/total-row-blank.d.ts.map +1 -0
- package/dist/structure/total-row-blank.js +15 -0
- package/dist/structure/total-row-blank.js.map +1 -0
- package/dist/structure/total.d.ts +17 -1
- package/dist/structure/total.d.ts.map +1 -1
- package/dist/structure/total.js +103 -7
- package/dist/structure/total.js.map +1 -1
- package/dist/structure/unlisted-items.d.ts +70 -0
- package/dist/structure/unlisted-items.d.ts.map +1 -0
- package/dist/structure/unlisted-items.js +152 -0
- package/dist/structure/unlisted-items.js.map +1 -0
- package/dist/structure/variance-table.d.ts +34 -0
- package/dist/structure/variance-table.d.ts.map +1 -0
- package/dist/structure/variance-table.js +130 -0
- package/dist/structure/variance-table.js.map +1 -0
- package/dist/structure/walk-time.d.ts +87 -0
- package/dist/structure/walk-time.d.ts.map +1 -0
- package/dist/structure/walk-time.js +195 -0
- package/dist/structure/walk-time.js.map +1 -0
- package/dist/table-names.d.ts +4 -3
- package/dist/table-names.d.ts.map +1 -1
- package/dist/table-names.js +6 -6
- package/dist/table-names.js.map +1 -1
- package/dist/unlabelled-references.d.ts +16 -0
- package/dist/unlabelled-references.d.ts.map +1 -0
- package/dist/unlabelled-references.js +73 -0
- package/dist/unlabelled-references.js.map +1 -0
- package/dist/vehicle-plates.d.ts +28 -0
- package/dist/vehicle-plates.d.ts.map +1 -0
- package/dist/vehicle-plates.js +116 -0
- package/dist/vehicle-plates.js.map +1 -0
- package/dist/whole-word-runs.d.ts +24 -0
- package/dist/whole-word-runs.d.ts.map +1 -0
- package/dist/whole-word-runs.js +26 -0
- package/dist/whole-word-runs.js.map +1 -0
- package/package.json +4 -3
- package/profiles/listing.yaml +20 -0
- package/rules/absolute-exception.yaml +1 -1
- package/rules/ai-generated-composite.yaml +1 -1
- package/rules/ai-tell.yaml +1 -1
- package/rules/amount-range-reversed.yaml +1 -1
- package/rules/amount-scale-consistency.yaml +1 -1
- package/rules/announced-count-mismatch.yaml +2 -2
- package/rules/announcing-opener.yaml +1 -1
- package/rules/annual-holidays-mismatch.yaml +65 -0
- package/rules/annual-pay-mismatch.yaml +64 -0
- package/rules/article-sound.yaml +1 -1
- package/rules/assistant-residue.yaml +1 -1
- package/rules/attachment-not-attached.yaml +1 -1
- package/rules/backorder-mismatch.yaml +57 -0
- package/rules/bmi-mismatch.yaml +63 -0
- package/rules/bold-label-list.yaml +1 -1
- package/rules/broken-link.yaml +1 -1
- package/rules/capacity-runtime-mismatch.yaml +66 -0
- package/rules/change-rate-mismatch.yaml +6 -6
- package/rules/chat-citation-residue.yaml +2 -2
- package/rules/cliche.yaml +2 -2
- package/rules/closing-balance-mismatch.yaml +63 -0
- package/rules/colon-lead-in.yaml +1 -1
- package/rules/comparative-without-baseline.yaml +1 -1
- package/rules/concrete-evidence-density.yaml +1 -1
- package/rules/connection-time-short.yaml +1 -1
- package/rules/contact-variant.yaml +76 -0
- package/rules/contrast-framing.yaml +2 -2
- package/rules/count-over-capacity.yaml +55 -0
- package/rules/cross-doc-broken-link.yaml +1 -1
- package/rules/cross-doc-fact-conflict.yaml +1 -1
- package/rules/cross-doc-term-variant.yaml +1 -1
- package/rules/cumulative-below-current.yaml +59 -0
- package/rules/currency-column-mix.yaml +70 -0
- package/rules/currency-notation-consistency.yaml +2 -2
- package/rules/cushion-phrase-density.yaml +1 -1
- package/rules/dangling-participle.yaml +2 -2
- package/rules/dangling-reference.yaml +1 -1
- package/rules/date-format-consistency.yaml +1 -1
- package/rules/date-outside-period.yaml +5 -5
- package/rules/date-range-reversed.yaml +2 -2
- package/rules/date-stamp-order.yaml +82 -0
- package/rules/date-without-year.yaml +12 -12
- package/rules/deadline-after-event.yaml +72 -0
- package/rules/deductible-exceeds-limit.yaml +54 -0
- package/rules/defined-name-repeated.yaml +3 -3
- package/rules/defined-term-form.yaml +2 -2
- package/rules/delivered-over-ordered.yaml +57 -0
- package/rules/demonstrative-opener-run.yaml +1 -1
- package/rules/discount-rate-mismatch.yaml +66 -0
- package/rules/due-before-issue.yaml +36 -11
- package/rules/duration-mismatch.yaml +16 -7
- package/rules/duration-product-mismatch.yaml +11 -3
- package/rules/elapsed-years-mismatch.yaml +11 -6
- package/rules/email-greeting-closing.yaml +2 -2
- package/rules/empty-conclusion.yaml +1 -1
- package/rules/empty-intensifier.yaml +1 -1
- package/rules/empty-list-item.yaml +1 -1
- package/rules/empty-section.yaml +1 -1
- package/rules/empty-table-cell.yaml +2 -2
- package/rules/expletive-construction.yaml +1 -1
- package/rules/fact-conflict.yaml +21 -4
- package/rules/figurative-density.yaml +1 -1
- package/rules/figure-reference-order.yaml +1 -1
- package/rules/footnote-mismatch.yaml +1 -1
- package/rules/fullwidth-alnum-consistency.yaml +1 -1
- package/rules/gpa-mismatch.yaml +80 -0
- package/rules/heading-echo.yaml +2 -2
- package/rules/heading-end-punctuation-mix.yaml +1 -1
- package/rules/heading-level-skip.yaml +1 -1
- package/rules/heading-numbering-mix.yaml +3 -3
- package/rules/homophone-slip.yaml +1 -1
- package/rules/humble-for-others.yaml +1 -1
- package/rules/idiom-misuse.yaml +1 -1
- package/rules/ime-residue.yaml +1 -1
- package/rules/impossible-date.yaml +10 -6
- package/rules/installment-total-mismatch.yaml +58 -0
- package/rules/interest-mismatch.yaml +50 -0
- package/rules/interval-count-mismatch.yaml +54 -0
- package/rules/invisible-character.yaml +1 -1
- package/rules/kana-function-word.yaml +2 -2
- package/rules/katakana-density.yaml +1 -1
- package/rules/katakana-long-vowel.yaml +2 -2
- package/rules/kutoten-consistency.yaml +1 -1
- package/rules/latin-spacing.yaml +20 -6
- package/rules/layout-code-mismatch.yaml +68 -0
- package/rules/less-for-fewer.yaml +1 -1
- package/rules/line-amount-mismatch.yaml +8 -7
- package/rules/link-text-url-mismatch.yaml +1 -1
- package/rules/list-item-form-mix.yaml +1 -1
- package/rules/lookalike-character.yaml +1 -1
- package/rules/max-kanji-continuous.yaml +1 -1
- package/rules/meter-usage-mismatch.yaml +64 -0
- package/rules/misconversion.yaml +1 -1
- package/rules/modal-conflict.yaml +1 -1
- package/rules/name-variant.yaml +18 -3
- package/rules/net-amount-mismatch.yaml +57 -0
- package/rules/net-over-gross.yaml +57 -0
- package/rules/no-doubled-joshi.yaml +1 -1
- package/rules/no-em-dash.yaml +2 -2
- package/rules/no-mixed-desumasu.yaml +1 -1
- package/rules/no-nakaguro-parallel.yaml +1 -1
- package/rules/nominalization.yaml +1 -1
- package/rules/nonstandard-word.yaml +1 -1
- package/rules/number-style-consistency.yaml +3 -3
- package/rules/number-without-unit.yaml +1 -1
- package/rules/number-word-figure-mismatch.yaml +1 -1
- package/rules/numbering-gap.yaml +1 -1
- package/rules/obligation-without-deadline.yaml +1 -1
- package/rules/ordinal-suffix-mismatch.yaml +1 -1
- package/rules/orthographic-variant.yaml +2 -2
- package/rules/outside-announced-list.yaml +1 -1
- package/rules/padded-intro.yaml +1 -1
- package/rules/paragraph-restatement.yaml +1 -1
- package/rules/party-role-name.yaml +3 -3
- package/rules/percent-sum-mismatch.yaml +2 -2
- package/rules/period-label-conflict.yaml +68 -0
- package/rules/period-multiple-mismatch.yaml +61 -0
- package/rules/period-part-exceeds-whole.yaml +62 -0
- package/rules/person-consistency.yaml +1 -1
- package/rules/phone-number-variant.yaml +3 -3
- package/rules/preamble-length.yaml +2 -2
- package/rules/preferred-term.yaml +2 -2
- package/rules/prerequisite-after-step.yaml +1 -1
- package/rules/product-exceeds-maximum.yaml +49 -0
- package/rules/proper-noun-density.yaml +1 -1
- package/rules/quantity-range-reversed.yaml +53 -0
- package/rules/range-band-mismatch.yaml +70 -0
- package/rules/ratio-mismatch.yaml +64 -0
- package/rules/reference-flag-mismatch.yaml +74 -0
- package/rules/reference-number-repeated.yaml +63 -0
- package/rules/reference-number-variant.yaml +81 -0
- package/rules/reference-title-mismatch.yaml +1 -1
- package/rules/reference-topic-missing.yaml +1 -1
- package/rules/reference-unit-mismatch.yaml +62 -0
- package/rules/relative-date-mismatch.yaml +1 -1
- package/rules/rent-multiple-mismatch.yaml +61 -0
- package/rules/request-without-deadline.yaml +3 -3
- package/rules/required-listed-as-preferred.yaml +1 -1
- package/rules/required-sections.yaml +2 -2
- package/rules/requirement-modal.yaml +2 -2
- package/rules/requirement-smell.yaml +1 -1
- package/rules/revision-direction-mismatch.yaml +66 -0
- package/rules/risk-disclosure.yaml +1 -1
- package/rules/running-balance-mismatch.yaml +59 -0
- package/rules/scaled-quantity-mismatch.yaml +69 -0
- package/rules/serial-range-reversed.yaml +52 -0
- package/rules/share-amount-mismatch.yaml +58 -0
- package/rules/share-over-hundred.yaml +1 -1
- package/rules/shell-prompt-mix.yaml +1 -1
- package/rules/space-before-punctuation.yaml +1 -1
- package/rules/spelling-consistency.yaml +1 -1
- package/rules/step-statement-mix.yaml +3 -3
- package/rules/step-time-sum-mismatch.yaml +65 -0
- package/rules/stock-transition.yaml +1 -1
- package/rules/summary-fact-mismatch.yaml +1 -1
- package/rules/table-header-variant.yaml +1 -1
- package/rules/table-unit-mix.yaml +82 -0
- package/rules/taigen-dome-in-prose.yaml +1 -1
- package/rules/tax-mismatch.yaml +13 -7
- package/rules/tier-threshold-mismatch.yaml +73 -0
- package/rules/time-order.yaml +7 -4
- package/rules/time-range-reversed.yaml +53 -0
- package/rules/title-case-consistency.yaml +2 -2
- package/rules/toc-heading-mismatch.yaml +1 -1
- package/rules/topic-predicate-distance.yaml +1 -1
- package/rules/total-mismatch.yaml +5 -5
- package/rules/ui-label-variant.yaml +1 -1
- package/rules/unclosed-code-fence.yaml +1 -1
- package/rules/uncomparable-graded.yaml +2 -2
- package/rules/undefined-term.yaml +2 -2
- package/rules/unfilled-placeholder.yaml +2 -2
- package/rules/unit-mismatch.yaml +13 -5
- package/rules/unit-spacing-consistency.yaml +1 -1
- package/rules/unknown-word.yaml +1 -1
- package/rules/unlisted-item-used.yaml +90 -0
- package/rules/unused-definition.yaml +2 -2
- package/rules/url-run-on.yaml +1 -1
- package/rules/use-before-definition.yaml +2 -2
- package/rules/vague-deadline.yaml +1 -1
- package/rules/vague-figure-reference.yaml +1 -1
- package/rules/vague-word-density.yaml +2 -2
- package/rules/variance-mismatch.yaml +67 -0
- package/rules/very-adjective.yaml +1 -1
- package/rules/walk-time-distance-mismatch.yaml +55 -0
- package/rules/warning-without-action.yaml +1 -1
- package/rules/weasel-word.yaml +2 -2
- package/rules/wordy-phrase.yaml +2 -2
- package/rules/yori-as-from.yaml +1 -1
- package/skills/chaff/SKILL.md +59 -9
- package/src/announced-count.ts +6 -3
- package/src/company-kana-spelling.ts +105 -0
- package/src/company-names.ts +159 -26
- package/src/contacts/addresses.ts +179 -0
- package/src/contacts/emails.ts +63 -0
- package/src/contacts/table-rows.ts +51 -0
- package/src/contacts/variants.ts +33 -0
- package/src/derived/age-on-date.ts +161 -0
- package/src/derived/battery-runtime.ts +284 -0
- package/src/derived/durations.ts +83 -12
- package/src/derived/hours-and-minutes.ts +41 -0
- package/src/derived/hyphenated-counts.ts +38 -0
- package/src/derived/marked-dates.ts +61 -0
- package/src/derived/money-span.ts +10 -0
- package/src/derived/period-counts.ts +178 -0
- package/src/derived/period-parts.ts +360 -0
- package/src/derived/readable-date.ts +63 -0
- package/src/derived/stays.ts +7 -2
- package/src/derived/time-lengths.ts +12 -9
- package/src/derived/timesheet-hours.ts +112 -0
- package/src/derived/use-interval.ts +151 -0
- package/src/derived/use-maximum.ts +158 -0
- package/src/derived/working-hours.ts +2 -2
- package/src/detectors/announced-count.ts +1 -0
- package/src/detectors/annual-holidays-mismatch.ts +41 -0
- package/src/detectors/annual-pay-mismatch.ts +71 -0
- package/src/detectors/blank-structure.ts +54 -14
- package/src/detectors/bmi-mismatch.ts +82 -0
- package/src/detectors/capacity-runtime.ts +128 -0
- package/src/detectors/change-rate.ts +27 -4
- package/src/detectors/closing-balance-mismatch.ts +52 -0
- package/src/detectors/contact-variant.ts +30 -0
- package/src/detectors/count-over-capacity.ts +37 -0
- package/src/detectors/cumulative-below-current.ts +30 -0
- package/src/detectors/currency-column.ts +37 -0
- package/src/detectors/date-any-year.ts +130 -0
- package/src/detectors/date-outside-period.ts +5 -10
- package/src/detectors/date-stamp-order.ts +29 -0
- package/src/detectors/date-year.ts +55 -13
- package/src/detectors/deductible-exceeds-limit.ts +55 -0
- package/src/detectors/defined-term-form.ts +48 -9
- package/src/detectors/definition-use.ts +6 -2
- package/src/detectors/derived-numbers.ts +52 -91
- package/src/detectors/discount-rate.ts +41 -0
- package/src/detectors/due-date.ts +28 -6
- package/src/detectors/email-letter.ts +45 -15
- package/src/detectors/en-shape.ts +11 -4
- package/src/detectors/event-deadline.ts +39 -0
- package/src/detectors/fact-consistency.ts +206 -7
- package/src/detectors/gloss-year.ts +21 -0
- package/src/detectors/gpa-mismatch.ts +43 -0
- package/src/detectors/heading-case.ts +13 -4
- package/src/detectors/heading-echo.ts +17 -1
- package/src/detectors/impossible-date.ts +25 -3
- package/src/detectors/installment-total-mismatch.ts +68 -0
- package/src/detectors/interest.ts +43 -0
- package/src/detectors/lab-columns.ts +9 -0
- package/src/detectors/labelled-age.ts +154 -0
- package/src/detectors/layout-code.ts +174 -0
- package/src/detectors/line-amount.ts +58 -3
- package/src/detectors/measured-facts.ts +20 -0
- package/src/detectors/meter-usage.ts +49 -0
- package/src/detectors/name-field.ts +43 -0
- package/src/detectors/name-variant-model-codes.ts +27 -0
- package/src/detectors/name-variant.ts +190 -20
- package/src/detectors/net-amount-mismatch.ts +86 -0
- package/src/detectors/net-gross-weight.ts +39 -0
- package/src/detectors/nominal-step.ts +35 -0
- package/src/detectors/number-style.ts +11 -2
- package/src/detectors/order-quantity.ts +46 -0
- package/src/detectors/orthographic-variant.ts +118 -19
- package/src/detectors/orthography.ts +34 -8
- package/src/detectors/period-label-conflict.ts +43 -0
- package/src/detectors/period-multiple-mismatch.ts +54 -0
- package/src/detectors/period-part.ts +71 -0
- package/src/detectors/quantity-range.ts +47 -0
- package/src/detectors/range-band.ts +125 -0
- package/src/detectors/range-words.ts +17 -0
- package/src/detectors/ratio-mismatch.ts +116 -0
- package/src/detectors/readable-dates.ts +36 -0
- package/src/detectors/reference-flag.ts +36 -0
- package/src/detectors/reference-number-repeated.ts +25 -0
- package/src/detectors/reference-number-variant.ts +44 -0
- package/src/detectors/reference-unit.ts +24 -0
- package/src/detectors/registry/annual-holidays-mismatch.ts +4 -0
- package/src/detectors/registry/annual-pay-mismatch.ts +4 -0
- package/src/detectors/registry/backorder-mismatch.ts +4 -0
- package/src/detectors/registry/bmi-mismatch.ts +4 -0
- package/src/detectors/registry/capacity-runtime-mismatch.ts +4 -0
- package/src/detectors/registry/closing-balance-mismatch.ts +4 -0
- package/src/detectors/registry/contact-variant.ts +4 -0
- package/src/detectors/registry/count-over-capacity.ts +4 -0
- package/src/detectors/registry/cumulative-below-current.ts +4 -0
- package/src/detectors/registry/currency-column-mix.ts +4 -0
- package/src/detectors/registry/date-stamp-order.ts +4 -0
- package/src/detectors/registry/deductible-exceeds-limit.ts +4 -0
- package/src/detectors/registry/delivered-over-ordered.ts +4 -0
- package/src/detectors/registry/discount-rate.ts +4 -0
- package/src/detectors/registry/elapsed-years-mismatch.ts +1 -1
- package/src/detectors/registry/event-deadline.ts +4 -0
- package/src/detectors/registry/gpa-mismatch.ts +4 -0
- package/src/detectors/registry/installment-total-mismatch.ts +4 -0
- package/src/detectors/registry/interest.ts +4 -0
- package/src/detectors/registry/interval-count-mismatch.ts +4 -0
- package/src/detectors/registry/layout-code-mismatch.ts +4 -0
- package/src/detectors/registry/meter-usage.ts +4 -0
- package/src/detectors/registry/net-amount-mismatch.ts +4 -0
- package/src/detectors/registry/net-over-gross.ts +4 -0
- package/src/detectors/registry/period-label-conflict.ts +4 -0
- package/src/detectors/registry/period-multiple-mismatch.ts +4 -0
- package/src/detectors/registry/period-part-exceeds-whole.ts +4 -0
- package/src/detectors/registry/product-exceeds-maximum.ts +4 -0
- package/src/detectors/registry/quantity-range.ts +4 -0
- package/src/detectors/registry/range-band-mismatch.ts +4 -0
- package/src/detectors/registry/ratio-mismatch.ts +4 -0
- package/src/detectors/registry/reference-flag-mismatch.ts +4 -0
- package/src/detectors/registry/reference-number-repeated.ts +4 -0
- package/src/detectors/registry/reference-number-variant.ts +4 -0
- package/src/detectors/registry/reference-unit.ts +4 -0
- package/src/detectors/registry/rent-multiple-mismatch.ts +4 -0
- package/src/detectors/registry/revision-direction.ts +4 -0
- package/src/detectors/registry/running-balance.ts +4 -0
- package/src/detectors/registry/scaled-quantity-mismatch.ts +4 -0
- package/src/detectors/registry/serial-range.ts +4 -0
- package/src/detectors/registry/share-amount.ts +4 -0
- package/src/detectors/registry/step-time-sum-mismatch.ts +4 -0
- package/src/detectors/registry/table-unit-mix.ts +4 -0
- package/src/detectors/registry/tier-threshold.ts +4 -0
- package/src/detectors/registry/time-range-reversed.ts +4 -0
- package/src/detectors/registry/unlisted-item-used.ts +4 -0
- package/src/detectors/registry/variance-mismatch.ts +4 -0
- package/src/detectors/registry/walk-time-distance-mismatch.ts +4 -0
- package/src/detectors/relative-dates.ts +2 -1
- package/src/detectors/relative-day-words.ts +2 -1
- package/src/detectors/rent-multiple-mismatch.ts +57 -0
- package/src/detectors/request-owner.ts +5 -2
- package/src/detectors/revision-direction.ts +44 -0
- package/src/detectors/row-sentence-amounts.ts +96 -0
- package/src/detectors/running-balance.ts +31 -0
- package/src/detectors/scaled-quantity.ts +49 -0
- package/src/detectors/serial-range.ts +37 -0
- package/src/detectors/share-amount.ts +51 -0
- package/src/detectors/signals.ts +3 -1
- package/src/detectors/step-time-sum.ts +55 -0
- package/src/detectors/structure-tree.ts +82 -9
- package/src/detectors/structure.ts +1 -1
- package/src/detectors/table-scale.ts +37 -0
- package/src/detectors/tax-amount.ts +45 -13
- package/src/detectors/technical-docs.ts +16 -2
- package/src/detectors/tier-threshold.ts +108 -0
- package/src/detectors/time-order.ts +55 -17
- package/src/detectors/unit-consistency.ts +50 -38
- package/src/detectors/unlisted-items.ts +72 -0
- package/src/detectors/use-count-words.ts +32 -0
- package/src/detectors/use-interval.ts +51 -0
- package/src/detectors/use-maximum.ts +38 -0
- package/src/detectors/variance.ts +33 -0
- package/src/detectors/walk-time-distance-mismatch.ts +45 -0
- package/src/detectors/whole-count-findings.ts +48 -0
- package/src/detectors/working-hours-findings.ts +100 -0
- package/src/facts/age-values.ts +124 -0
- package/src/facts/approximate-tolerance.ts +19 -0
- package/src/facts/cell-keys.ts +21 -0
- package/src/facts/count-labels.ts +28 -0
- package/src/facts/document-terms.ts +107 -0
- package/src/facts/duration-scale.ts +22 -0
- package/src/facts/duration-values.ts +44 -0
- package/src/facts/fact-values.ts +36 -7
- package/src/facts/item-amounts.ts +94 -0
- package/src/facts/labelled-facts.ts +92 -13
- package/src/facts/measure-units.ts +49 -0
- package/src/facts/measures.ts +114 -26
- package/src/facts/qualified-labels.ts +126 -0
- package/src/facts/rate-values.ts +117 -0
- package/src/facts/retention-periods.ts +216 -0
- package/src/facts/row-sentence-amounts.ts +113 -0
- package/src/facts/superscript-power.ts +5 -0
- package/src/facts/table-facts.ts +35 -7
- package/src/facts/term-values.ts +236 -0
- package/src/facts/unit-conflicts.ts +22 -9
- package/src/facts/unit-equivalents.ts +70 -0
- package/src/facts/unit-tolerance.ts +17 -0
- package/src/facts/unit-word.ts +48 -0
- package/src/facts/verb-quantity-facts.ts +84 -0
- package/src/facts/whole-counts.ts +183 -0
- package/src/facts/written-precision.ts +23 -0
- package/src/kana-spelling.ts +25 -0
- package/src/model-codes.ts +104 -0
- package/src/name-char-reading.ts +24 -0
- package/src/name-line-block.ts +40 -0
- package/src/name-lookalike-chars.ts +53 -0
- package/src/name-neighbours.ts +58 -0
- package/src/name-ordinary-word.ts +68 -0
- package/src/name-person.ts +31 -0
- package/src/name-separator.ts +48 -0
- package/src/name-spelling-chars.ts +34 -0
- package/src/name-variants.ts +49 -92
- package/src/name-weight.ts +12 -0
- package/src/person-field.ts +43 -0
- package/src/person-full-name.ts +70 -0
- package/src/phone-numbers.ts +76 -20
- package/src/place-names.ts +53 -14
- package/src/plugin.ts +4 -0
- package/src/preamble-paragraphs.ts +21 -2
- package/src/product-names.ts +98 -0
- package/src/profile/parse.ts +10 -0
- package/src/reference-numbers.ts +55 -0
- package/src/spaced-person-name.ts +97 -0
- package/src/spacing-code.ts +47 -0
- package/src/structure/amount-range.ts +16 -7
- package/src/structure/annual-holidays.ts +222 -0
- package/src/structure/annual-pay.ts +339 -0
- package/src/structure/bmi.ts +133 -0
- package/src/structure/capacity-count.ts +196 -0
- package/src/structure/change-rate-table.ts +135 -0
- package/src/structure/change-rate.ts +54 -17
- package/src/structure/closing-balance.ts +104 -0
- package/src/structure/column-date-order.ts +73 -0
- package/src/structure/compound-hours.ts +49 -0
- package/src/structure/counted-amounts.ts +5 -4
- package/src/structure/cumulative-below-current.ts +66 -0
- package/src/structure/currency-column.ts +97 -0
- package/src/structure/date-deadline-mark.ts +30 -0
- package/src/structure/date-outside-period.ts +28 -15
- package/src/structure/date-range.ts +7 -10
- package/src/structure/deadline-after-event.ts +184 -0
- package/src/structure/deductible-limit.ts +255 -0
- package/src/structure/definition-use.ts +59 -2
- package/src/structure/discount-rate.ts +209 -0
- package/src/structure/due-date.ts +8 -32
- package/src/structure/generic-role.ts +8 -0
- package/src/structure/gpa.ts +218 -0
- package/src/structure/installment-total.ts +343 -0
- package/src/structure/interest.ts +133 -0
- package/src/structure/key-value-row.ts +45 -0
- package/src/structure/lab-columns.ts +21 -0
- package/src/structure/labelled-date-order.ts +100 -0
- package/src/structure/labelled-order.ts +122 -0
- package/src/structure/labelled-time-order.ts +100 -0
- package/src/structure/layout-codes.ts +210 -0
- package/src/structure/line-amount-label.ts +100 -0
- package/src/structure/line-amount-rate.ts +178 -0
- package/src/structure/line-amount-unit.ts +16 -0
- package/src/structure/line-amount.ts +200 -48
- package/src/structure/measured-amounts.ts +138 -0
- package/src/structure/meter-usage-read.ts +139 -0
- package/src/structure/meter-usage.ts +224 -0
- package/src/structure/net-amount.ts +243 -0
- package/src/structure/net-gross-weight.ts +97 -0
- package/src/structure/order-quantity.ts +125 -0
- package/src/structure/party-role.ts +4 -1
- package/src/structure/percent-sum.ts +3 -0
- package/src/structure/period-label-conflict.ts +174 -0
- package/src/structure/period-labels.ts +147 -0
- package/src/structure/period-multiple.ts +186 -0
- package/src/structure/quantity-range.ts +47 -0
- package/src/structure/range-bands.ts +316 -0
- package/src/structure/range-years.ts +75 -0
- package/src/structure/ratio.ts +296 -0
- package/src/structure/reference-flags.ts +156 -0
- package/src/structure/reference-number-repeated.ts +57 -0
- package/src/structure/reference-unit.ts +105 -0
- package/src/structure/rent-multiple.ts +207 -0
- package/src/structure/revision-direction.ts +214 -0
- package/src/structure/running-balance.ts +157 -0
- package/src/structure/scaled-quantities.ts +239 -0
- package/src/structure/serial-range.ts +52 -0
- package/src/structure/share-amount.ts +206 -0
- package/src/structure/shift-times.ts +136 -0
- package/src/structure/span-label.ts +26 -0
- package/src/structure/stamp-order.ts +100 -0
- package/src/structure/stated-multiple.ts +82 -0
- package/src/structure/stated-period.ts +23 -11
- package/src/structure/step-times.ts +169 -0
- package/src/structure/table-scale.ts +239 -0
- package/src/structure/tax-price.ts +136 -0
- package/src/structure/tax.ts +55 -20
- package/src/structure/term-deadline.ts +35 -0
- package/src/structure/tier-threshold.ts +218 -0
- package/src/structure/time-range.ts +70 -0
- package/src/structure/total-line.ts +232 -0
- package/src/structure/total-row-blank.ts +23 -0
- package/src/structure/total.ts +156 -12
- package/src/structure/unlisted-items.ts +207 -0
- package/src/structure/variance-table.ts +167 -0
- package/src/structure/walk-time.ts +285 -0
- package/src/table-names.ts +6 -6
- package/src/unlabelled-references.ts +83 -0
- package/src/vehicle-plates.ts +142 -0
- package/src/whole-word-runs.ts +38 -0
package/src/name-variants.ts
CHANGED
|
@@ -2,6 +2,10 @@ import type { Token } from "./plugin.ts";
|
|
|
2
2
|
import { escapeRegExp } from "./orthography.ts";
|
|
3
3
|
import { nameCueAt, type NameCue, type NameCues } from "./name-cue.ts";
|
|
4
4
|
import { isNearSurname } from "./surname-near.ts";
|
|
5
|
+
import { foldedKeysOf, NO_SPELLING, type SpellingInput } from "./name-spelling-chars.ts";
|
|
6
|
+
import { NO_CHAR_READINGS, readingOfWords } from "./name-char-reading.ts";
|
|
7
|
+
import { isPersonRun } from "./name-person.ts";
|
|
8
|
+
import { heavierFirst, outweighs, type NameWeight } from "./name-weight.ts";
|
|
5
9
|
|
|
6
10
|
// 同じ名前(人・会社・製品)を、文書の中で少しだけ違う形に書いた所。どの形が正しいかは決めず、少ないほうを指す。
|
|
7
11
|
// 三通りで同じ名前と見る。書き方の違いだけ(GitHub と Github、Mac OS と macOS)、読みが同じ(山田太郎 と 山田太朗)、
|
|
@@ -9,7 +13,9 @@ import { isNearSurname } from "./surname-near.ts";
|
|
|
9
13
|
|
|
10
14
|
/**
|
|
11
15
|
* words は名前の語(記号を除く)。読みが同じ二つの名前が、どの語で違うかを見るため。person は人の名前と読めるもの(解析器が
|
|
12
|
-
* 人名と読むか、敬称が付く)。cue は前後の語から見た名前らしさ(name-cue.ts)。
|
|
16
|
+
* 人名と読むか、敬称が付く)。cue は前後の語から見た名前らしさ(name-cue.ts)。ordinary は、ふつうの語でもある一語の名前で、
|
|
17
|
+
* 文書がその形をどこでも名前に使わないもの(name-ordinary-word.ts)。labelled は、人を書く欄(氏名:、Contractor:)に書いた名前
|
|
18
|
+
* (person-field.ts)。
|
|
13
19
|
*/
|
|
14
20
|
export type NameMention = {
|
|
15
21
|
readonly surface: string;
|
|
@@ -18,12 +24,14 @@ export type NameMention = {
|
|
|
18
24
|
readonly words: readonly string[];
|
|
19
25
|
readonly person?: boolean;
|
|
20
26
|
readonly cue?: NameCue;
|
|
27
|
+
readonly ordinary?: boolean;
|
|
28
|
+
readonly labelled?: boolean;
|
|
21
29
|
};
|
|
22
30
|
|
|
23
31
|
export type NameVariant = {
|
|
24
32
|
readonly mention: NameMention;
|
|
25
33
|
readonly usual: string;
|
|
26
|
-
readonly kind: "spelling" | "reading" | "near" | "surname" | "character";
|
|
34
|
+
readonly kind: "spelling" | "kana" | "reading" | "near" | "surname" | "character" | "field";
|
|
27
35
|
};
|
|
28
36
|
|
|
29
37
|
/** 字体の違う同じ字(斎・斉・齋)。字から、その組の代表の字へ。 */
|
|
@@ -78,18 +86,12 @@ const withoutEdgeQuotes = (text: string): string => {
|
|
|
78
86
|
*/
|
|
79
87
|
const NOT_COMPARED = /@|(?:^|\s)\p{L}(?:\s|$)/u;
|
|
80
88
|
|
|
81
|
-
/** 人名と読む解析器の印(UD の NameType: 姓 Sur、名 Giv、どちらとも言えない人名 Prs)。 */
|
|
82
|
-
const PERSON_TYPES: ReadonlySet<string> = new Set(["Sur", "Giv", "Prs"]);
|
|
83
|
-
|
|
84
|
-
/** 人の名前か。解析器が人名と読む語を含むか、すぐ後ろに敬称(様、さん、氏)が付く。 */
|
|
85
|
-
const isPerson = (run: readonly Token[], next: Token | undefined, suffixes: readonly string[]): boolean =>
|
|
86
|
-
run.some((token) => PERSON_TYPES.has(token.features?.["NameType"] ?? "")) || (next !== undefined && suffixes.includes(next.surface));
|
|
87
|
-
|
|
88
89
|
/**
|
|
89
90
|
* 文の語から、名前の現れ。surface は source の上の書いたまま(折り返しの空白は一つにまとめる)。
|
|
90
91
|
* 大文字だけの名前(ACME INC、NASA)は外す。契約書の署名欄や略語で、ふつうの書き方の別の形ではない。小文字の英字だけの語も外す。
|
|
92
|
+
* charReadings は解析器が読めない名前の字の読み(name-char-reading.ts)。人の名前と読めるものだけに使う。
|
|
91
93
|
*/
|
|
92
|
-
export const mentionsIn = (tokens: readonly Token[], source: string, personSuffixes: readonly string[] = []): NameMention[] =>
|
|
94
|
+
export const mentionsIn = (tokens: readonly Token[], source: string, personSuffixes: readonly string[] = [], charReadings = NO_CHAR_READINGS): NameMention[] =>
|
|
93
95
|
runsOf(tokens).flatMap((run) => {
|
|
94
96
|
const first = run[0];
|
|
95
97
|
const last = run.at(-1);
|
|
@@ -98,67 +100,11 @@ export const mentionsIn = (tokens: readonly Token[], source: string, personSuffi
|
|
|
98
100
|
const surface = withoutEdgeQuotes(written);
|
|
99
101
|
if (surface === "" || isUpperOnly(surface) || LOWER_LATIN_ONLY.test(surface) || NOT_COMPARED.test(surface)) return [];
|
|
100
102
|
const words = run.filter((token) => !JOINERS.has(token.surface));
|
|
101
|
-
const
|
|
102
|
-
const reading =
|
|
103
|
-
const person = isPerson(run, tokens[tokens.indexOf(last) + 1], personSuffixes);
|
|
103
|
+
const person = isPersonRun(run, tokens, personSuffixes);
|
|
104
|
+
const reading = readingOfWords(words, person ? charReadings : NO_CHAR_READINGS);
|
|
104
105
|
return [{ surface, offset: first.span.start, reading, words: words.map((token) => token.surface), person }];
|
|
105
106
|
});
|
|
106
107
|
|
|
107
|
-
/** 隣の語を探す範囲(UTF-16 の単位)。 */
|
|
108
|
-
const NEIGHBOUR_LOOKBACK = 40;
|
|
109
|
-
/** 隣の語の外側の記号((Rachel、Floyd.)。名前の側の記号(Rachel, Whitford の ,)は語を切るので残す。 */
|
|
110
|
-
const MARK = /\p{P}/u;
|
|
111
|
-
const withoutLeadingMarks = (word: string): string => {
|
|
112
|
-
const chars = [...word];
|
|
113
|
-
const start = chars.findIndex((char) => !MARK.test(char));
|
|
114
|
-
return start < 0 ? "" : chars.slice(start).join("");
|
|
115
|
-
};
|
|
116
|
-
const withoutTrailingMarks = (word: string): string => {
|
|
117
|
-
const chars = [...word];
|
|
118
|
-
return chars.slice(0, chars.findLastIndex((char) => !MARK.test(char)) + 1).join("");
|
|
119
|
-
};
|
|
120
|
-
|
|
121
|
-
const wordBeforeAt = (source: string, offset: number): string | undefined => {
|
|
122
|
-
if (source.charAt(offset - 1) !== " ") return undefined;
|
|
123
|
-
const from = Math.max(0, offset - 1 - NEIGHBOUR_LOOKBACK);
|
|
124
|
-
const parts = source.slice(from, offset - 1).split(/\s/u);
|
|
125
|
-
const word = withoutLeadingMarks(parts.at(-1) ?? "");
|
|
126
|
-
return word === "" || (from > 0 && parts.length === 1) ? undefined : word;
|
|
127
|
-
};
|
|
128
|
-
|
|
129
|
-
const wordAfterAt = (source: string, end: number): string | undefined => {
|
|
130
|
-
if (source.charAt(end) !== " ") return undefined;
|
|
131
|
-
const word = withoutTrailingMarks(source.slice(end + 1, end + 1 + NEIGHBOUR_LOOKBACK).split(/\s/u)[0] ?? "");
|
|
132
|
-
return word === "" ? undefined : word;
|
|
133
|
-
};
|
|
134
|
-
|
|
135
|
-
/**
|
|
136
|
-
* 解析器が名前の一語を名前と読まなかった所(to Rachel Whitford の Rachel を動詞と読む)。空白一つで隣の語と合わせた形を、ほかの所で
|
|
137
|
-
* 名前と読めていれば、その形の現れと見る。隣の語がほかの名前の現れに入るなら合わせない。
|
|
138
|
-
*/
|
|
139
|
-
export const withKnownNeighbours = (mentions: readonly NameMention[], source: string): NameMention[] => {
|
|
140
|
-
const known = new Set(mentions.filter((mention) => mention.words.length >= 2).map((mention) => mention.surface));
|
|
141
|
-
const taken = (start: number, end: number): boolean => mentions.some((mention) => mention.offset < end && start < mention.offset + mention.surface.length);
|
|
142
|
-
return mentions.map((mention) => {
|
|
143
|
-
const end = mention.offset + mention.surface.length;
|
|
144
|
-
const before = wordBeforeAt(source, mention.offset);
|
|
145
|
-
const after = wordAfterAt(source, end);
|
|
146
|
-
if (before !== undefined && known.has(`${before} ${mention.surface}`) && !taken(mention.offset - 1 - before.length, mention.offset - 1)) {
|
|
147
|
-
return {
|
|
148
|
-
...mention,
|
|
149
|
-
surface: `${before} ${mention.surface}`,
|
|
150
|
-
offset: mention.offset - 1 - before.length,
|
|
151
|
-
reading: undefined,
|
|
152
|
-
words: [before, ...mention.words],
|
|
153
|
-
};
|
|
154
|
-
}
|
|
155
|
-
if (after !== undefined && known.has(`${mention.surface} ${after}`) && !taken(end + 1, end + 1 + after.length)) {
|
|
156
|
-
return { ...mention, surface: `${mention.surface} ${after}`, reading: undefined, words: [...mention.words, after] };
|
|
157
|
-
}
|
|
158
|
-
return mention;
|
|
159
|
-
});
|
|
160
|
-
};
|
|
161
|
-
|
|
162
108
|
/** 敬称の前の名前の字数(髙橋、髙橋太郎)。長い漢字の連なり(株式会社髙橋)は名前だけを切り出せない。 */
|
|
163
109
|
const MAX_SUFFIXED_NAME = 4;
|
|
164
110
|
const MIN_SUFFIXED_NAME = 2;
|
|
@@ -217,7 +163,11 @@ export const nameKey = (surface: string): string =>
|
|
|
217
163
|
*/
|
|
218
164
|
export type NameEvidence = { readonly person: boolean; readonly named: boolean; readonly nameLike: boolean };
|
|
219
165
|
|
|
220
|
-
|
|
166
|
+
/** readings は書き方の現れの読みのすべて。解析器は同じ字を所によって別に読む(佐伯 を サエキ と サイキ)。 */
|
|
167
|
+
type Tally = NameEvidence & NameWeight & { readonly surface: string; readonly first: NameMention; readonly readings: readonly string[] };
|
|
168
|
+
|
|
169
|
+
const readingsWith = (readings: readonly string[], reading: string | undefined): readonly string[] =>
|
|
170
|
+
reading === undefined || readings.includes(reading) ? readings : [...readings, reading];
|
|
221
171
|
|
|
222
172
|
const evidenceOf = (mention: NameMention): NameEvidence => ({
|
|
223
173
|
person: mention.person === true,
|
|
@@ -234,22 +184,24 @@ const talliesOf = (mentions: readonly NameMention[]): Tally[] => {
|
|
|
234
184
|
tallies.set(
|
|
235
185
|
mention.surface,
|
|
236
186
|
tally === undefined
|
|
237
|
-
? { surface: mention.surface, first: mention, count: 1, ...evidence }
|
|
187
|
+
? { surface: mention.surface, first: mention, count: 1, readings: readingsWith([], mention.reading), labelled: mention.labelled === true, ...evidence }
|
|
238
188
|
: {
|
|
239
189
|
...tally,
|
|
240
190
|
count: tally.count + 1,
|
|
191
|
+
readings: readingsWith(tally.readings, mention.reading),
|
|
241
192
|
person: tally.person || evidence.person,
|
|
242
193
|
named: tally.named || evidence.named,
|
|
243
194
|
nameLike: tally.nameLike || evidence.nameLike,
|
|
195
|
+
labelled: tally.labelled || mention.labelled === true,
|
|
244
196
|
},
|
|
245
197
|
);
|
|
246
198
|
});
|
|
247
199
|
return [...tallies.values()];
|
|
248
200
|
};
|
|
249
201
|
|
|
250
|
-
/**
|
|
202
|
+
/** 重いほう(name-weight.ts)。同じ重さなら先に書いたほう。 */
|
|
251
203
|
const usualOf = (group: readonly Tally[]): Tally | undefined =>
|
|
252
|
-
group.toSorted((left, right) => right
|
|
204
|
+
group.toSorted((left, right) => heavierFirst(left, right) || left.first.offset - right.first.offset)[0];
|
|
253
205
|
|
|
254
206
|
const groupBy = (tallies: readonly Tally[], keysOf: (tally: Tally) => readonly string[]): Tally[][] => {
|
|
255
207
|
const groups = new Map<string, Tally[]>();
|
|
@@ -265,13 +217,17 @@ const groupBy = (tallies: readonly Tally[], keysOf: (tally: Tally) => readonly s
|
|
|
265
217
|
|
|
266
218
|
/**
|
|
267
219
|
* 組の中で、それぞれの書き方を、同じ名前と言える相手(alike)のうち多いほうと比べる。組全体で一番多いものとだけ比べると、
|
|
268
|
-
* 同じ読みの別の名前(山田太郎 と 矢間田多労)が多ければ、本当の書き分け(山田太朗)が隠れる。
|
|
220
|
+
* 同じ読みの別の名前(山田太郎 と 矢間田多労)が多ければ、本当の書き分け(山田太朗)が隠れる。alike が数を問う見方では、
|
|
221
|
+
* 一度だけ書いた相手を選んだのは人を書く欄に書いたからなので、field と言う。
|
|
269
222
|
*/
|
|
270
|
-
|
|
223
|
+
type Alike = (tally: Tally, other: Tally) => boolean;
|
|
224
|
+
|
|
225
|
+
const variantsIn = (groups: readonly Tally[][], kind: NameVariant["kind"], alike: Alike = () => true, counted = false): NameVariant[] =>
|
|
271
226
|
groups.flatMap((group) =>
|
|
272
227
|
group.flatMap((tally) => {
|
|
273
228
|
const usual = usualOf([tally, ...group.filter((other) => other !== tally && alike(tally, other))]);
|
|
274
|
-
|
|
229
|
+
if (usual === undefined || usual === tally) return [];
|
|
230
|
+
return [{ mention: tally.first, usual: usual.surface, kind: counted && usual.count === 1 ? "field" : kind }];
|
|
275
231
|
}),
|
|
276
232
|
);
|
|
277
233
|
|
|
@@ -334,28 +290,28 @@ const differingWords = (left: Tally, right: Tally): readonly [string, string] |
|
|
|
334
290
|
return leftWords.length === rightWords.length && leftWord !== undefined && rightWord !== undefined ? [leftWord, rightWord] : undefined;
|
|
335
291
|
};
|
|
336
292
|
|
|
337
|
-
/**
|
|
293
|
+
/** 一語だけが一字違いで、相手のほうが重い(outweighs)。どちらもふつうの語(Green と Greek)なら、別の二つの語。 */
|
|
338
294
|
const isSlipOf = (tally: Tally, other: Tally): boolean => {
|
|
339
|
-
if (tally.
|
|
295
|
+
if (!outweighs(other, tally) || (tally.first.ordinary === true && other.first.ordinary === true)) return false;
|
|
340
296
|
const words = differingWords(tally, other);
|
|
341
297
|
return words !== undefined && isNearWord(...words);
|
|
342
298
|
};
|
|
343
299
|
|
|
344
|
-
const nearVariants = (tallies: readonly Tally[]): NameVariant[] => variantsIn(groupBy(tallies, maskedKeys), "near", isSlipOf);
|
|
300
|
+
const nearVariants = (tallies: readonly Tally[]): NameVariant[] => variantsIn(groupBy(tallies, maskedKeys), "near", isSlipOf, true);
|
|
345
301
|
|
|
346
302
|
/**
|
|
347
303
|
* 名が同じで姓だけが二字ほど違う人の名前(Rachel Whitford と Rachel Whitfield)。一字違い(near)より遠いので、名と姓の二語以上
|
|
348
|
-
*
|
|
304
|
+
* で、違うのが最後の語のときに限る。相手のほうが重い(outweighs)。名の違う二人(Sara Whitford と Rachel Whitfield)は比べない。
|
|
349
305
|
*/
|
|
350
306
|
const isSurnameSlipOf = (tally: Tally, other: Tally): boolean => {
|
|
351
|
-
if (
|
|
307
|
+
if (!outweighs(other, tally)) return false;
|
|
352
308
|
const [words, others] = [wordsOf(tally.surface), wordsOf(other.surface)];
|
|
353
309
|
const last = words.length - 1;
|
|
354
310
|
const sameBefore = words.slice(0, last).every((word, index) => word === others[index]);
|
|
355
311
|
return last >= 1 && words.length === others.length && sameBefore && isNearSurname(words[last] ?? "", others[last] ?? "");
|
|
356
312
|
};
|
|
357
313
|
|
|
358
|
-
const surnameVariants = (tallies: readonly Tally[]): NameVariant[] => variantsIn(groupBy(tallies, maskedKeys), "surname", isSurnameSlipOf);
|
|
314
|
+
const surnameVariants = (tallies: readonly Tally[]): NameVariant[] => variantsIn(groupBy(tallies, maskedKeys), "surname", isSurnameSlipOf, true);
|
|
359
315
|
|
|
360
316
|
/** 字体の違う字(斎と斉)を組の代表の字に寄せた形。 */
|
|
361
317
|
const characterKey = (tally: Tally, chars: VariantChars): string => [...tally.surface].map((letter) => chars.get(letter) ?? letter).join("");
|
|
@@ -386,26 +342,27 @@ const oneCharApart = (left: string, right: string): boolean => {
|
|
|
386
342
|
};
|
|
387
343
|
|
|
388
344
|
/**
|
|
389
|
-
* 読みが同じ人の名前が、一字だけ違う(松本 と 松元)。読みの同じ別の姓(伊藤 と
|
|
390
|
-
*
|
|
345
|
+
* 読みが同じ人の名前が、一字だけ違う(松本 と 松元)。読みの同じ別の姓(伊藤 と 伊東)もあるので、相手のほうが重い(outweighs)
|
|
346
|
+
* ときに限る。
|
|
391
347
|
*/
|
|
392
|
-
const isPersonSlipOf = (tally: Tally, other: Tally): boolean =>
|
|
348
|
+
const isPersonSlipOf = (tally: Tally, other: Tally): boolean => outweighs(other, tally) && oneCharApart(tally.surface, other.surface);
|
|
393
349
|
|
|
394
350
|
const personReadingVariants = (tallies: readonly Tally[]): NameVariant[] =>
|
|
395
351
|
variantsIn(
|
|
396
352
|
groupBy(
|
|
397
353
|
tallies.filter((tally) => tally.person),
|
|
398
|
-
(tally) =>
|
|
354
|
+
(tally) => tally.readings,
|
|
399
355
|
),
|
|
400
356
|
"reading",
|
|
401
357
|
isPersonSlipOf,
|
|
358
|
+
true,
|
|
402
359
|
);
|
|
403
360
|
|
|
404
361
|
/**
|
|
405
362
|
* 同じ名前の、少ないほうの書き方。書き方ごとに最初の現れを一つ。同じ現れを二つの見方が言えば、先の見方だけ。chars は字体の
|
|
406
363
|
* 違う同じ字の組(語彙表 name-variant-char)。
|
|
407
364
|
*/
|
|
408
|
-
export const nameVariants = (mentions: readonly NameMention[], chars: VariantChars = new Map()): NameVariant[] => {
|
|
365
|
+
export const nameVariants = (mentions: readonly NameMention[], chars: VariantChars = new Map(), spelling: SpellingInput = NO_SPELLING): NameVariant[] => {
|
|
409
366
|
const tallies = talliesOf(mentions);
|
|
410
367
|
const found = [
|
|
411
368
|
...variantsIn(
|
|
@@ -413,7 +370,11 @@ export const nameVariants = (mentions: readonly NameMention[], chars: VariantCha
|
|
|
413
370
|
"spelling",
|
|
414
371
|
),
|
|
415
372
|
...variantsIn(
|
|
416
|
-
groupBy(
|
|
373
|
+
groupBy(talliesOf([...mentions, ...spelling.alsoWritten]), (tally) => foldedKeysOf(tally.surface, spelling.chars).map(nameKey)),
|
|
374
|
+
"kana",
|
|
375
|
+
),
|
|
376
|
+
...variantsIn(
|
|
377
|
+
groupBy(tallies, (tally) => tally.readings),
|
|
417
378
|
"reading",
|
|
418
379
|
oneWordApart,
|
|
419
380
|
),
|
|
@@ -424,10 +385,6 @@ export const nameVariants = (mentions: readonly NameMention[], chars: VariantCha
|
|
|
424
385
|
];
|
|
425
386
|
const reported = new Set<string>();
|
|
426
387
|
return found
|
|
427
|
-
.filter((variant) =>
|
|
428
|
-
if (reported.has(variant.mention.surface)) return false;
|
|
429
|
-
reported.add(variant.mention.surface);
|
|
430
|
-
return true;
|
|
431
|
-
})
|
|
388
|
+
.filter((variant) => !reported.has(variant.mention.surface) && reported.add(variant.mention.surface).size > 0)
|
|
432
389
|
.toSorted((left, right) => left.mention.offset - right.mention.offset);
|
|
433
390
|
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// 同じ名前の二つの書き方のうち、どちらを正しい形と見るか。多く書いたほう。どちらも一度だけなら、人を書く欄(氏名:、
|
|
2
|
+
// Contractor:)に書いたほう。欄に書いた名前は、書き手が確かめて書いた形。
|
|
3
|
+
|
|
4
|
+
/** count は文書の中で書いた数、labelled はどれかの現れを人を書く欄に書いたか。 */
|
|
5
|
+
export type NameWeight = { readonly count: number; readonly labelled: boolean };
|
|
6
|
+
|
|
7
|
+
/** 並べたとき重いほうが先。数が多いほう、同数なら欄に書いたほう。 */
|
|
8
|
+
export const heavierFirst = (left: NameWeight, right: NameWeight): number => right.count - left.count || Number(right.labelled) - Number(left.labelled);
|
|
9
|
+
|
|
10
|
+
/** 一度だけ書いた slip を、other の書き損じと見てよいか。other が二度以上か、どちらも一度だけで other だけを欄に書いたとき。 */
|
|
11
|
+
export const outweighs = (other: NameWeight, slip: NameWeight): boolean =>
|
|
12
|
+
slip.count === 1 && (other.count >= 2 || (other.count === 1 && other.labelled && !slip.labelled));
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// 人を書く欄(氏名:山下 美咲、Contractor: Priya Raman)に書いた名前。欄の語は語彙表 person-label から。
|
|
2
|
+
|
|
3
|
+
const FIELD_COLON = /[::]/u;
|
|
4
|
+
/** 欄の行の頭の、Markdown の印(箇条書き、引用、見出し、太字)。 */
|
|
5
|
+
const LINE_MARKS = /^[\s>*#+-]*(?:\*\*|__)?/u;
|
|
6
|
+
const TRAILING_BOLD = /(?:\*\*|__)$/u;
|
|
7
|
+
/** 「:」と名前のあいだ: 空白と太字の印だけ。欄の値の途中の名前(ご宿泊者:森下 千尋 様 の 千尋 様)は欄の名前でない。 */
|
|
8
|
+
const VALUE_START = /^(?:[ \t\u3000]|\*\*|__)*$/u;
|
|
9
|
+
/** 名前の後ろ: 太字の閉じと、行の終わり。日付などの括弧一つで終わってもよい。「,」の後ろは文の続きのことがある(Priya Raman, and …)。 */
|
|
10
|
+
const FIELD_END = /^(?:\*\*|__)?[ \t\u3000]*(?:[((][^()()\n]*[))][ \t\u3000]*)?(?:\r?\n|$)/u;
|
|
11
|
+
const LEADING_SPACE = /^[ \t\u3000]+/u;
|
|
12
|
+
/** 欄の語の前で語を切らない字。Company name の name は欄の語 Name ではない。患者氏名 の 氏名 は 氏名。 */
|
|
13
|
+
const WORD_BEFORE = /[\s\p{Script=Latin}]$/u;
|
|
14
|
+
|
|
15
|
+
const lineStart = (source: string, offset: number): number => source.lastIndexOf("\n", offset - 1) + 1;
|
|
16
|
+
|
|
17
|
+
/** 欄の語。行の頭の「:」の前まるごとで、大文字小文字は見ない。漢字やかなの欄の語は、前に語が付いてもよい(患者氏名)。 */
|
|
18
|
+
const isPersonLabel = (label: string, labels: readonly string[]): boolean => {
|
|
19
|
+
const lower = label.toLowerCase();
|
|
20
|
+
return labels.some((pattern) => {
|
|
21
|
+
const wanted = pattern.toLowerCase();
|
|
22
|
+
return lower === wanted || (lower.endsWith(wanted) && !WORD_BEFORE.test(lower.slice(0, -wanted.length)));
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
/** 名前の後ろの敬称(中村 健太 様)を一つ除いた残り。 */
|
|
27
|
+
const afterSuffix = (rest: string, suffixes: readonly string[]): string => {
|
|
28
|
+
const trimmed = rest.replace(LEADING_SPACE, "");
|
|
29
|
+
const suffix = suffixes.find((word) => trimmed.startsWith(word));
|
|
30
|
+
return suffix === undefined ? rest : trimmed.slice(suffix.length);
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* source の offset から length の名前が、人を書く欄の行の、欄の語と「:」のすぐ後ろにあり、そこで行が終わるか(氏名:山下 美咲、
|
|
35
|
+
* 患者氏名:中村 健太 様、- **Contractor:** Priya Raman、Name: **Priya Raman**)。suffixes は名前の後ろに付いてよい敬称(様)。
|
|
36
|
+
*/
|
|
37
|
+
export const isInPersonField = (source: string, offset: number, length: number, labels: readonly string[], suffixes: readonly string[] = []): boolean => {
|
|
38
|
+
const head = source.slice(lineStart(source, offset), offset);
|
|
39
|
+
const colon = head.search(FIELD_COLON);
|
|
40
|
+
if (colon < 0 || !VALUE_START.test(head.slice(colon + 1)) || !FIELD_END.test(afterSuffix(source.slice(offset + length), suffixes))) return false;
|
|
41
|
+
const label = head.slice(0, colon).replace(LINE_MARKS, "").replace(TRAILING_BOLD, "").trim();
|
|
42
|
+
return label !== "" && isPersonLabel(label, labels);
|
|
43
|
+
};
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import type { NameCue } from "./name-cue.ts";
|
|
2
|
+
import type { NameMention } from "./name-variants.ts";
|
|
3
|
+
import type { Span, Token } from "./plugin.ts";
|
|
4
|
+
import { isFollowedBySuffix } from "./name-person.ts";
|
|
5
|
+
|
|
6
|
+
// 空白(半角か全角)を挟んで書いた姓と名(田中 裕子)。解析器は空白で名前を切るので、名だけ(裕子)が名前の現れになり、別の人の
|
|
7
|
+
// 名(鈴木 祐子 の 祐子)と比べてしまう。姓と名を一つの現れにして、名前まるごとで比べる。
|
|
8
|
+
|
|
9
|
+
/** 姓と名のあいだの空白(半角、全角)。 */
|
|
10
|
+
const NAME_SPACE = /^[ \u3000]$/u;
|
|
11
|
+
|
|
12
|
+
const nameTypeOf = (token: Token | undefined): string | undefined => (token?.pos === "PROPN" ? token.features?.["NameType"] : undefined);
|
|
13
|
+
|
|
14
|
+
/** 姓の後ろの名。解析器が名(Giv)と読む語か、名を地名と読んでも(千尋 を Geo)後ろに敬称が付く、姓でない固有名詞。 */
|
|
15
|
+
const isGivenName = (token: Token | undefined, tokens: readonly Token[], suffixes: readonly string[]): boolean => {
|
|
16
|
+
const type = nameTypeOf(token);
|
|
17
|
+
return type === "Giv" || (token?.pos === "PROPN" && type !== "Sur" && isFollowedBySuffix(token, tokens, suffixes));
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/** 姓と名を分ける空白の語。前の語を解析器が姓(Sur)と読み、後ろの語が名の、空白一つ。suffixes は敬称(様、さん)。 */
|
|
21
|
+
export const fullNameGaps = (tokens: readonly Token[], suffixes: readonly string[] = []): Span[] =>
|
|
22
|
+
tokens.flatMap((token, index) =>
|
|
23
|
+
NAME_SPACE.test(token.surface) && nameTypeOf(tokens[index - 1]) === "Sur" && isGivenName(tokens[index + 1], tokens, suffixes) ? [token.span] : [],
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
const CUE_STRENGTH: readonly (NameCue | undefined)[] = [undefined, "bare", "slot", "person"];
|
|
27
|
+
|
|
28
|
+
/** 二つの現れの名前らしさの強いほう。前置き(担当の)は姓の前に、敬称(様)は名の後ろに付く。 */
|
|
29
|
+
const strongerCue = (left: NameCue | undefined, right: NameCue | undefined): NameCue | undefined =>
|
|
30
|
+
CUE_STRENGTH.indexOf(left) >= CUE_STRENGTH.indexOf(right) ? left : right;
|
|
31
|
+
|
|
32
|
+
const joined = (surname: NameMention, given: NameMention): NameMention => {
|
|
33
|
+
const cue = strongerCue(surname.cue, given.cue);
|
|
34
|
+
return {
|
|
35
|
+
...surname,
|
|
36
|
+
surface: `${surname.surface} ${given.surface}`,
|
|
37
|
+
reading: surname.reading === undefined || given.reading === undefined ? undefined : surname.reading + given.reading,
|
|
38
|
+
words: [...surname.words, ...given.words],
|
|
39
|
+
person: surname.person === true || given.person === true,
|
|
40
|
+
...(cue === undefined ? {} : { cue }),
|
|
41
|
+
};
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
/** 空白をちょうど挟む、一語の姓と名か。名は解析器が二語に切ることがある(健汰 を 健 と 汰)。 */
|
|
45
|
+
const isPair = (surname: NameMention, given: NameMention, gaps: readonly Span[]): boolean =>
|
|
46
|
+
surname.words.length === 1 && gaps.some((gap) => gap.start === surname.offset + surname.surface.length && gap.end === given.offset);
|
|
47
|
+
|
|
48
|
+
/** 空白を挟んだ一語の姓と名(田中 裕子)を、一つの名前の現れにする。名だけ、姓だけの現れはそのまま。 */
|
|
49
|
+
export const joinFullNames = (mentions: readonly NameMention[], gaps: readonly Span[]): NameMention[] => {
|
|
50
|
+
const names: NameMention[] = [];
|
|
51
|
+
mentions
|
|
52
|
+
.toSorted((left, right) => left.offset - right.offset)
|
|
53
|
+
.forEach((mention) => {
|
|
54
|
+
const previous = names.at(-1);
|
|
55
|
+
if (previous !== undefined && isPair(previous, mention, gaps)) names.splice(-1, 1, joined(previous, mention));
|
|
56
|
+
else names.push(mention);
|
|
57
|
+
});
|
|
58
|
+
return names;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
const LATIN = /\p{Script=Latin}/u;
|
|
62
|
+
const SPACE = /\s/u;
|
|
63
|
+
const withoutSpaces = (surface: string): string => surface.replaceAll(/\s/gu, "");
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* 日本語の名前の、姓と名のあいだに空白を置くかどうかだけが違う二つ(田中 裕子 と 田中裕子)。書き方の揺れとしては指さない。空白の
|
|
67
|
+
* 幅の違い(半角と全角)と、英字の名前の空白(Mac OS と MacOS)は書き方の違いなので、ここには入れない。
|
|
68
|
+
*/
|
|
69
|
+
export const spacedOnly = (left: string, right: string): boolean =>
|
|
70
|
+
!LATIN.test(left) && !LATIN.test(right) && SPACE.test(left) !== SPACE.test(right) && withoutSpaces(left) === withoutSpaces(right);
|
package/src/phone-numbers.ts
CHANGED
|
@@ -20,9 +20,22 @@ const NUMBER_EDGE_AFTER = String.raw`(?![\d\-‐−]|[.,]\d)`;
|
|
|
20
20
|
const COUNTRY_CODE = String.raw`(?:\+\d{1,3}[ -]?)?`;
|
|
21
21
|
/** Groups of digits joined by hyphens or brackets (03-1234-5678, 03(1234)5678, (555) 123-4567, +81-3-1234-5678). */
|
|
22
22
|
const NUMBER_SHAPE = new RegExp(String.raw`${NUMBER_EDGE_BEFORE}${COUNTRY_CODE}[((]?\d{1,5}(?:${GROUP_JOIN}\d{1,5}){1,3}${NUMBER_EDGE_AFTER}`, "gu");
|
|
23
|
+
/**
|
|
24
|
+
* Groups of digits joined by spaces (020 7946 0186, +44 20 7946 0186, 03 1234 5678). The last group has three digits or
|
|
25
|
+
* more and no such group follows it, so a count after the number ("0186 24 hours") is left out and a run that does not
|
|
26
|
+
* split one way only ("2026 10 09 020 7946 0186") is not read.
|
|
27
|
+
*/
|
|
28
|
+
const SPACED_SHAPE = new RegExp(
|
|
29
|
+
String.raw`${NUMBER_EDGE_BEFORE}(?:\+\d{1,3}[ \u00A0])?\d{1,5}(?:[ \u00A0]\d{1,5}){0,2}[ \u00A0]\d{3,5}${NUMBER_EDGE_AFTER}(?![ \u00A0]\d{3})`,
|
|
30
|
+
"gu",
|
|
31
|
+
);
|
|
32
|
+
/** Spaced digits are a phone number only with a country code, or right after their label: dates, amounts and ids are spaced too. */
|
|
33
|
+
const COUNTRY_CODE_START = /^\+/u;
|
|
34
|
+
const LABEL_TO_NUMBER = /^(?:[\s::..]|\uFE0F)*$/u;
|
|
23
35
|
const NOT_DIGIT = /\D/gu;
|
|
24
36
|
const LATIN_START = /^[A-Za-z]/u;
|
|
25
|
-
|
|
37
|
+
/** A Latin label is a whole word among Latin letters only: 「FAX受付」 has no spaces between words. */
|
|
38
|
+
const LETTER = /\p{Script=Latin}/u;
|
|
26
39
|
/** How far before a number its label may end: 「電話でのお問合せは、」, "by phone, call". */
|
|
27
40
|
const MAX_LABEL_GAP = 15;
|
|
28
41
|
const URL = /\b(?:https?:\/\/|www\.)\S+/giu;
|
|
@@ -35,35 +48,72 @@ const lastPlace = (before: string, label: string): number => {
|
|
|
35
48
|
return whole.at(-1) ?? -1;
|
|
36
49
|
};
|
|
37
50
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
51
|
+
type LabelBefore = { readonly group: string; readonly between: string };
|
|
52
|
+
type LabelHit = { readonly group: string; readonly at: number; readonly end: number };
|
|
53
|
+
|
|
54
|
+
/** The label ending nearest the end of a line's text, the longest when two end together (携帯電話 over 電話). */
|
|
55
|
+
const nearestLabel = (before: string, labels: readonly LexiconEntry[]): LabelHit | undefined =>
|
|
56
|
+
labels
|
|
43
57
|
.map((entry) => {
|
|
44
58
|
const at = lastPlace(before, entry.pattern);
|
|
45
59
|
return { group: entry.group ?? entry.pattern, at, end: at + entry.pattern.length };
|
|
46
60
|
})
|
|
47
61
|
.filter((hit) => hit.at >= 0 && before.length - hit.end <= MAX_LABEL_GAP)
|
|
48
62
|
.toSorted((a, b) => b.end - a.end || a.at - b.at)[0];
|
|
49
|
-
|
|
63
|
+
|
|
64
|
+
/** A desk's name (窓口, Recall Line) says where a number goes, not what it is: FAX受付窓口 and Fax line name fax numbers. */
|
|
65
|
+
const DESK_GROUP = "desk";
|
|
66
|
+
const DESK_DEFAULT_GROUP = "phone";
|
|
67
|
+
const DIGIT = /\d/u;
|
|
68
|
+
|
|
69
|
+
/** The kind a label right before a desk's name gives its number, with no digits between; a phone number when there is none. */
|
|
70
|
+
const deskKind = (before: string, desk: LabelHit, labels: readonly LexiconEntry[]): string => {
|
|
71
|
+
const kinds = labels.filter((entry) => entry.group !== DESK_GROUP);
|
|
72
|
+
const kind = nearestLabel(before.slice(0, desk.at), kinds);
|
|
73
|
+
return kind === undefined || DIGIT.test(before.slice(kind.end, desk.at)) ? DESK_DEFAULT_GROUP : kind.group;
|
|
50
74
|
};
|
|
51
75
|
|
|
76
|
+
/** The label ending nearest before a number on its line, the kind of number it gives, and what lies between. */
|
|
77
|
+
export const labelBefore = (text: string, offset: number, labels: readonly LexiconEntry[]): LabelBefore | undefined => {
|
|
78
|
+
const lineStart = text.lastIndexOf("\n", offset - 1) + 1;
|
|
79
|
+
const before = text.slice(lineStart, offset).toLowerCase();
|
|
80
|
+
const nearest = nearestLabel(before, labels);
|
|
81
|
+
if (nearest === undefined) return undefined;
|
|
82
|
+
const between = before.slice(nearest.end);
|
|
83
|
+
if (nearest.group !== DESK_GROUP) return { group: nearest.group, between };
|
|
84
|
+
return ANY_LETTER.test(between) ? undefined : { group: deskKind(before, nearest, labels), between };
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
/** A word between a desk's name and the digits says they are something else: Support ticket, 窓口受付番号. */
|
|
88
|
+
const ANY_LETTER = /\p{L}/u;
|
|
89
|
+
const UNCLOSED_OPENING = /^[((](?!.*[))])/u;
|
|
90
|
+
|
|
91
|
+
/** A number as quoted: the bracket the number is put in (窓口(0120-123-456)) is not part of it, an area code's is ((555) 123-4567). */
|
|
92
|
+
const withoutUnclosedBracket = (written: string): string => written.replace(UNCLOSED_OPENING, "");
|
|
93
|
+
|
|
52
94
|
/** URLs covered with spaces, so neither a path segment (/call/) nor an id in one is read. Offsets stay the same. */
|
|
53
|
-
const withoutUrls = (text: string): string => text.replaceAll(URL, (url) => " ".repeat(url.length));
|
|
95
|
+
export const withoutUrls = (text: string): string => text.replaceAll(URL, (url) => " ".repeat(url.length));
|
|
54
96
|
|
|
55
97
|
/** The phone numbers of a text that have a label shortly before them on their line; unlabelled digits and URLs are not read. */
|
|
56
98
|
export const labelledPhoneNumbers = (source: string, labels: readonly LexiconEntry[]): PhoneNumber[] => {
|
|
57
99
|
const text = withoutUrls(source);
|
|
58
|
-
|
|
100
|
+
const read = (match: RegExpExecArray, spaced: boolean): PhoneNumber[] => {
|
|
59
101
|
const digits = match[0].replaceAll(NOT_DIGIT, "");
|
|
60
102
|
if (digits.length < MIN_DIGITS || digits.length > MAX_DIGITS) return [];
|
|
61
103
|
const label = labelBefore(text, match.index, labels);
|
|
62
|
-
|
|
63
|
-
|
|
104
|
+
if (label === undefined) return [];
|
|
105
|
+
if (spaced && !COUNTRY_CODE_START.test(match[0]) && !LABEL_TO_NUMBER.test(label.between)) return [];
|
|
106
|
+
const matched = match[0].trim();
|
|
107
|
+
const written = withoutUnclosedBracket(matched);
|
|
108
|
+
return [{ offset: match.index + matched.length - written.length, written, digits, label: label.group }];
|
|
109
|
+
};
|
|
110
|
+
return [
|
|
111
|
+
...[...text.matchAll(NUMBER_SHAPE)].flatMap((match) => read(match, false)),
|
|
112
|
+
...[...text.matchAll(SPACED_SHAPE)].flatMap((match) => read(match, true)),
|
|
113
|
+
].toSorted((a, b) => a.offset - b.offset);
|
|
64
114
|
};
|
|
65
115
|
|
|
66
|
-
/** Whether two
|
|
116
|
+
/** Whether two strings (digits, or a reference number's letters and digits) are the same but for one pair of neighbours swapped. */
|
|
67
117
|
export const swapsNeighbours = (a: string, b: string): boolean => {
|
|
68
118
|
if (a.length !== b.length || a === b) return false;
|
|
69
119
|
const differ = [...a].flatMap((digit, index) => (digit === b[index] ? [] : [index]));
|
|
@@ -71,24 +121,27 @@ export const swapsNeighbours = (a: string, b: string): boolean => {
|
|
|
71
121
|
return differ.length === 2 && first !== undefined && second === first + 1 && a[first] === b[second] && a[second] === b[first];
|
|
72
122
|
};
|
|
73
123
|
|
|
74
|
-
|
|
124
|
+
/** A labelled writing compared with the others of its label: where it is and the label's group. */
|
|
125
|
+
type LabelledWriting = { readonly offset: number; readonly label: string };
|
|
75
126
|
|
|
76
127
|
/**
|
|
77
|
-
* Every writing
|
|
78
|
-
* written fewer times, or the one first written later when both are written as often. Each
|
|
128
|
+
* Every writing that is another writing of the same label with two neighbouring characters swapped (characters is what is
|
|
129
|
+
* compared): of the two, the one written fewer times, or the one first written later when both are written as often. Each
|
|
130
|
+
* comes with the other writing.
|
|
79
131
|
*/
|
|
80
|
-
export const
|
|
81
|
-
const
|
|
82
|
-
const
|
|
132
|
+
export const swappedVariants = <T extends LabelledWriting>(writtenAll: readonly T[], characters: (writing: T) => string): { number: T; other: T }[] => {
|
|
133
|
+
const keyOf = (writing: T): string => `${writing.label}\u0000${characters(writing)}`;
|
|
134
|
+
const writings = writtenAll.reduce((byKey, writing) => byKey.set(keyOf(writing), [...(byKey.get(keyOf(writing)) ?? []), writing]), new Map<string, T[]>());
|
|
135
|
+
const timesOf = (writing: T): number => writings.get(keyOf(writing))?.length ?? 0;
|
|
83
136
|
const firsts = [...writings.values()].flatMap((group) => group.slice(0, 1));
|
|
84
|
-
const minorityOf = (a:
|
|
137
|
+
const minorityOf = (a: T, b: T): T => {
|
|
85
138
|
if (timesOf(a) !== timesOf(b)) return timesOf(a) < timesOf(b) ? a : b;
|
|
86
139
|
return a.offset > b.offset ? a : b;
|
|
87
140
|
};
|
|
88
141
|
return firsts
|
|
89
142
|
.flatMap((first, index) =>
|
|
90
143
|
firsts.slice(index + 1).flatMap((second) => {
|
|
91
|
-
if (first.label !== second.label || !swapsNeighbours(first
|
|
144
|
+
if (first.label !== second.label || !swapsNeighbours(characters(first), characters(second))) return [];
|
|
92
145
|
const minority = minorityOf(first, second);
|
|
93
146
|
const other = minority === first ? second : first;
|
|
94
147
|
return (writings.get(keyOf(minority)) ?? []).map((number) => ({ number, other }));
|
|
@@ -96,3 +149,6 @@ export const phoneVariants = (numbers: readonly PhoneNumber[]): PhoneVariant[] =
|
|
|
96
149
|
)
|
|
97
150
|
.toSorted((a, b) => a.number.offset - b.number.offset);
|
|
98
151
|
};
|
|
152
|
+
|
|
153
|
+
/** Every phone number that is another of the same label with two neighbouring digits swapped (swappedVariants). */
|
|
154
|
+
export const phoneVariants = (numbers: readonly PhoneNumber[]): PhoneVariant[] => swappedVariants(numbers, (number) => number.digits);
|