@mailwoman/corpus 9.3.0 → 10.0.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 +16 -0
- package/lib/adapters/geonames/adapter.ts +3 -3
- package/lib/adapters/geonames/postal/adapter.ts +122 -0
- package/lib/adapters/index.ts +39 -32
- package/lib/adapters/openaddresses/adapter.ts +4 -7
- package/lib/adapters/osm/adapter.ts +278 -0
- package/lib/adapters/overture/adapter.ts +22 -7
- package/lib/adapters/utils/index.ts +1 -1
- package/lib/adapters/wof/admin/json/adapter.ts +239 -0
- package/lib/adapters/wof/json-rows.ts +181 -0
- package/lib/adapters/wof/postalcode-json/adapter.ts +196 -0
- package/lib/au/adapters/gnaf/adapter.ts +152 -0
- package/lib/au/adapters/gnaf/assemble.ts +225 -0
- package/lib/cz/recipes/pcfirst-preposition.ts +112 -0
- package/lib/de/recipes/locale.ts +360 -0
- package/lib/fr/adapters/ban/adapter.ts +159 -0
- package/lib/fr/recipes/admin-split.ts +243 -0
- package/lib/fr/recipes/bare-street.ts +171 -0
- package/lib/fr/recipes/fragment.ts +334 -0
- package/lib/fr/recipes/lieudit.ts +274 -0
- package/lib/fr/recipes/order.ts +246 -0
- package/lib/fr/tools/fetch/ban.ts +289 -0
- package/lib/index.ts +1 -1
- package/lib/international/recipes/locale.ts +598 -0
- package/lib/jp/tools/fetch/houjin.ts +141 -0
- package/lib/kr/adapters/juso/label-rows.ts +259 -0
- package/lib/kr/adapters/localdata/align.ts +299 -0
- package/lib/kr/adapters/localdata/key-index.ts +185 -0
- package/lib/kr/adapters/localdata/permit-rows.ts +186 -0
- package/lib/kr/tools/fetch/juso.ts +172 -0
- package/lib/kr/tools/fetch/localdata.ts +206 -0
- package/lib/nl/recipes/postcode.ts +117 -0
- package/lib/no/recipes/fragment.ts +213 -0
- package/lib/no/recipes/street/index.ts +91 -0
- package/lib/no/recipes/street/led.ts +135 -0
- package/lib/recipes/anchor-absorption.ts +2 -2
- package/lib/recipes/bare/country.ts +95 -0
- package/lib/recipes/bare/postcode/eval.ts +99 -0
- package/lib/recipes/bare/postcode/index.ts +327 -0
- package/lib/recipes/boundary-stress.ts +3 -1
- package/lib/recipes/country-balanced.ts +3 -2
- package/lib/recipes/house-venue.ts +2 -1
- package/lib/recipes/index.ts +28 -21
- package/lib/recipes/intersection.ts +3 -2
- package/lib/recipes/po/box/cedex/au-nz.ts +82 -0
- package/lib/recipes/po/box/cedex/ca.ts +58 -0
- package/lib/recipes/po/box/cedex/fr.ts +76 -0
- package/lib/recipes/po/box/cedex/phrases.ts +108 -0
- package/lib/recipes/po/box/cedex/recipe.ts +203 -0
- package/lib/recipes/po/box/cedex/sources.ts +189 -0
- package/lib/recipes/po/box/cedex/types.ts +35 -0
- package/lib/recipes/po/box/cedex/us.ts +69 -0
- package/lib/recipes/po/box/cedex/vocabulary.ts +106 -0
- package/lib/recipes/po/box/cedex.ts +9 -0
- package/lib/recipes/po/box/index.ts +128 -0
- package/lib/recipes/scaffold.ts +18 -42
- package/lib/recipes/street/affix.ts +807 -0
- package/lib/recipes/street/bare.ts +102 -0
- package/lib/recipes/street.ts +3 -1
- package/lib/recipes/sub/venue/context.ts +149 -0
- package/lib/recipes/sub/venue/index.ts +997 -0
- package/lib/recipes/sub/venue/sources.ts +739 -0
- package/lib/recipes/trailing-region.ts +9 -9
- package/lib/recipes/unit.ts +3 -3
- package/lib/sg/recipes/register.ts +270 -0
- package/lib/sg/tools/fetch/acra.ts +179 -0
- package/lib/si/recipes/bare-village.ts +99 -0
- package/lib/south-asia/recipes/register.ts +214 -0
- package/lib/synthesizers/anchor-absorption.ts +1 -1
- package/lib/synthesizers/locale.ts +261 -0
- package/lib/synthesizers/street.ts +1 -1
- package/lib/synthesizers/utils.ts +2 -2
- package/lib/tools/audit.ts +3 -2
- package/lib/tools/corpus-stats.ts +3 -3
- package/lib/tools/fetch/download/index.ts +10 -0
- package/lib/tools/fetch/download/manifest.ts +102 -0
- package/lib/tools/fetch/download/network.ts +226 -0
- package/lib/tools/fetch/download/retry.ts +173 -0
- package/lib/tools/fetch/geonames/dump.ts +257 -0
- package/lib/tools/fetch/geonames/postal.ts +180 -0
- package/lib/tools/fetch/index.ts +47 -20
- package/lib/tools/fetch/openaddresses.ts +2 -2
- package/lib/tools/fetch/ourairports.ts +2 -2
- package/lib/tools/fetch/ppd.ts +1 -3
- package/lib/tools/fetch/wikidata-subvenue.ts +2 -2
- package/lib/tools/golden/promote.ts +340 -0
- package/lib/tools/golden/relabel-street/directory.ts +340 -0
- package/lib/tools/golden/relabel-street/index.ts +9 -0
- package/lib/tools/golden/relabel-street/row.ts +361 -0
- package/lib/tools/index.ts +10 -10
- package/lib/tools/ingest-csv.ts +5 -7
- package/lib/tools/lint/slice/vocab.ts +376 -0
- package/lib/tools/overlay-manifest.ts +92 -25
- package/lib/tools/overture-subvenue.ts +1 -1
- package/lib/tools/postcode-triples.ts +138 -14
- package/lib/tools/sub/venue/harvest.ts +234 -0
- package/lib/tools/sub/venue/head-nouns.ts +245 -0
- package/lib/tools/sub/venue/lexicon.ts +429 -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/tw/tools/fetch/gcis.ts +180 -0
- package/lib/types.ts +1 -1
- package/lib/us/adapters/fcc-bdc/adapter.ts +173 -0
- package/lib/us/adapters/state/hi-schools/adapter.ts +160 -0
- package/lib/us/adapters/state/ia-contractors/adapter.ts +136 -0
- package/lib/us/adapters/state/ny-notaries/adapter.ts +133 -0
- package/lib/us/adapters/state/tx-notaries/adapter.ts +149 -0
- package/lib/us/adapters/tiger/adapter.ts +250 -0
- package/lib/us/adapters/usgov/hrsa-fqhc/adapter.ts +156 -0
- package/lib/us/adapters/usgov/imls-pls/adapter.ts +134 -0
- package/lib/us/adapters/usgov/irs-bmf/adapter.ts +145 -0
- package/lib/us/adapters/usgov/nad/adapter.ts +324 -0
- package/lib/us/adapters/usgov/nppes/adapter.ts +143 -0
- package/lib/us/adapters/usgov/samhsa-treatment-locator/adapter.ts +182 -0
- package/lib/us/tools/fetch/hrsa.ts +59 -0
- package/lib/us/tools/fetch/imls-pls.ts +149 -0
- package/lib/us/tools/fetch/nad.ts +341 -0
- package/lib/us/tools/fetch/nppes.ts +165 -0
- package/lib/us/tools/fetch/state/hi-schools.ts +161 -0
- package/lib/us/tools/fetch/state/sources.ts +146 -0
- package/lib/us/tools/fetch/tiger-full.ts +308 -0
- package/lib/utils/align.ts +1 -1
- package/lib/utils/golden.ts +12 -8
- package/lib/utils/wof-json.ts +7 -13
- package/out/adapters/geonames/adapter.d.ts +1 -1
- package/out/adapters/geonames/adapter.js +3 -3
- package/out/adapters/geonames/adapter.js.map +1 -1
- 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/index.d.ts +16 -16
- package/out/adapters/index.d.ts.map +1 -1
- package/out/adapters/index.js +34 -32
- package/out/adapters/index.js.map +1 -1
- package/out/adapters/openaddresses/adapter.d.ts.map +1 -1
- package/out/adapters/openaddresses/adapter.js +4 -6
- package/out/adapters/openaddresses/adapter.js.map +1 -1
- package/out/adapters/osm/adapter.d.ts +95 -0
- package/out/adapters/osm/adapter.d.ts.map +1 -0
- package/out/adapters/osm/adapter.js +211 -0
- package/out/adapters/osm/adapter.js.map +1 -0
- package/out/adapters/overture/adapter.d.ts +10 -0
- package/out/adapters/overture/adapter.d.ts.map +1 -1
- package/out/adapters/overture/adapter.js +20 -7
- package/out/adapters/overture/adapter.js.map +1 -1
- package/out/adapters/synth-po-box/adapter.js.map +1 -1
- package/out/adapters/utils/index.d.ts +1 -1
- package/out/adapters/utils/index.d.ts.map +1 -1
- package/out/adapters/utils/index.js.map +1 -1
- 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 +204 -0
- package/out/adapters/wof/admin/json/adapter.js.map +1 -0
- package/out/adapters/wof/json-rows.d.ts +73 -0
- package/out/adapters/wof/json-rows.d.ts.map +1 -0
- package/out/adapters/wof/json-rows.js +115 -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 +167 -0
- package/out/adapters/wof/postalcode-json/adapter.js.map +1 -0
- package/out/au/adapters/gnaf/adapter.d.ts.map +1 -0
- package/out/au/adapters/gnaf/adapter.js +127 -0
- package/out/au/adapters/gnaf/adapter.js.map +1 -0
- package/out/au/adapters/gnaf/assemble.d.ts +65 -0
- package/out/au/adapters/gnaf/assemble.d.ts.map +1 -0
- package/out/au/adapters/gnaf/assemble.js +154 -0
- package/out/au/adapters/gnaf/assemble.js.map +1 -0
- package/out/cn/recipes/organizational-units.d.ts +36 -0
- package/out/cn/recipes/organizational-units.d.ts.map +1 -0
- package/out/cn/recipes/organizational-units.js +159 -0
- package/out/cn/recipes/organizational-units.js.map +1 -0
- package/out/cz/recipes/pcfirst-preposition.d.ts +22 -0
- package/out/cz/recipes/pcfirst-preposition.d.ts.map +1 -0
- package/out/cz/recipes/pcfirst-preposition.js +101 -0
- package/out/cz/recipes/pcfirst-preposition.js.map +1 -0
- package/out/de/recipes/locale.d.ts +44 -0
- package/out/de/recipes/locale.d.ts.map +1 -0
- package/out/de/recipes/locale.js +289 -0
- package/out/de/recipes/locale.js.map +1 -0
- package/out/env.d.ts +1 -1
- package/out/fr/adapters/ban/adapter.d.ts.map +1 -0
- package/out/fr/adapters/ban/adapter.js +123 -0
- package/out/fr/adapters/ban/adapter.js.map +1 -0
- package/out/fr/adapters/ban/street-decompose.d.ts.map +1 -0
- package/out/fr/adapters/ban/street-decompose.js.map +1 -0
- package/out/fr/recipes/admin-split.d.ts +38 -0
- package/out/fr/recipes/admin-split.d.ts.map +1 -0
- package/out/fr/recipes/admin-split.js +192 -0
- package/out/fr/recipes/admin-split.js.map +1 -0
- package/out/fr/recipes/bare-street.d.ts +28 -0
- package/out/fr/recipes/bare-street.d.ts.map +1 -0
- package/out/fr/recipes/bare-street.js +144 -0
- package/out/fr/recipes/bare-street.js.map +1 -0
- package/out/fr/recipes/fragment.d.ts +77 -0
- package/out/fr/recipes/fragment.d.ts.map +1 -0
- package/out/fr/recipes/fragment.js +277 -0
- package/out/fr/recipes/fragment.js.map +1 -0
- package/out/fr/recipes/lieudit.d.ts +32 -0
- package/out/fr/recipes/lieudit.d.ts.map +1 -0
- package/out/fr/recipes/lieudit.js +211 -0
- package/out/fr/recipes/lieudit.js.map +1 -0
- package/out/fr/recipes/order.d.ts +38 -0
- package/out/fr/recipes/order.d.ts.map +1 -0
- package/out/fr/recipes/order.js +198 -0
- package/out/fr/recipes/order.js.map +1 -0
- package/out/fr/tools/fetch/ban.d.ts +31 -0
- package/out/fr/tools/fetch/ban.d.ts.map +1 -0
- package/out/fr/tools/fetch/ban.js +239 -0
- package/out/fr/tools/fetch/ban.js.map +1 -0
- package/out/index.d.ts +1 -1
- package/out/index.d.ts.map +1 -1
- package/out/index.js +1 -1
- package/out/index.js.map +1 -1
- package/out/international/recipes/locale.d.ts +136 -0
- package/out/international/recipes/locale.d.ts.map +1 -0
- package/out/international/recipes/locale.js +458 -0
- package/out/international/recipes/locale.js.map +1 -0
- package/out/jp/adapters/wof-admin/adapter.d.ts.map +1 -0
- package/out/jp/adapters/wof-admin/adapter.js.map +1 -0
- package/out/jp/tools/fetch/houjin.d.ts +24 -0
- package/out/jp/tools/fetch/houjin.d.ts.map +1 -0
- package/out/jp/tools/fetch/houjin.js +102 -0
- package/out/jp/tools/fetch/houjin.js.map +1 -0
- package/out/kr/adapters/juso/label-rows.d.ts +76 -0
- package/out/kr/adapters/juso/label-rows.d.ts.map +1 -0
- package/out/kr/adapters/juso/label-rows.js +194 -0
- package/out/kr/adapters/juso/label-rows.js.map +1 -0
- package/out/kr/adapters/localdata/align.d.ts +43 -0
- package/out/kr/adapters/localdata/align.d.ts.map +1 -0
- package/out/kr/adapters/localdata/align.js +223 -0
- package/out/kr/adapters/localdata/align.js.map +1 -0
- package/out/kr/adapters/localdata/key-index.d.ts +71 -0
- package/out/kr/adapters/localdata/key-index.d.ts.map +1 -0
- package/out/kr/adapters/localdata/key-index.js +133 -0
- package/out/kr/adapters/localdata/key-index.js.map +1 -0
- package/out/kr/adapters/localdata/permit-rows.d.ts +66 -0
- package/out/kr/adapters/localdata/permit-rows.d.ts.map +1 -0
- package/out/kr/adapters/localdata/permit-rows.js +131 -0
- package/out/kr/adapters/localdata/permit-rows.js.map +1 -0
- package/out/kr/tools/fetch/juso.d.ts +30 -0
- package/out/kr/tools/fetch/juso.d.ts.map +1 -0
- package/out/kr/tools/fetch/juso.js +120 -0
- package/out/kr/tools/fetch/juso.js.map +1 -0
- package/out/kr/tools/fetch/localdata.d.ts +30 -0
- package/out/kr/tools/fetch/localdata.d.ts.map +1 -0
- package/out/kr/tools/fetch/localdata.js +139 -0
- package/out/kr/tools/fetch/localdata.js.map +1 -0
- package/out/nl/recipes/postcode.d.ts +26 -0
- package/out/nl/recipes/postcode.d.ts.map +1 -0
- package/out/nl/recipes/postcode.js +103 -0
- package/out/nl/recipes/postcode.js.map +1 -0
- package/out/no/recipes/fragment.d.ts +43 -0
- package/out/no/recipes/fragment.d.ts.map +1 -0
- package/out/no/recipes/fragment.js +183 -0
- package/out/no/recipes/fragment.js.map +1 -0
- package/out/no/recipes/street/index.d.ts +18 -0
- package/out/no/recipes/street/index.d.ts.map +1 -0
- package/out/no/recipes/street/index.js +72 -0
- package/out/no/recipes/street/index.js.map +1 -0
- package/out/no/recipes/street/led.d.ts +24 -0
- package/out/no/recipes/street/led.d.ts.map +1 -0
- package/out/no/recipes/street/led.js +114 -0
- package/out/no/recipes/street/led.js.map +1 -0
- package/out/recipes/anchor-absorption.d.ts.map +1 -1
- package/out/recipes/anchor-absorption.js +2 -1
- package/out/recipes/anchor-absorption.js.map +1 -1
- 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 +88 -0
- package/out/recipes/bare/country.js.map +1 -0
- package/out/recipes/bare/postcode/eval.d.ts +29 -0
- package/out/recipes/bare/postcode/eval.d.ts.map +1 -0
- package/out/recipes/bare/postcode/eval.js +85 -0
- package/out/recipes/bare/postcode/eval.js.map +1 -0
- package/out/recipes/bare/postcode/index.d.ts +62 -0
- package/out/recipes/bare/postcode/index.d.ts.map +1 -0
- package/out/recipes/bare/postcode/index.js +267 -0
- package/out/recipes/bare/postcode/index.js.map +1 -0
- package/out/recipes/boundary-stress.d.ts.map +1 -1
- package/out/recipes/boundary-stress.js +2 -1
- package/out/recipes/boundary-stress.js.map +1 -1
- package/out/recipes/country-balanced.d.ts.map +1 -1
- package/out/recipes/country-balanced.js +2 -1
- package/out/recipes/country-balanced.js.map +1 -1
- package/out/recipes/house-venue.d.ts.map +1 -1
- package/out/recipes/house-venue.js +2 -1
- package/out/recipes/house-venue.js.map +1 -1
- package/out/recipes/index.d.ts.map +1 -1
- package/out/recipes/index.js +28 -21
- package/out/recipes/index.js.map +1 -1
- package/out/recipes/intersection.d.ts.map +1 -1
- package/out/recipes/intersection.js +2 -1
- package/out/recipes/intersection.js.map +1 -1
- package/out/recipes/po/box/cedex/au-nz.d.ts +7 -0
- package/out/recipes/po/box/cedex/au-nz.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/au-nz.js +56 -0
- package/out/recipes/po/box/cedex/au-nz.js.map +1 -0
- package/out/recipes/po/box/cedex/ca.d.ts +7 -0
- package/out/recipes/po/box/cedex/ca.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/ca.js +38 -0
- package/out/recipes/po/box/cedex/ca.js.map +1 -0
- package/out/recipes/po/box/cedex/fr.d.ts +7 -0
- package/out/recipes/po/box/cedex/fr.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/fr.js +57 -0
- package/out/recipes/po/box/cedex/fr.js.map +1 -0
- package/out/recipes/po/box/cedex/phrases.d.ts +8 -0
- package/out/recipes/po/box/cedex/phrases.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/phrases.js +76 -0
- package/out/recipes/po/box/cedex/phrases.js.map +1 -0
- package/out/recipes/po/box/cedex/recipe.d.ts +9 -0
- package/out/recipes/po/box/cedex/recipe.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/recipe.js +153 -0
- package/out/recipes/po/box/cedex/recipe.js.map +1 -0
- package/out/recipes/po/box/cedex/sources.d.ts +86 -0
- package/out/recipes/po/box/cedex/sources.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/sources.js +143 -0
- package/out/recipes/po/box/cedex/sources.js.map +1 -0
- package/out/recipes/po/box/cedex/types.d.ts +31 -0
- package/out/recipes/po/box/cedex/types.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/types.js +5 -0
- package/out/recipes/po/box/cedex/types.js.map +1 -0
- package/out/recipes/po/box/cedex/us.d.ts +7 -0
- package/out/recipes/po/box/cedex/us.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/us.js +51 -0
- package/out/recipes/po/box/cedex/us.js.map +1 -0
- package/out/recipes/po/box/cedex/vocabulary.d.ts +68 -0
- package/out/recipes/po/box/cedex/vocabulary.d.ts.map +1 -0
- package/out/recipes/po/box/cedex/vocabulary.js +90 -0
- package/out/recipes/po/box/cedex/vocabulary.js.map +1 -0
- package/out/recipes/po/box/cedex.d.ts +9 -0
- package/out/recipes/po/box/cedex.d.ts.map +1 -0
- package/out/recipes/po/box/cedex.js +9 -0
- package/out/recipes/po/box/cedex.js.map +1 -0
- package/out/recipes/po/box/index.d.ts +17 -0
- package/out/recipes/po/box/index.d.ts.map +1 -0
- package/out/recipes/po/box/index.js +105 -0
- package/out/recipes/po/box/index.js.map +1 -0
- package/out/recipes/scaffold.d.ts +20 -1
- package/out/recipes/scaffold.d.ts.map +1 -1
- package/out/recipes/scaffold.js +18 -49
- package/out/recipes/scaffold.js.map +1 -1
- 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 +565 -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 +87 -0
- package/out/recipes/street/bare.js.map +1 -0
- package/out/recipes/street.d.ts.map +1 -1
- package/out/recipes/street.js +2 -1
- package/out/recipes/street.js.map +1 -1
- package/out/recipes/sub/venue/context.d.ts +29 -0
- package/out/recipes/sub/venue/context.d.ts.map +1 -0
- package/out/recipes/sub/venue/context.js +106 -0
- package/out/recipes/sub/venue/context.js.map +1 -0
- package/out/recipes/sub/venue/index.d.ts +270 -0
- package/out/recipes/sub/venue/index.d.ts.map +1 -0
- package/out/recipes/sub/venue/index.js +728 -0
- package/out/recipes/sub/venue/index.js.map +1 -0
- package/out/recipes/sub/venue/sources.d.ts +209 -0
- package/out/recipes/sub/venue/sources.d.ts.map +1 -0
- package/out/recipes/sub/venue/sources.js +555 -0
- package/out/recipes/sub/venue/sources.js.map +1 -0
- package/out/recipes/trailing-region.d.ts.map +1 -1
- package/out/recipes/trailing-region.js +8 -2
- package/out/recipes/trailing-region.js.map +1 -1
- package/out/recipes/unit.d.ts.map +1 -1
- package/out/recipes/unit.js +2 -1
- package/out/recipes/unit.js.map +1 -1
- package/out/sg/recipes/register.d.ts +69 -0
- package/out/sg/recipes/register.d.ts.map +1 -0
- package/out/sg/recipes/register.js +211 -0
- package/out/sg/recipes/register.js.map +1 -0
- package/out/sg/tools/fetch/acra.d.ts +23 -0
- package/out/sg/tools/fetch/acra.d.ts.map +1 -0
- package/out/sg/tools/fetch/acra.js +126 -0
- package/out/sg/tools/fetch/acra.js.map +1 -0
- package/out/si/recipes/bare-village.d.ts +32 -0
- package/out/si/recipes/bare-village.d.ts.map +1 -0
- package/out/si/recipes/bare-village.js +89 -0
- package/out/si/recipes/bare-village.js.map +1 -0
- package/out/south-asia/recipes/register.d.ts +51 -0
- package/out/south-asia/recipes/register.d.ts.map +1 -0
- package/out/south-asia/recipes/register.js +154 -0
- package/out/south-asia/recipes/register.js.map +1 -0
- package/out/synthesizers/anchor-absorption.d.ts +1 -1
- package/out/synthesizers/anchor-absorption.d.ts.map +1 -1
- package/out/synthesizers/anchor-absorption.js.map +1 -1
- package/out/synthesizers/boundary-stress.js.map +1 -1
- package/out/synthesizers/house-venue.js.map +1 -1
- package/out/synthesizers/intersection.js.map +1 -1
- package/out/synthesizers/locale.d.ts +116 -0
- package/out/synthesizers/locale.d.ts.map +1 -0
- package/out/synthesizers/locale.js +150 -0
- package/out/synthesizers/locale.js.map +1 -0
- package/out/synthesizers/no-street.d.ts.map +1 -1
- package/out/synthesizers/no-street.js.map +1 -1
- package/out/synthesizers/po-box.js.map +1 -1
- package/out/synthesizers/street.d.ts.map +1 -1
- package/out/synthesizers/street.js +1 -1
- package/out/synthesizers/street.js.map +1 -1
- package/out/synthesizers/utils.js +1 -1
- package/out/synthesizers/utils.js.map +1 -1
- package/out/test-kit/corpus-recipe.d.ts.map +1 -1
- package/out/test-kit/corpus-recipe.js.map +1 -1
- package/out/tools/audit.d.ts.map +1 -1
- package/out/tools/audit.js +3 -2
- package/out/tools/audit.js.map +1 -1
- package/out/tools/corpus-stats.js +3 -3
- package/out/tools/corpus-stats.js.map +1 -1
- package/out/tools/fetch/download/index.d.ts +10 -0
- package/out/tools/fetch/download/index.d.ts.map +1 -0
- package/out/tools/fetch/download/index.js +10 -0
- package/out/tools/fetch/download/index.js.map +1 -0
- package/out/tools/fetch/download/manifest.d.ts +47 -0
- package/out/tools/fetch/download/manifest.d.ts.map +1 -0
- package/out/tools/fetch/download/manifest.js +74 -0
- package/out/tools/fetch/download/manifest.js.map +1 -0
- package/out/tools/fetch/download/network.d.ts +105 -0
- package/out/tools/fetch/download/network.d.ts.map +1 -0
- package/out/tools/fetch/download/network.js +130 -0
- package/out/tools/fetch/download/network.js.map +1 -0
- package/out/tools/fetch/download/retry.d.ts +45 -0
- package/out/tools/fetch/download/retry.d.ts.map +1 -0
- package/out/tools/fetch/download/retry.js +136 -0
- package/out/tools/fetch/download/retry.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/index.d.ts +47 -20
- package/out/tools/fetch/index.d.ts.map +1 -1
- package/out/tools/fetch/index.js +47 -20
- package/out/tools/fetch/index.js.map +1 -1
- package/out/tools/fetch/openaddresses.d.ts +1 -1
- package/out/tools/fetch/openaddresses.d.ts.map +1 -1
- package/out/tools/fetch/openaddresses.js +1 -1
- package/out/tools/fetch/openaddresses.js.map +1 -1
- package/out/tools/fetch/ourairports.d.ts +1 -1
- package/out/tools/fetch/ourairports.d.ts.map +1 -1
- package/out/tools/fetch/ourairports.js +1 -1
- package/out/tools/fetch/ourairports.js.map +1 -1
- package/out/tools/fetch/ppd.js +1 -3
- package/out/tools/fetch/ppd.js.map +1 -1
- package/out/tools/fetch/wikidata-subvenue.d.ts +1 -1
- package/out/tools/fetch/wikidata-subvenue.d.ts.map +1 -1
- package/out/tools/fetch/wikidata-subvenue.js +1 -1
- package/out/tools/fetch/wikidata-subvenue.js.map +1 -1
- 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 +72 -0
- package/out/tools/golden/promote.d.ts.map +1 -0
- package/out/tools/golden/promote.js +243 -0
- package/out/tools/golden/promote.js.map +1 -0
- package/out/tools/golden/relabel-street/directory.d.ts +83 -0
- package/out/tools/golden/relabel-street/directory.d.ts.map +1 -0
- package/out/tools/golden/relabel-street/directory.js +216 -0
- package/out/tools/golden/relabel-street/directory.js.map +1 -0
- package/out/tools/golden/relabel-street/index.d.ts +9 -0
- package/out/tools/golden/relabel-street/index.d.ts.map +1 -0
- package/out/tools/golden/relabel-street/index.js +9 -0
- package/out/tools/golden/relabel-street/index.js.map +1 -0
- package/out/tools/golden/relabel-street/row.d.ts +121 -0
- package/out/tools/golden/relabel-street/row.d.ts.map +1 -0
- package/out/tools/golden/relabel-street/row.js +232 -0
- package/out/tools/golden/relabel-street/row.js.map +1 -0
- package/out/tools/index.d.ts +10 -10
- package/out/tools/index.d.ts.map +1 -1
- package/out/tools/index.js +10 -10
- package/out/tools/index.js.map +1 -1
- package/out/tools/ingest-csv.d.ts.map +1 -1
- package/out/tools/ingest-csv.js +5 -7
- package/out/tools/ingest-csv.js.map +1 -1
- package/out/tools/lint/slice/index.d.ts +93 -0
- package/out/tools/lint/slice/index.d.ts.map +1 -0
- package/out/tools/lint/slice/index.js +322 -0
- package/out/tools/lint/slice/index.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 +254 -0
- package/out/tools/lint/slice/vocab.js.map +1 -0
- package/out/tools/overlay-manifest.d.ts +56 -6
- package/out/tools/overlay-manifest.d.ts.map +1 -1
- package/out/tools/overlay-manifest.js +56 -15
- package/out/tools/overlay-manifest.js.map +1 -1
- package/out/tools/overture-subvenue.d.ts +1 -1
- package/out/tools/postcode-triples.d.ts +36 -0
- package/out/tools/postcode-triples.d.ts.map +1 -1
- package/out/tools/postcode-triples.js +91 -12
- package/out/tools/postcode-triples.js.map +1 -1
- 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.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/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.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.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/tw/tools/fetch/gcis.d.ts +23 -0
- package/out/tw/tools/fetch/gcis.d.ts.map +1 -0
- package/out/tw/tools/fetch/gcis.js +135 -0
- package/out/tw/tools/fetch/gcis.js.map +1 -0
- package/out/types.d.ts +1 -1
- package/out/types.d.ts.map +1 -1
- package/out/us/adapters/fcc-bdc/adapter.d.ts.map +1 -0
- package/out/us/adapters/fcc-bdc/adapter.js +142 -0
- package/out/us/adapters/fcc-bdc/adapter.js.map +1 -0
- package/out/us/adapters/state/hi-schools/adapter.d.ts.map +1 -0
- package/out/us/adapters/state/hi-schools/adapter.js +136 -0
- package/out/us/adapters/state/hi-schools/adapter.js.map +1 -0
- package/out/us/adapters/state/hi-schools/workbook.d.ts.map +1 -0
- package/out/us/adapters/state/hi-schools/workbook.js.map +1 -0
- package/out/us/adapters/state/ia-contractors/adapter.d.ts.map +1 -0
- package/out/us/adapters/state/ia-contractors/adapter.js +104 -0
- package/out/us/adapters/state/ia-contractors/adapter.js.map +1 -0
- package/out/us/adapters/state/ny-notaries/adapter.d.ts.map +1 -0
- package/out/us/adapters/state/ny-notaries/adapter.js +112 -0
- package/out/us/adapters/state/ny-notaries/adapter.js.map +1 -0
- package/out/us/adapters/state/tx-notaries/adapter.d.ts.map +1 -0
- package/out/us/adapters/state/tx-notaries/adapter.js +118 -0
- package/out/us/adapters/state/tx-notaries/adapter.js.map +1 -0
- package/out/us/adapters/tiger/adapter.d.ts +55 -0
- package/out/us/adapters/tiger/adapter.d.ts.map +1 -0
- package/out/us/adapters/tiger/adapter.js +197 -0
- package/out/us/adapters/tiger/adapter.js.map +1 -0
- package/out/us/adapters/tiger/street-decompose.d.ts.map +1 -0
- package/out/us/adapters/tiger/street-decompose.js.map +1 -0
- package/out/us/adapters/usgov/hrsa-fqhc/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/hrsa-fqhc/adapter.js +121 -0
- package/out/us/adapters/usgov/hrsa-fqhc/adapter.js.map +1 -0
- package/out/us/adapters/usgov/imls-pls/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/imls-pls/adapter.js +106 -0
- package/out/us/adapters/usgov/imls-pls/adapter.js.map +1 -0
- package/out/us/adapters/usgov/irs-bmf/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/irs-bmf/adapter.js +116 -0
- package/out/us/adapters/usgov/irs-bmf/adapter.js.map +1 -0
- package/out/us/adapters/usgov/nad/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/nad/adapter.js +239 -0
- package/out/us/adapters/usgov/nad/adapter.js.map +1 -0
- package/out/us/adapters/usgov/nppes/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/nppes/adapter.js +110 -0
- package/out/us/adapters/usgov/nppes/adapter.js.map +1 -0
- package/out/us/adapters/usgov/samhsa-treatment-locator/adapter.d.ts.map +1 -0
- package/out/us/adapters/usgov/samhsa-treatment-locator/adapter.js +143 -0
- package/out/us/adapters/usgov/samhsa-treatment-locator/adapter.js.map +1 -0
- package/out/us/fips-state.d.ts +41 -0
- package/out/us/fips-state.d.ts.map +1 -0
- package/out/us/fips-state.js +100 -0
- package/out/us/fips-state.js.map +1 -0
- package/out/us/tools/fetch/hrsa.d.ts +18 -0
- package/out/us/tools/fetch/hrsa.d.ts.map +1 -0
- package/out/us/tools/fetch/hrsa.js +46 -0
- package/out/us/tools/fetch/hrsa.js.map +1 -0
- package/out/us/tools/fetch/imls-pls.d.ts +25 -0
- package/out/us/tools/fetch/imls-pls.d.ts.map +1 -0
- package/out/us/tools/fetch/imls-pls.js +108 -0
- package/out/us/tools/fetch/imls-pls.js.map +1 -0
- package/out/us/tools/fetch/nad.d.ts +70 -0
- package/out/us/tools/fetch/nad.d.ts.map +1 -0
- package/out/us/tools/fetch/nad.js +234 -0
- package/out/us/tools/fetch/nad.js.map +1 -0
- package/out/us/tools/fetch/nppes.d.ts +26 -0
- package/out/us/tools/fetch/nppes.d.ts.map +1 -0
- package/out/us/tools/fetch/nppes.js +126 -0
- package/out/us/tools/fetch/nppes.js.map +1 -0
- package/out/us/tools/fetch/state/hi-schools.d.ts +26 -0
- package/out/us/tools/fetch/state/hi-schools.d.ts.map +1 -0
- package/out/us/tools/fetch/state/hi-schools.js +112 -0
- package/out/us/tools/fetch/state/hi-schools.js.map +1 -0
- package/out/us/tools/fetch/state/sources.d.ts +26 -0
- package/out/us/tools/fetch/state/sources.d.ts.map +1 -0
- package/out/us/tools/fetch/state/sources.js +111 -0
- package/out/us/tools/fetch/state/sources.js.map +1 -0
- package/out/us/tools/fetch/tiger-full.d.ts +22 -0
- package/out/us/tools/fetch/tiger-full.d.ts.map +1 -0
- package/out/us/tools/fetch/tiger-full.js +217 -0
- package/out/us/tools/fetch/tiger-full.js.map +1 -0
- package/out/utils/align.d.ts +1 -1
- package/out/utils/align.d.ts.map +1 -1
- package/out/utils/align.js.map +1 -1
- package/out/utils/golden.d.ts +7 -3
- package/out/utils/golden.d.ts.map +1 -1
- package/out/utils/golden.js +12 -8
- package/out/utils/golden.js.map +1 -1
- package/out/utils/parquet.d.ts.map +1 -1
- package/out/utils/split.js.map +1 -1
- package/out/utils/wof-json.d.ts.map +1 -1
- package/out/utils/wof-json.js +7 -12
- package/out/utils/wof-json.js.map +1 -1
- package/out/ve/recipes/reviewed-postcode-tail.d.ts.map +1 -0
- package/out/ve/recipes/reviewed-postcode-tail.js.map +1 -0
- package/package.json +196 -46
- package/lib/adapters/ban/adapter.ts +0 -190
- package/lib/adapters/fcc-bdc/adapter.ts +0 -174
- package/lib/adapters/geonames-postal/adapter.ts +0 -122
- package/lib/adapters/gnaf/adapter.ts +0 -149
- package/lib/adapters/gnaf/assemble.ts +0 -225
- package/lib/adapters/state-hi-schools/adapter.ts +0 -170
- package/lib/adapters/state-ia-contractors/adapter.ts +0 -144
- package/lib/adapters/state-ny-notaries/adapter.ts +0 -141
- package/lib/adapters/state-tx-notaries/adapter.ts +0 -157
- package/lib/adapters/tiger/adapter.ts +0 -252
- package/lib/adapters/usgov-hrsa-fqhc/adapter.ts +0 -167
- package/lib/adapters/usgov-imls-pls/adapter.ts +0 -143
- package/lib/adapters/usgov-irs-bmf/adapter.ts +0 -151
- package/lib/adapters/usgov-nad/adapter.ts +0 -334
- package/lib/adapters/usgov-nppes/adapter.ts +0 -151
- package/lib/adapters/usgov-samhsa-treatment-locator/adapter.ts +0 -193
- package/lib/adapters/wof-admin-json/adapter.ts +0 -231
- package/lib/adapters/wof-json-rows.ts +0 -129
- package/lib/adapters/wof-postalcode-json/adapter.ts +0 -176
- package/lib/name-prone-us-suffixes.ts +0 -12
- package/lib/recipes/bare-country.ts +0 -95
- package/lib/recipes/cz-pcfirst-preposition.ts +0 -111
- package/lib/recipes/fr-admin-split.ts +0 -242
- package/lib/recipes/fr-bare-street.ts +0 -170
- package/lib/recipes/fr-fragment.ts +0 -333
- package/lib/recipes/fr-lieudit.ts +0 -301
- package/lib/recipes/fr-order.ts +0 -245
- package/lib/recipes/german.ts +0 -359
- package/lib/recipes/locale.ts +0 -599
- package/lib/recipes/nl-postcode.ts +0 -115
- package/lib/recipes/no-fragment.ts +0 -219
- package/lib/recipes/no-street-led.ts +0 -141
- package/lib/recipes/no-street.ts +0 -90
- package/lib/recipes/po-box-cedex.ts +0 -976
- package/lib/recipes/po-box.ts +0 -123
- package/lib/recipes/si-bare-village.ts +0 -97
- package/lib/recipes/street-affix.ts +0 -804
- package/lib/recipes/street-bare.ts +0 -100
- package/lib/recipes/sub-venue-sources.ts +0 -877
- package/lib/recipes/sub-venue.ts +0 -997
- package/lib/synthesizers/german.ts +0 -260
- package/lib/tools/fetch/ban.ts +0 -289
- package/lib/tools/fetch/download.ts +0 -262
- package/lib/tools/fetch/geonames-dump.ts +0 -257
- package/lib/tools/fetch/geonames-postal.ts +0 -180
- package/lib/tools/fetch/hrsa.ts +0 -59
- package/lib/tools/fetch/imls-pls.ts +0 -149
- package/lib/tools/fetch/nad.ts +0 -341
- package/lib/tools/fetch/nppes.ts +0 -165
- package/lib/tools/fetch/state-hi-schools.ts +0 -161
- package/lib/tools/fetch/state-sources.ts +0 -146
- package/lib/tools/fetch/tiger-full.ts +0 -308
- package/lib/tools/golden-promote.ts +0 -337
- package/lib/tools/golden-relabel-street.ts +0 -683
- package/lib/tools/lint-slice-vocab.ts +0 -388
- package/lib/tools/sub-venue/harvest.ts +0 -234
- package/lib/tools/sub-venue/head-nouns.ts +0 -245
- package/lib/tools/sub-venue/surfaces.ts +0 -95
- package/lib/tools/sub-venue/table.ts +0 -281
- package/lib/tools/sub-venue/wikidata.ts +0 -85
- package/lib/tools/sub-venue-lexicon.ts +0 -429
- package/out/adapters/ban/adapter.d.ts.map +0 -1
- package/out/adapters/ban/adapter.js +0 -149
- package/out/adapters/ban/adapter.js.map +0 -1
- package/out/adapters/ban/street-decompose.d.ts.map +0 -1
- package/out/adapters/ban/street-decompose.js.map +0 -1
- package/out/adapters/fcc-bdc/adapter.d.ts.map +0 -1
- package/out/adapters/fcc-bdc/adapter.js +0 -144
- package/out/adapters/fcc-bdc/adapter.js.map +0 -1
- package/out/adapters/geonames-postal/adapter.d.ts.map +0 -1
- package/out/adapters/geonames-postal/adapter.js +0 -107
- package/out/adapters/geonames-postal/adapter.js.map +0 -1
- package/out/adapters/gnaf/adapter.d.ts.map +0 -1
- package/out/adapters/gnaf/adapter.js +0 -124
- package/out/adapters/gnaf/adapter.js.map +0 -1
- package/out/adapters/gnaf/assemble.d.ts +0 -65
- package/out/adapters/gnaf/assemble.d.ts.map +0 -1
- package/out/adapters/gnaf/assemble.js +0 -154
- package/out/adapters/gnaf/assemble.js.map +0 -1
- package/out/adapters/state-hi-schools/adapter.d.ts.map +0 -1
- package/out/adapters/state-hi-schools/adapter.js +0 -145
- package/out/adapters/state-hi-schools/adapter.js.map +0 -1
- package/out/adapters/state-hi-schools/workbook.d.ts.map +0 -1
- package/out/adapters/state-hi-schools/workbook.js.map +0 -1
- package/out/adapters/state-ia-contractors/adapter.d.ts.map +0 -1
- package/out/adapters/state-ia-contractors/adapter.js +0 -111
- package/out/adapters/state-ia-contractors/adapter.js.map +0 -1
- package/out/adapters/state-ny-notaries/adapter.d.ts.map +0 -1
- package/out/adapters/state-ny-notaries/adapter.js +0 -119
- package/out/adapters/state-ny-notaries/adapter.js.map +0 -1
- package/out/adapters/state-tx-notaries/adapter.d.ts.map +0 -1
- package/out/adapters/state-tx-notaries/adapter.js +0 -125
- package/out/adapters/state-tx-notaries/adapter.js.map +0 -1
- package/out/adapters/tiger/adapter.d.ts +0 -55
- package/out/adapters/tiger/adapter.d.ts.map +0 -1
- package/out/adapters/tiger/adapter.js +0 -201
- package/out/adapters/tiger/adapter.js.map +0 -1
- package/out/adapters/tiger/street-decompose.d.ts.map +0 -1
- package/out/adapters/tiger/street-decompose.js.map +0 -1
- package/out/adapters/usgov-hrsa-fqhc/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-hrsa-fqhc/adapter.js +0 -132
- package/out/adapters/usgov-hrsa-fqhc/adapter.js.map +0 -1
- package/out/adapters/usgov-imls-pls/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-imls-pls/adapter.js +0 -114
- package/out/adapters/usgov-imls-pls/adapter.js.map +0 -1
- package/out/adapters/usgov-irs-bmf/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-irs-bmf/adapter.js +0 -120
- package/out/adapters/usgov-irs-bmf/adapter.js.map +0 -1
- package/out/adapters/usgov-nad/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-nad/adapter.js +0 -249
- package/out/adapters/usgov-nad/adapter.js.map +0 -1
- package/out/adapters/usgov-nppes/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-nppes/adapter.js +0 -118
- package/out/adapters/usgov-nppes/adapter.js.map +0 -1
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.d.ts.map +0 -1
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.js +0 -154
- package/out/adapters/usgov-samhsa-treatment-locator/adapter.js.map +0 -1
- package/out/adapters/wof-admin-jp/adapter.d.ts.map +0 -1
- package/out/adapters/wof-admin-jp/adapter.js.map +0 -1
- package/out/adapters/wof-admin-json/adapter.d.ts +0 -79
- package/out/adapters/wof-admin-json/adapter.d.ts.map +0 -1
- package/out/adapters/wof-admin-json/adapter.js +0 -197
- package/out/adapters/wof-admin-json/adapter.js.map +0 -1
- package/out/adapters/wof-json-rows.d.ts +0 -62
- package/out/adapters/wof-json-rows.d.ts.map +0 -1
- package/out/adapters/wof-json-rows.js +0 -83
- package/out/adapters/wof-json-rows.js.map +0 -1
- package/out/adapters/wof-postalcode-json/adapter.d.ts +0 -65
- package/out/adapters/wof-postalcode-json/adapter.d.ts.map +0 -1
- package/out/adapters/wof-postalcode-json/adapter.js +0 -151
- package/out/adapters/wof-postalcode-json/adapter.js.map +0 -1
- package/out/codex/us-fips-state.d.ts +0 -41
- package/out/codex/us-fips-state.d.ts.map +0 -1
- package/out/codex/us-fips-state.js +0 -100
- package/out/codex/us-fips-state.js.map +0 -1
- package/out/name-prone-us-suffixes.d.ts +0 -12
- package/out/name-prone-us-suffixes.d.ts.map +0 -1
- package/out/name-prone-us-suffixes.js +0 -12
- package/out/name-prone-us-suffixes.js.map +0 -1
- package/out/recipes/bare-country.d.ts +0 -25
- package/out/recipes/bare-country.d.ts.map +0 -1
- package/out/recipes/bare-country.js +0 -87
- package/out/recipes/bare-country.js.map +0 -1
- package/out/recipes/cn-organizational-units.d.ts +0 -36
- package/out/recipes/cn-organizational-units.d.ts.map +0 -1
- package/out/recipes/cn-organizational-units.js +0 -159
- package/out/recipes/cn-organizational-units.js.map +0 -1
- package/out/recipes/cz-pcfirst-preposition.d.ts +0 -22
- package/out/recipes/cz-pcfirst-preposition.d.ts.map +0 -1
- package/out/recipes/cz-pcfirst-preposition.js +0 -100
- package/out/recipes/cz-pcfirst-preposition.js.map +0 -1
- package/out/recipes/fr-admin-split.d.ts +0 -38
- package/out/recipes/fr-admin-split.d.ts.map +0 -1
- package/out/recipes/fr-admin-split.js +0 -192
- package/out/recipes/fr-admin-split.js.map +0 -1
- package/out/recipes/fr-bare-street.d.ts +0 -28
- package/out/recipes/fr-bare-street.d.ts.map +0 -1
- package/out/recipes/fr-bare-street.js +0 -143
- package/out/recipes/fr-bare-street.js.map +0 -1
- package/out/recipes/fr-fragment.d.ts +0 -77
- package/out/recipes/fr-fragment.d.ts.map +0 -1
- package/out/recipes/fr-fragment.js +0 -276
- package/out/recipes/fr-fragment.js.map +0 -1
- package/out/recipes/fr-lieudit.d.ts +0 -32
- package/out/recipes/fr-lieudit.d.ts.map +0 -1
- package/out/recipes/fr-lieudit.js +0 -227
- package/out/recipes/fr-lieudit.js.map +0 -1
- package/out/recipes/fr-order.d.ts +0 -38
- package/out/recipes/fr-order.d.ts.map +0 -1
- package/out/recipes/fr-order.js +0 -197
- package/out/recipes/fr-order.js.map +0 -1
- package/out/recipes/german.d.ts +0 -44
- package/out/recipes/german.d.ts.map +0 -1
- package/out/recipes/german.js +0 -288
- package/out/recipes/german.js.map +0 -1
- package/out/recipes/locale.d.ts +0 -136
- package/out/recipes/locale.d.ts.map +0 -1
- package/out/recipes/locale.js +0 -460
- package/out/recipes/locale.js.map +0 -1
- package/out/recipes/nl-postcode.d.ts +0 -26
- package/out/recipes/nl-postcode.d.ts.map +0 -1
- package/out/recipes/nl-postcode.js +0 -102
- package/out/recipes/nl-postcode.js.map +0 -1
- package/out/recipes/no-fragment.d.ts +0 -43
- package/out/recipes/no-fragment.d.ts.map +0 -1
- package/out/recipes/no-fragment.js +0 -182
- package/out/recipes/no-fragment.js.map +0 -1
- package/out/recipes/no-street-led.d.ts +0 -24
- package/out/recipes/no-street-led.d.ts.map +0 -1
- package/out/recipes/no-street-led.js +0 -113
- package/out/recipes/no-street-led.js.map +0 -1
- package/out/recipes/no-street.d.ts +0 -18
- package/out/recipes/no-street.d.ts.map +0 -1
- package/out/recipes/no-street.js +0 -71
- package/out/recipes/no-street.js.map +0 -1
- package/out/recipes/po-box-cedex.d.ts +0 -38
- package/out/recipes/po-box-cedex.d.ts.map +0 -1
- package/out/recipes/po-box-cedex.js +0 -767
- package/out/recipes/po-box-cedex.js.map +0 -1
- package/out/recipes/po-box.d.ts +0 -17
- package/out/recipes/po-box.d.ts.map +0 -1
- package/out/recipes/po-box.js +0 -100
- package/out/recipes/po-box.js.map +0 -1
- package/out/recipes/reviewed-postcode-tail.d.ts.map +0 -1
- package/out/recipes/reviewed-postcode-tail.js.map +0 -1
- package/out/recipes/si-bare-village.d.ts +0 -32
- package/out/recipes/si-bare-village.d.ts.map +0 -1
- package/out/recipes/si-bare-village.js +0 -88
- package/out/recipes/si-bare-village.js.map +0 -1
- package/out/recipes/street-affix.d.ts +0 -89
- package/out/recipes/street-affix.d.ts.map +0 -1
- package/out/recipes/street-affix.js +0 -563
- package/out/recipes/street-affix.js.map +0 -1
- package/out/recipes/street-bare.d.ts +0 -25
- package/out/recipes/street-bare.d.ts.map +0 -1
- package/out/recipes/street-bare.js +0 -86
- package/out/recipes/street-bare.js.map +0 -1
- package/out/recipes/sub-venue-sources.d.ts +0 -229
- package/out/recipes/sub-venue-sources.d.ts.map +0 -1
- package/out/recipes/sub-venue-sources.js +0 -653
- package/out/recipes/sub-venue-sources.js.map +0 -1
- package/out/recipes/sub-venue.d.ts +0 -269
- package/out/recipes/sub-venue.d.ts.map +0 -1
- package/out/recipes/sub-venue.js +0 -725
- package/out/recipes/sub-venue.js.map +0 -1
- package/out/synthesizers/german.d.ts +0 -115
- package/out/synthesizers/german.d.ts.map +0 -1
- package/out/synthesizers/german.js +0 -149
- package/out/synthesizers/german.js.map +0 -1
- package/out/tools/fetch/ban.d.ts +0 -31
- package/out/tools/fetch/ban.d.ts.map +0 -1
- package/out/tools/fetch/ban.js +0 -239
- package/out/tools/fetch/ban.js.map +0 -1
- package/out/tools/fetch/download.d.ts +0 -117
- package/out/tools/fetch/download.d.ts.map +0 -1
- package/out/tools/fetch/download.js +0 -160
- package/out/tools/fetch/download.js.map +0 -1
- package/out/tools/fetch/geonames-dump.d.ts +0 -91
- package/out/tools/fetch/geonames-dump.d.ts.map +0 -1
- package/out/tools/fetch/geonames-dump.js +0 -171
- package/out/tools/fetch/geonames-dump.js.map +0 -1
- package/out/tools/fetch/geonames-postal.d.ts +0 -76
- package/out/tools/fetch/geonames-postal.d.ts.map +0 -1
- package/out/tools/fetch/geonames-postal.js +0 -126
- package/out/tools/fetch/geonames-postal.js.map +0 -1
- package/out/tools/fetch/hrsa.d.ts +0 -18
- package/out/tools/fetch/hrsa.d.ts.map +0 -1
- package/out/tools/fetch/hrsa.js +0 -46
- package/out/tools/fetch/hrsa.js.map +0 -1
- package/out/tools/fetch/imls-pls.d.ts +0 -25
- package/out/tools/fetch/imls-pls.d.ts.map +0 -1
- package/out/tools/fetch/imls-pls.js +0 -108
- package/out/tools/fetch/imls-pls.js.map +0 -1
- package/out/tools/fetch/nad.d.ts +0 -70
- package/out/tools/fetch/nad.d.ts.map +0 -1
- package/out/tools/fetch/nad.js +0 -234
- package/out/tools/fetch/nad.js.map +0 -1
- package/out/tools/fetch/nppes.d.ts +0 -26
- package/out/tools/fetch/nppes.d.ts.map +0 -1
- package/out/tools/fetch/nppes.js +0 -126
- package/out/tools/fetch/nppes.js.map +0 -1
- package/out/tools/fetch/state-hi-schools.d.ts +0 -26
- package/out/tools/fetch/state-hi-schools.d.ts.map +0 -1
- package/out/tools/fetch/state-hi-schools.js +0 -112
- package/out/tools/fetch/state-hi-schools.js.map +0 -1
- package/out/tools/fetch/state-sources.d.ts +0 -26
- package/out/tools/fetch/state-sources.d.ts.map +0 -1
- package/out/tools/fetch/state-sources.js +0 -111
- package/out/tools/fetch/state-sources.js.map +0 -1
- package/out/tools/fetch/tiger-full.d.ts +0 -22
- package/out/tools/fetch/tiger-full.d.ts.map +0 -1
- package/out/tools/fetch/tiger-full.js +0 -217
- package/out/tools/fetch/tiger-full.js.map +0 -1
- package/out/tools/golden-expand.d.ts +0 -90
- package/out/tools/golden-expand.d.ts.map +0 -1
- package/out/tools/golden-expand.js +0 -406
- package/out/tools/golden-expand.js.map +0 -1
- package/out/tools/golden-promote.d.ts +0 -72
- package/out/tools/golden-promote.d.ts.map +0 -1
- package/out/tools/golden-promote.js +0 -240
- package/out/tools/golden-promote.js.map +0 -1
- package/out/tools/golden-relabel-street.d.ts +0 -196
- package/out/tools/golden-relabel-street.d.ts.map +0 -1
- package/out/tools/golden-relabel-street.js +0 -440
- package/out/tools/golden-relabel-street.js.map +0 -1
- package/out/tools/lint-slice-vocab.d.ts +0 -90
- package/out/tools/lint-slice-vocab.d.ts.map +0 -1
- package/out/tools/lint-slice-vocab.js +0 -267
- package/out/tools/lint-slice-vocab.js.map +0 -1
- package/out/tools/lint-slice.d.ts +0 -93
- package/out/tools/lint-slice.d.ts.map +0 -1
- package/out/tools/lint-slice.js +0 -322
- package/out/tools/lint-slice.js.map +0 -1
- package/out/tools/slice-kryptonite.d.ts +0 -32
- package/out/tools/slice-kryptonite.d.ts.map +0 -1
- package/out/tools/slice-kryptonite.js +0 -99
- package/out/tools/slice-kryptonite.js.map +0 -1
- package/out/tools/slice-translit.d.ts +0 -51
- package/out/tools/slice-translit.d.ts.map +0 -1
- package/out/tools/slice-translit.js +0 -166
- package/out/tools/slice-translit.js.map +0 -1
- package/out/tools/sub-venue/harvest.d.ts +0 -100
- package/out/tools/sub-venue/harvest.d.ts.map +0 -1
- package/out/tools/sub-venue/harvest.js +0 -168
- package/out/tools/sub-venue/harvest.js.map +0 -1
- package/out/tools/sub-venue/head-nouns.d.ts +0 -50
- package/out/tools/sub-venue/head-nouns.d.ts.map +0 -1
- package/out/tools/sub-venue/head-nouns.js.map +0 -1
- package/out/tools/sub-venue/surfaces.d.ts +0 -45
- package/out/tools/sub-venue/surfaces.d.ts.map +0 -1
- package/out/tools/sub-venue/surfaces.js.map +0 -1
- package/out/tools/sub-venue/table.d.ts +0 -229
- package/out/tools/sub-venue/table.d.ts.map +0 -1
- package/out/tools/sub-venue/table.js.map +0 -1
- package/out/tools/sub-venue/wikidata.d.ts +0 -26
- package/out/tools/sub-venue/wikidata.d.ts.map +0 -1
- package/out/tools/sub-venue/wikidata.js +0 -62
- package/out/tools/sub-venue/wikidata.js.map +0 -1
- package/out/tools/sub-venue-lexicon.d.ts +0 -156
- package/out/tools/sub-venue-lexicon.d.ts.map +0 -1
- package/out/tools/sub-venue-lexicon.js +0 -283
- package/out/tools/sub-venue-lexicon.js.map +0 -1
- package/out/tools/sub-venue-promotions.d.ts +0 -94
- package/out/tools/sub-venue-promotions.d.ts.map +0 -1
- package/out/tools/sub-venue-promotions.js +0 -266
- package/out/tools/sub-venue-promotions.js.map +0 -1
- /package/lib/{recipes/cn-organizational-units.ts → cn/recipes/organizational-units.ts} +0 -0
- /package/lib/{adapters → fr/adapters}/ban/street-decompose.ts +0 -0
- /package/lib/{adapters/wof-admin-jp → jp/adapters/wof-admin}/adapter.ts +0 -0
- /package/lib/tools/{golden-expand.ts → golden/expand.ts} +0 -0
- /package/lib/tools/{lint-slice.ts → lint/slice/index.ts} +0 -0
- /package/lib/tools/{slice-kryptonite.ts → slice/kryptonite.ts} +0 -0
- /package/lib/tools/{slice-translit.ts → slice/translit.ts} +0 -0
- /package/lib/tools/{sub-venue-promotions.ts → sub/venue/promotions.ts} +0 -0
- /package/lib/{adapters/state-hi-schools → us/adapters/state/hi-schools}/workbook.ts +0 -0
- /package/lib/{adapters → us/adapters}/tiger/street-decompose.ts +0 -0
- /package/lib/{codex/us-fips-state.ts → us/fips-state.ts} +0 -0
- /package/lib/{recipes → ve/recipes}/reviewed-postcode-tail.ts +0 -0
- /package/out/adapters/{geonames-postal → geonames/postal}/adapter.d.ts +0 -0
- /package/out/{adapters → au/adapters}/gnaf/adapter.d.ts +0 -0
- /package/out/{adapters → fr/adapters}/ban/adapter.d.ts +0 -0
- /package/out/{adapters → fr/adapters}/ban/street-decompose.d.ts +0 -0
- /package/out/{adapters → fr/adapters}/ban/street-decompose.js +0 -0
- /package/out/{adapters/wof-admin-jp → jp/adapters/wof-admin}/adapter.d.ts +0 -0
- /package/out/{adapters/wof-admin-jp → jp/adapters/wof-admin}/adapter.js +0 -0
- /package/out/tools/{sub-venue → sub/venue}/head-nouns.js +0 -0
- /package/out/tools/{sub-venue → sub/venue}/surfaces.js +0 -0
- /package/out/tools/{sub-venue → sub/venue}/table.js +0 -0
- /package/out/{adapters → us/adapters}/fcc-bdc/adapter.d.ts +0 -0
- /package/out/{adapters/state-hi-schools → us/adapters/state/hi-schools}/adapter.d.ts +0 -0
- /package/out/{adapters/state-hi-schools → us/adapters/state/hi-schools}/workbook.d.ts +0 -0
- /package/out/{adapters/state-hi-schools → us/adapters/state/hi-schools}/workbook.js +0 -0
- /package/out/{adapters/state-ia-contractors → us/adapters/state/ia-contractors}/adapter.d.ts +0 -0
- /package/out/{adapters/state-ny-notaries → us/adapters/state/ny-notaries}/adapter.d.ts +0 -0
- /package/out/{adapters/state-tx-notaries → us/adapters/state/tx-notaries}/adapter.d.ts +0 -0
- /package/out/{adapters → us/adapters}/tiger/street-decompose.d.ts +0 -0
- /package/out/{adapters → us/adapters}/tiger/street-decompose.js +0 -0
- /package/out/{adapters/usgov-hrsa-fqhc → us/adapters/usgov/hrsa-fqhc}/adapter.d.ts +0 -0
- /package/out/{adapters/usgov-imls-pls → us/adapters/usgov/imls-pls}/adapter.d.ts +0 -0
- /package/out/{adapters/usgov-irs-bmf → us/adapters/usgov/irs-bmf}/adapter.d.ts +0 -0
- /package/out/{adapters/usgov-nad → us/adapters/usgov/nad}/adapter.d.ts +0 -0
- /package/out/{adapters/usgov-nppes → us/adapters/usgov/nppes}/adapter.d.ts +0 -0
- /package/out/{adapters/usgov-samhsa-treatment-locator → us/adapters/usgov/samhsa-treatment-locator}/adapter.d.ts +0 -0
- /package/out/{recipes → ve/recipes}/reviewed-postcode-tail.d.ts +0 -0
- /package/out/{recipes → ve/recipes}/reviewed-postcode-tail.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"imls-pls.js","sourceRoot":"","sources":["../../../../lib/us/tools/fetch/imls-pls.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH;kGACkG;AAElG,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,+BAA+B,CAAA;AAC5E,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,M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CAAC,OAAO,CAAC,OAAO,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,MAAM,EAAE,CAAC,CAAA;IAC1E,MAAM,EAAE,CAAC,yBAAyB,YAAY,EAAE,CAAC,CAAA;IAEjD,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAA;AAC9D,CAAC"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Fetch the US DOT National Address Database (NAD) — ~97 million structured US address-point
|
|
7
|
+
* records aggregated from state and local authorities. Source for the `usgov-nad` adapter (#30).
|
|
8
|
+
* US Public Domain (17 U.S.C. § 105).
|
|
9
|
+
*
|
|
10
|
+
* - Bounded per-chunk page concurrency (4× speedup at safe pressure)
|
|
11
|
+
* - 5× larger page size (5 000 vs. the old bash fetcher's 2 000) — fewer round-trips per chunk
|
|
12
|
+
* - Honest `complete: true` flag: only set when every page in the chunk fetched cleanly
|
|
13
|
+
* - Built-in fetch with gzip/brotli decompression (no curl + Python subprocess tax)
|
|
14
|
+
* - Per-chunk manifest with sha256 + record count + error count
|
|
15
|
+
*
|
|
16
|
+
* ## Source layout
|
|
17
|
+
*
|
|
18
|
+
* The ArcGIS FeatureServer is the only fully-automated path. As of 2026-05:
|
|
19
|
+
*
|
|
20
|
+
* - **`bulk`** mode requires a pre-signed S3 URL (Akamai blocks scripted curl on the DOT page). Pass
|
|
21
|
+
* `--nad-url <presigned>` from a browser visit to
|
|
22
|
+
* [https://www.transportation.gov/gis/national-address-database](https://www.transportation.gov/gis/national-address-database).
|
|
23
|
+
* - **`featureserver`** mode (default) pages the live FeatureService via OBJECTID ranges, writing
|
|
24
|
+
* NDJSON chunks into `<outRoot>/usgov-nad/featureserver/`.
|
|
25
|
+
*
|
|
26
|
+
* ## Usage
|
|
27
|
+
*
|
|
28
|
+
* ```sh
|
|
29
|
+
* mailwoman corpus fetch nad --out-root $MAILWOMAN_DATA_ROOT/corpus/sources
|
|
30
|
+
*
|
|
31
|
+
* # Resume from an OID
|
|
32
|
+
* mailwoman corpus fetch nad --start-oid 34400001
|
|
33
|
+
*
|
|
34
|
+
* # Increase concurrency on a fast link
|
|
35
|
+
* mailwoman corpus fetch nad --concurrency 8 --page-size 10000
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
import type { BaseFetchOptions, FetchSummary } from "#tools/fetch/download/index";
|
|
39
|
+
export interface FetchNADOptions extends BaseFetchOptions {
|
|
40
|
+
/**
|
|
41
|
+
* Fetch strategy. Default `featureserver`.
|
|
42
|
+
*/
|
|
43
|
+
mode?: "featureserver" | "bulk";
|
|
44
|
+
/**
|
|
45
|
+
* Pre-signed S3 URL for bulk mode.
|
|
46
|
+
*/
|
|
47
|
+
nadURL?: string;
|
|
48
|
+
/**
|
|
49
|
+
* Records per output file. Default `100000`.
|
|
50
|
+
*/
|
|
51
|
+
chunkSize?: number;
|
|
52
|
+
/**
|
|
53
|
+
* Records per HTTP request. Default `5000`.
|
|
54
|
+
*/
|
|
55
|
+
pageSize?: number;
|
|
56
|
+
/**
|
|
57
|
+
* Parallel page fetches within a chunk. Default `4`.
|
|
58
|
+
*/
|
|
59
|
+
concurrency?: number;
|
|
60
|
+
/**
|
|
61
|
+
* Start OBJECTID. Default `1`.
|
|
62
|
+
*/
|
|
63
|
+
startOID?: number;
|
|
64
|
+
/**
|
|
65
|
+
* Stop before this OID. Default = total count.
|
|
66
|
+
*/
|
|
67
|
+
endOID?: number;
|
|
68
|
+
}
|
|
69
|
+
export declare function fetchNAD(options: FetchNADOptions, report?: (line: string) => void): Promise<FetchSummary>;
|
|
70
|
+
//# sourceMappingURL=nad.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nad.d.ts","sourceRoot":"","sources":["../../../../lib/us/tools/fetch/nad.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAQH,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAA;AAQjF,MAAM,WAAW,eAAgB,SAAQ,gBAAgB;IACxD;;OAEG;IACH,IAAI,CAAC,EAAE,eAAe,GAAG,MAAM,CAAA;IAC/B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;CACf;AAuPD,wBAAsB,QAAQ,CAAC,OAAO,EAAE,eAAe,EAAE,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC,CAY/G"}
|
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Fetch the US DOT National Address Database (NAD) — ~97 million structured US address-point
|
|
7
|
+
* records aggregated from state and local authorities. Source for the `usgov-nad` adapter (#30).
|
|
8
|
+
* US Public Domain (17 U.S.C. § 105).
|
|
9
|
+
*
|
|
10
|
+
* - Bounded per-chunk page concurrency (4× speedup at safe pressure)
|
|
11
|
+
* - 5× larger page size (5 000 vs. the old bash fetcher's 2 000) — fewer round-trips per chunk
|
|
12
|
+
* - Honest `complete: true` flag: only set when every page in the chunk fetched cleanly
|
|
13
|
+
* - Built-in fetch with gzip/brotli decompression (no curl + Python subprocess tax)
|
|
14
|
+
* - Per-chunk manifest with sha256 + record count + error count
|
|
15
|
+
*
|
|
16
|
+
* ## Source layout
|
|
17
|
+
*
|
|
18
|
+
* The ArcGIS FeatureServer is the only fully-automated path. As of 2026-05:
|
|
19
|
+
*
|
|
20
|
+
* - **`bulk`** mode requires a pre-signed S3 URL (Akamai blocks scripted curl on the DOT page). Pass
|
|
21
|
+
* `--nad-url <presigned>` from a browser visit to
|
|
22
|
+
* [https://www.transportation.gov/gis/national-address-database](https://www.transportation.gov/gis/national-address-database).
|
|
23
|
+
* - **`featureserver`** mode (default) pages the live FeatureService via OBJECTID ranges, writing
|
|
24
|
+
* NDJSON chunks into `<outRoot>/usgov-nad/featureserver/`.
|
|
25
|
+
*
|
|
26
|
+
* ## Usage
|
|
27
|
+
*
|
|
28
|
+
* ```sh
|
|
29
|
+
* mailwoman corpus fetch nad --out-root $MAILWOMAN_DATA_ROOT/corpus/sources
|
|
30
|
+
*
|
|
31
|
+
* # Resume from an OID
|
|
32
|
+
* mailwoman corpus fetch nad --start-oid 34400001
|
|
33
|
+
*
|
|
34
|
+
* # Increase concurrency on a fast link
|
|
35
|
+
* mailwoman corpus fetch nad --concurrency 8 --page-size 10000
|
|
36
|
+
* ```
|
|
37
|
+
*/
|
|
38
|
+
import { APIClient, pluckResponseData } from "@mailwoman/core/api";
|
|
39
|
+
import { statPath, pathExists } from "@mailwoman/core/fs/readers";
|
|
40
|
+
import { makeDirectories, writeLocalTextFile } from "@mailwoman/core/fs/writers";
|
|
41
|
+
import { sha256File } from "@mailwoman/core/hash";
|
|
42
|
+
import { join } from "path-ts";
|
|
43
|
+
import { downloadToFile, readManifest, writeManifest } from "#tools/fetch/download/index";
|
|
44
|
+
const SLUG = "usgov-nad";
|
|
45
|
+
const FEATURE_SERVICE_URL = "https://services.arcgis.com/xOi1kZaI0eWDREZv/ArcGIS/rest/services/Address_Points_from_National_Address_Database_view/FeatureServer/0";
|
|
46
|
+
/**
|
|
47
|
+
* ArcGIS paged reads. Retry is ON: the loop walks OBJECTID ranges to completion, so one throttled page previously ended
|
|
48
|
+
* a multi-hour national download. No rate budget — pages are requested one at a time and each assembles thousands of
|
|
49
|
+
* records server-side.
|
|
50
|
+
*/
|
|
51
|
+
const nadClient = new APIClient({
|
|
52
|
+
displayName: "nad",
|
|
53
|
+
retry: true,
|
|
54
|
+
axios: { headers: { "Accept-Encoding": "gzip, br" } },
|
|
55
|
+
});
|
|
56
|
+
async function fetchPage(startOID, endOID, pageSize) {
|
|
57
|
+
const url = new URL(`${FEATURE_SERVICE_URL}/query`);
|
|
58
|
+
url.searchParams.set("where", `OBJECTID BETWEEN ${startOID} AND ${endOID}`);
|
|
59
|
+
url.searchParams.set("outFields", "*");
|
|
60
|
+
url.searchParams.set("f", "json");
|
|
61
|
+
url.searchParams.set("resultRecordCount", String(pageSize));
|
|
62
|
+
const data = await nadClient
|
|
63
|
+
.fetch({
|
|
64
|
+
url: url.toString(),
|
|
65
|
+
timeout: 120_000,
|
|
66
|
+
})
|
|
67
|
+
.then(pluckResponseData);
|
|
68
|
+
if (data.error)
|
|
69
|
+
throw new Error(`ArcGIS error on OID ${startOID}-${endOID}: ${data.error.message}`);
|
|
70
|
+
return (data.features ?? []).map((f) => f.attributes);
|
|
71
|
+
}
|
|
72
|
+
async function discoverTotalCount() {
|
|
73
|
+
const url = new URL(`${FEATURE_SERVICE_URL}/query`);
|
|
74
|
+
url.searchParams.set("where", "1=1");
|
|
75
|
+
url.searchParams.set("returnCountOnly", "true");
|
|
76
|
+
url.searchParams.set("f", "json");
|
|
77
|
+
const data = await nadClient
|
|
78
|
+
.fetch({ url: url.toString(), timeout: 30_000 })
|
|
79
|
+
.then(pluckResponseData);
|
|
80
|
+
if (typeof data.count !== "number")
|
|
81
|
+
throw new Error("NAD count query returned no count field");
|
|
82
|
+
return data.count;
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Fetch a single chunk by paging through its OID range with bounded concurrency. Returns the count of records written
|
|
86
|
+
* and the count of pages that errored. The caller decides whether to mark the chunk complete based on errors === 0.
|
|
87
|
+
*
|
|
88
|
+
* NOTE(phase1): this is a JSON API pager, not a file download — the shared `downloadToFile` doesn't apply here.
|
|
89
|
+
*/
|
|
90
|
+
async function fetchChunk(chunkPath, chunkStart, chunkEnd, pageSize, concurrency, report) {
|
|
91
|
+
const pageRanges = [];
|
|
92
|
+
for (let cursor = chunkStart; cursor <= chunkEnd; cursor += pageSize) {
|
|
93
|
+
pageRanges.push([cursor, Math.min(cursor + pageSize - 1, chunkEnd)]);
|
|
94
|
+
}
|
|
95
|
+
// Run bounded-concurrency page fetches. Results indexed by page slot for in-order write.
|
|
96
|
+
const pageResults = pageRanges.map(() => ({
|
|
97
|
+
rows: [],
|
|
98
|
+
error: null,
|
|
99
|
+
}));
|
|
100
|
+
let nextSlot = 0;
|
|
101
|
+
const workers = Array.from({ length: Math.min(concurrency, pageRanges.length) }, async () => {
|
|
102
|
+
while (true) {
|
|
103
|
+
const slot = nextSlot++;
|
|
104
|
+
if (slot >= pageRanges.length)
|
|
105
|
+
return;
|
|
106
|
+
const [s, e] = pageRanges[slot];
|
|
107
|
+
try {
|
|
108
|
+
pageResults[slot].rows = await fetchPage(s, e, pageSize);
|
|
109
|
+
}
|
|
110
|
+
catch (error) {
|
|
111
|
+
pageResults[slot].error = error;
|
|
112
|
+
report?.(` ✗ page ${s}-${e}: ${error.message}`);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
});
|
|
116
|
+
await Promise.all(workers);
|
|
117
|
+
// Single-writer phase — write all pages in OID order to keep NDJSON deterministic.
|
|
118
|
+
const lines = [];
|
|
119
|
+
let errors = 0;
|
|
120
|
+
for (const { rows, error } of pageResults) {
|
|
121
|
+
if (error) {
|
|
122
|
+
errors++;
|
|
123
|
+
continue;
|
|
124
|
+
}
|
|
125
|
+
for (const row of rows) {
|
|
126
|
+
lines.push(JSON.stringify(row));
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
await writeLocalTextFile(!lines.length ? "" : lines.join("\n") + "\n", chunkPath);
|
|
130
|
+
return { recordCount: lines.length, errors };
|
|
131
|
+
}
|
|
132
|
+
async function featureserverMode(options, report) {
|
|
133
|
+
const chunkSize = options.chunkSize ?? 100_000;
|
|
134
|
+
const pageSize = options.pageSize ?? 5000;
|
|
135
|
+
const concurrency = options.concurrency ?? 4;
|
|
136
|
+
const startOID = options.startOID ?? 1;
|
|
137
|
+
const chunkDir = join(options.outRoot, SLUG, "featureserver");
|
|
138
|
+
await makeDirectories(chunkDir);
|
|
139
|
+
report?.(`=== ${SLUG} / featureserver`);
|
|
140
|
+
report?.(` Discovering record count ...`);
|
|
141
|
+
const totalCount = await discoverTotalCount();
|
|
142
|
+
const endOID = options.endOID ?? totalCount;
|
|
143
|
+
report?.(` Total records: ${totalCount.toLocaleString()}`);
|
|
144
|
+
report?.(` OID range: ${startOID.toLocaleString()} .. ${endOID.toLocaleString()}`);
|
|
145
|
+
report?.(` Chunk size: ${chunkSize}, page size: ${pageSize}, concurrency: ${concurrency}`);
|
|
146
|
+
let fetched = 0;
|
|
147
|
+
let skipped = 0;
|
|
148
|
+
let totalRecords = 0;
|
|
149
|
+
let totalErrors = 0;
|
|
150
|
+
const failedCodes = [];
|
|
151
|
+
for (let cursor = startOID; cursor <= endOID; cursor += chunkSize) {
|
|
152
|
+
const chunkEnd = Math.min(cursor + chunkSize - 1, endOID);
|
|
153
|
+
const chunkName = `oids_${cursor}-${chunkEnd}`;
|
|
154
|
+
const chunkPath = join(chunkDir, `${chunkName}.ndjson`);
|
|
155
|
+
const manifestPath = join(chunkDir, `${chunkName}.manifest.json`);
|
|
156
|
+
// Idempotency: skip a chunk only if it's marked complete (the bash version's bug was
|
|
157
|
+
// marking complete on partial-failure runs; we now only set complete after a clean fetch).
|
|
158
|
+
if (await pathExists(chunkPath)) {
|
|
159
|
+
const recorded = await readManifest(manifestPath);
|
|
160
|
+
if (recorded?.complete) {
|
|
161
|
+
skipped++;
|
|
162
|
+
continue;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
report?.(` Fetching ${chunkName} ...`);
|
|
166
|
+
const t0 = Date.now();
|
|
167
|
+
const { recordCount, errors } = await fetchChunk(chunkPath, cursor, chunkEnd, pageSize, concurrency, report);
|
|
168
|
+
const elapsed = ((Date.now() - t0) / 1000).toFixed(1);
|
|
169
|
+
const bytes = (await statPath(chunkPath)).size;
|
|
170
|
+
const sha = await sha256File(chunkPath);
|
|
171
|
+
const manifest = {
|
|
172
|
+
source_url: FEATURE_SERVICE_URL,
|
|
173
|
+
oid_range: [cursor, chunkEnd],
|
|
174
|
+
downloaded_at: new Date().toISOString(),
|
|
175
|
+
filename: `${chunkName}.ndjson`,
|
|
176
|
+
sha256: sha,
|
|
177
|
+
bytes,
|
|
178
|
+
record_count: recordCount,
|
|
179
|
+
page_errors: errors,
|
|
180
|
+
complete: errors === 0,
|
|
181
|
+
};
|
|
182
|
+
await writeManifest(manifestPath, manifest);
|
|
183
|
+
const status = errors === 0 ? "✓" : `⚠ ${errors} page errors`;
|
|
184
|
+
report?.(` ${status} ${recordCount.toLocaleString()} records in ${elapsed}s (${(bytes / 1024 / 1024).toFixed(1)} MB)`);
|
|
185
|
+
fetched++;
|
|
186
|
+
totalRecords += recordCount;
|
|
187
|
+
totalErrors += errors;
|
|
188
|
+
if (errors > 0) {
|
|
189
|
+
failedCodes.push(chunkName);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
report?.(`=== featureserver summary ===`);
|
|
193
|
+
report?.(`chunks fetched: ${fetched} skipped: ${skipped}`);
|
|
194
|
+
report?.(`total records: ${totalRecords.toLocaleString()}`);
|
|
195
|
+
report?.(`page errors: ${totalErrors}`);
|
|
196
|
+
report?.(`output: ${chunkDir}`);
|
|
197
|
+
// `failed` counts page errors (the old exit-1 condition), `failedCodes` names the dirty chunks.
|
|
198
|
+
return { fetched, skipped, failed: totalErrors, failedCodes };
|
|
199
|
+
}
|
|
200
|
+
async function bulkMode(options, report) {
|
|
201
|
+
if (!options.nadURL) {
|
|
202
|
+
throw new Error(`bulk mode requires --nad-url. Akamai protects the DOT page; ` +
|
|
203
|
+
`visit https://www.transportation.gov/gis/national-address-database in a browser, ` +
|
|
204
|
+
`accept the disclaimer, and re-run with the pre-signed S3 URL.`);
|
|
205
|
+
}
|
|
206
|
+
const destDir = join(options.outRoot, SLUG);
|
|
207
|
+
await makeDirectories(destDir);
|
|
208
|
+
const filename = new URL(options.nadURL).pathname.split("/").pop() ?? "NAD.zip";
|
|
209
|
+
const destPath = join(destDir, filename);
|
|
210
|
+
report?.(`=== ${SLUG} / ${filename}`);
|
|
211
|
+
report?.(` URL: ${options.nadURL.slice(0, 100)}${options.nadURL.length > 100 ? "…" : ""}`);
|
|
212
|
+
const { bytes } = await downloadToFile({ url: options.nadURL, dest: destPath, timeoutMs: 3 * 3600 * 1000, report });
|
|
213
|
+
const sha = await sha256File(destPath);
|
|
214
|
+
await writeManifest(join(destDir, "MANIFEST.json"), {
|
|
215
|
+
source_url: options.nadURL,
|
|
216
|
+
downloaded_at: new Date().toISOString(),
|
|
217
|
+
filename,
|
|
218
|
+
sha256: sha,
|
|
219
|
+
bytes,
|
|
220
|
+
});
|
|
221
|
+
report?.(` ✓ ${(bytes / 1024 / 1024 / 1024).toFixed(2)} GB sha256=${sha}`);
|
|
222
|
+
return { fetched: 1, skipped: 0, failed: 0, failedCodes: [] };
|
|
223
|
+
}
|
|
224
|
+
export async function fetchNAD(options, report) {
|
|
225
|
+
const mode = options.mode ?? "featureserver";
|
|
226
|
+
if (mode === "featureserver") {
|
|
227
|
+
return featureserverMode(options, report);
|
|
228
|
+
}
|
|
229
|
+
if (mode === "bulk") {
|
|
230
|
+
return bulkMode(options, report);
|
|
231
|
+
}
|
|
232
|
+
throw new Error(`unknown mode "${String(mode)}" (expected featureserver|bulk)`);
|
|
233
|
+
}
|
|
234
|
+
//# sourceMappingURL=nad.js.map
|
|
@@ -0,0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C;QACrB,OAAO,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,CAAA;IACjC,CAAC;IAED,MAAM,IAAI,KAAK,CAAC,iBAAiB,MAAM,CAAC,IAAI,CAAC,iCAAiC,CAAC,CAAA;AAChF,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Re-fetch the NPPES (National Plan and Provider Enumeration System) full monthly data
|
|
7
|
+
* dissemination file. ~7M provider rows with venue+address data. Source for the `usgov-nppes`
|
|
8
|
+
* adapter. US Public Domain.
|
|
9
|
+
*
|
|
10
|
+
* The file is published monthly by CMS. This module discovers the current filename by scraping the
|
|
11
|
+
* NPI_Files.html index, then downloads the ZIP and extracts only the main registry CSV
|
|
12
|
+
* (npidata_pfile_*.csv). The smaller endpoint/othername/pl files stay zipped — we don't need them.
|
|
13
|
+
*
|
|
14
|
+
* Uses Node's built-in fetch (gzip/brotli) to parse the HTML index and download the ZIP, and
|
|
15
|
+
* streaming sha256 instead of sha256sum. The ZIP is unpacked with the `unzip` binary via
|
|
16
|
+
* `node:child_process` (no clean Node equivalent for member listing + selective extraction). NOTE:
|
|
17
|
+
* the old bash fetcher used `curl --continue-at -` to resume a partial download; native fetch has
|
|
18
|
+
* no resume, so a partial run re-downloads from the start.
|
|
19
|
+
*
|
|
20
|
+
* Invoke via `mailwoman corpus fetch nppes --out-root <path>`. Idempotent: if dest CSV exists and
|
|
21
|
+
* sha256 matches MANIFEST, skips download.
|
|
22
|
+
*/
|
|
23
|
+
import type { BaseFetchOptions, FetchSummary } from "#tools/fetch/download/index";
|
|
24
|
+
export type FetchNPPESOptions = BaseFetchOptions;
|
|
25
|
+
export declare function fetchNPPES(options: FetchNPPESOptions, report?: (line: string) => void): Promise<FetchSummary>;
|
|
26
|
+
//# sourceMappingURL=nppes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nppes.d.ts","sourceRoot":"","sources":["../../../../lib/us/tools/fetch/nppes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAYH,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAkB,MAAM,6BAA6B,CAAA;AAOjG,MAAM,MAAM,iBAAiB,GAAG,gBAAgB,CAAA;AAmChD,wBAAsB,UAAU,CAAC,OAAO,EAAE,iBAAiB,EAAE,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,YAAY,CAAC,CAyFnH"}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Re-fetch the NPPES (National Plan and Provider Enumeration System) full monthly data
|
|
7
|
+
* dissemination file. ~7M provider rows with venue+address data. Source for the `usgov-nppes`
|
|
8
|
+
* adapter. US Public Domain.
|
|
9
|
+
*
|
|
10
|
+
* The file is published monthly by CMS. This module discovers the current filename by scraping the
|
|
11
|
+
* NPI_Files.html index, then downloads the ZIP and extracts only the main registry CSV
|
|
12
|
+
* (npidata_pfile_*.csv). The smaller endpoint/othername/pl files stay zipped — we don't need them.
|
|
13
|
+
*
|
|
14
|
+
* Uses Node's built-in fetch (gzip/brotli) to parse the HTML index and download the ZIP, and
|
|
15
|
+
* streaming sha256 instead of sha256sum. The ZIP is unpacked with the `unzip` binary via
|
|
16
|
+
* `node:child_process` (no clean Node equivalent for member listing + selective extraction). NOTE:
|
|
17
|
+
* the old bash fetcher used `curl --continue-at -` to resume a partial download; native fetch has
|
|
18
|
+
* no resume, so a partial run re-downloads from the start.
|
|
19
|
+
*
|
|
20
|
+
* Invoke via `mailwoman corpus fetch nppes --out-root <path>`. Idempotent: if dest CSV exists and
|
|
21
|
+
* sha256 matches MANIFEST, skips download.
|
|
22
|
+
*/
|
|
23
|
+
/* oxlint-disable sister-software/prefer-region-over-marks -- these markers label steps inside one
|
|
24
|
+
procedure, not sections of declarations. A region there folds nothing a reader wants folded. */
|
|
25
|
+
import { APIClient, pluckResponseData } from "@mailwoman/core/api";
|
|
26
|
+
import { statPath, pathExists } from "@mailwoman/core/fs/readers";
|
|
27
|
+
import { makeDirectories, removePathIfPresent } from "@mailwoman/core/fs/writers";
|
|
28
|
+
import { extractZipEntry, listZipEntries } from "@mailwoman/core/fs/zip";
|
|
29
|
+
import { sha256File } from "@mailwoman/core/hash";
|
|
30
|
+
import { basename, join } from "path-ts";
|
|
31
|
+
import { downloadToFile, readManifest, writeManifest } from "#tools/fetch/download/index";
|
|
32
|
+
const INDEX_URL = "https://download.cms.gov/nppes/NPI_Files.html";
|
|
33
|
+
const BASE_URL = "https://download.cms.gov/nppes";
|
|
34
|
+
const SLUG = "usgov-nppes";
|
|
35
|
+
/**
|
|
36
|
+
* Scrape the NPI_Files.html index for the latest full monthly ZIP. Full-replacement files match
|
|
37
|
+
* `NPPES_Data_Dissemination_<Month>_<Year>*.zip`; weekly files carry a `MMDDYY_MMDDYY` date range, which we exclude.
|
|
38
|
+
*/
|
|
39
|
+
async function discoverLatestZip() {
|
|
40
|
+
// `responseType: "text"` — the index is HTML, scraped by regex below.
|
|
41
|
+
const html = await new APIClient({
|
|
42
|
+
displayName: "nppes-index",
|
|
43
|
+
retry: true,
|
|
44
|
+
axios: { headers: { "Accept-Encoding": "gzip, br" } },
|
|
45
|
+
})
|
|
46
|
+
.fetch({ url: INDEX_URL, responseType: "text", timeout: 60_000 })
|
|
47
|
+
.then(pluckResponseData);
|
|
48
|
+
for (const match of html.matchAll(/NPPES_Data_Dissemination_[A-Za-z]+_\d{4}[^"]*\.zip/g)) {
|
|
49
|
+
const name = match[0];
|
|
50
|
+
if (name && !/\d{6}_\d{6}/.test(name))
|
|
51
|
+
return name;
|
|
52
|
+
}
|
|
53
|
+
return undefined;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* The main registry CSV (npidata_pfile_*.csv), which the archive also carries alongside a header file and a per-month
|
|
57
|
+
* change file.
|
|
58
|
+
*/
|
|
59
|
+
async function findNpidataCSV(zipPath) {
|
|
60
|
+
const entries = await listZipEntries(zipPath);
|
|
61
|
+
return entries.find((entry) => /npidata_pfile\S+\.csv/i.test(entry.name))?.name;
|
|
62
|
+
}
|
|
63
|
+
export async function fetchNPPES(options, report) {
|
|
64
|
+
const destDir = join(options.outRoot, SLUG);
|
|
65
|
+
await makeDirectories(destDir);
|
|
66
|
+
const manifestPath = join(destDir, "MANIFEST.json");
|
|
67
|
+
report?.(`=== ${SLUG}`);
|
|
68
|
+
report?.(` Discovering latest full-replacement ZIP from ${INDEX_URL} ...`);
|
|
69
|
+
const zipFilename = await discoverLatestZip();
|
|
70
|
+
if (!zipFilename) {
|
|
71
|
+
report?.(` ✗ Could not discover ZIP filename from ${INDEX_URL}`);
|
|
72
|
+
return { fetched: 0, skipped: 0, failed: 1, failedCodes: [SLUG] };
|
|
73
|
+
}
|
|
74
|
+
const zipURL = `${BASE_URL}/${zipFilename}`;
|
|
75
|
+
const zipDest = join(destDir, zipFilename);
|
|
76
|
+
report?.(` Latest full file: ${zipFilename}`);
|
|
77
|
+
// Idempotency check: if the main CSV already exists and sha matches,
|
|
78
|
+
// skip re-download.
|
|
79
|
+
const recorded = await readManifest(manifestPath);
|
|
80
|
+
if (recorded?.sha256 && recorded.filename) {
|
|
81
|
+
const recordedPath = join(destDir, recorded.filename);
|
|
82
|
+
if ((await pathExists(recordedPath)) && (await sha256File(recordedPath)) === recorded.sha256) {
|
|
83
|
+
report?.(" ✓ Already current (sha256 matches MANIFEST) — skipping download.");
|
|
84
|
+
return { fetched: 0, skipped: 1, failed: 0, failedCodes: [] };
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
// MARK: Download ZIP (large; 60-minute timeout)
|
|
88
|
+
report?.(` Downloading ${zipURL} ...`);
|
|
89
|
+
const { bytes: zipSize } = await downloadToFile({
|
|
90
|
+
url: zipURL,
|
|
91
|
+
dest: zipDest,
|
|
92
|
+
timeoutMs: 3_600_000,
|
|
93
|
+
headers: { "Accept-Encoding": "gzip, br" },
|
|
94
|
+
report,
|
|
95
|
+
});
|
|
96
|
+
report?.(` Downloaded: ${(zipSize / 1024 / 1024).toFixed(1)} MB`);
|
|
97
|
+
// MARK: Extract only the main registry CSV (npidata_pfile_*.csv)
|
|
98
|
+
report?.(" Extracting npidata_pfile CSV from ZIP ...");
|
|
99
|
+
const csvName = await findNpidataCSV(zipDest);
|
|
100
|
+
if (!csvName) {
|
|
101
|
+
report?.(" ✗ Could not find npidata_pfile CSV inside ZIP");
|
|
102
|
+
return { fetched: 0, skipped: 0, failed: 1, failedCodes: [SLUG] };
|
|
103
|
+
}
|
|
104
|
+
report?.(` Extracting: ${csvName}`);
|
|
105
|
+
const csvDest = join(destDir, basename(csvName));
|
|
106
|
+
await extractZipEntry(zipDest, csvName, csvDest);
|
|
107
|
+
const csvSize = (await statPath(csvDest)).size;
|
|
108
|
+
const csvSha = await sha256File(csvDest);
|
|
109
|
+
report?.(` CSV size: ${(csvSize / 1024 / 1024).toFixed(1)} MB`);
|
|
110
|
+
// MARK: Remove the ZIP to reclaim ~1 GB
|
|
111
|
+
await removePathIfPresent(zipDest);
|
|
112
|
+
report?.(" Removed ZIP (CSV kept)");
|
|
113
|
+
// MARK: Write MANIFEST (records the extracted CSV, not the ZIP)
|
|
114
|
+
const manifest = {
|
|
115
|
+
source_url: zipURL,
|
|
116
|
+
downloaded_at: new Date().toISOString(),
|
|
117
|
+
filename: csvName,
|
|
118
|
+
sha256: csvSha,
|
|
119
|
+
bytes: csvSize,
|
|
120
|
+
};
|
|
121
|
+
await writeManifest(manifestPath, manifest);
|
|
122
|
+
report?.(` ✓ ${(csvSize / 1024 / 1024).toFixed(1)} MB sha256=${csvSha}`);
|
|
123
|
+
report?.(` MANIFEST written to ${manifestPath}`);
|
|
124
|
+
return { fetched: 1, skipped: 0, failed: 0, failedCodes: [] };
|
|
125
|
+
}
|
|
126
|
+
//# sourceMappingURL=nppes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nppes.js","sourceRoot":"","sources":["../../../../lib/us/tools/fetch/nppes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH;kGACkG;AAElG,OAAO,EAAE,SAAS,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAA;AAClE,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AACjE,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACjF,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AACxE,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AACjD,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAGxC,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAA;AAEzF,MAAM,SAAS,GAAG,+CAA+C,CAAA;AACjE,MAAM,QAAQ,GAAG,gCAAgC,CAAA;AACjD,MAAM,IAAI,GAAG,aAAa,CAAA;AAI1B;;;GAGG;AACH,KAAK,UAAU,iBAAiB;IAC/B,sEAAsE;IACtE,MAAM,IAAI,GAAG,MAAM,IAAI,SAAS,CAAC;QAChC,WAAW,EAAE,aAAa;QAC1B,KAAK,EAAE,IAAI;QACX,KAAK,EAAE,EAAE,OAAO,EAAE,EAAE,iBAAiB,EAAE,UAAU,EAAE,EAAE;KACrD,CAAC;SACA,KAAK,CAAS,EAAE,GAAG,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;SACxE,IAAI,CAAC,iBAAiB,CAAC,CAAA;IAEzB,K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E,CAAC,yBAAyB,YAAY,EAAE,CAAC,CAAA;IAEjD,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,EAAE,EAAE,CAAA;AAC9D,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Re-fetch the Hawaii State DOE school directory as its original XLSX workbook. The
|
|
7
|
+
* `state-hi-schools` adapter reads both worksheets directly.
|
|
8
|
+
*
|
|
9
|
+
* Upstream is a single XLSX (~64 KB) with two sheets — `HIDOE` (~258 district schools) and `PCS`
|
|
10
|
+
* (~38 public charter schools). Both sheets are validated against the adapter's required columns
|
|
11
|
+
* before the workbook is recorded as fetched.
|
|
12
|
+
*
|
|
13
|
+
* License: Hawaii state government open data (Tier A — state PD-equivalent).
|
|
14
|
+
*
|
|
15
|
+
* Invoke via `mailwoman corpus fetch state-hi-schools --out-root <path>`. Idempotent: if the dest
|
|
16
|
+
* workbook exists and its sha matches MANIFEST, skips download.
|
|
17
|
+
*/
|
|
18
|
+
import type { BaseFetchOptions, FetchSummary } from "#tools/fetch/download/index";
|
|
19
|
+
export interface FetchStateHISchoolsOptions extends BaseFetchOptions {
|
|
20
|
+
/**
|
|
21
|
+
* Workbook URL. Defaults to the Hawaii DOE source; overridable for an isolated fetch test.
|
|
22
|
+
*/
|
|
23
|
+
sourceURL?: string;
|
|
24
|
+
}
|
|
25
|
+
export declare function fetchStateHISchools(options: FetchStateHISchoolsOptions, report?: (line: string) => void): Promise<FetchSummary>;
|
|
26
|
+
//# sourceMappingURL=hi-schools.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"hi-schools.d.ts","sourceRoot":"","sources":["../../../../../lib/us/tools/fetch/state/hi-schools.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AASH,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,6BAA6B,CAAA;AAQjF,MAAM,WAAW,0BAA2B,SAAQ,gBAAgB;IACnE;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;CAClB;AAqCD,wBAAsB,mBAAmB,CACxC,OAAO,EAAE,0BAA0B,EACnC,MAAM,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,GAC7B,OAAO,CAAC,YAAY,CAAC,CAkFvB"}
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @copyright Sister Software
|
|
3
|
+
* @license AGPL-3.0
|
|
4
|
+
* @author Teffen Ellis, et al.
|
|
5
|
+
*
|
|
6
|
+
* Re-fetch the Hawaii State DOE school directory as its original XLSX workbook. The
|
|
7
|
+
* `state-hi-schools` adapter reads both worksheets directly.
|
|
8
|
+
*
|
|
9
|
+
* Upstream is a single XLSX (~64 KB) with two sheets — `HIDOE` (~258 district schools) and `PCS`
|
|
10
|
+
* (~38 public charter schools). Both sheets are validated against the adapter's required columns
|
|
11
|
+
* before the workbook is recorded as fetched.
|
|
12
|
+
*
|
|
13
|
+
* License: Hawaii state government open data (Tier A — state PD-equivalent).
|
|
14
|
+
*
|
|
15
|
+
* Invoke via `mailwoman corpus fetch state-hi-schools --out-root <path>`. Idempotent: if the dest
|
|
16
|
+
* workbook exists and its sha matches MANIFEST, skips download.
|
|
17
|
+
*/
|
|
18
|
+
import { BYTES_PER_KIB, ByteFormatter } from "@mailwoman/core/fs/formatters";
|
|
19
|
+
import { statPath, pathExists } from "@mailwoman/core/fs/readers";
|
|
20
|
+
import { makeDirectories, removePathIfPresent } from "@mailwoman/core/fs/writers";
|
|
21
|
+
import { sha256File } from "@mailwoman/core/hash";
|
|
22
|
+
import { join } from "path-ts";
|
|
23
|
+
import { XLSXSpliterator } from "spliterator";
|
|
24
|
+
import { downloadToFile, readManifest, writeManifest } from "#tools/fetch/download/index";
|
|
25
|
+
import { STATE_HI_SCHOOL_REQUIRED_COLUMNS, STATE_HI_SCHOOL_SHEETS } from "#us/adapters/state/hi-schools/workbook";
|
|
26
|
+
const SOURCE_URL = "https://www.hawaiipublicschools.org/DOE%20Forms/SchoolList.xlsx";
|
|
27
|
+
const SLUG = "state-hi-schools";
|
|
28
|
+
const XLSX_FILENAME = "HI_Public_Schools_List.xlsx";
|
|
29
|
+
async function validateWorkbook(path) {
|
|
30
|
+
for (const sheet of STATE_HI_SCHOOL_SHEETS) {
|
|
31
|
+
const rows = await XLSXSpliterator.fromAsync(path, {
|
|
32
|
+
sheet,
|
|
33
|
+
header: false,
|
|
34
|
+
take: 2,
|
|
35
|
+
}).toArray();
|
|
36
|
+
const header = rows[0];
|
|
37
|
+
if (!header || rows.length < 2) {
|
|
38
|
+
throw new Error(`sheet ${sheet} must contain a header and at least one school row`);
|
|
39
|
+
}
|
|
40
|
+
// Exact casing is part of the adapter contract: object mode preserves the workbook's header names, so accepting
|
|
41
|
+
// `Code` here while the reader asks for `record.code` would validate a workbook whose every row is later skipped.
|
|
42
|
+
const columns = new Set(header.map((cell) => String(cell ?? "").trim()));
|
|
43
|
+
const missing = STATE_HI_SCHOOL_REQUIRED_COLUMNS.filter((column) => !columns.has(column));
|
|
44
|
+
if (missing.length) {
|
|
45
|
+
throw new Error(`sheet ${sheet} is missing required columns: ${missing.join(", ")}`);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
export async function fetchStateHISchools(options, report) {
|
|
50
|
+
const destDir = join(options.outRoot, SLUG);
|
|
51
|
+
await makeDirectories(destDir);
|
|
52
|
+
const xlsxDest = join(destDir, XLSX_FILENAME);
|
|
53
|
+
const manifestPath = join(destDir, "MANIFEST.json");
|
|
54
|
+
const sourceURL = options.sourceURL ?? SOURCE_URL;
|
|
55
|
+
report?.(`=== ${SLUG}`);
|
|
56
|
+
// Idempotency: skip if the source workbook exists and sha matches the recorded manifest.
|
|
57
|
+
if (await pathExists(xlsxDest)) {
|
|
58
|
+
const recorded = await readManifest(manifestPath);
|
|
59
|
+
if (recorded?.sha256 && recorded.filename === XLSX_FILENAME) {
|
|
60
|
+
const actualSha = await sha256File(xlsxDest);
|
|
61
|
+
if (actualSha === recorded.sha256) {
|
|
62
|
+
report?.(` ✓ Already current (sha256 matches MANIFEST) — skipping download.`);
|
|
63
|
+
return { fetched: 0, skipped: 1, failed: 0, failedCodes: [] };
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
// Download XLSX.
|
|
68
|
+
report?.(` Downloading ${sourceURL} ...`);
|
|
69
|
+
try {
|
|
70
|
+
await downloadToFile({
|
|
71
|
+
url: sourceURL,
|
|
72
|
+
dest: xlsxDest,
|
|
73
|
+
timeoutMs: 600_000,
|
|
74
|
+
headers: { "Accept-Encoding": "gzip, br" },
|
|
75
|
+
report,
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
catch (error) {
|
|
79
|
+
report?.(` ✗ Download failed (${error.message})`);
|
|
80
|
+
return { fetched: 0, skipped: 0, failed: 1, failedCodes: [SLUG] };
|
|
81
|
+
}
|
|
82
|
+
const xlsxSize = (await statPath(xlsxDest)).size;
|
|
83
|
+
report?.(` Downloaded XLSX: ${ByteFormatter.formatIEC(xlsxSize)}`);
|
|
84
|
+
if (xlsxSize < BYTES_PER_KIB) {
|
|
85
|
+
report?.(` ✗ Response too small (${xlsxSize} bytes) — probable error page`);
|
|
86
|
+
await removePathIfPresent(xlsxDest);
|
|
87
|
+
return { fetched: 0, skipped: 0, failed: 1, failedCodes: [SLUG] };
|
|
88
|
+
}
|
|
89
|
+
try {
|
|
90
|
+
await validateWorkbook(xlsxDest);
|
|
91
|
+
}
|
|
92
|
+
catch (error) {
|
|
93
|
+
report?.(` ✗ Workbook validation failed (${error.message})`);
|
|
94
|
+
await removePathIfPresent(xlsxDest);
|
|
95
|
+
return { fetched: 0, skipped: 0, failed: 1, failedCodes: [SLUG] };
|
|
96
|
+
}
|
|
97
|
+
const xlsxSha = await sha256File(xlsxDest);
|
|
98
|
+
// Write MANIFEST.
|
|
99
|
+
const manifest = {
|
|
100
|
+
source_url: sourceURL,
|
|
101
|
+
downloaded_at: new Date().toISOString(),
|
|
102
|
+
filename: XLSX_FILENAME,
|
|
103
|
+
sha256: xlsxSha,
|
|
104
|
+
bytes: xlsxSize,
|
|
105
|
+
notes: "Original XLSX; the adapter reads the HIDOE and PCS sheets directly.",
|
|
106
|
+
};
|
|
107
|
+
await writeManifest(manifestPath, manifest);
|
|
108
|
+
report?.(` ✓ ${STATE_HI_SCHOOL_SHEETS.join(" + ")} validated · ${ByteFormatter.formatIEC(xlsxSize)} sha256=${xlsxSha}`);
|
|
109
|
+
report?.(` MANIFEST written to ${manifestPath}`);
|
|
110
|
+
return { fetched: 1, skipped: 0, failed: 0, failedCodes: [] };
|
|
111
|
+
}
|
|
112
|
+
//# sourceMappingURL=hi-schools.js.map
|