[addresses] Fixes for English/French Canadian apartment numbers
This commit is contained in:
@@ -1357,16 +1357,19 @@ countries:
|
|||||||
components:
|
components:
|
||||||
combinations:
|
combinations:
|
||||||
house_number_unit:
|
house_number_unit:
|
||||||
|
probability: 0.0
|
||||||
|
unit_house_number:
|
||||||
components:
|
components:
|
||||||
- unit
|
- unit
|
||||||
- house_number
|
- house_number
|
||||||
|
label: house_number
|
||||||
separators:
|
separators:
|
||||||
- separator: /
|
- separator: /
|
||||||
probability: 0.1
|
probability: 0.04
|
||||||
- separator: "-"
|
- separator: "-"
|
||||||
probability: 0.8
|
probability: 0.95
|
||||||
- separator: " - "
|
- separator: " - "
|
||||||
probability: 0.1
|
probability: 0.01
|
||||||
probability: 0.1
|
probability: 0.1
|
||||||
levels:
|
levels:
|
||||||
# Note: Canadian English uses "storey" keeping with the British convention, so no need to change that
|
# Note: Canadian English uses "storey" keeping with the British convention, so no need to change that
|
||||||
|
|||||||
@@ -4,9 +4,8 @@
|
|||||||
components:
|
components:
|
||||||
level:
|
level:
|
||||||
# If no floor number is specified
|
# If no floor number is specified
|
||||||
null_probability: 0.6
|
null_probability: 0.8
|
||||||
alphanumeric_probability: 0.35
|
alphanumeric_probability: 0.2
|
||||||
standalone_probability: 0.05
|
|
||||||
|
|
||||||
staircase:
|
staircase:
|
||||||
null_probability: 0.99
|
null_probability: 0.99
|
||||||
@@ -18,12 +17,10 @@ components:
|
|||||||
|
|
||||||
unit:
|
unit:
|
||||||
# If no unit number is specified
|
# If no unit number is specified
|
||||||
null_probability: 0.3
|
null_probability: 0.8
|
||||||
alphanumeric_probability: 0.65
|
alphanumeric_probability: 0.2
|
||||||
standalone_probability: 0.05
|
|
||||||
|
|
||||||
combinations:
|
combinations:
|
||||||
# For unit types like 2/34 (more common in Canada and Australia)
|
|
||||||
house_number_unit:
|
house_number_unit:
|
||||||
components:
|
components:
|
||||||
- house_number
|
- house_number
|
||||||
@@ -92,9 +89,8 @@ levels:
|
|||||||
sample_probability: 0.2
|
sample_probability: 0.2
|
||||||
numeric:
|
numeric:
|
||||||
direction: left
|
direction: left
|
||||||
direction_probability: 0.8
|
|
||||||
add_number_phrase: true
|
add_number_phrase: true
|
||||||
add_number_phrase_probability: 0.2
|
add_number_phrase_probability: 0.05
|
||||||
ordinal:
|
ordinal:
|
||||||
direction: right
|
direction: right
|
||||||
numeric_probability: 0.75
|
numeric_probability: 0.75
|
||||||
@@ -106,9 +102,8 @@ levels:
|
|||||||
sample_probability: 0.1
|
sample_probability: 0.1
|
||||||
numeric:
|
numeric:
|
||||||
direction: left
|
direction: left
|
||||||
direction_probability: 0.8
|
|
||||||
add_number_phrase: true
|
add_number_phrase: true
|
||||||
add_number_phrase_probability: 0.2
|
add_number_phrase_probability: 0.05
|
||||||
ordinal:
|
ordinal:
|
||||||
direction: right
|
direction: right
|
||||||
numeric_probability: 0.75
|
numeric_probability: 0.75
|
||||||
@@ -419,7 +414,7 @@ entrances:
|
|||||||
directional:
|
directional:
|
||||||
modifier:
|
modifier:
|
||||||
direction: right # e.g. Entrance Nord
|
direction: right # e.g. Entrance Nord
|
||||||
direction_probability: 0.9
|
direction_probability: 0.95
|
||||||
alternatives:
|
alternatives:
|
||||||
- alternative: *nord
|
- alternative: *nord
|
||||||
- alternative: *sud
|
- alternative: *sud
|
||||||
@@ -456,8 +451,8 @@ staircases:
|
|||||||
whitespace_probability: 0.1
|
whitespace_probability: 0.1
|
||||||
|
|
||||||
directional:
|
directional:
|
||||||
direction: right # e.g. Escalera Izq
|
direction: right # e.g. Escalier Izq
|
||||||
direction_probability: 0.8
|
direction_probability: 0.9
|
||||||
modifier:
|
modifier:
|
||||||
alternatives:
|
alternatives:
|
||||||
- alternative: *nord
|
- alternative: *nord
|
||||||
@@ -637,6 +632,27 @@ units:
|
|||||||
probability: 0.095
|
probability: 0.095
|
||||||
- alternative: *chambre
|
- alternative: *chambre
|
||||||
probability: 0.005
|
probability: 0.005
|
||||||
|
numeric_probability: 0.9 # e.g. Appartement 1
|
||||||
|
numeric_plus_alpha_probability: 0.03 # e.g. 1A
|
||||||
|
alpha_plus_numeric_probability: 0.03 # e.g. A1
|
||||||
|
alpha_probability: 0.04 # e.g. Appartement A
|
||||||
|
|
||||||
|
alpha_plus_numeric:
|
||||||
|
whitespace_probability: 0.1
|
||||||
|
numeric_plus_alpha:
|
||||||
|
whitespace_probability: 0.1
|
||||||
|
|
||||||
|
# Separate random probability for adding directions like 2D, 2G, etc.
|
||||||
|
add_direction: true
|
||||||
|
add_direction_probability: 0.1
|
||||||
|
|
||||||
|
# Add directions for plain numbers
|
||||||
|
add_direction_numeric: true
|
||||||
|
# Add direction only e.g. Unité Gauche
|
||||||
|
add_direction_standalone: true
|
||||||
|
|
||||||
|
# If there are 10 floors, create unit numbers like #301 or #1032
|
||||||
|
use_floor_probability: 0.1
|
||||||
|
|
||||||
zones:
|
zones:
|
||||||
residential: *unit_alphanumeric
|
residential: *unit_alphanumeric
|
||||||
@@ -763,37 +779,6 @@ categories:
|
|||||||
- alternative:
|
- alternative:
|
||||||
canonical: a proximite de la
|
canonical: a proximite de la
|
||||||
probability: 0.05
|
probability: 0.05
|
||||||
alternatives:
|
|
||||||
- alternative:
|
|
||||||
canonical: próximo
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: proximo
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: cerca de aquí
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: cerca de aqui
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: acá
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: aca
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: cerca de acá
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: cerca de aca
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: por aquí
|
|
||||||
probability: 0.05
|
|
||||||
- alternative:
|
|
||||||
canonical: por aqui
|
|
||||||
probability: 0.05
|
|
||||||
near_me:
|
near_me:
|
||||||
default:
|
default:
|
||||||
canonical: proche de chez moi
|
canonical: proche de chez moi
|
||||||
@@ -834,11 +819,50 @@ categories:
|
|||||||
|
|
||||||
countries:
|
countries:
|
||||||
ca:
|
ca:
|
||||||
|
components:
|
||||||
|
|
||||||
|
unit:
|
||||||
|
null_probability: 0.6
|
||||||
|
alphanumeric_probability: 0.4
|
||||||
|
combinations:
|
||||||
|
house_number_unit:
|
||||||
|
probability: 0.0
|
||||||
|
unit_house_number:
|
||||||
|
components:
|
||||||
|
- unit
|
||||||
|
- house_number
|
||||||
|
label: house_number
|
||||||
|
separators:
|
||||||
|
- separator: /
|
||||||
|
probability: 0.04
|
||||||
|
- separator: "-"
|
||||||
|
probability: 0.95
|
||||||
|
- separator: " - "
|
||||||
|
probability: 0.01
|
||||||
|
probability: 0.1
|
||||||
levels:
|
levels:
|
||||||
numbering_starts_at: 1
|
numbering_starts_at: 1
|
||||||
aliases:
|
aliases:
|
||||||
"1":
|
"1":
|
||||||
default: *rez_de_chaussee
|
# Have to do this because etage is numeric
|
||||||
|
# and has keys like "numeric_probability" which
|
||||||
|
# we don't want to infect rez_de_chausee when doing
|
||||||
|
# a recursive merge
|
||||||
|
default: *etage
|
||||||
|
probability: 0.1
|
||||||
|
alternatives:
|
||||||
|
- alternative: *rez_de_chaussee
|
||||||
|
probability: 0.8
|
||||||
|
- alternative: *bel_etage
|
||||||
|
probability: 0.05
|
||||||
|
- alternative: *etage_noble
|
||||||
|
probability: 0.05
|
||||||
|
|
||||||
|
units:
|
||||||
|
alphanumeric:
|
||||||
|
# More common to use in in Canada, as in the US
|
||||||
|
use_floor_probability: 0.35
|
||||||
|
|
||||||
be:
|
be:
|
||||||
units:
|
units:
|
||||||
alphanumeric:
|
alphanumeric:
|
||||||
|
|||||||
Reference in New Issue
Block a user