Conversation
|
I know TristanDiet-TomTom will provide the deep insights on property names and edge cases around the world, so I'll steer clear of that. One thing I think is important (as discussed a bit in this morning's Schema TF meeting) relates to the 3 "admin levels" referenced in the summary, currently stated as
What if we did this? 👇 It's annoying in the short-term due to schema refactoring, but probably gives us the most coherent overall schema in the longer-term.
|
|
Victor Schappert (@vcschapp) Thanks. At the addresses meeting today, people liked the idea of just getting very generic here and calling it "admin1", "admin2", "admin3", etc. (exact name TBD but something like that is where we're leaning) and not try to map everything neatly to a known hierarchical value like the division subtypes. The idea would not be to treat these like admin_levels but rather just populate them in order. So in US, admin1 is state, admin2 is city. But some places might have admin1 as state, admin2 is county, admin3 is city, etc. Not sure. I think country could stay as these will always be valid ISO3166-2 country codes. |
This seems reasonable. It can also be an array property so we don't need 3 columns for it. |
bff7266 to
1d99ef9
Compare
|
An alternative considered is to use a list of 5 elements and have null elements e.g. |
6e585fb to
d49b740
Compare
Sharing a couple thoughts. NamingWhat if we used the word My thoughts are:
StructureHaving five top-level columns suffixed 1-5 really bugs me. It seems to be calling out for some kind of structured usage. As discussed in today's Schema TF meeting, my map idea won't work. (Or would have to be made really awkward to make it work.) I don't mind your array with One pattern we have used successfully in other parts of the Overture schema is an array of structures. While it's a little bit less susceptible to JSON Schema validation, it does provide some other benefits. We use it in ---
properties:
theme: addresses
type: address
humber: 10
street: Downing Street
sectors:
- level: 1
value: London
- level: 3
value: UK |
|
Victor Schappert (@vcschapp) Thanks for the feedback. After discussing with a bunch of people on address-tf I think I'm leaning towards a single list. We are not going to align the levels across countries, they'll still just be populated in order on a per-country basis. So each country will have a known length, but each individual record might not have all values populated and some can be null. Also I discussed with Matt Travis (@mtravis) from AddressCloud who said the phrase "address_level" is sometimes used to describe these fields so that's how I'm leaning. We'll have a set of rules for each country that describes how address fields map to indexes within |
Jacob Wasserman (@jwass) Victor Schappert (@vcschapp) I'm really keen to use address_levels as opposed to admin or something else. And using a list is a great idea and allows us more scope for change in the future if needed. |
This is a another little papercut reason why I'd like to replace |
|
Victor Schappert (@vcschapp) Are you okay with |
d49b740 to
7b2486b
Compare
We recently decided that the initial addresses schema would be based on the output of the Open Addresses (OA) "conform" schema. The definition of the fields can be found at https://github.com/openaddresses/openaddresses/blob/master/schema/layers/address_conform.json This initial schema is a strawman intended for feedback and discussion. Our initial schema looks at all properties included in the US Northeast distribution which includes the following fields: * id * country (the first element in the filepath e.g. us/ma/city_of_boston-addresses-city.geojson is "us") * subcountry (the second element in the filepath e.g. us/ma/city_of_boston-addresses-city.geojson is "ma") - This field should be renamed or be removed * region * district * city * postcode * street * number * unit
Update the address schema to contain the following fields: * country (required) * street (required) * number (required) * unit (optional) * postcode (required) * region (optional) * city (optional) * district (optional) In the future we may add rules that depending on the country, it will make certain fields required or forbidden.
Remove region, city, district and replace with a more generic/flexible levels name
3f68c9e to
aaa1547
Compare
David Karlaš (DavidKarlas)
left a comment
There was a problem hiding this comment.
Ideally we would have references to other entites in divisions and other themes like named road segment instead of street name… But all of that can be added later as additional properties, I think this is good starting schema for addresses.
See initial PR #179
Addresses defines a point to describe a single address. All addresses have:
Furthermore we need 3 "admin levels". Depending on the country or region, some may be required or forbidden. We have not yet defined these rules or added them to the schema. The 3 fields for each level are:
Note that addresses can be arbitrary and often without significant rules or structure. So we cannot restrict the "region" value to be an ISO3166 subdivision code. Different regions refer to the admin levels in their own way but we map them to one of the above fields depending on the region.
This first version does not link addresses to divisions and leaves it for future progress