@mailwoman/corpus 9.2.0 → 9.3.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.md +22 -22
- package/data/PROVENANCE.md +7 -7
- package/lib/adapters/ban/adapter.ts +190 -0
- package/lib/adapters/ban/street-decompose.ts +66 -0
- package/lib/adapters/fcc-bdc/adapter.ts +174 -0
- package/lib/adapters/geonames/adapter.ts +199 -0
- package/lib/adapters/geonames-postal/adapter.ts +122 -0
- package/lib/adapters/gnaf/adapter.ts +149 -0
- package/lib/adapters/gnaf/assemble.ts +225 -0
- package/lib/adapters/index.ts +153 -0
- package/lib/adapters/openaddresses/adapter.ts +251 -0
- package/lib/adapters/overture/adapter.ts +162 -0
- package/lib/adapters/state-hi-schools/adapter.ts +170 -0
- package/lib/adapters/state-hi-schools/workbook.ts +35 -0
- package/lib/adapters/synth-po-box/adapter.ts +204 -0
- package/lib/adapters/tiger/adapter.ts +252 -0
- package/lib/adapters/tiger/street-decompose.ts +83 -0
- package/lib/adapters/usgov-hrsa-fqhc/adapter.ts +167 -0
- package/lib/adapters/usgov-imls-pls/adapter.ts +143 -0
- package/lib/adapters/usgov-irs-bmf/adapter.ts +151 -0
- package/lib/adapters/usgov-nad/adapter.ts +334 -0
- package/lib/adapters/usgov-nppes/adapter.ts +151 -0
- package/lib/adapters/usgov-samhsa-treatment-locator/adapter.ts +193 -0
- package/lib/adapters/utils/index.ts +307 -0
- package/lib/adapters/wof-admin-jp/adapter.ts +214 -0
- package/lib/adapters/wof-admin-json/adapter.ts +231 -0
- package/lib/adapters/wof-json-rows.ts +129 -0
- package/lib/adapters/wof-postalcode-json/adapter.ts +176 -0
- package/lib/build.ts +378 -0
- package/lib/env.ts +50 -0
- package/lib/index.ts +13 -0
- package/lib/name-prone-us-suffixes.ts +12 -0
- package/lib/recipes/anchor-absorption.ts +101 -0
- package/lib/recipes/bare-country.ts +95 -0
- package/lib/recipes/boundary-stress.ts +100 -0
- package/lib/recipes/cn-organizational-units.ts +199 -0
- package/lib/recipes/country-balanced.ts +509 -0
- package/lib/recipes/cz-pcfirst-preposition.ts +111 -0
- package/lib/recipes/fr-admin-split.ts +242 -0
- package/lib/recipes/fr-bare-street.ts +170 -0
- package/lib/recipes/fr-fragment.ts +333 -0
- package/lib/recipes/fr-lieudit.ts +301 -0
- package/lib/recipes/fr-order.ts +245 -0
- package/lib/recipes/german.ts +359 -0
- package/lib/recipes/house-venue.ts +92 -0
- package/lib/recipes/index.ts +97 -0
- package/lib/recipes/intersection.ts +618 -0
- package/lib/recipes/locale.ts +599 -0
- package/lib/recipes/nl-postcode.ts +115 -0
- package/lib/recipes/no-fragment.ts +219 -0
- package/lib/recipes/no-street-led.ts +141 -0
- package/lib/recipes/no-street.ts +90 -0
- package/lib/recipes/po-box-cedex.ts +976 -0
- package/lib/recipes/po-box.ts +123 -0
- package/lib/recipes/reviewed-postcode-tail.ts +190 -0
- package/lib/recipes/scaffold.ts +469 -0
- package/lib/recipes/si-bare-village.ts +97 -0
- package/lib/recipes/street-affix.ts +804 -0
- package/lib/recipes/street-bare.ts +100 -0
- package/lib/recipes/street.ts +81 -0
- package/lib/recipes/sub-venue-sources.ts +877 -0
- package/lib/recipes/sub-venue.ts +997 -0
- package/lib/recipes/trailing-region.ts +183 -0
- package/lib/recipes/unit.ts +304 -0
- package/lib/runner.ts +312 -0
- package/lib/synthesizers/anchor-absorption.ts +288 -0
- package/lib/synthesizers/boundary-stress.ts +532 -0
- package/lib/synthesizers/german.ts +260 -0
- package/lib/synthesizers/house-venue.ts +308 -0
- package/lib/synthesizers/intersection.ts +233 -0
- package/lib/synthesizers/no-street.ts +327 -0
- package/lib/synthesizers/po-box.ts +323 -0
- package/lib/synthesizers/street.ts +269 -0
- package/lib/synthesizers/utils.ts +993 -0
- package/lib/test-kit/corpus-recipe.ts +86 -0
- package/lib/test-kit/index.ts +100 -0
- package/lib/tools/align-slice.ts +68 -0
- package/lib/tools/audit.ts +403 -0
- package/lib/tools/corpus-stats.ts +136 -0
- package/lib/tools/fetch/ban.ts +289 -0
- package/lib/tools/fetch/download.ts +262 -0
- package/lib/tools/fetch/geonames-dump.ts +257 -0
- package/lib/tools/fetch/geonames-postal.ts +180 -0
- package/lib/tools/fetch/hrsa.ts +59 -0
- package/lib/tools/fetch/imls-pls.ts +149 -0
- package/lib/tools/fetch/index.ts +147 -0
- package/lib/tools/fetch/nad.ts +341 -0
- package/lib/tools/fetch/nppes.ts +165 -0
- package/lib/tools/fetch/openaddresses.ts +347 -0
- package/lib/tools/fetch/ourairports.ts +170 -0
- package/lib/tools/fetch/ppd.ts +121 -0
- package/lib/tools/fetch/state-hi-schools.ts +161 -0
- package/lib/tools/fetch/state-sources.ts +146 -0
- package/lib/tools/fetch/tiger-full.ts +308 -0
- package/lib/tools/fetch/wikidata-subvenue.ts +384 -0
- package/lib/tools/golden-expand.ts +574 -0
- package/lib/tools/golden-promote.ts +337 -0
- package/lib/tools/golden-relabel-street.ts +683 -0
- package/lib/tools/index.ts +28 -0
- package/lib/tools/ingest-csv.ts +378 -0
- package/lib/tools/jsonl-to-parquet.ts +207 -0
- package/lib/tools/lint-slice-vocab.ts +388 -0
- package/lib/tools/lint-slice.ts +496 -0
- package/lib/tools/overlay-manifest.ts +148 -0
- package/lib/tools/overture-subvenue.ts +209 -0
- package/lib/tools/postcode-triples.ts +363 -0
- package/lib/tools/slice-kryptonite.ts +137 -0
- package/lib/tools/slice-translit.ts +218 -0
- package/lib/tools/sub-venue/harvest.ts +234 -0
- package/lib/tools/sub-venue/head-nouns.ts +245 -0
- package/lib/tools/sub-venue/surfaces.ts +95 -0
- package/lib/tools/sub-venue/table.ts +281 -0
- package/lib/tools/sub-venue/wikidata.ts +85 -0
- package/lib/tools/sub-venue-lexicon.ts +429 -0
- package/lib/tools/sub-venue-promotions.ts +330 -0
- package/lib/types.ts +247 -0
- package/lib/utils/align.ts +330 -0
- package/lib/utils/golden.ts +189 -0
- package/lib/utils/index.ts +14 -0
- package/lib/utils/parquet.ts +582 -0
- package/lib/utils/slice-stats.ts +95 -0
- package/lib/utils/split.ts +279 -0
- package/lib/utils/tokenize.ts +120 -0
- package/lib/utils/wof-json.ts +247 -0
- package/out/adapters/ban/adapter.d.ts.map +1 -0
- package/out/adapters/ban/adapter.js +149 -0
- package/out/adapters/ban/adapter.js.map +1 -0
- package/out/adapters/ban/street-decompose.d.ts.map +1 -0
- package/out/adapters/ban/street-decompose.js +51 -0
- package/out/adapters/ban/street-decompose.js.map +1 -0
- package/out/adapters/fcc-bdc/adapter.d.ts.map +1 -0
- package/out/adapters/fcc-bdc/adapter.js +144 -0
- package/out/adapters/fcc-bdc/adapter.js.map +1 -0
- package/out/adapters/geonames/adapter.d.ts.map +1 -0
- package/out/adapters/geonames/adapter.js +176 -0
- package/out/adapters/geonames/adapter.js.map +1 -0
- package/out/adapters/geonames-postal/adapter.d.ts +54 -0
- package/out/adapters/geonames-postal/adapter.d.ts.map +1 -0
- package/out/adapters/geonames-postal/adapter.js +107 -0
- package/out/adapters/geonames-postal/adapter.js.map +1 -0
- package/out/adapters/gnaf/adapter.d.ts +49 -0
- package/out/adapters/gnaf/adapter.d.ts.map +1 -0
- package/out/adapters/gnaf/adapter.js +124 -0
- package/out/adapters/gnaf/adapter.js.map +1 -0
- package/out/adapters/gnaf/assemble.d.ts +65 -0
- package/out/adapters/gnaf/assemble.d.ts.map +1 -0
- package/out/adapters/gnaf/assemble.js +154 -0
- package/out/adapters/gnaf/assemble.js.map +1 -0
- package/out/adapters/index.d.ts +51 -0
- package/out/adapters/index.d.ts.map +1 -0
- package/out/adapters/index.js +95 -0
- package/out/adapters/index.js.map +1 -0
- package/out/adapters/openaddresses/adapter.d.ts.map +1 -0
- package/out/adapters/openaddresses/adapter.js +186 -0
- package/out/adapters/openaddresses/adapter.js.map +1 -0
- package/out/adapters/overture/adapter.d.ts +48 -0
- package/out/adapters/overture/adapter.d.ts.map +1 -0
- package/out/adapters/overture/adapter.js +125 -0
- package/out/adapters/overture/adapter.js.map +1 -0
- package/out/adapters/state-hi-schools/adapter.d.ts +46 -0
- package/out/adapters/state-hi-schools/adapter.d.ts.map +1 -0
- package/out/adapters/state-hi-schools/adapter.js +145 -0
- package/out/adapters/state-hi-schools/adapter.js.map +1 -0
- package/out/adapters/state-hi-schools/workbook.d.ts +29 -0
- package/out/adapters/state-hi-schools/workbook.d.ts.map +1 -0
- package/out/adapters/state-hi-schools/workbook.js +20 -0
- package/out/adapters/state-hi-schools/workbook.js.map +1 -0
- package/out/adapters/state-ia-contractors/adapter.d.ts.map +1 -0
- package/out/adapters/state-ia-contractors/adapter.js.map +1 -0
- package/out/adapters/state-ny-notaries/adapter.d.ts.map +1 -0
- package/out/adapters/state-ny-notaries/adapter.js.map +1 -0
- package/out/adapters/state-tx-notaries/adapter.d.ts.map +1 -0
- package/out/adapters/state-tx-notaries/adapter.js.map +1 -0
- package/out/adapters/synth-po-box/adapter.d.ts.map +1 -0
- package/out/adapters/synth-po-box/adapter.js +140 -0
- package/out/adapters/synth-po-box/adapter.js.map +1 -0
- package/out/adapters/tiger/adapter.d.ts +55 -0
- package/out/adapters/tiger/adapter.d.ts.map +1 -0
- package/out/adapters/tiger/adapter.js +201 -0
- package/out/adapters/tiger/adapter.js.map +1 -0
- package/out/adapters/tiger/street-decompose.d.ts.map +1 -0
- package/out/adapters/tiger/street-decompose.js +68 -0
- package/out/adapters/tiger/street-decompose.js.map +1 -0
- package/out/adapters/usgov-hrsa-fqhc/adapter.d.ts +56 -0
- package/out/adapters/usgov-hrsa-fqhc/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-hrsa-fqhc/adapter.js +132 -0
- package/out/adapters/usgov-hrsa-fqhc/adapter.js.map +1 -0
- package/out/adapters/usgov-imls-pls/adapter.d.ts +36 -0
- package/out/adapters/usgov-imls-pls/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-imls-pls/adapter.js +114 -0
- package/out/adapters/usgov-imls-pls/adapter.js.map +1 -0
- package/out/adapters/usgov-irs-bmf/adapter.d.ts +37 -0
- package/out/adapters/usgov-irs-bmf/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-irs-bmf/adapter.js +120 -0
- package/out/adapters/usgov-irs-bmf/adapter.js.map +1 -0
- package/out/adapters/usgov-nad/adapter.d.ts +48 -0
- package/out/adapters/usgov-nad/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-nad/adapter.js +249 -0
- package/out/adapters/usgov-nad/adapter.js.map +1 -0
- package/out/adapters/usgov-nppes/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-nppes/adapter.js +118 -0
- package/out/adapters/usgov-nppes/adapter.js.map +1 -0
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.d.ts.map +1 -0
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.js +154 -0
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.js.map +1 -0
- package/out/adapters/utils/index.d.ts +191 -0
- package/out/adapters/utils/index.d.ts.map +1 -0
- package/out/adapters/utils/index.js +206 -0
- package/out/adapters/utils/index.js.map +1 -0
- package/out/adapters/wof-admin-jp/adapter.d.ts.map +1 -0
- package/out/adapters/wof-admin-jp/adapter.js +161 -0
- package/out/adapters/wof-admin-jp/adapter.js.map +1 -0
- package/out/adapters/wof-admin-json/adapter.d.ts +79 -0
- package/out/adapters/wof-admin-json/adapter.d.ts.map +1 -0
- package/out/adapters/wof-admin-json/adapter.js +197 -0
- package/out/adapters/wof-admin-json/adapter.js.map +1 -0
- package/out/adapters/wof-json-rows.d.ts +62 -0
- package/out/adapters/wof-json-rows.d.ts.map +1 -0
- package/out/adapters/wof-json-rows.js +83 -0
- package/out/adapters/wof-json-rows.js.map +1 -0
- package/out/adapters/wof-postalcode-json/adapter.d.ts +65 -0
- package/out/adapters/wof-postalcode-json/adapter.d.ts.map +1 -0
- package/out/adapters/wof-postalcode-json/adapter.js +151 -0
- package/out/adapters/wof-postalcode-json/adapter.js.map +1 -0
- package/out/build.d.ts +132 -0
- package/out/build.d.ts.map +1 -0
- package/out/build.js +245 -0
- package/out/build.js.map +1 -0
- package/out/codex/us-fips-state.d.ts.map +1 -0
- package/out/codex/us-fips-state.js.map +1 -0
- package/out/env.d.ts +46 -0
- package/out/env.d.ts.map +1 -0
- package/out/env.js +46 -0
- package/out/env.js.map +1 -0
- package/out/index.d.ts +13 -0
- package/out/index.d.ts.map +1 -0
- package/out/index.js +13 -0
- package/out/index.js.map +1 -0
- package/out/name-prone-us-suffixes.d.ts +12 -0
- package/out/name-prone-us-suffixes.d.ts.map +1 -0
- package/out/name-prone-us-suffixes.js +12 -0
- package/out/name-prone-us-suffixes.js.map +1 -0
- package/out/recipes/anchor-absorption.d.ts +20 -0
- package/out/recipes/anchor-absorption.d.ts.map +1 -0
- package/out/recipes/anchor-absorption.js +81 -0
- package/out/recipes/anchor-absorption.js.map +1 -0
- package/out/recipes/bare-country.d.ts +25 -0
- package/out/recipes/bare-country.d.ts.map +1 -0
- package/out/recipes/bare-country.js +87 -0
- package/out/recipes/bare-country.js.map +1 -0
- package/out/recipes/boundary-stress.d.ts +20 -0
- package/out/recipes/boundary-stress.d.ts.map +1 -0
- package/out/recipes/boundary-stress.js +83 -0
- package/out/recipes/boundary-stress.js.map +1 -0
- package/out/recipes/cn-organizational-units.d.ts +36 -0
- package/out/recipes/cn-organizational-units.d.ts.map +1 -0
- package/out/recipes/cn-organizational-units.js +159 -0
- package/out/recipes/cn-organizational-units.js.map +1 -0
- package/out/recipes/country-balanced.d.ts +32 -0
- package/out/recipes/country-balanced.d.ts.map +1 -0
- package/out/recipes/country-balanced.js +393 -0
- package/out/recipes/country-balanced.js.map +1 -0
- package/out/recipes/cz-pcfirst-preposition.d.ts +22 -0
- package/out/recipes/cz-pcfirst-preposition.d.ts.map +1 -0
- package/out/recipes/cz-pcfirst-preposition.js +100 -0
- package/out/recipes/cz-pcfirst-preposition.js.map +1 -0
- package/out/recipes/fr-admin-split.d.ts +38 -0
- package/out/recipes/fr-admin-split.d.ts.map +1 -0
- package/out/recipes/fr-admin-split.js +192 -0
- package/out/recipes/fr-admin-split.js.map +1 -0
- package/out/recipes/fr-bare-street.d.ts +28 -0
- package/out/recipes/fr-bare-street.d.ts.map +1 -0
- package/out/recipes/fr-bare-street.js +143 -0
- package/out/recipes/fr-bare-street.js.map +1 -0
- package/out/recipes/fr-fragment.d.ts +77 -0
- package/out/recipes/fr-fragment.d.ts.map +1 -0
- package/out/recipes/fr-fragment.js +276 -0
- package/out/recipes/fr-fragment.js.map +1 -0
- package/out/recipes/fr-lieudit.d.ts +32 -0
- package/out/recipes/fr-lieudit.d.ts.map +1 -0
- package/out/recipes/fr-lieudit.js +227 -0
- package/out/recipes/fr-lieudit.js.map +1 -0
- package/out/recipes/fr-order.d.ts +38 -0
- package/out/recipes/fr-order.d.ts.map +1 -0
- package/out/recipes/fr-order.js +197 -0
- package/out/recipes/fr-order.js.map +1 -0
- package/out/recipes/german.d.ts +44 -0
- package/out/recipes/german.d.ts.map +1 -0
- package/out/recipes/german.js +288 -0
- package/out/recipes/german.js.map +1 -0
- package/out/recipes/house-venue.d.ts +18 -0
- package/out/recipes/house-venue.d.ts.map +1 -0
- package/out/recipes/house-venue.js +73 -0
- package/out/recipes/house-venue.js.map +1 -0
- package/out/recipes/index.d.ts +24 -0
- package/out/recipes/index.d.ts.map +1 -0
- package/out/recipes/index.js +91 -0
- package/out/recipes/index.js.map +1 -0
- package/out/recipes/intersection.d.ts +42 -0
- package/out/recipes/intersection.d.ts.map +1 -0
- package/out/recipes/intersection.js +452 -0
- package/out/recipes/intersection.js.map +1 -0
- package/out/recipes/locale.d.ts +136 -0
- package/out/recipes/locale.d.ts.map +1 -0
- package/out/recipes/locale.js +460 -0
- package/out/recipes/locale.js.map +1 -0
- package/out/recipes/nl-postcode.d.ts +26 -0
- package/out/recipes/nl-postcode.d.ts.map +1 -0
- package/out/recipes/nl-postcode.js +102 -0
- package/out/recipes/nl-postcode.js.map +1 -0
- package/out/recipes/no-fragment.d.ts +43 -0
- package/out/recipes/no-fragment.d.ts.map +1 -0
- package/out/recipes/no-fragment.js +182 -0
- package/out/recipes/no-fragment.js.map +1 -0
- package/out/recipes/no-street-led.d.ts +24 -0
- package/out/recipes/no-street-led.d.ts.map +1 -0
- package/out/recipes/no-street-led.js +113 -0
- package/out/recipes/no-street-led.js.map +1 -0
- package/out/recipes/no-street.d.ts +18 -0
- package/out/recipes/no-street.d.ts.map +1 -0
- package/out/recipes/no-street.js +71 -0
- package/out/recipes/no-street.js.map +1 -0
- package/out/recipes/po-box-cedex.d.ts +38 -0
- package/out/recipes/po-box-cedex.d.ts.map +1 -0
- package/out/recipes/po-box-cedex.js +767 -0
- package/out/recipes/po-box-cedex.js.map +1 -0
- package/out/recipes/po-box.d.ts +17 -0
- package/out/recipes/po-box.d.ts.map +1 -0
- package/out/recipes/po-box.js +100 -0
- package/out/recipes/po-box.js.map +1 -0
- package/out/recipes/reviewed-postcode-tail.d.ts +47 -0
- package/out/recipes/reviewed-postcode-tail.d.ts.map +1 -0
- package/out/recipes/reviewed-postcode-tail.js +125 -0
- package/out/recipes/reviewed-postcode-tail.js.map +1 -0
- package/out/recipes/scaffold.d.ts +324 -0
- package/out/recipes/scaffold.d.ts.map +1 -0
- package/out/recipes/scaffold.js +186 -0
- package/out/recipes/scaffold.js.map +1 -0
- package/out/recipes/si-bare-village.d.ts +32 -0
- package/out/recipes/si-bare-village.d.ts.map +1 -0
- package/out/recipes/si-bare-village.js +88 -0
- package/out/recipes/si-bare-village.js.map +1 -0
- package/out/recipes/street-affix.d.ts +89 -0
- package/out/recipes/street-affix.d.ts.map +1 -0
- package/out/recipes/street-affix.js +563 -0
- package/out/recipes/street-affix.js.map +1 -0
- package/out/recipes/street-bare.d.ts +25 -0
- package/out/recipes/street-bare.d.ts.map +1 -0
- package/out/recipes/street-bare.js +86 -0
- package/out/recipes/street-bare.js.map +1 -0
- package/out/recipes/street.d.ts +15 -0
- package/out/recipes/street.d.ts.map +1 -0
- package/out/recipes/street.js +69 -0
- package/out/recipes/street.js.map +1 -0
- package/out/recipes/sub-venue-sources.d.ts +229 -0
- package/out/recipes/sub-venue-sources.d.ts.map +1 -0
- package/out/recipes/sub-venue-sources.js +653 -0
- package/out/recipes/sub-venue-sources.js.map +1 -0
- package/out/recipes/sub-venue.d.ts +269 -0
- package/out/recipes/sub-venue.d.ts.map +1 -0
- package/out/recipes/sub-venue.js +725 -0
- package/out/recipes/sub-venue.js.map +1 -0
- package/out/recipes/trailing-region.d.ts +74 -0
- package/out/recipes/trailing-region.d.ts.map +1 -0
- package/out/recipes/trailing-region.js +157 -0
- package/out/recipes/trailing-region.js.map +1 -0
- package/out/recipes/unit.d.ts +29 -0
- package/out/recipes/unit.d.ts.map +1 -0
- package/out/recipes/unit.js +230 -0
- package/out/recipes/unit.js.map +1 -0
- package/out/runner.d.ts +130 -0
- package/out/runner.d.ts.map +1 -0
- package/out/runner.js +185 -0
- package/out/runner.js.map +1 -0
- package/out/synthesizers/anchor-absorption.d.ts +63 -0
- package/out/synthesizers/anchor-absorption.d.ts.map +1 -0
- package/out/synthesizers/anchor-absorption.js +221 -0
- package/out/synthesizers/anchor-absorption.js.map +1 -0
- package/out/synthesizers/boundary-stress.d.ts +78 -0
- package/out/synthesizers/boundary-stress.d.ts.map +1 -0
- package/out/synthesizers/boundary-stress.js +455 -0
- package/out/synthesizers/boundary-stress.js.map +1 -0
- package/out/synthesizers/german.d.ts +115 -0
- package/out/synthesizers/german.d.ts.map +1 -0
- package/out/synthesizers/german.js +149 -0
- package/out/synthesizers/german.js.map +1 -0
- package/out/synthesizers/house-venue.d.ts +56 -0
- package/out/synthesizers/house-venue.d.ts.map +1 -0
- package/out/synthesizers/house-venue.js +247 -0
- package/out/synthesizers/house-venue.js.map +1 -0
- package/out/synthesizers/intersection.d.ts +52 -0
- package/out/synthesizers/intersection.d.ts.map +1 -0
- package/out/synthesizers/intersection.js +175 -0
- package/out/synthesizers/intersection.js.map +1 -0
- package/out/synthesizers/no-street.d.ts +72 -0
- package/out/synthesizers/no-street.d.ts.map +1 -0
- package/out/synthesizers/no-street.js +262 -0
- package/out/synthesizers/no-street.js.map +1 -0
- package/out/synthesizers/po-box.d.ts +108 -0
- package/out/synthesizers/po-box.d.ts.map +1 -0
- package/out/synthesizers/po-box.js +250 -0
- package/out/synthesizers/po-box.js.map +1 -0
- package/out/synthesizers/street.d.ts +54 -0
- package/out/synthesizers/street.d.ts.map +1 -0
- package/out/synthesizers/street.js +218 -0
- package/out/synthesizers/street.js.map +1 -0
- package/out/synthesizers/utils.d.ts +241 -0
- package/out/synthesizers/utils.d.ts.map +1 -0
- package/out/synthesizers/utils.js +776 -0
- package/out/synthesizers/utils.js.map +1 -0
- package/out/test-kit/corpus-recipe.d.ts +59 -0
- package/out/test-kit/corpus-recipe.d.ts.map +1 -0
- package/out/test-kit/corpus-recipe.js +39 -0
- package/out/test-kit/corpus-recipe.js.map +1 -0
- package/out/test-kit/index.d.ts +48 -0
- package/out/test-kit/index.d.ts.map +1 -0
- package/out/test-kit/index.js +78 -0
- package/out/test-kit/index.js.map +1 -0
- package/out/tools/align-slice.d.ts +7 -0
- package/out/tools/align-slice.d.ts.map +1 -0
- package/out/tools/align-slice.js +55 -0
- package/out/tools/align-slice.js.map +1 -0
- package/out/tools/audit.d.ts +29 -0
- package/out/tools/audit.d.ts.map +1 -0
- package/out/tools/audit.js +282 -0
- package/out/tools/audit.js.map +1 -0
- package/out/tools/corpus-stats.d.ts +44 -0
- package/out/tools/corpus-stats.d.ts.map +1 -0
- package/out/tools/corpus-stats.js +102 -0
- package/out/tools/corpus-stats.js.map +1 -0
- package/out/tools/fetch/ban.d.ts +31 -0
- package/out/tools/fetch/ban.d.ts.map +1 -0
- package/out/tools/fetch/ban.js +239 -0
- package/out/tools/fetch/ban.js.map +1 -0
- package/out/tools/fetch/download.d.ts +117 -0
- package/out/tools/fetch/download.d.ts.map +1 -0
- package/out/tools/fetch/download.js +160 -0
- package/out/tools/fetch/download.js.map +1 -0
- package/out/tools/fetch/geonames-dump.d.ts +91 -0
- package/out/tools/fetch/geonames-dump.d.ts.map +1 -0
- package/out/tools/fetch/geonames-dump.js +171 -0
- package/out/tools/fetch/geonames-dump.js.map +1 -0
- package/out/tools/fetch/geonames-postal.d.ts +76 -0
- package/out/tools/fetch/geonames-postal.d.ts.map +1 -0
- package/out/tools/fetch/geonames-postal.js +126 -0
- package/out/tools/fetch/geonames-postal.js.map +1 -0
- package/out/tools/fetch/hrsa.d.ts +18 -0
- package/out/tools/fetch/hrsa.d.ts.map +1 -0
- package/out/tools/fetch/hrsa.js +46 -0
- package/out/tools/fetch/hrsa.js.map +1 -0
- package/out/tools/fetch/imls-pls.d.ts +25 -0
- package/out/tools/fetch/imls-pls.d.ts.map +1 -0
- package/out/tools/fetch/imls-pls.js +108 -0
- package/out/tools/fetch/imls-pls.js.map +1 -0
- package/out/tools/fetch/index.d.ts +144 -0
- package/out/tools/fetch/index.d.ts.map +1 -0
- package/out/tools/fetch/index.js +143 -0
- package/out/tools/fetch/index.js.map +1 -0
- package/out/tools/fetch/nad.d.ts +70 -0
- package/out/tools/fetch/nad.d.ts.map +1 -0
- package/out/tools/fetch/nad.js +234 -0
- package/out/tools/fetch/nad.js.map +1 -0
- package/out/tools/fetch/nppes.d.ts +26 -0
- package/out/tools/fetch/nppes.d.ts.map +1 -0
- package/out/tools/fetch/nppes.js +126 -0
- package/out/tools/fetch/nppes.js.map +1 -0
- package/out/tools/fetch/openaddresses.d.ts +9 -0
- package/out/tools/fetch/openaddresses.d.ts.map +1 -0
- package/out/tools/fetch/openaddresses.js +279 -0
- package/out/tools/fetch/openaddresses.js.map +1 -0
- package/out/tools/fetch/ourairports.d.ts +45 -0
- package/out/tools/fetch/ourairports.d.ts.map +1 -0
- package/out/tools/fetch/ourairports.js +128 -0
- package/out/tools/fetch/ourairports.js.map +1 -0
- package/out/tools/fetch/ppd.d.ts.map +1 -0
- package/out/tools/fetch/ppd.js +85 -0
- package/out/tools/fetch/ppd.js.map +1 -0
- package/out/tools/fetch/state-hi-schools.d.ts +26 -0
- package/out/tools/fetch/state-hi-schools.d.ts.map +1 -0
- package/out/tools/fetch/state-hi-schools.js +112 -0
- package/out/tools/fetch/state-hi-schools.js.map +1 -0
- package/out/tools/fetch/state-sources.d.ts +26 -0
- package/out/tools/fetch/state-sources.d.ts.map +1 -0
- package/out/tools/fetch/state-sources.js +111 -0
- package/out/tools/fetch/state-sources.js.map +1 -0
- package/out/tools/fetch/tiger-full.d.ts +22 -0
- package/out/tools/fetch/tiger-full.d.ts.map +1 -0
- package/out/tools/fetch/tiger-full.js +217 -0
- package/out/tools/fetch/tiger-full.js.map +1 -0
- package/out/tools/fetch/wikidata-subvenue.d.ts +171 -0
- package/out/tools/fetch/wikidata-subvenue.d.ts.map +1 -0
- package/out/tools/fetch/wikidata-subvenue.js +274 -0
- package/out/tools/fetch/wikidata-subvenue.js.map +1 -0
- package/out/tools/gb-title-case.d.ts.map +1 -0
- package/out/tools/gb-title-case.js.map +1 -0
- package/out/tools/golden-expand.d.ts +90 -0
- package/out/tools/golden-expand.d.ts.map +1 -0
- package/out/tools/golden-expand.js +406 -0
- package/out/tools/golden-expand.js.map +1 -0
- package/out/tools/golden-promote.d.ts.map +1 -0
- package/out/tools/golden-promote.js +240 -0
- package/out/tools/golden-promote.js.map +1 -0
- package/out/tools/golden-relabel-street.d.ts +196 -0
- package/out/tools/golden-relabel-street.d.ts.map +1 -0
- package/out/tools/golden-relabel-street.js +440 -0
- package/out/tools/golden-relabel-street.js.map +1 -0
- package/out/tools/index.d.ts +28 -0
- package/out/tools/index.d.ts.map +1 -0
- package/out/tools/index.js +28 -0
- package/out/tools/index.js.map +1 -0
- package/out/tools/ingest-csv.d.ts.map +1 -0
- package/out/tools/ingest-csv.js +265 -0
- package/out/tools/ingest-csv.js.map +1 -0
- package/out/tools/jsonl-to-parquet.d.ts +61 -0
- package/out/tools/jsonl-to-parquet.d.ts.map +1 -0
- package/out/tools/jsonl-to-parquet.js +150 -0
- package/out/tools/jsonl-to-parquet.js.map +1 -0
- package/out/tools/lint-slice-vocab.d.ts +90 -0
- package/out/tools/lint-slice-vocab.d.ts.map +1 -0
- package/out/tools/lint-slice-vocab.js +267 -0
- package/out/tools/lint-slice-vocab.js.map +1 -0
- package/out/tools/lint-slice.d.ts +93 -0
- package/out/tools/lint-slice.d.ts.map +1 -0
- package/out/tools/lint-slice.js +322 -0
- package/out/tools/lint-slice.js.map +1 -0
- package/out/tools/overlay-manifest.d.ts +39 -0
- package/out/tools/overlay-manifest.d.ts.map +1 -0
- package/out/tools/overlay-manifest.js +90 -0
- package/out/tools/overlay-manifest.js.map +1 -0
- package/out/tools/overture-subvenue.d.ts +112 -0
- package/out/tools/overture-subvenue.d.ts.map +1 -0
- package/out/tools/overture-subvenue.js +139 -0
- package/out/tools/overture-subvenue.js.map +1 -0
- package/out/tools/postcode-triples.d.ts +174 -0
- package/out/tools/postcode-triples.d.ts.map +1 -0
- package/out/tools/postcode-triples.js +292 -0
- package/out/tools/postcode-triples.js.map +1 -0
- package/out/tools/slice-kryptonite.d.ts +32 -0
- package/out/tools/slice-kryptonite.d.ts.map +1 -0
- package/out/tools/slice-kryptonite.js +99 -0
- package/out/tools/slice-kryptonite.js.map +1 -0
- package/out/tools/slice-translit.d.ts +51 -0
- package/out/tools/slice-translit.d.ts.map +1 -0
- package/out/tools/slice-translit.js +166 -0
- package/out/tools/slice-translit.js.map +1 -0
- package/out/tools/sub-venue/harvest.d.ts +100 -0
- package/out/tools/sub-venue/harvest.d.ts.map +1 -0
- package/out/tools/sub-venue/harvest.js +168 -0
- package/out/tools/sub-venue/harvest.js.map +1 -0
- package/out/tools/sub-venue/head-nouns.d.ts +50 -0
- package/out/tools/sub-venue/head-nouns.d.ts.map +1 -0
- package/out/tools/sub-venue/head-nouns.js +213 -0
- package/out/tools/sub-venue/head-nouns.js.map +1 -0
- package/out/tools/sub-venue/surfaces.d.ts +45 -0
- package/out/tools/sub-venue/surfaces.d.ts.map +1 -0
- package/out/tools/sub-venue/surfaces.js +77 -0
- package/out/tools/sub-venue/surfaces.js.map +1 -0
- package/out/tools/sub-venue/table.d.ts +229 -0
- package/out/tools/sub-venue/table.d.ts.map +1 -0
- package/out/tools/sub-venue/table.js +108 -0
- package/out/tools/sub-venue/table.js.map +1 -0
- package/out/tools/sub-venue/wikidata.d.ts +26 -0
- package/out/tools/sub-venue/wikidata.d.ts.map +1 -0
- package/out/tools/sub-venue/wikidata.js +62 -0
- package/out/tools/sub-venue/wikidata.js.map +1 -0
- package/out/tools/sub-venue-lexicon.d.ts +156 -0
- package/out/tools/sub-venue-lexicon.d.ts.map +1 -0
- package/out/tools/sub-venue-lexicon.js +283 -0
- package/out/tools/sub-venue-lexicon.js.map +1 -0
- package/out/tools/sub-venue-promotions.d.ts +94 -0
- package/out/tools/sub-venue-promotions.d.ts.map +1 -0
- package/out/tools/sub-venue-promotions.js +266 -0
- package/out/tools/sub-venue-promotions.js.map +1 -0
- package/out/types.d.ts +221 -0
- package/out/types.d.ts.map +1 -0
- package/out/types.js.map +1 -0
- package/out/utils/align.d.ts +93 -0
- package/out/utils/align.d.ts.map +1 -0
- package/out/utils/align.js +234 -0
- package/out/utils/align.js.map +1 -0
- package/out/utils/golden.d.ts +85 -0
- package/out/utils/golden.d.ts.map +1 -0
- package/out/utils/golden.js +127 -0
- package/out/utils/golden.js.map +1 -0
- package/out/utils/index.d.ts +14 -0
- package/out/utils/index.d.ts.map +1 -0
- package/out/utils/index.js +14 -0
- package/out/utils/index.js.map +1 -0
- package/out/utils/license.d.ts.map +1 -0
- package/out/utils/license.js.map +1 -0
- package/out/utils/parquet.d.ts +178 -0
- package/out/utils/parquet.d.ts.map +1 -0
- package/out/utils/parquet.js +371 -0
- package/out/utils/parquet.js.map +1 -0
- package/out/utils/slice-stats.d.ts +52 -0
- package/out/utils/slice-stats.d.ts.map +1 -0
- package/out/utils/slice-stats.js +58 -0
- package/out/utils/slice-stats.js.map +1 -0
- package/out/utils/split.d.ts +128 -0
- package/out/utils/split.d.ts.map +1 -0
- package/out/utils/split.js +204 -0
- package/out/utils/split.js.map +1 -0
- package/out/utils/tokenize.d.ts +64 -0
- package/out/utils/tokenize.d.ts.map +1 -0
- package/out/utils/tokenize.js +82 -0
- package/out/utils/tokenize.js.map +1 -0
- package/out/utils/wof-json.d.ts +113 -0
- package/out/utils/wof-json.d.ts.map +1 -0
- package/out/utils/wof-json.js +173 -0
- package/out/utils/wof-json.js.map +1 -0
- package/package.json +259 -194
- package/out/src/adapters/ban/adapter.d.ts.map +0 -1
- package/out/src/adapters/ban/adapter.js +0 -149
- package/out/src/adapters/ban/adapter.js.map +0 -1
- package/out/src/adapters/ban/street-decompose.d.ts.map +0 -1
- package/out/src/adapters/ban/street-decompose.js +0 -75
- package/out/src/adapters/ban/street-decompose.js.map +0 -1
- package/out/src/adapters/fcc-bdc/adapter.d.ts.map +0 -1
- package/out/src/adapters/fcc-bdc/adapter.js +0 -144
- package/out/src/adapters/fcc-bdc/adapter.js.map +0 -1
- package/out/src/adapters/geonames/adapter.d.ts.map +0 -1
- package/out/src/adapters/geonames/adapter.js +0 -176
- package/out/src/adapters/geonames/adapter.js.map +0 -1
- package/out/src/adapters/geonames-postal/adapter.d.ts +0 -41
- package/out/src/adapters/geonames-postal/adapter.d.ts.map +0 -1
- package/out/src/adapters/geonames-postal/adapter.js +0 -104
- package/out/src/adapters/geonames-postal/adapter.js.map +0 -1
- package/out/src/adapters/gnaf/adapter.d.ts +0 -49
- package/out/src/adapters/gnaf/adapter.d.ts.map +0 -1
- package/out/src/adapters/gnaf/adapter.js +0 -124
- package/out/src/adapters/gnaf/adapter.js.map +0 -1
- package/out/src/adapters/gnaf/assemble.d.ts +0 -65
- package/out/src/adapters/gnaf/assemble.d.ts.map +0 -1
- package/out/src/adapters/gnaf/assemble.js +0 -154
- package/out/src/adapters/gnaf/assemble.js.map +0 -1
- package/out/src/adapters/index.d.ts +0 -51
- package/out/src/adapters/index.d.ts.map +0 -1
- package/out/src/adapters/index.js +0 -95
- package/out/src/adapters/index.js.map +0 -1
- package/out/src/adapters/openaddresses/adapter.d.ts.map +0 -1
- package/out/src/adapters/openaddresses/adapter.js +0 -186
- package/out/src/adapters/openaddresses/adapter.js.map +0 -1
- package/out/src/adapters/overture/adapter.d.ts +0 -48
- package/out/src/adapters/overture/adapter.d.ts.map +0 -1
- package/out/src/adapters/overture/adapter.js +0 -125
- package/out/src/adapters/overture/adapter.js.map +0 -1
- package/out/src/adapters/state-hi-schools/adapter.d.ts +0 -47
- package/out/src/adapters/state-hi-schools/adapter.d.ts.map +0 -1
- package/out/src/adapters/state-hi-schools/adapter.js +0 -133
- package/out/src/adapters/state-hi-schools/adapter.js.map +0 -1
- package/out/src/adapters/state-ia-contractors/adapter.d.ts.map +0 -1
- package/out/src/adapters/state-ia-contractors/adapter.js.map +0 -1
- package/out/src/adapters/state-ny-notaries/adapter.d.ts.map +0 -1
- package/out/src/adapters/state-ny-notaries/adapter.js.map +0 -1
- package/out/src/adapters/state-tx-notaries/adapter.d.ts.map +0 -1
- package/out/src/adapters/state-tx-notaries/adapter.js.map +0 -1
- package/out/src/adapters/synth-po-box/adapter.d.ts.map +0 -1
- package/out/src/adapters/synth-po-box/adapter.js +0 -140
- package/out/src/adapters/synth-po-box/adapter.js.map +0 -1
- package/out/src/adapters/tiger/adapter.d.ts +0 -55
- package/out/src/adapters/tiger/adapter.d.ts.map +0 -1
- package/out/src/adapters/tiger/adapter.js +0 -201
- package/out/src/adapters/tiger/adapter.js.map +0 -1
- package/out/src/adapters/tiger/street-decompose.d.ts.map +0 -1
- package/out/src/adapters/tiger/street-decompose.js +0 -90
- package/out/src/adapters/tiger/street-decompose.js.map +0 -1
- package/out/src/adapters/usgov-hrsa-fqhc/adapter.d.ts +0 -47
- package/out/src/adapters/usgov-hrsa-fqhc/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-hrsa-fqhc/adapter.js +0 -139
- package/out/src/adapters/usgov-hrsa-fqhc/adapter.js.map +0 -1
- package/out/src/adapters/usgov-imls-pls/adapter.d.ts +0 -36
- package/out/src/adapters/usgov-imls-pls/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-imls-pls/adapter.js +0 -114
- package/out/src/adapters/usgov-imls-pls/adapter.js.map +0 -1
- package/out/src/adapters/usgov-irs-bmf/adapter.d.ts +0 -37
- package/out/src/adapters/usgov-irs-bmf/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-irs-bmf/adapter.js +0 -124
- package/out/src/adapters/usgov-irs-bmf/adapter.js.map +0 -1
- package/out/src/adapters/usgov-nad/adapter.d.ts +0 -48
- package/out/src/adapters/usgov-nad/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-nad/adapter.js +0 -252
- package/out/src/adapters/usgov-nad/adapter.js.map +0 -1
- package/out/src/adapters/usgov-nppes/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-nppes/adapter.js +0 -116
- package/out/src/adapters/usgov-nppes/adapter.js.map +0 -1
- package/out/src/adapters/usgov-samhsa-treatment-locator/adapter.d.ts.map +0 -1
- package/out/src/adapters/usgov-samhsa-treatment-locator/adapter.js +0 -156
- package/out/src/adapters/usgov-samhsa-treatment-locator/adapter.js.map +0 -1
- package/out/src/adapters/utils/index.d.ts +0 -150
- package/out/src/adapters/utils/index.d.ts.map +0 -1
- package/out/src/adapters/utils/index.js +0 -159
- package/out/src/adapters/utils/index.js.map +0 -1
- package/out/src/adapters/wof-admin-jp/adapter.d.ts.map +0 -1
- package/out/src/adapters/wof-admin-jp/adapter.js +0 -164
- package/out/src/adapters/wof-admin-jp/adapter.js.map +0 -1
- package/out/src/adapters/wof-admin-json/adapter.d.ts +0 -82
- package/out/src/adapters/wof-admin-json/adapter.d.ts.map +0 -1
- package/out/src/adapters/wof-admin-json/adapter.js +0 -224
- package/out/src/adapters/wof-admin-json/adapter.js.map +0 -1
- package/out/src/adapters/wof-json-rows.d.ts +0 -32
- package/out/src/adapters/wof-json-rows.d.ts.map +0 -1
- package/out/src/adapters/wof-json-rows.js +0 -45
- package/out/src/adapters/wof-json-rows.js.map +0 -1
- package/out/src/adapters/wof-postalcode-json/adapter.d.ts +0 -65
- package/out/src/adapters/wof-postalcode-json/adapter.d.ts.map +0 -1
- package/out/src/adapters/wof-postalcode-json/adapter.js +0 -160
- package/out/src/adapters/wof-postalcode-json/adapter.js.map +0 -1
- package/out/src/build.d.ts +0 -132
- package/out/src/build.d.ts.map +0 -1
- package/out/src/build.js +0 -251
- package/out/src/build.js.map +0 -1
- package/out/src/codex/us-fips-state.d.ts.map +0 -1
- package/out/src/codex/us-fips-state.js.map +0 -1
- package/out/src/index.d.ts +0 -14
- package/out/src/index.d.ts.map +0 -1
- package/out/src/index.js +0 -14
- package/out/src/index.js.map +0 -1
- package/out/src/name-prone-us-suffixes.d.ts +0 -12
- package/out/src/name-prone-us-suffixes.d.ts.map +0 -1
- package/out/src/name-prone-us-suffixes.js +0 -12
- package/out/src/name-prone-us-suffixes.js.map +0 -1
- package/out/src/parquet-wrapper/index.d.ts +0 -9
- package/out/src/parquet-wrapper/index.d.ts.map +0 -1
- package/out/src/parquet-wrapper/index.js +0 -9
- package/out/src/parquet-wrapper/index.js.map +0 -1
- package/out/src/parquet-wrapper/reader.d.ts +0 -34
- package/out/src/parquet-wrapper/reader.d.ts.map +0 -1
- package/out/src/parquet-wrapper/reader.js +0 -69
- package/out/src/parquet-wrapper/reader.js.map +0 -1
- package/out/src/parquet-wrapper/schema.d.ts +0 -49
- package/out/src/parquet-wrapper/schema.d.ts.map +0 -1
- package/out/src/parquet-wrapper/schema.js +0 -55
- package/out/src/parquet-wrapper/schema.js.map +0 -1
- package/out/src/parquet-wrapper/writer.d.ts +0 -46
- package/out/src/parquet-wrapper/writer.d.ts.map +0 -1
- package/out/src/parquet-wrapper/writer.js +0 -76
- package/out/src/parquet-wrapper/writer.js.map +0 -1
- package/out/src/runner.d.ts +0 -126
- package/out/src/runner.d.ts.map +0 -1
- package/out/src/runner.js +0 -189
- package/out/src/runner.js.map +0 -1
- package/out/src/shard-recipes/anchor-absorption.d.ts +0 -20
- package/out/src/shard-recipes/anchor-absorption.d.ts.map +0 -1
- package/out/src/shard-recipes/anchor-absorption.js +0 -82
- package/out/src/shard-recipes/anchor-absorption.js.map +0 -1
- package/out/src/shard-recipes/bare-country.d.ts +0 -25
- package/out/src/shard-recipes/bare-country.d.ts.map +0 -1
- package/out/src/shard-recipes/bare-country.js +0 -87
- package/out/src/shard-recipes/bare-country.js.map +0 -1
- package/out/src/shard-recipes/boundary-stress.d.ts +0 -20
- package/out/src/shard-recipes/boundary-stress.d.ts.map +0 -1
- package/out/src/shard-recipes/boundary-stress.js +0 -83
- package/out/src/shard-recipes/boundary-stress.js.map +0 -1
- package/out/src/shard-recipes/country-balanced.d.ts +0 -32
- package/out/src/shard-recipes/country-balanced.d.ts.map +0 -1
- package/out/src/shard-recipes/country-balanced.js +0 -406
- package/out/src/shard-recipes/country-balanced.js.map +0 -1
- package/out/src/shard-recipes/cz-pcfirst-preposition.d.ts +0 -22
- package/out/src/shard-recipes/cz-pcfirst-preposition.d.ts.map +0 -1
- package/out/src/shard-recipes/cz-pcfirst-preposition.js +0 -100
- package/out/src/shard-recipes/cz-pcfirst-preposition.js.map +0 -1
- package/out/src/shard-recipes/fr-admin-split.d.ts +0 -38
- package/out/src/shard-recipes/fr-admin-split.d.ts.map +0 -1
- package/out/src/shard-recipes/fr-admin-split.js +0 -188
- package/out/src/shard-recipes/fr-admin-split.js.map +0 -1
- package/out/src/shard-recipes/fr-bare-street.d.ts +0 -28
- package/out/src/shard-recipes/fr-bare-street.d.ts.map +0 -1
- package/out/src/shard-recipes/fr-bare-street.js +0 -143
- package/out/src/shard-recipes/fr-bare-street.js.map +0 -1
- package/out/src/shard-recipes/fr-fragment.d.ts +0 -77
- package/out/src/shard-recipes/fr-fragment.d.ts.map +0 -1
- package/out/src/shard-recipes/fr-fragment.js +0 -276
- package/out/src/shard-recipes/fr-fragment.js.map +0 -1
- package/out/src/shard-recipes/fr-lieudit.d.ts +0 -32
- package/out/src/shard-recipes/fr-lieudit.d.ts.map +0 -1
- package/out/src/shard-recipes/fr-lieudit.js +0 -226
- package/out/src/shard-recipes/fr-lieudit.js.map +0 -1
- package/out/src/shard-recipes/fr-order.d.ts +0 -38
- package/out/src/shard-recipes/fr-order.d.ts.map +0 -1
- package/out/src/shard-recipes/fr-order.js +0 -208
- package/out/src/shard-recipes/fr-order.js.map +0 -1
- package/out/src/shard-recipes/german.d.ts +0 -23
- package/out/src/shard-recipes/german.d.ts.map +0 -1
- package/out/src/shard-recipes/german.js +0 -132
- package/out/src/shard-recipes/german.js.map +0 -1
- package/out/src/shard-recipes/house-venue.d.ts +0 -18
- package/out/src/shard-recipes/house-venue.d.ts.map +0 -1
- package/out/src/shard-recipes/house-venue.js +0 -74
- package/out/src/shard-recipes/house-venue.js.map +0 -1
- package/out/src/shard-recipes/index.d.ts +0 -24
- package/out/src/shard-recipes/index.d.ts.map +0 -1
- package/out/src/shard-recipes/index.js +0 -89
- package/out/src/shard-recipes/index.js.map +0 -1
- package/out/src/shard-recipes/intersection.d.ts +0 -42
- package/out/src/shard-recipes/intersection.d.ts.map +0 -1
- package/out/src/shard-recipes/intersection.js +0 -460
- package/out/src/shard-recipes/intersection.js.map +0 -1
- package/out/src/shard-recipes/locale.d.ts +0 -135
- package/out/src/shard-recipes/locale.d.ts.map +0 -1
- package/out/src/shard-recipes/locale.js +0 -459
- package/out/src/shard-recipes/locale.js.map +0 -1
- package/out/src/shard-recipes/nl-postcode.d.ts +0 -26
- package/out/src/shard-recipes/nl-postcode.d.ts.map +0 -1
- package/out/src/shard-recipes/nl-postcode.js +0 -102
- package/out/src/shard-recipes/nl-postcode.js.map +0 -1
- package/out/src/shard-recipes/no-fragment.d.ts +0 -43
- package/out/src/shard-recipes/no-fragment.d.ts.map +0 -1
- package/out/src/shard-recipes/no-fragment.js +0 -188
- package/out/src/shard-recipes/no-fragment.js.map +0 -1
- package/out/src/shard-recipes/no-street-led.d.ts +0 -24
- package/out/src/shard-recipes/no-street-led.d.ts.map +0 -1
- package/out/src/shard-recipes/no-street-led.js +0 -121
- package/out/src/shard-recipes/no-street-led.js.map +0 -1
- package/out/src/shard-recipes/no-street.d.ts +0 -18
- package/out/src/shard-recipes/no-street.d.ts.map +0 -1
- package/out/src/shard-recipes/no-street.js +0 -72
- package/out/src/shard-recipes/no-street.js.map +0 -1
- package/out/src/shard-recipes/po-box-cedex.d.ts +0 -38
- package/out/src/shard-recipes/po-box-cedex.d.ts.map +0 -1
- package/out/src/shard-recipes/po-box-cedex.js +0 -726
- package/out/src/shard-recipes/po-box-cedex.js.map +0 -1
- package/out/src/shard-recipes/po-box.d.ts +0 -17
- package/out/src/shard-recipes/po-box.d.ts.map +0 -1
- package/out/src/shard-recipes/po-box.js +0 -101
- package/out/src/shard-recipes/po-box.js.map +0 -1
- package/out/src/shard-recipes/reviewed-postcode-tail.d.ts +0 -47
- package/out/src/shard-recipes/reviewed-postcode-tail.d.ts.map +0 -1
- package/out/src/shard-recipes/reviewed-postcode-tail.js +0 -125
- package/out/src/shard-recipes/reviewed-postcode-tail.js.map +0 -1
- package/out/src/shard-recipes/scaffold.d.ts +0 -246
- package/out/src/shard-recipes/scaffold.d.ts.map +0 -1
- package/out/src/shard-recipes/scaffold.js +0 -137
- package/out/src/shard-recipes/scaffold.js.map +0 -1
- package/out/src/shard-recipes/si-bare-village.d.ts +0 -32
- package/out/src/shard-recipes/si-bare-village.d.ts.map +0 -1
- package/out/src/shard-recipes/si-bare-village.js +0 -88
- package/out/src/shard-recipes/si-bare-village.js.map +0 -1
- package/out/src/shard-recipes/street-affix.d.ts +0 -89
- package/out/src/shard-recipes/street-affix.d.ts.map +0 -1
- package/out/src/shard-recipes/street-affix.js +0 -578
- package/out/src/shard-recipes/street-affix.js.map +0 -1
- package/out/src/shard-recipes/street-bare.d.ts +0 -25
- package/out/src/shard-recipes/street-bare.d.ts.map +0 -1
- package/out/src/shard-recipes/street-bare.js +0 -86
- package/out/src/shard-recipes/street-bare.js.map +0 -1
- package/out/src/shard-recipes/street.d.ts +0 -15
- package/out/src/shard-recipes/street.d.ts.map +0 -1
- package/out/src/shard-recipes/street.js +0 -69
- package/out/src/shard-recipes/street.js.map +0 -1
- package/out/src/shard-recipes/sub-venue-sources.d.ts +0 -228
- package/out/src/shard-recipes/sub-venue-sources.d.ts.map +0 -1
- package/out/src/shard-recipes/sub-venue-sources.js +0 -664
- package/out/src/shard-recipes/sub-venue-sources.js.map +0 -1
- package/out/src/shard-recipes/sub-venue.d.ts +0 -269
- package/out/src/shard-recipes/sub-venue.d.ts.map +0 -1
- package/out/src/shard-recipes/sub-venue.js +0 -710
- package/out/src/shard-recipes/sub-venue.js.map +0 -1
- package/out/src/shard-recipes/trailing-region.d.ts +0 -74
- package/out/src/shard-recipes/trailing-region.d.ts.map +0 -1
- package/out/src/shard-recipes/trailing-region.js +0 -157
- package/out/src/shard-recipes/trailing-region.js.map +0 -1
- package/out/src/shard-recipes/unit.d.ts +0 -29
- package/out/src/shard-recipes/unit.d.ts.map +0 -1
- package/out/src/shard-recipes/unit.js +0 -243
- package/out/src/shard-recipes/unit.js.map +0 -1
- package/out/src/synthesizers/anchor-absorption.d.ts +0 -63
- package/out/src/synthesizers/anchor-absorption.d.ts.map +0 -1
- package/out/src/synthesizers/anchor-absorption.js +0 -223
- package/out/src/synthesizers/anchor-absorption.js.map +0 -1
- package/out/src/synthesizers/boundary-stress.d.ts +0 -78
- package/out/src/synthesizers/boundary-stress.d.ts.map +0 -1
- package/out/src/synthesizers/boundary-stress.js +0 -455
- package/out/src/synthesizers/boundary-stress.js.map +0 -1
- package/out/src/synthesizers/german.d.ts +0 -107
- package/out/src/synthesizers/german.d.ts.map +0 -1
- package/out/src/synthesizers/german.js +0 -148
- package/out/src/synthesizers/german.js.map +0 -1
- package/out/src/synthesizers/house-venue.d.ts +0 -56
- package/out/src/synthesizers/house-venue.d.ts.map +0 -1
- package/out/src/synthesizers/house-venue.js +0 -267
- package/out/src/synthesizers/house-venue.js.map +0 -1
- package/out/src/synthesizers/intersection.d.ts +0 -52
- package/out/src/synthesizers/intersection.d.ts.map +0 -1
- package/out/src/synthesizers/intersection.js +0 -175
- package/out/src/synthesizers/intersection.js.map +0 -1
- package/out/src/synthesizers/no-street.d.ts +0 -72
- package/out/src/synthesizers/no-street.d.ts.map +0 -1
- package/out/src/synthesizers/no-street.js +0 -282
- package/out/src/synthesizers/no-street.js.map +0 -1
- package/out/src/synthesizers/po-box.d.ts +0 -104
- package/out/src/synthesizers/po-box.d.ts.map +0 -1
- package/out/src/synthesizers/po-box.js +0 -266
- package/out/src/synthesizers/po-box.js.map +0 -1
- package/out/src/synthesizers/street.d.ts +0 -54
- package/out/src/synthesizers/street.d.ts.map +0 -1
- package/out/src/synthesizers/street.js +0 -221
- package/out/src/synthesizers/street.js.map +0 -1
- package/out/src/synthesizers/utils.d.ts +0 -203
- package/out/src/synthesizers/utils.d.ts.map +0 -1
- package/out/src/synthesizers/utils.js +0 -708
- package/out/src/synthesizers/utils.js.map +0 -1
- package/out/src/tools/align-shard.d.ts +0 -8
- package/out/src/tools/align-shard.d.ts.map +0 -1
- package/out/src/tools/align-shard.js +0 -56
- package/out/src/tools/align-shard.js.map +0 -1
- package/out/src/tools/audit.d.ts +0 -28
- package/out/src/tools/audit.d.ts.map +0 -1
- package/out/src/tools/audit.js +0 -285
- package/out/src/tools/audit.js.map +0 -1
- package/out/src/tools/corpus-stats.d.ts +0 -44
- package/out/src/tools/corpus-stats.d.ts.map +0 -1
- package/out/src/tools/corpus-stats.js +0 -138
- package/out/src/tools/corpus-stats.js.map +0 -1
- package/out/src/tools/fetch/ban.d.ts +0 -31
- package/out/src/tools/fetch/ban.d.ts.map +0 -1
- package/out/src/tools/fetch/ban.js +0 -239
- package/out/src/tools/fetch/ban.js.map +0 -1
- package/out/src/tools/fetch/download.d.ts +0 -78
- package/out/src/tools/fetch/download.d.ts.map +0 -1
- package/out/src/tools/fetch/download.js +0 -116
- package/out/src/tools/fetch/download.js.map +0 -1
- package/out/src/tools/fetch/geonames-dump.d.ts +0 -87
- package/out/src/tools/fetch/geonames-dump.d.ts.map +0 -1
- package/out/src/tools/fetch/geonames-dump.js +0 -178
- package/out/src/tools/fetch/geonames-dump.js.map +0 -1
- package/out/src/tools/fetch/geonames-postal.d.ts +0 -76
- package/out/src/tools/fetch/geonames-postal.d.ts.map +0 -1
- package/out/src/tools/fetch/geonames-postal.js +0 -125
- package/out/src/tools/fetch/geonames-postal.js.map +0 -1
- package/out/src/tools/fetch/hrsa.d.ts +0 -18
- package/out/src/tools/fetch/hrsa.d.ts.map +0 -1
- package/out/src/tools/fetch/hrsa.js +0 -46
- package/out/src/tools/fetch/hrsa.js.map +0 -1
- package/out/src/tools/fetch/imls-pls.d.ts +0 -25
- package/out/src/tools/fetch/imls-pls.d.ts.map +0 -1
- package/out/src/tools/fetch/imls-pls.js +0 -108
- package/out/src/tools/fetch/imls-pls.js.map +0 -1
- package/out/src/tools/fetch/index.d.ts +0 -144
- package/out/src/tools/fetch/index.d.ts.map +0 -1
- package/out/src/tools/fetch/index.js +0 -143
- package/out/src/tools/fetch/index.js.map +0 -1
- package/out/src/tools/fetch/nad.d.ts +0 -70
- package/out/src/tools/fetch/nad.d.ts.map +0 -1
- package/out/src/tools/fetch/nad.js +0 -234
- package/out/src/tools/fetch/nad.js.map +0 -1
- package/out/src/tools/fetch/nppes.d.ts +0 -26
- package/out/src/tools/fetch/nppes.d.ts.map +0 -1
- package/out/src/tools/fetch/nppes.js +0 -126
- package/out/src/tools/fetch/nppes.js.map +0 -1
- package/out/src/tools/fetch/openaddresses.d.ts +0 -61
- package/out/src/tools/fetch/openaddresses.d.ts.map +0 -1
- package/out/src/tools/fetch/openaddresses.js +0 -317
- package/out/src/tools/fetch/openaddresses.js.map +0 -1
- package/out/src/tools/fetch/ourairports.d.ts +0 -45
- package/out/src/tools/fetch/ourairports.d.ts.map +0 -1
- package/out/src/tools/fetch/ourairports.js +0 -128
- package/out/src/tools/fetch/ourairports.js.map +0 -1
- package/out/src/tools/fetch/ppd.d.ts.map +0 -1
- package/out/src/tools/fetch/ppd.js +0 -100
- package/out/src/tools/fetch/ppd.js.map +0 -1
- package/out/src/tools/fetch/state-hi-schools.d.ts +0 -25
- package/out/src/tools/fetch/state-hi-schools.d.ts.map +0 -1
- package/out/src/tools/fetch/state-hi-schools.js +0 -162
- package/out/src/tools/fetch/state-hi-schools.js.map +0 -1
- package/out/src/tools/fetch/state-sources.d.ts +0 -26
- package/out/src/tools/fetch/state-sources.d.ts.map +0 -1
- package/out/src/tools/fetch/state-sources.js +0 -111
- package/out/src/tools/fetch/state-sources.js.map +0 -1
- package/out/src/tools/fetch/tiger-full.d.ts +0 -42
- package/out/src/tools/fetch/tiger-full.d.ts.map +0 -1
- package/out/src/tools/fetch/tiger-full.js +0 -248
- package/out/src/tools/fetch/tiger-full.js.map +0 -1
- package/out/src/tools/fetch/wikidata-subvenue.d.ts +0 -171
- package/out/src/tools/fetch/wikidata-subvenue.d.ts.map +0 -1
- package/out/src/tools/fetch/wikidata-subvenue.js +0 -275
- package/out/src/tools/fetch/wikidata-subvenue.js.map +0 -1
- package/out/src/tools/gb-title-case.d.ts.map +0 -1
- package/out/src/tools/gb-title-case.js.map +0 -1
- package/out/src/tools/golden-expand.d.ts +0 -90
- package/out/src/tools/golden-expand.d.ts.map +0 -1
- package/out/src/tools/golden-expand.js +0 -413
- package/out/src/tools/golden-expand.js.map +0 -1
- package/out/src/tools/golden-promote.d.ts.map +0 -1
- package/out/src/tools/golden-promote.js +0 -244
- package/out/src/tools/golden-promote.js.map +0 -1
- package/out/src/tools/golden-relabel-street.d.ts +0 -196
- package/out/src/tools/golden-relabel-street.d.ts.map +0 -1
- package/out/src/tools/golden-relabel-street.js +0 -440
- package/out/src/tools/golden-relabel-street.js.map +0 -1
- package/out/src/tools/index.d.ts +0 -28
- package/out/src/tools/index.d.ts.map +0 -1
- package/out/src/tools/index.js +0 -28
- package/out/src/tools/index.js.map +0 -1
- package/out/src/tools/ingest-csv.d.ts.map +0 -1
- package/out/src/tools/ingest-csv.js +0 -296
- package/out/src/tools/ingest-csv.js.map +0 -1
- package/out/src/tools/jsonl-to-parquet.d.ts +0 -61
- package/out/src/tools/jsonl-to-parquet.d.ts.map +0 -1
- package/out/src/tools/jsonl-to-parquet.js +0 -164
- package/out/src/tools/jsonl-to-parquet.js.map +0 -1
- package/out/src/tools/lint-shard-vocab.d.ts +0 -90
- package/out/src/tools/lint-shard-vocab.d.ts.map +0 -1
- package/out/src/tools/lint-shard-vocab.js +0 -281
- package/out/src/tools/lint-shard-vocab.js.map +0 -1
- package/out/src/tools/lint-shard.d.ts +0 -93
- package/out/src/tools/lint-shard.d.ts.map +0 -1
- package/out/src/tools/lint-shard.js +0 -354
- package/out/src/tools/lint-shard.js.map +0 -1
- package/out/src/tools/overlay-manifest.d.ts +0 -39
- package/out/src/tools/overlay-manifest.d.ts.map +0 -1
- package/out/src/tools/overlay-manifest.js +0 -98
- package/out/src/tools/overlay-manifest.js.map +0 -1
- package/out/src/tools/overture-subvenue.d.ts +0 -112
- package/out/src/tools/overture-subvenue.d.ts.map +0 -1
- package/out/src/tools/overture-subvenue.js +0 -144
- package/out/src/tools/overture-subvenue.js.map +0 -1
- package/out/src/tools/postcode-triples.d.ts +0 -175
- package/out/src/tools/postcode-triples.d.ts.map +0 -1
- package/out/src/tools/postcode-triples.js +0 -304
- package/out/src/tools/postcode-triples.js.map +0 -1
- package/out/src/tools/shard-kryptonite.d.ts +0 -32
- package/out/src/tools/shard-kryptonite.d.ts.map +0 -1
- package/out/src/tools/shard-kryptonite.js +0 -100
- package/out/src/tools/shard-kryptonite.js.map +0 -1
- package/out/src/tools/shard-translit.d.ts +0 -51
- package/out/src/tools/shard-translit.d.ts.map +0 -1
- package/out/src/tools/shard-translit.js +0 -175
- package/out/src/tools/shard-translit.js.map +0 -1
- package/out/src/tools/sub-venue/harvest.d.ts +0 -100
- package/out/src/tools/sub-venue/harvest.d.ts.map +0 -1
- package/out/src/tools/sub-venue/harvest.js +0 -168
- package/out/src/tools/sub-venue/harvest.js.map +0 -1
- package/out/src/tools/sub-venue/head-nouns.d.ts +0 -50
- package/out/src/tools/sub-venue/head-nouns.d.ts.map +0 -1
- package/out/src/tools/sub-venue/head-nouns.js +0 -210
- package/out/src/tools/sub-venue/head-nouns.js.map +0 -1
- package/out/src/tools/sub-venue/surfaces.d.ts +0 -45
- package/out/src/tools/sub-venue/surfaces.d.ts.map +0 -1
- package/out/src/tools/sub-venue/surfaces.js +0 -77
- package/out/src/tools/sub-venue/surfaces.js.map +0 -1
- package/out/src/tools/sub-venue/table.d.ts +0 -229
- package/out/src/tools/sub-venue/table.d.ts.map +0 -1
- package/out/src/tools/sub-venue/table.js +0 -108
- package/out/src/tools/sub-venue/table.js.map +0 -1
- package/out/src/tools/sub-venue/wikidata.d.ts +0 -26
- package/out/src/tools/sub-venue/wikidata.d.ts.map +0 -1
- package/out/src/tools/sub-venue/wikidata.js +0 -62
- package/out/src/tools/sub-venue/wikidata.js.map +0 -1
- package/out/src/tools/sub-venue-lexicon.d.ts +0 -156
- package/out/src/tools/sub-venue-lexicon.d.ts.map +0 -1
- package/out/src/tools/sub-venue-lexicon.js +0 -282
- package/out/src/tools/sub-venue-lexicon.js.map +0 -1
- package/out/src/tools/sub-venue-promotions.d.ts +0 -94
- package/out/src/tools/sub-venue-promotions.d.ts.map +0 -1
- package/out/src/tools/sub-venue-promotions.js +0 -266
- package/out/src/tools/sub-venue-promotions.js.map +0 -1
- package/out/src/types.d.ts +0 -221
- package/out/src/types.d.ts.map +0 -1
- package/out/src/types.js.map +0 -1
- package/out/src/utils/align.d.ts +0 -93
- package/out/src/utils/align.d.ts.map +0 -1
- package/out/src/utils/align.js +0 -234
- package/out/src/utils/align.js.map +0 -1
- package/out/src/utils/golden.d.ts +0 -69
- package/out/src/utils/golden.d.ts.map +0 -1
- package/out/src/utils/golden.js +0 -127
- package/out/src/utils/golden.js.map +0 -1
- package/out/src/utils/index.d.ts +0 -14
- package/out/src/utils/index.d.ts.map +0 -1
- package/out/src/utils/index.js +0 -14
- package/out/src/utils/index.js.map +0 -1
- package/out/src/utils/license.d.ts.map +0 -1
- package/out/src/utils/license.js.map +0 -1
- package/out/src/utils/parquet.d.ts +0 -162
- package/out/src/utils/parquet.d.ts.map +0 -1
- package/out/src/utils/parquet.js +0 -262
- package/out/src/utils/parquet.js.map +0 -1
- package/out/src/utils/split.d.ts +0 -127
- package/out/src/utils/split.d.ts.map +0 -1
- package/out/src/utils/split.js +0 -204
- package/out/src/utils/split.js.map +0 -1
- package/out/src/utils/tokenize.d.ts +0 -56
- package/out/src/utils/tokenize.d.ts.map +0 -1
- package/out/src/utils/tokenize.js +0 -48
- package/out/src/utils/tokenize.js.map +0 -1
- package/out/src/utils/wof-json.d.ts +0 -109
- package/out/src/utils/wof-json.d.ts.map +0 -1
- package/out/src/utils/wof-json.js +0 -173
- package/out/src/utils/wof-json.js.map +0 -1
- package/src/adapters/ban/adapter.ts +0 -191
- package/src/adapters/ban/street-decompose.ts +0 -96
- package/src/adapters/fcc-bdc/adapter.ts +0 -174
- package/src/adapters/geonames/adapter.ts +0 -200
- package/src/adapters/geonames-postal/adapter.ts +0 -119
- package/src/adapters/gnaf/adapter.ts +0 -149
- package/src/adapters/gnaf/assemble.ts +0 -226
- package/src/adapters/index.ts +0 -149
- package/src/adapters/openaddresses/adapter.ts +0 -251
- package/src/adapters/overture/adapter.ts +0 -162
- package/src/adapters/state-hi-schools/adapter.ts +0 -164
- package/src/adapters/synth-po-box/adapter.ts +0 -204
- package/src/adapters/tiger/adapter.ts +0 -253
- package/src/adapters/tiger/street-decompose.ts +0 -111
- package/src/adapters/usgov-hrsa-fqhc/adapter.ts +0 -183
- package/src/adapters/usgov-imls-pls/adapter.ts +0 -143
- package/src/adapters/usgov-irs-bmf/adapter.ts +0 -163
- package/src/adapters/usgov-nad/adapter.ts +0 -348
- package/src/adapters/usgov-nppes/adapter.ts +0 -159
- package/src/adapters/usgov-samhsa-treatment-locator/adapter.ts +0 -204
- package/src/adapters/utils/index.ts +0 -233
- package/src/adapters/wof-admin-jp/adapter.ts +0 -216
- package/src/adapters/wof-admin-json/adapter.ts +0 -256
- package/src/adapters/wof-json-rows.ts +0 -79
- package/src/adapters/wof-postalcode-json/adapter.ts +0 -183
- package/src/build.ts +0 -386
- package/src/index.ts +0 -14
- package/src/name-prone-us-suffixes.ts +0 -12
- package/src/parquet-wrapper/index.ts +0 -9
- package/src/parquet-wrapper/reader.ts +0 -97
- package/src/parquet-wrapper/schema.ts +0 -88
- package/src/parquet-wrapper/writer.ts +0 -110
- package/src/runner.ts +0 -317
- package/src/shard-recipes/anchor-absorption.ts +0 -103
- package/src/shard-recipes/bare-country.ts +0 -95
- package/src/shard-recipes/boundary-stress.ts +0 -101
- package/src/shard-recipes/country-balanced.ts +0 -524
- package/src/shard-recipes/cz-pcfirst-preposition.ts +0 -111
- package/src/shard-recipes/fr-admin-split.ts +0 -239
- package/src/shard-recipes/fr-bare-street.ts +0 -170
- package/src/shard-recipes/fr-fragment.ts +0 -332
- package/src/shard-recipes/fr-lieudit.ts +0 -302
- package/src/shard-recipes/fr-order.ts +0 -258
- package/src/shard-recipes/german.ts +0 -170
- package/src/shard-recipes/house-venue.ts +0 -88
- package/src/shard-recipes/index.ts +0 -95
- package/src/shard-recipes/intersection.ts +0 -630
- package/src/shard-recipes/locale.ts +0 -599
- package/src/shard-recipes/nl-postcode.ts +0 -115
- package/src/shard-recipes/no-fragment.ts +0 -219
- package/src/shard-recipes/no-street-led.ts +0 -143
- package/src/shard-recipes/no-street.ts +0 -86
- package/src/shard-recipes/po-box-cedex.ts +0 -920
- package/src/shard-recipes/po-box.ts +0 -119
- package/src/shard-recipes/reviewed-postcode-tail.ts +0 -189
- package/src/shard-recipes/scaffold.ts +0 -360
- package/src/shard-recipes/si-bare-village.ts +0 -97
- package/src/shard-recipes/street-affix.ts +0 -826
- package/src/shard-recipes/street-bare.ts +0 -101
- package/src/shard-recipes/street.ts +0 -82
- package/src/shard-recipes/sub-venue-sources.ts +0 -885
- package/src/shard-recipes/sub-venue.ts +0 -984
- package/src/shard-recipes/trailing-region.ts +0 -183
- package/src/shard-recipes/unit.ts +0 -321
- package/src/synthesizers/anchor-absorption.ts +0 -290
- package/src/synthesizers/boundary-stress.ts +0 -531
- package/src/synthesizers/german.ts +0 -251
- package/src/synthesizers/house-venue.ts +0 -330
- package/src/synthesizers/intersection.ts +0 -232
- package/src/synthesizers/no-street.ts +0 -349
- package/src/synthesizers/po-box.ts +0 -339
- package/src/synthesizers/street.ts +0 -274
- package/src/synthesizers/utils.ts +0 -903
- package/src/tools/align-shard.ts +0 -70
- package/src/tools/audit.ts +0 -399
- package/src/tools/corpus-stats.ts +0 -184
- package/src/tools/fetch/ban.ts +0 -290
- package/src/tools/fetch/download.ts +0 -176
- package/src/tools/fetch/geonames-dump.ts +0 -267
- package/src/tools/fetch/geonames-postal.ts +0 -180
- package/src/tools/fetch/hrsa.ts +0 -68
- package/src/tools/fetch/imls-pls.ts +0 -158
- package/src/tools/fetch/index.ts +0 -147
- package/src/tools/fetch/nad.ts +0 -342
- package/src/tools/fetch/nppes.ts +0 -174
- package/src/tools/fetch/openaddresses.ts +0 -404
- package/src/tools/fetch/ourairports.ts +0 -171
- package/src/tools/fetch/ppd.ts +0 -137
- package/src/tools/fetch/state-hi-schools.ts +0 -208
- package/src/tools/fetch/state-sources.ts +0 -155
- package/src/tools/fetch/tiger-full.ts +0 -354
- package/src/tools/fetch/wikidata-subvenue.ts +0 -386
- package/src/tools/golden-expand.ts +0 -584
- package/src/tools/golden-promote.ts +0 -353
- package/src/tools/golden-relabel-street.ts +0 -685
- package/src/tools/index.ts +0 -28
- package/src/tools/ingest-csv.ts +0 -422
- package/src/tools/jsonl-to-parquet.ts +0 -221
- package/src/tools/lint-shard-vocab.ts +0 -409
- package/src/tools/lint-shard.ts +0 -543
- package/src/tools/overlay-manifest.ts +0 -157
- package/src/tools/overture-subvenue.ts +0 -215
- package/src/tools/postcode-triples.ts +0 -375
- package/src/tools/shard-kryptonite.ts +0 -139
- package/src/tools/shard-translit.ts +0 -245
- package/src/tools/sub-venue/harvest.ts +0 -235
- package/src/tools/sub-venue/head-nouns.ts +0 -242
- package/src/tools/sub-venue/surfaces.ts +0 -95
- package/src/tools/sub-venue/table.ts +0 -281
- package/src/tools/sub-venue/wikidata.ts +0 -85
- package/src/tools/sub-venue-lexicon.ts +0 -431
- package/src/tools/sub-venue-promotions.ts +0 -330
- package/src/types.ts +0 -247
- package/src/utils/align.ts +0 -331
- package/src/utils/golden.ts +0 -176
- package/src/utils/index.ts +0 -14
- package/src/utils/parquet.ts +0 -391
- package/src/utils/split.ts +0 -279
- package/src/utils/tokenize.ts +0 -78
- package/src/utils/wof-json.ts +0 -244
- /package/{src → lib}/adapters/state-ia-contractors/adapter.ts +0 -0
- /package/{src → lib}/adapters/state-ny-notaries/adapter.ts +0 -0
- /package/{src → lib}/adapters/state-tx-notaries/adapter.ts +0 -0
- /package/{src → lib}/codex/us-fips-state.ts +0 -0
- /package/{src → lib}/tools/gb-title-case.ts +0 -0
- /package/{src → lib}/utils/license.ts +0 -0
- /package/out/{src/adapters → adapters}/ban/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/ban/street-decompose.d.ts +0 -0
- /package/out/{src/adapters → adapters}/fcc-bdc/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/geonames/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/openaddresses/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/state-ia-contractors/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/state-ia-contractors/adapter.js +0 -0
- /package/out/{src/adapters → adapters}/state-ny-notaries/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/state-ny-notaries/adapter.js +0 -0
- /package/out/{src/adapters → adapters}/state-tx-notaries/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/state-tx-notaries/adapter.js +0 -0
- /package/out/{src/adapters → adapters}/synth-po-box/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/tiger/street-decompose.d.ts +0 -0
- /package/out/{src/adapters → adapters}/usgov-nppes/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/usgov-samhsa-treatment-locator/adapter.d.ts +0 -0
- /package/out/{src/adapters → adapters}/wof-admin-jp/adapter.d.ts +0 -0
- /package/out/{src/codex → codex}/us-fips-state.d.ts +0 -0
- /package/out/{src/codex → codex}/us-fips-state.js +0 -0
- /package/out/{src/tools → tools}/fetch/ppd.d.ts +0 -0
- /package/out/{src/tools → tools}/gb-title-case.d.ts +0 -0
- /package/out/{src/tools → tools}/gb-title-case.js +0 -0
- /package/out/{src/tools → tools}/golden-promote.d.ts +0 -0
- /package/out/{src/tools → tools}/ingest-csv.d.ts +0 -0
- /package/out/{src/types.js → types.js} +0 -0
- /package/out/{src/utils → utils}/license.d.ts +0 -0
- /package/out/{src/utils → utils}/license.js +0 -0
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
* @file `cn-organizational-units` recipe (#2034) — real CN address strings whose settlement is an ORGANIZATIONAL
|
|
6
|
+
* ladder (`赵光三分场二十九队`: the Zhaoguang farm, No. 3 sub-farm, No. 29 production team), labeled by rule and aligned
|
|
7
|
+
* character by character for the CJK sibling model.
|
|
8
|
+
*
|
|
9
|
+
* THE LABELS ARE A READING OF THE SUFFIX, NOT A GUESS. Every generic that ends an ordinal unit (`分场`, `大队`, `队`,
|
|
10
|
+
* `连`, `团`, `组`, `场部`) is in `@mailwoman/core/locale/zh-cn-units`' one table, and the same table reads the span back
|
|
11
|
+
* after decode. The whole ordinal chain is ONE `locality_unit` span; the named head it belongs to (`赵光`, `孟定农场`) is
|
|
12
|
+
* `dependent_locality`; a province, city or county written in front of it takes `region`, `locality`, `subregion`; a
|
|
13
|
+
* Latin admin tail (`, Heilongjiang, China`) takes `region` and `country`. A row with no chain is skipped, not labeled:
|
|
14
|
+
* `红卫大队` is a village name whose generic carries no ordinal, and `苗辽林场` is a named forest farm.
|
|
15
|
+
*
|
|
16
|
+
* WHERE THE ROWS COME FROM. `--input` is a JSONL of `{ raw, country }` rows — the shape of `data/coarse-placer/*.jsonl`,
|
|
17
|
+
* whose 50,000 CN rows hold 328 with unit vocabulary. That file is a local artifact and carries no per-row source; the
|
|
18
|
+
* `<name>, <admin1>, <country>` shape is the corpus's GeoNames adapter's, so the rows are stamped with GeoNames'
|
|
19
|
+
* licence and the inference is stated in the `license` field rather than hidden behind it.
|
|
20
|
+
*
|
|
21
|
+
* FOR THE CJK MODEL ONLY. The tokenizer is {@link cjkAwareTokenizer}: one token per Han character, because the
|
|
22
|
+
* whitespace tokenizer reads `三分场八队` as one word and could never give it two labels. The Latin model never trains
|
|
23
|
+
* on this recipe's rows; its label set has no `locality_unit`.
|
|
24
|
+
*/
|
|
25
|
+
import { splitCNUnitChain } from "@mailwoman/core/locale/zh-cn-units";
|
|
26
|
+
import { readTuples, sliceSourceID } from "#recipes/scaffold";
|
|
27
|
+
import { alignRow } from "#utils/align";
|
|
28
|
+
import { cjkAwareTokenizer } from "#utils/tokenize";
|
|
29
|
+
/**
|
|
30
|
+
* The leading run of Han characters (plus the digits an ordinal may be written with): the Chinese half of a row.
|
|
31
|
+
*/
|
|
32
|
+
const LEADING_HAN = /^[\p{Script=Han}〇\d]+/u;
|
|
33
|
+
/**
|
|
34
|
+
* Admin prefixes a CJK address writes in front of the settlement, coarsest first. Each is matched at the START of what
|
|
35
|
+
* remains, so `云南省临沧市孟定农场三分场二队` peels `云南省` (province), `临沧市` (city), and hands `孟定农场三分场二队` to the unit reader.
|
|
36
|
+
*/
|
|
37
|
+
const ADMIN_PREFIXES = [
|
|
38
|
+
[/^(.+?(?:省|自治区))/u, "region"],
|
|
39
|
+
[/^(.+?市)/u, "locality"],
|
|
40
|
+
[/^(.+?(?:自治县|县|旗))/u, "subregion"],
|
|
41
|
+
];
|
|
42
|
+
/**
|
|
43
|
+
* The components a row's string supports, every value a verbatim substring of `raw`, or `null` when the string carries
|
|
44
|
+
* no organizational chain and so teaches nothing this recipe exists for.
|
|
45
|
+
*/
|
|
46
|
+
export function labelCNOrganizationalRow(raw) {
|
|
47
|
+
const han = LEADING_HAN.exec(raw)?.[0];
|
|
48
|
+
if (!han)
|
|
49
|
+
return null;
|
|
50
|
+
const components = {};
|
|
51
|
+
let rest = han;
|
|
52
|
+
for (const [pattern, tag] of ADMIN_PREFIXES) {
|
|
53
|
+
const match = pattern.exec(rest);
|
|
54
|
+
// A prefix must leave something behind it, or the whole run was the admin name and there is no settlement.
|
|
55
|
+
if (match && match[1].length < rest.length) {
|
|
56
|
+
components[tag] = match[1];
|
|
57
|
+
rest = rest.slice(match[1].length);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
const split = splitCNUnitChain(rest);
|
|
61
|
+
if (!split)
|
|
62
|
+
return null;
|
|
63
|
+
if (split.head) {
|
|
64
|
+
components.dependent_locality = split.head;
|
|
65
|
+
}
|
|
66
|
+
components.locality_unit = split.chain;
|
|
67
|
+
const tail = raw.slice(han.length).trim();
|
|
68
|
+
if (tail) {
|
|
69
|
+
// `, Heilongjiang, China` or `Hunan China` or `Inner Mongolia`: comma segments when there are commas, else the last
|
|
70
|
+
// word is the country when it says so and the rest is the admin1 name.
|
|
71
|
+
const segments = tail.includes(",")
|
|
72
|
+
? tail
|
|
73
|
+
.split(",")
|
|
74
|
+
.map((segment) => segment.trim())
|
|
75
|
+
.filter((segment) => segment.length > 0)
|
|
76
|
+
: tailWithoutCommas(tail);
|
|
77
|
+
for (const segment of segments) {
|
|
78
|
+
if (/^china$/iu.test(segment)) {
|
|
79
|
+
components.country = segment;
|
|
80
|
+
}
|
|
81
|
+
else if (!components.region && !/^\d+$/u.test(segment)) {
|
|
82
|
+
components.region = segment;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
return components;
|
|
87
|
+
}
|
|
88
|
+
/**
|
|
89
|
+
* A space-separated tail: `Hunan China` → [`Hunan`, `China`]; `Inner Mongolia` → [`Inner Mongolia`]; `Xinjiang Uyghur`
|
|
90
|
+
* → [`Xinjiang Uyghur`].
|
|
91
|
+
*/
|
|
92
|
+
function tailWithoutCommas(tail) {
|
|
93
|
+
const words = tail.split(/\s+/u).filter((word) => word.length > 0);
|
|
94
|
+
const last = words.at(-1);
|
|
95
|
+
if (last && /^china$/iu.test(last) && words.length > 1) {
|
|
96
|
+
return [words.slice(0, -1).join(" "), last];
|
|
97
|
+
}
|
|
98
|
+
return [words.join(" ")];
|
|
99
|
+
}
|
|
100
|
+
const SOURCE = "coarse-placer-cn-units";
|
|
101
|
+
/**
|
|
102
|
+
* Slice recipe registered with the corpus builder — see the file header for the rows it labels and why every label is a
|
|
103
|
+
* reading of a generic rather than a guess.
|
|
104
|
+
*/
|
|
105
|
+
export const cnOrganizationalUnitsRecipe = {
|
|
106
|
+
name: "cn-organizational-units",
|
|
107
|
+
description: "CN rows whose settlement is an organizational ladder (分场/队/连/组), labeled by the suffix grammar as one locality_unit span, per-character BIO",
|
|
108
|
+
mode: "tuples",
|
|
109
|
+
options: [],
|
|
110
|
+
async run(opts, write) {
|
|
111
|
+
if (!opts.input) {
|
|
112
|
+
throw new Error("cn-organizational-units: --input <rows.jsonl> is required ({ raw, country } rows)");
|
|
113
|
+
}
|
|
114
|
+
const tokenizer = cjkAwareTokenizer();
|
|
115
|
+
let emitted = 0;
|
|
116
|
+
let skipped = 0;
|
|
117
|
+
let quarantined = 0;
|
|
118
|
+
for await (const tuple of readTuples(opts.input)) {
|
|
119
|
+
const raw = typeof tuple["raw"] === "string" ? tuple["raw"].trim() : "";
|
|
120
|
+
const country = typeof tuple["country"] === "string" ? tuple["country"].toUpperCase() : "CN";
|
|
121
|
+
if (!raw || country !== "CN") {
|
|
122
|
+
skipped++;
|
|
123
|
+
continue;
|
|
124
|
+
}
|
|
125
|
+
const components = labelCNOrganizationalRow(raw);
|
|
126
|
+
if (!components) {
|
|
127
|
+
skipped++;
|
|
128
|
+
continue;
|
|
129
|
+
}
|
|
130
|
+
if (opts.golden) {
|
|
131
|
+
write(JSON.stringify({ raw, components, country: "CN", locale: "zh-CN" }) + "\n");
|
|
132
|
+
emitted++;
|
|
133
|
+
continue;
|
|
134
|
+
}
|
|
135
|
+
const canonical = {
|
|
136
|
+
raw,
|
|
137
|
+
components,
|
|
138
|
+
country: "CN",
|
|
139
|
+
locale: "zh-CN",
|
|
140
|
+
source: opts.sourceName ?? SOURCE,
|
|
141
|
+
source_id: sliceSourceID(opts.sourceName ?? SOURCE, { raw }),
|
|
142
|
+
corpus_version: "0.4.0",
|
|
143
|
+
license: "CC-BY-4.0 — GeoNames populated places, INFERRED from the `<name>, <admin1>, <country>` row shape; data/coarse-placer carries no per-row source",
|
|
144
|
+
};
|
|
145
|
+
// Verbatim only: every value above was sliced out of `raw`, so an edit-distance match would mean this file
|
|
146
|
+
// has a bug, not that the source spells something differently.
|
|
147
|
+
const aligned = alignRow(canonical, { tokenizer, maxEditDistance: 0 });
|
|
148
|
+
if (aligned.kind !== "labeled" || !aligned.row) {
|
|
149
|
+
quarantined++;
|
|
150
|
+
continue;
|
|
151
|
+
}
|
|
152
|
+
write(JSON.stringify({ ...aligned.row, synth_method: "cn-organizational-units", synth_base_id: null }) + "\n");
|
|
153
|
+
emitted++;
|
|
154
|
+
}
|
|
155
|
+
console.error(` cn-organizational-units: ${emitted} labeled, ${skipped} without a chain, ${quarantined} quarantined`);
|
|
156
|
+
return { emitted, skipped, quarantined };
|
|
157
|
+
},
|
|
158
|
+
};
|
|
159
|
+
//# sourceMappingURL=cn-organizational-units.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cn-organizational-units.js","sourceRoot":"","sources":["../../lib/recipes/cn-organizational-units.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,EAAE,gBAAgB,EAAE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AAE,IAAI,EAAE,CAAC,GAAG,IAAI,CAAC,CAAA;YAE9G,OAAO,EAAE,CAAA;QACV,CAAC;QAED,OAAO,CAAC,KAAK,CACZ,8BAA8B,OAAO,aAAa,OAAO,qBAAqB,WAAW,cAAc,CACvG,CAAA;QAED,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,CAAA;IACzC,CAAC;CACD,CAAA"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* `country-balanced` slice recipe — the BALANCED, MODEL-FIRST country-coverage slice (#464). The
|
|
7
|
+
* shipped model is STARVED on `country` (P=R=F1=0 on the homograph eval), so this fills the void
|
|
8
|
+
* the way the `unit` slice did, but built to AVOID over-firing "trailing token ⇒ country". Three
|
|
9
|
+
* ingredients, ported faithfully from scripts/build-country-slice-balanced.mjs:
|
|
10
|
+
*
|
|
11
|
+
* 1. Breadth/recall — real OA skeletons (US/DE/FR/IT/NL) with a country token in a varied surface form
|
|
12
|
+
* from `@mailwoman/codex/country` (canonical / endonym / ISO code), + ~30% country-ABSENT
|
|
13
|
+
* negatives (teach O-emission, the precision floor).
|
|
14
|
+
* 2. Homograph CONTRAST pairs — each true country-name homograph (Georgia, Jordan, Lebanon, Mexico,
|
|
15
|
+
* Peru, Turkey) rendered BOTH ways: as `country` (foreign-city context) AND as the US
|
|
16
|
+
* `region`/`locality` (US-ZIP context). Teaches that the label is CONTEXTUAL, not
|
|
17
|
+
* positional.
|
|
18
|
+
* 3. Code-as-region negatives — 2-letter codes that are both a US state abbrev and an ISO country code
|
|
19
|
+
* (CA/GA/IN/MA/PA/AL) in US-ZIP context → must read as `region`, never `country`.
|
|
20
|
+
*
|
|
21
|
+
* `--golden` emits a held-out synthetic val over the VT (US) + Berlin (DE) holdouts. This is a
|
|
22
|
+
* `generate`-mode recipe that still reads REAL tuples off disk — `--count` bounds the OUTPUT, not
|
|
23
|
+
* the input. The passed `random` (the framework LCG) is consumed in the exact call order the
|
|
24
|
+
* legacy script used.
|
|
25
|
+
*/
|
|
26
|
+
import { type CorpusRecipe } from "#recipes/scaffold";
|
|
27
|
+
/**
|
|
28
|
+
* Slice recipe registered with the corpus builder — see the file header for the parse behaviour it exists to exercise,
|
|
29
|
+
* and `description` below for the surface form it generates.
|
|
30
|
+
*/
|
|
31
|
+
export declare const countryBalancedRecipe: CorpusRecipe;
|
|
32
|
+
//# sourceMappingURL=country-balanced.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"country-balanced.d.ts","sourceRoot":"","sources":["../../lib/recipes/country-balanced.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AASH,OAAO,EAAgC,KAAK,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAmXnF;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,YAoGnC,CAAA"}
|
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* `country-balanced` slice recipe — the BALANCED, MODEL-FIRST country-coverage slice (#464). The
|
|
7
|
+
* shipped model is STARVED on `country` (P=R=F1=0 on the homograph eval), so this fills the void
|
|
8
|
+
* the way the `unit` slice did, but built to AVOID over-firing "trailing token ⇒ country". Three
|
|
9
|
+
* ingredients, ported faithfully from scripts/build-country-slice-balanced.mjs:
|
|
10
|
+
*
|
|
11
|
+
* 1. Breadth/recall — real OA skeletons (US/DE/FR/IT/NL) with a country token in a varied surface form
|
|
12
|
+
* from `@mailwoman/codex/country` (canonical / endonym / ISO code), + ~30% country-ABSENT
|
|
13
|
+
* negatives (teach O-emission, the precision floor).
|
|
14
|
+
* 2. Homograph CONTRAST pairs — each true country-name homograph (Georgia, Jordan, Lebanon, Mexico,
|
|
15
|
+
* Peru, Turkey) rendered BOTH ways: as `country` (foreign-city context) AND as the US
|
|
16
|
+
* `region`/`locality` (US-ZIP context). Teaches that the label is CONTEXTUAL, not
|
|
17
|
+
* positional.
|
|
18
|
+
* 3. Code-as-region negatives — 2-letter codes that are both a US state abbrev and an ISO country code
|
|
19
|
+
* (CA/GA/IN/MA/PA/AL) in US-ZIP context → must read as `region`, never `country`.
|
|
20
|
+
*
|
|
21
|
+
* `--golden` emits a held-out synthetic val over the VT (US) + Berlin (DE) holdouts. This is a
|
|
22
|
+
* `generate`-mode recipe that still reads REAL tuples off disk — `--count` bounds the OUTPUT, not
|
|
23
|
+
* the input. The passed `random` (the framework LCG) is consumed in the exact call order the
|
|
24
|
+
* legacy script used.
|
|
25
|
+
*/
|
|
26
|
+
import { COUNTRY_SURFACE_FORMS, CountryNames } from "@mailwoman/codex/country";
|
|
27
|
+
import { dataRootPath } from "@mailwoman/core/data-root";
|
|
28
|
+
import { isPresent } from "@mailwoman/core/objects";
|
|
29
|
+
import { stableSourceID } from "#adapters/utils";
|
|
30
|
+
import { makeMulberry32, readOATuples } from "#recipes/scaffold";
|
|
31
|
+
import { pick } from "#synthesizers/utils";
|
|
32
|
+
import { alignRow } from "#utils";
|
|
33
|
+
// v2: the country TOKEN is decoupled from the skeleton's locale and drawn from a BROAD pool — every
|
|
34
|
+
// ISO canonical name + every curated surface form (endonyms/abbrevs). Surface forms are over-weighted
|
|
35
|
+
// so endonyms/abbrevs ("Deutschland","USA","NL") get strong signal.
|
|
36
|
+
const COUNTRY_FORM_POOL = (() => {
|
|
37
|
+
const surface = Object.values(COUNTRY_SURFACE_FORMS).flat(); // endonyms + abbrevs + canonical (curated)
|
|
38
|
+
const names = [...CountryNames];
|
|
39
|
+
// all ~249 ISO canonical English names (breadth)
|
|
40
|
+
return { surface, names };
|
|
41
|
+
})();
|
|
42
|
+
/**
|
|
43
|
+
* Negatives: rows with NO country token → teach golden precision.
|
|
44
|
+
*/
|
|
45
|
+
const COUNTRY_ABSENT_PROB = 0.3;
|
|
46
|
+
/**
|
|
47
|
+
* Multi-locale OA sources. region = implied admin where the extract is single-region (US states, DE Saxony);
|
|
48
|
+
* countrywide extracts (FR/IT/NL) read region from the CSV when present.
|
|
49
|
+
*/
|
|
50
|
+
const SOURCES = [
|
|
51
|
+
{
|
|
52
|
+
zip: dataRootPath("oa-cache", "us__ia__statewide.zip"),
|
|
53
|
+
csv: "us/ia/statewide.csv",
|
|
54
|
+
iso2: "US",
|
|
55
|
+
region: "IA",
|
|
56
|
+
order: "us",
|
|
57
|
+
},
|
|
58
|
+
{ zip: dataRootPath("oa-cache", "us__il__cook.zip"), csv: "us/il/cook.csv", iso2: "US", region: "IL", order: "us" },
|
|
59
|
+
{
|
|
60
|
+
zip: dataRootPath("oa-cache", "us__mt__statewide.zip"),
|
|
61
|
+
csv: "us/mt/statewide.csv",
|
|
62
|
+
iso2: "US",
|
|
63
|
+
region: "MT",
|
|
64
|
+
order: "us",
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
zip: dataRootPath("oa-cache", "us__sd__statewide.zip"),
|
|
68
|
+
csv: "us/sd/statewide.csv",
|
|
69
|
+
iso2: "US",
|
|
70
|
+
region: "SD",
|
|
71
|
+
order: "us",
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
zip: dataRootPath("oa-cache", "de__sn__statewide.zip"),
|
|
75
|
+
csv: "de/sn/statewide.csv",
|
|
76
|
+
iso2: "DE",
|
|
77
|
+
region: "",
|
|
78
|
+
order: "eu",
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
zip: dataRootPath("oa-cache", "fr__countrywide.zip"),
|
|
82
|
+
csv: "fr/countrywide.csv",
|
|
83
|
+
iso2: "FR",
|
|
84
|
+
region: "",
|
|
85
|
+
order: "fr",
|
|
86
|
+
},
|
|
87
|
+
// ES uses the Spanish IGN schema, not the OA standard columns — skipped here (codex still recognizes
|
|
88
|
+
// "España"/"Spain"). A dedicated IGN adapter is a follow-up.
|
|
89
|
+
{
|
|
90
|
+
zip: dataRootPath("oa-cache", "it__countrywide.zip"),
|
|
91
|
+
csv: "it/countrywide.csv",
|
|
92
|
+
iso2: "IT",
|
|
93
|
+
region: "",
|
|
94
|
+
order: "eu",
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
zip: dataRootPath("oa-cache", "nl__countrywide.zip"),
|
|
98
|
+
csv: "nl/countrywide.csv",
|
|
99
|
+
iso2: "NL",
|
|
100
|
+
region: "",
|
|
101
|
+
order: "eu",
|
|
102
|
+
},
|
|
103
|
+
];
|
|
104
|
+
/**
|
|
105
|
+
* Held-out for --golden: Vermont (US holdout) + Berlin (DE holdout) — geographic split, never trained.
|
|
106
|
+
*/
|
|
107
|
+
const EVAL_SOURCES = [
|
|
108
|
+
{
|
|
109
|
+
zip: dataRootPath("oa-cache", "us__vt__statewide.zip"),
|
|
110
|
+
csv: "us/vt/statewide.csv",
|
|
111
|
+
iso2: "US",
|
|
112
|
+
region: "VT",
|
|
113
|
+
order: "us",
|
|
114
|
+
},
|
|
115
|
+
{ zip: dataRootPath("oa-cache", "de__berlin.zip"), csv: "de/berlin.csv", iso2: "DE", region: "", order: "eu" },
|
|
116
|
+
];
|
|
117
|
+
/**
|
|
118
|
+
* The countrywide extracts (FR/IT/NL) are GB-scale, so this reads only as far as `limit` distinct tuples: the `break`
|
|
119
|
+
* closes the reader, which releases the archive without inflating the rest of the member.
|
|
120
|
+
*/
|
|
121
|
+
async function readTuples(source, limit) {
|
|
122
|
+
return readOATuples(source, {
|
|
123
|
+
limit,
|
|
124
|
+
extra: (fields, row) => ({
|
|
125
|
+
...fields,
|
|
126
|
+
region: row.region || source.region,
|
|
127
|
+
iso2: source.iso2,
|
|
128
|
+
order: source.order,
|
|
129
|
+
}),
|
|
130
|
+
});
|
|
131
|
+
}
|
|
132
|
+
// After the absent draw: 60% curated surface forms (endonym/abbrev variety), 40% broad ISO canonical names.
|
|
133
|
+
const SURFACE_FORM_SHARE = 0.6;
|
|
134
|
+
/**
|
|
135
|
+
* Pick a country token from the BROAD pool, or null (a country-absent negative). v2.
|
|
136
|
+
*/
|
|
137
|
+
function pickCountry(random) {
|
|
138
|
+
if (random() < COUNTRY_ABSENT_PROB)
|
|
139
|
+
return null; // negative — teaches "trailing token != always country"
|
|
140
|
+
const pool = random() < SURFACE_FORM_SHARE ? COUNTRY_FORM_POOL.surface : COUNTRY_FORM_POOL.names;
|
|
141
|
+
return pick(pool, random);
|
|
142
|
+
}
|
|
143
|
+
// Country-bearing rows: 80% full, 12% full-nl, 8% bare.
|
|
144
|
+
const FULL_CUTOFF = 0.8;
|
|
145
|
+
const FULL_NEWLINE_CUTOFF = 0.92;
|
|
146
|
+
/**
|
|
147
|
+
* Render the address body in native-ish order. `country` null → a country-ABSENT negative row.
|
|
148
|
+
*/
|
|
149
|
+
function renderCountry(random, t, country) {
|
|
150
|
+
const { house_number: hn, street, locality: loc, region: reg, postcode: pc, order } = t;
|
|
151
|
+
const components = { house_number: hn, street, locality: loc };
|
|
152
|
+
if (reg) {
|
|
153
|
+
components.region = reg;
|
|
154
|
+
}
|
|
155
|
+
if (pc) {
|
|
156
|
+
components.postcode = pc;
|
|
157
|
+
}
|
|
158
|
+
let body;
|
|
159
|
+
if (order === "us") {
|
|
160
|
+
const regPc = [reg, pc].filter(isPresent).join(" ");
|
|
161
|
+
body = `${hn} ${street}, ${loc}${regPc ? ", " + regPc : ""}`;
|
|
162
|
+
}
|
|
163
|
+
else if (order === "fr") {
|
|
164
|
+
// French is NUMBER-street, postcode-city: "84 Route de la Fontaine, 75008 Paris".
|
|
165
|
+
body = `${hn} ${street}, ${[pc, loc].filter(isPresent).join(" ")}`;
|
|
166
|
+
}
|
|
167
|
+
else {
|
|
168
|
+
// DE/IT/NL: street-number, postcode-city: "Pariser Platz 1, 10117 Berlin".
|
|
169
|
+
const pcCity = [pc, loc].filter(isPresent).join(" ");
|
|
170
|
+
body = `${street} ${hn}, ${pcCity}`;
|
|
171
|
+
}
|
|
172
|
+
if (!country) {
|
|
173
|
+
// Negative: a normal address, NO country token/component. Teaches that a trailing region/city/
|
|
174
|
+
// postcode is NOT a country (counters the v1 golden over-firing).
|
|
175
|
+
return { fmt: "negative", raw: body, components };
|
|
176
|
+
}
|
|
177
|
+
const withC = { ...components, country };
|
|
178
|
+
const r = random();
|
|
179
|
+
if (r < FULL_CUTOFF)
|
|
180
|
+
return { fmt: "full", raw: `${body}, ${country}`, components: withC };
|
|
181
|
+
if (r < FULL_NEWLINE_CUTOFF)
|
|
182
|
+
return { fmt: "full-nl", raw: `${body}\n${country}`, components: withC };
|
|
183
|
+
const bareBody = order === "us" || order === "fr" ? `${hn} ${street}, ${loc}` : `${street} ${hn}, ${loc}`;
|
|
184
|
+
return {
|
|
185
|
+
fmt: "bare",
|
|
186
|
+
raw: `${bareBody}, ${country}`,
|
|
187
|
+
components: { house_number: hn, street, locality: loc, country },
|
|
188
|
+
};
|
|
189
|
+
}
|
|
190
|
+
const HOMOGRAPHS = [
|
|
191
|
+
{
|
|
192
|
+
surface: "Georgia",
|
|
193
|
+
iso2: "GE",
|
|
194
|
+
cities: ["Tbilisi", "Batumi", "Kutaisi", "Rustavi"],
|
|
195
|
+
us: { role: "region", locality: "Atlanta", region: "Georgia", postcodes: ["30309", "31401", "30601", "31201"] },
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
surface: "Jordan",
|
|
199
|
+
iso2: "JO",
|
|
200
|
+
cities: ["Amman", "Irbid", "Zarqa", "Aqaba"],
|
|
201
|
+
us: { role: "locality", locality: "Jordan", region: "MN", postcodes: ["55352"] },
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
surface: "Lebanon",
|
|
205
|
+
iso2: "LB",
|
|
206
|
+
cities: ["Beirut", "Tripoli", "Sidon", "Byblos"],
|
|
207
|
+
us: { role: "locality", locality: "Lebanon", region: "TN", postcodes: ["37087", "03766", "17042", "45036"] },
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
surface: "Mexico",
|
|
211
|
+
iso2: "MX",
|
|
212
|
+
cities: ["Guadalajara", "Monterrey", "Puebla", "Oaxaca"],
|
|
213
|
+
us: { role: "locality", locality: "Mexico", region: "MO", postcodes: ["65265"] },
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
surface: "Peru",
|
|
217
|
+
iso2: "PE",
|
|
218
|
+
cities: ["Cusco", "Arequipa", "Trujillo", "Iquitos"],
|
|
219
|
+
us: { role: "locality", locality: "Peru", region: "IL", postcodes: ["61354", "46970"] },
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
surface: "Turkey",
|
|
223
|
+
iso2: "TR",
|
|
224
|
+
cities: ["Ankara", "Izmir", "Bursa", "Antalya"],
|
|
225
|
+
us: { role: "locality", locality: "Turkey", region: "TX", postcodes: ["79261", "28393"] },
|
|
226
|
+
},
|
|
227
|
+
];
|
|
228
|
+
const ABBREV_REGIONS = [
|
|
229
|
+
{ code: "CA", localities: ["Los Angeles", "Sacramento", "San Diego"], postcodes: ["90012", "95814", "92101"] }, // California / Canada
|
|
230
|
+
{ code: "GA", localities: ["Atlanta", "Savannah", "Macon"], postcodes: ["30309", "31401", "31201"] }, // Georgia(US) / Georgia
|
|
231
|
+
{ code: "IN", localities: ["Indianapolis", "Fort Wayne"], postcodes: ["46204", "46802"] }, // Indiana / India
|
|
232
|
+
{ code: "MA", localities: ["Boston", "Worcester"], postcodes: ["02108", "01608"] }, // Massachusetts / Morocco
|
|
233
|
+
{ code: "PA", localities: ["Philadelphia", "Pittsburgh"], postcodes: ["19103", "15222"] }, // Pennsylvania / Panama
|
|
234
|
+
{ code: "AL", localities: ["Birmingham", "Montgomery"], postcodes: ["35203", "36104"] }, // Alabama / Albania
|
|
235
|
+
];
|
|
236
|
+
const STREET_POOL = [
|
|
237
|
+
"Main Street",
|
|
238
|
+
"Oak Avenue",
|
|
239
|
+
"Park Road",
|
|
240
|
+
"Elm Street",
|
|
241
|
+
"Hill Road",
|
|
242
|
+
"Market Street",
|
|
243
|
+
"Church Street",
|
|
244
|
+
"King Street",
|
|
245
|
+
"2nd Avenue",
|
|
246
|
+
"Maple Drive",
|
|
247
|
+
];
|
|
248
|
+
const houseNo = (random) => String(1 + Math.floor(random() * 998));
|
|
249
|
+
// Country-surface homograph rows: 60% carry a street line, 40% are a bare `city, surface`.
|
|
250
|
+
const HOMOGRAPH_WITH_STREET_SHARE = 0.6;
|
|
251
|
+
/**
|
|
252
|
+
* A homograph CONTRAST row: ~half render the surface as `country` (foreign city), half as the US `region`/`locality`
|
|
253
|
+
* (US ZIP, NO country). Returns iso2 for provenance.
|
|
254
|
+
*/
|
|
255
|
+
function renderHomograph(random) {
|
|
256
|
+
const h = pick(HOMOGRAPHS, random);
|
|
257
|
+
const hn = houseNo(random), street = pick(STREET_POOL, random);
|
|
258
|
+
if (random() < 0.5) {
|
|
259
|
+
const city = pick(h.cities, random);
|
|
260
|
+
const withStreet = random() < HOMOGRAPH_WITH_STREET_SHARE;
|
|
261
|
+
const raw = withStreet ? `${hn} ${street}, ${city}, ${h.surface}` : `${city}, ${h.surface}`;
|
|
262
|
+
const components = withStreet
|
|
263
|
+
? { house_number: hn, street, locality: city, country: h.surface }
|
|
264
|
+
: { locality: city, country: h.surface };
|
|
265
|
+
return { fmt: "homograph-country", raw, components, iso2: h.iso2 };
|
|
266
|
+
}
|
|
267
|
+
const pc = pick(h.us.postcodes, random);
|
|
268
|
+
if (h.us.role === "region") {
|
|
269
|
+
// surface is the US STATE: "123 Oak Ave, Atlanta, Georgia 30309" → region, no country
|
|
270
|
+
return {
|
|
271
|
+
fmt: "homograph-us-region",
|
|
272
|
+
raw: `${hn} ${street}, ${h.us.locality}, ${h.surface} ${pc}`,
|
|
273
|
+
components: { house_number: hn, street, locality: h.us.locality, region: h.surface, postcode: pc },
|
|
274
|
+
iso2: "US",
|
|
275
|
+
};
|
|
276
|
+
}
|
|
277
|
+
// surface is the US CITY: "123 Oak Ave, Lebanon, TN 37087" → locality, no country
|
|
278
|
+
return {
|
|
279
|
+
fmt: "homograph-us-locality",
|
|
280
|
+
raw: `${hn} ${street}, ${h.surface}, ${h.us.region} ${pc}`,
|
|
281
|
+
components: { house_number: hn, street, locality: h.surface, region: h.us.region, postcode: pc },
|
|
282
|
+
iso2: "US",
|
|
283
|
+
};
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* An abbrev-as-region negative: "123 Main St, Los Angeles, CA 90012" → region CA, NO country.
|
|
287
|
+
*/
|
|
288
|
+
function renderAbbrevRegion(random) {
|
|
289
|
+
const a = pick(ABBREV_REGIONS, random);
|
|
290
|
+
const hn = houseNo(random), street = pick(STREET_POOL, random), locality = pick(a.localities, random), postcode = pick(a.postcodes, random);
|
|
291
|
+
return {
|
|
292
|
+
fmt: "abbrev-region",
|
|
293
|
+
raw: `${hn} ${street}, ${locality}, ${a.code} ${postcode}`,
|
|
294
|
+
components: { house_number: hn, street, locality, region: a.code, postcode },
|
|
295
|
+
iso2: "US",
|
|
296
|
+
};
|
|
297
|
+
}
|
|
298
|
+
/**
|
|
299
|
+
* Share of rows that are homograph contrast pairs.
|
|
300
|
+
*/
|
|
301
|
+
const HOMOGRAPH_FRAC = 0.22;
|
|
302
|
+
/**
|
|
303
|
+
* Share that are code-as-region negatives (cumulative with HOMOGRAPH_FRAC)
|
|
304
|
+
*/
|
|
305
|
+
const ABBREV_FRAC = 0.08;
|
|
306
|
+
/**
|
|
307
|
+
* Slice recipe registered with the corpus builder — see the file header for the parse behaviour it exists to exercise,
|
|
308
|
+
* and `description` below for the surface form it generates.
|
|
309
|
+
*/
|
|
310
|
+
export const countryBalancedRecipe = {
|
|
311
|
+
name: "country-balanced",
|
|
312
|
+
description: "Balanced model-first country rows (#464): OA skeletons + ISO surface forms + homograph contrast pairs",
|
|
313
|
+
mode: "generate",
|
|
314
|
+
options: [{ flag: "--golden", description: "Emit the held-out VT+Berlin eval slice" }],
|
|
315
|
+
async run(opts, write) {
|
|
316
|
+
if (opts.count == null)
|
|
317
|
+
throw new Error("country-balanced recipe requires --count <N>");
|
|
318
|
+
const count = opts.count;
|
|
319
|
+
// Legacy build-country-slice-balanced.mjs seeded mulberry32 with the raw seed: `const random = mulberry32(opts.seed)`.
|
|
320
|
+
const random = makeMulberry32(opts.seed);
|
|
321
|
+
const source = opts.sourceName ?? "synth-country";
|
|
322
|
+
const sources = opts.golden ? EVAL_SOURCES : SOURCES;
|
|
323
|
+
const perSource = Math.ceil((count * 3) / sources.length); // over-read; balance locales
|
|
324
|
+
const pool = [];
|
|
325
|
+
for (const s of sources) {
|
|
326
|
+
const t = await readTuples(s, perSource);
|
|
327
|
+
console.error(` ${s.csv} (${s.iso2}): ${t.length} tuples`);
|
|
328
|
+
for (const x of t) {
|
|
329
|
+
pool.push(x);
|
|
330
|
+
}
|
|
331
|
+
}
|
|
332
|
+
if (!pool.length) {
|
|
333
|
+
throw new Error(`No tuples — are the cached OA zips present in ${dataRootPath("oa-cache")}?`);
|
|
334
|
+
}
|
|
335
|
+
let emitted = 0;
|
|
336
|
+
let skipped = 0;
|
|
337
|
+
let guard = 0;
|
|
338
|
+
const N = pool.length;
|
|
339
|
+
while (emitted < count && guard++ < count * 8) {
|
|
340
|
+
// Mix three row types: homograph contrast (the distinction), code-as-region negatives, and the
|
|
341
|
+
// breadth/recall main path (random ISO form on an OA skeleton, ~30% country-absent).
|
|
342
|
+
const roll = random();
|
|
343
|
+
let rendered;
|
|
344
|
+
let rowISO2;
|
|
345
|
+
if (roll < HOMOGRAPH_FRAC) {
|
|
346
|
+
const h = renderHomograph(random);
|
|
347
|
+
rendered = h;
|
|
348
|
+
rowISO2 = h.iso2;
|
|
349
|
+
}
|
|
350
|
+
else if (roll < HOMOGRAPH_FRAC + ABBREV_FRAC) {
|
|
351
|
+
const a = renderAbbrevRegion(random);
|
|
352
|
+
rendered = a;
|
|
353
|
+
rowISO2 = a.iso2;
|
|
354
|
+
}
|
|
355
|
+
else {
|
|
356
|
+
const t = pool[Math.floor(random() * N)];
|
|
357
|
+
const country = pickCountry(random); // may be null → a country-absent negative row
|
|
358
|
+
rendered = renderCountry(random, t, country);
|
|
359
|
+
rowISO2 = t.iso2;
|
|
360
|
+
if (country && !rendered.raw.includes(country)) {
|
|
361
|
+
skipped++;
|
|
362
|
+
continue;
|
|
363
|
+
}
|
|
364
|
+
}
|
|
365
|
+
const { raw, components } = rendered;
|
|
366
|
+
const localeTag = rowISO2 === "US" ? "en-US" : `${rowISO2.toLowerCase()}-${rowISO2}`;
|
|
367
|
+
if (opts.golden) {
|
|
368
|
+
write(JSON.stringify({ raw, components, country: rowISO2 }) + "\n");
|
|
369
|
+
emitted++;
|
|
370
|
+
continue;
|
|
371
|
+
}
|
|
372
|
+
const canonical = {
|
|
373
|
+
raw,
|
|
374
|
+
components,
|
|
375
|
+
country: rowISO2,
|
|
376
|
+
locale: localeTag,
|
|
377
|
+
source,
|
|
378
|
+
source_id: stableSourceID(source, components),
|
|
379
|
+
corpus_version: "0.4.0",
|
|
380
|
+
license: "OpenAddresses multi-locale skeletons + injected ISO-3166 country surface forms (codex)",
|
|
381
|
+
};
|
|
382
|
+
const aligned = alignRow(canonical);
|
|
383
|
+
if (aligned.kind !== "labeled" || !aligned.row) {
|
|
384
|
+
skipped++;
|
|
385
|
+
continue;
|
|
386
|
+
}
|
|
387
|
+
write(JSON.stringify({ ...aligned.row, synth_method: "country", synth_base_id: null }) + "\n");
|
|
388
|
+
emitted++;
|
|
389
|
+
}
|
|
390
|
+
return { emitted, skipped };
|
|
391
|
+
},
|
|
392
|
+
};
|
|
393
|
+
//# sourceMappingURL=country-balanced.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"country-balanced.js","sourceRoot":"","sources":["../../lib/recipes/country-balanced.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,qBAAqB,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;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OAAO,EAAE,CAAA;QACV,CAAC;QAED,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CAAA;IAC5B,CAAC;CACD,CAAA"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* `cz-pcfirst-preposition` — the Czech pc-first prepositional-locality slice, fourth orthography
|
|
7
|
+
* of the #901 leading-name-boundary family. The #897 close-out read all 8 residual CZ rows as one
|
|
8
|
+
* class: a LEADING postcode mis-assigned as house_number while the multi-word "nad/pod/u X"
|
|
9
|
+
* locality shatters ("51244 Rokytnice nad Jizerou, Dolní Rokytnice 111" → street
|
|
10
|
+
* 'RokytnicenadJizerou' + house_number '51244'). That leading-5-digit confusion is the
|
|
11
|
+
* anchor-pollution class whose decode-time OVERRIDE was correctly killed in #723 — this slice is
|
|
12
|
+
* the model-first fix as DATA: real prepositional localities in the order that breaks, so the
|
|
13
|
+
* model learns that a leading postcode before a multi-word name is a postcode. pc-first leads the
|
|
14
|
+
* cycle (the lesson); canonical and city-first keep the polarity balanced (the v1.9.9 lesson).
|
|
15
|
+
*/
|
|
16
|
+
import { type CorpusRecipe } from "#recipes/scaffold";
|
|
17
|
+
/**
|
|
18
|
+
* Slice recipe registered with the corpus builder — see the file header for the parse behaviour it exists to exercise,
|
|
19
|
+
* and `description` below for the surface form it generates.
|
|
20
|
+
*/
|
|
21
|
+
export declare const czPcFirstPrepositionRecipe: CorpusRecipe;
|
|
22
|
+
//# sourceMappingURL=cz-pcfirst-preposition.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cz-pcfirst-preposition.d.ts","sourceRoot":"","sources":["../../lib/recipes/cz-pcfirst-preposition.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAA6C,KAAK,YAAY,EAAiB,MAAM,mBAAmB,CAAA;AAS/G;;;GAGG;AACH,eAAO,MAAM,0BAA0B,EAAE,YAiFxC,CAAA"}
|