Make great documentation goal 1.2, and plan the README's reorganisation and the nested-template gaps #33
@@ -90,7 +90,7 @@ In [docs/decisions.md](docs/decisions.md):
|
||||
- A path is walked once without drawing before it is walked for real
|
||||
- A country's postal codes and streets are siblings under its locality
|
||||
- A locale package imports its country's geo package, and its `Modules()` returns both
|
||||
- The default embed holds every Swedish postort the import can place, a population-weighted tenth of the US places that hold most of a postal code's land, and a tenth of each place's streets, at least ten
|
||||
- The default embed holds every Swedish postort the import can place with all its streets, and of the US places that hold most of a postal code's land every state capital, every place of 100,000 and a population-weighted tenth of the rest, each with a quarter of its streets, at least ten
|
||||
- A locale's `address` binds its country's record once and prints it whole
|
||||
- A postort's kommun comes from its name, its tätort or its codes, never from distance
|
||||
- A highway designation is not a street, and a US postal code belongs to the place holding most of its land inside places
|
||||
|
||||
+5
-3
@@ -94,9 +94,11 @@ replacement, and each removed path, column or flag.
|
||||
it. `sv_SE.address` and `en_US.address` bind those records once, so
|
||||
`en_US.address.street` no longer carries `name` and `suffix`, and a locale's `address`
|
||||
reads its country's `geo` module. Every Swedish postort the import can place and give
|
||||
a street ships, and a tenth of the US incorporated places that hold most of some postal
|
||||
code's land, drawn by population down to villages of a hundred people, so a city of any size may be missing; each place carries
|
||||
a tenth of its streets, at least ten.
|
||||
a street ships with all its streets. Of the US incorporated places that hold most of
|
||||
some postal code's land, every state capital but Honolulu, every place of 100,000 or
|
||||
more, and a tenth of the rest drawn by population down to villages of a hundred people
|
||||
ship, so a smaller city may be missing; each carries a quarter of its streets, at least
|
||||
ten.
|
||||
- `{date(from,to,'layout')}` and `{time('layout')}`: a second between two days, or
|
||||
within one, in a single-quoted Go layout, drawn in UTC; `from` may equal `to`.
|
||||
`sv_SE.date`, `en_US.date`, `sv_SE.time` and `en_US.time` render through them, so
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ Every shipped dataset, its source, its licence and the attribution it asks for.
|
||||
| `geo/SE/locality.tsv`, `postal-code.tsv` | [GeoNames](https://www.geonames.org/) postal codes for SE; populations from SCB tätorter 2023 | [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/); CC0 1.0 | "Postal codes from GeoNames, www.geonames.org" | `data-import/geo-se.py` |
|
||||
| `geo/SE/region.tsv`, `municipality.tsv` | [SCB](https://www.scb.se/) län and kommun codes 2026 and population 2024 | [CC0 1.0](https://creativecommons.org/publicdomain/zero/1.0/) | none required | `data-import/geo-se.py` |
|
||||
| `geo/SE/street.tsv` | [Trafikverket NVDB](https://www.trafikverket.se/) Gatunamn, through the open API | CC0 1.0 | none required | `data-import/geo-se.py` |
|
||||
| `geo/US/region.tsv`, `municipality.tsv`, `locality.tsv` | [Census Bureau](https://www.census.gov/) Gazetteer 2026 and population estimates 2025 | [public domain](https://www.usa.gov/government-works) | none required | `data-import/geo-us.py` |
|
||||
| `geo/US/region.tsv`, `municipality.tsv`, `locality.tsv` | [Census Bureau](https://www.census.gov/) Gazetteer 2026 and population estimates 2025; which places are state capitals from [Wikidata](https://www.wikidata.org/) | [public domain](https://www.usa.gov/government-works); CC0 1.0 | none required | `data-import/geo-us.py` |
|
||||
| `geo/US/postal-code.tsv`, `street.tsv` | Census Bureau ZCTA to place relationships 2020 and TIGER/Line 2025 address ranges and feature names | public domain | none required | `data-import/geo-us.py` |
|
||||
| `sv_SE/first-name.tsv`, `last-name.tsv` | [SCB](https://www.scb.se/) names with at least two bearers, 31 December 2022 | CC0 1.0 | "Källa: SCB" | `data-import/names-se.py` |
|
||||
| `en_US/first-name.tsv` | [SSA](https://www.ssa.gov/oact/babynames/) baby names, births 1930 to 2020, through [hackerb9/ssa-baby-names](https://github.com/hackerb9/ssa-baby-names) | public domain | none required | `data-import/names-us.py` |
|
||||
|
||||
@@ -313,13 +313,14 @@ neighbouring one.
|
||||
| `municipality` | kommun, by code or name | county, by FIPS code or name | population |
|
||||
| `locality` | postort, by name; [`geo-se.py`](data-import/geo-se.py)'s `localities` picks the candidates, and one with no street is dropped | incorporated place, by GEOID or name; Hawaii has none | tätort population, the kommun's where the postort names it, else 200; place population |
|
||||
| `postal-code` | postnummer with street delivery, by code | ZCTA, by code | one; address ranges |
|
||||
| `street` | gatunamn, per postort the tenth with most road segments, at least ten | street name, per place the tenth with most address ranges, at least ten | segments; address ranges |
|
||||
| `street` | gatunamn, every one | street name, per place the quarter with most address ranges, at least ten | segments; address ranges |
|
||||
|
||||
`geo.SE.region[Skåne län].municipality` draws a kommun in Skåne,
|
||||
`geo.SE.locality[Lund].street` a street in Lund, and
|
||||
`geo.US.region[IL].locality[Springfield]` settles which Springfield. The US places are a
|
||||
tenth of the incorporated places that hold most of some postal code's land, drawn with
|
||||
odds by population, so a city of any size may be missing: look one up in
|
||||
`geo.US.region[IL].locality[Springfield]` settles which Springfield. The US places are
|
||||
the incorporated places that hold most of some postal code's land: every state capital,
|
||||
every place of 100,000 or more, and a tenth of the rest drawn with odds by population,
|
||||
so a smaller city may be missing: look one up in
|
||||
[`locality.tsv`](data/geo/US/locality.tsv) before selecting it. A region row
|
||||
carries its `timezone`, the state's predominant zone, and a locality its `lat` and
|
||||
`lon`. What ports across countries is the five table names, the `name` column,
|
||||
|
||||
+15
-8
@@ -603,18 +603,25 @@ providing `geo.SE`'s paths, and without one `sv_SE.address` fails at first reach
|
||||
`FS` works against goal 6.2. Every package exports `Modules()`, so one spelling loads any of
|
||||
them; a data package imports only the packages it reads.
|
||||
|
||||
## The default embed holds every Swedish postort the import can place, a population-weighted tenth of the US places that hold most of a postal code's land, and a tenth of each place's streets, at least ten
|
||||
## The default embed holds every Swedish postort the import can place with all its streets, and of the US places that hold most of a postal code's land every state capital, every place of 100,000 and a population-weighted tenth of the rest, each with a quarter of its streets, at least ten
|
||||
|
||||
2026-10-11, Lilleman auf Larv. Goals 2 and 14: ten streets per place put 500 Stockholm
|
||||
2026-10-11, Lilleman auf Larv; revised the same day, after a tenth of the streets gave
|
||||
Göteborg 163 and Stockholm 37. Goals 2 and 14: ten streets per place put 500 Stockholm
|
||||
customers on ten streets, and US places of 25,000 or more left out every town and
|
||||
village. `geo-us.py` draws with Efraimidis and Spirakis's weighted sampling. It draws
|
||||
only among places holding most of some ZCTA's land, since no other place can carry a
|
||||
postal code. The draw keeps 968 of the 1,584 places of 25,000 or more and 310 of those of
|
||||
100,000 or more, and its smallest place holds 93 people. On 2026-10-11 the embed grew
|
||||
from 1.3 MB to 5.2 MB, and the first draw of `en_US.address` took 75 ms against 19 ms
|
||||
before, within goal 13. `--place-share`, `--street-share` and `--min-streets` on the
|
||||
import scripts build another set. Valid while the first reach of a country stays
|
||||
unnoticed beside a test run.
|
||||
postal code. The draw alone kept 310 of the 343 places of 100,000 or more and left out
|
||||
13 state capitals, so a test author pinning a city they know hit `no row of … has key
|
||||
or name`; every capital and every place of 100,000 now ships beside the draw, and its
|
||||
smallest place holds 93 people. The capitals are each state's `capital` (P36) in
|
||||
[Wikidata](https://www.wikidata.org/), matched to a Census place by its GNIS id and
|
||||
else by name in its state. Honolulu, a census-designated place, is the one capital and
|
||||
the one place of 100,000 that cannot ship. Every Swedish street is 174k rows; a quarter
|
||||
of the US streets 475k. On 2026-10-11 the embed grew from 5.2 MB to 16 MB, and a CLI
|
||||
run printing the first `en_US.address` took 145 ms, `sv_SE.address` 95 ms and
|
||||
`misc.territory` 3 ms, within goal 13. `--place-share`, `--street-share` and
|
||||
`--min-streets` on the import scripts build another set. Valid while the first reach of
|
||||
a country stays unnoticed beside a test run.
|
||||
|
||||
## A locale's `address` binds its country's record once and prints it whole
|
||||
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
|
||||
| ID | Release | Exempt | Item | R | S | A | G | Goals | Score |
|
||||
|---|---|---|---|---|---|---|---|---|---|
|
||||
| 200 | 0.1.0 | | **Ship every Swedish street and a quarter of each US place's streets, at least ten.** | 2 | 2 | 9 | 9 | 2 | 32.6 |
|
||||
| 61 | 0.1.0 | | **Add a locale, with its `geo/` tree, for each of the ten most-spoken languages and each Nordic country.** | 4 | 9 | 9 | 10 | 2.1 | 30.8 |
|
||||
| 185 | 0.1.0 | decision | **Seat a panel of the README's audience personas to pull data in through the module API and build a custom CLI, and fix what it names.** | 1 | 3 | 7 | 8 | 2.3, 1 | 28.2 |
|
||||
| 16 | 0.1.0 | | **Add locale categories: company, phone, finance, vehicle, words.** | 3 | 8 | 8 | 9 | 2.2, 15 | 28.1 |
|
||||
@@ -76,7 +75,6 @@
|
||||
| 201 | 0.1.0 | | **Place each Swedish street in the postort whose area holds it, so a big postort such as Stockholm carries its own streets.** | 4 | 6 | 8 | 8 | 2, 16 | 25.7 |
|
||||
| 129 | 0.1.0 | decision | **Take a template wherever the library renders, so `fake:"{/sv_SE.person.first}"` and `Fake("{/sv_SE.person}")` render, and text with no `{…}` prints as written, as the CLI already does.** | 5 | 8 | 8 | 10 | 5.9, 7 | 25.0 |
|
||||
| 163 | 0.1.0 | | **Lift the CLI's `--repeat` cap, since the CLI streams each render, and give the builtins' count and decimal caps a technical reason in the README.** | 2 | 2 | 7 | 7 | 2, 5.7 | 24.8 |
|
||||
| 199 | 0.1.0 | | **Ship every state capital and every US place of 100,000 or more beside the drawn tenth of the US places.** | 2 | 3 | 6 | 7 | 2, 16 | 22.5 |
|
||||
| 57 | 0.1.0 | | **Rewrite `CHANGELOG.md`'s `[Unreleased]` as what v0.1.0 holds.** | 1 | 2 | 6 | 6 | 1.1 | 22.5 |
|
||||
| 196 | 0.1.0 | decision | **Name, in the error for a reference nothing loaded provides, the module the reader's manifest reads by default that would provide it, or say none does.** | 3 | 4 | 6 | 8 | 6.2, 9.2 | 20.0 |
|
||||
| 164 | 0.1.0 | | **Let a table's format or a cell bind a name, which lives in that format or cell and keeps one pick through the draw.** | 2 | 2 | 5 | 7 | 4.1, 5.3 | 19.4 |
|
||||
@@ -177,10 +175,6 @@
|
||||
|
||||
## Details
|
||||
|
||||
### 200. Ship every Swedish street and a quarter of each US place's streets, at least ten.
|
||||
|
||||
The maintainer chose these shares on 2026-10-11, after a tenth gave Göteborg 163 streets and Stockholm 37. Measured that day against a tenth: every Swedish street is 174k rows and 4.5 MB, with the first `sv_SE.address` in 74 ms; a quarter of the US streets is about 457k rows and 10 MB. The defaults of `--street-share` move per country, and the decision "The default embed holds every Swedish postort…" is revised to match. Re-pin seeded output in its own commit.
|
||||
|
||||
### 61. Add a locale, with its `geo/` tree, for each of the ten most-spoken languages and each Nordic country.
|
||||
|
||||
Pick the ten from a published ranking of languages by total speakers, such as Ethnologue's, each in the country where it has the most speakers, and record the ranking in the decision that names them. The Nordic ones are sv_SE (shipped), nb_NO, da_DK, fi_FI and is_IS. A new country decides three rules `geo-se.py` fixes for SE: `well_cased` drops a name spelled in capitals, and Bring's register spells every poststed so; a locality is keyed by name in SE and by code in US; and `data_test.go`'s `geoPlaces` reads every country but US by SE's column positions. A second country reading GeoNames' postal codes moves `geonames()` from `geo-se.py`, and the nearest-centroid street assignment in its `streets()`, into `geo.py`. Each locale carries goal 2.2's categories, and its `address` reads its country's `geo/` tree by reference. `rows.Pins` holds eight pins inline, sized for a five-deep geo tree; a deeper tree needs more to keep a render off the heap.
|
||||
@@ -284,10 +278,6 @@ Split it into items for the CLI, struct tags and the library before starting.
|
||||
|
||||
The README's Audience names a bulk fixture author writing millions of rows, and `-n 5000000` is misuse today, so they loop. The decision "The repeat cap bounds renders, not bytes" covers nested repeats in data, not `-n`. The README's Functions section justifies the builtin caps by a fat-fingered `hex(2000000000)`, a guess at a mistake under goal 5.7; the reason that holds is that one render may not allocate gigabytes. The goals audit of the narrowed goal 5.7 found it.
|
||||
|
||||
### 199. Ship every state capital and every US place of 100,000 or more beside the drawn tenth of the US places.
|
||||
|
||||
The maintainer ruled so on 2026-10-11. The draw by population leaves out about 25 of the 335 places of 100,000 or more, and some state capitals, so a test author pinning a city they know hits `no row of … has key or name`. Shipping them always keeps such selectors working across a refresh of the sources. Source the capitals from a published list and cite it in the decision on the default embed; a capital owning no ZCTA, such as one whose codes lie mostly in a neighbour, is named in the import's log.
|
||||
|
||||
### 57. Rewrite `CHANGELOG.md`'s `[Unreleased]` as what v0.1.0 holds.
|
||||
|
||||
Nothing has shipped, so "no longer paths", "where it used to fail" and "where it used to be an empty string" describe versions no reader can have installed.
|
||||
|
||||
Reference in New Issue
Block a user