Browse Source

Merge pull request #356 from pelias/improved_address_schema

update address matching analyzers.
pull/363/head
Peter Johnson a.k.a. insertcoffee 9 years ago
parent
commit
a0e174fad8
  1. 3
      helper/adminFields.js
  2. 8
      query/autocomplete_defaults.js
  3. 6
      query/reverse_defaults.js
  4. 8
      query/search_defaults.js

3
helper/adminFields.js

@ -10,7 +10,8 @@ var ADMIN_FIELDS = [
'admin2', 'admin2',
'local_admin', 'local_admin',
'locality', 'locality',
'neighborhood' 'neighborhood',
'address.zip'
]; ];
/** /**

8
query/autocomplete_defaults.js

@ -38,17 +38,17 @@ module.exports = extend( false, peliasQuery.defaults, {
'function_score:score_mode': 'avg', 'function_score:score_mode': 'avg',
'function_score:boost_mode': 'replace', 'function_score:boost_mode': 'replace',
'address:housenumber:analyzer': 'standard', 'address:housenumber:analyzer': 'peliasHousenumber',
'address:housenumber:field': 'address.number', 'address:housenumber:field': 'address.number',
'address:housenumber:boost': 2, 'address:housenumber:boost': 2,
'address:street:analyzer': 'standard', 'address:street:analyzer': 'peliasStreet',
'address:street:field': 'address.street', 'address:street:field': 'address.street',
'address:street:boost': 5, 'address:street:boost': 5,
'address:postcode:analyzer': 'standard', 'address:postcode:analyzer': 'peliasZip',
'address:postcode:field': 'address.zip', 'address:postcode:field': 'address.zip',
'address:postcode:boost': 3, 'address:postcode:boost': 20,
'admin:alpha3:analyzer': 'standard', 'admin:alpha3:analyzer': 'standard',
'admin:alpha3:field': 'alpha3', 'admin:alpha3:field': 'alpha3',

6
query/reverse_defaults.js

@ -38,15 +38,15 @@ module.exports = extend( false, peliasQuery.defaults, {
'function_score:score_mode': 'avg', 'function_score:score_mode': 'avg',
'function_score:boost_mode': 'replace', 'function_score:boost_mode': 'replace',
'address:housenumber:analyzer': 'standard', 'address:housenumber:analyzer': 'peliasHousenumber',
'address:housenumber:field': 'address.number', 'address:housenumber:field': 'address.number',
'address:housenumber:boost': 2, 'address:housenumber:boost': 2,
'address:street:analyzer': 'standard', 'address:street:analyzer': 'peliasStreet',
'address:street:field': 'address.street', 'address:street:field': 'address.street',
'address:street:boost': 5, 'address:street:boost': 5,
'address:postcode:analyzer': 'standard', 'address:postcode:analyzer': 'peliasZip',
'address:postcode:field': 'address.zip', 'address:postcode:field': 'address.zip',
'address:postcode:boost': 3, 'address:postcode:boost': 3,

8
query/search_defaults.js

@ -38,17 +38,17 @@ module.exports = extend( false, peliasQuery.defaults, {
'function_score:score_mode': 'avg', 'function_score:score_mode': 'avg',
'function_score:boost_mode': 'replace', 'function_score:boost_mode': 'replace',
'address:housenumber:analyzer': 'standard', 'address:housenumber:analyzer': 'peliasHousenumber',
'address:housenumber:field': 'address.number', 'address:housenumber:field': 'address.number',
'address:housenumber:boost': 2, 'address:housenumber:boost': 2,
'address:street:analyzer': 'standard', 'address:street:analyzer': 'peliasStreet',
'address:street:field': 'address.street', 'address:street:field': 'address.street',
'address:street:boost': 5, 'address:street:boost': 5,
'address:postcode:analyzer': 'standard', 'address:postcode:analyzer': 'peliasZip',
'address:postcode:field': 'address.zip', 'address:postcode:field': 'address.zip',
'address:postcode:boost': 3, 'address:postcode:boost': 20,
'admin:alpha3:analyzer': 'standard', 'admin:alpha3:analyzer': 'standard',
'admin:alpha3:field': 'alpha3', 'admin:alpha3:field': 'alpha3',

Loading…
Cancel
Save