Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pelias-query

Package Overview
Dependencies
Maintainers
5
Versions
76
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pelias-query - npm Package Compare versions

Comparing version 5.1.0 to 6.0.0

44

defaults.json

@@ -48,33 +48,33 @@ {

"admin:alpha3:analyzer": "standard",
"admin:alpha3:field": "alpha3",
"admin:alpha3:boost": 1,
"admin:country_a:analyzer": "standard",
"admin:country_a:field": "parent.country_a",
"admin:country_a:boost": 1,
"admin:admin0:analyzer": "peliasAdmin",
"admin:admin0:field": "admin0",
"admin:admin0:boost": 1,
"admin:country:analyzer": "peliasAdmin",
"admin:country:field": "parent.country",
"admin:country:boost": 1,
"admin:admin1:analyzer": "peliasAdmin",
"admin:admin1:field": "admin1",
"admin:admin1:boost": 1,
"admin:region:analyzer": "peliasAdmin",
"admin:region:field": "paretn.region",
"admin:region:boost": 1,
"admin:admin1_abbr:analyzer": "peliasAdmin",
"admin:admin1_abbr:field": "admin1_abbr",
"admin:admin1_abbr:boost": 1,
"admin:region_a:analyzer": "peliasAdmin",
"admin:region_a:field": "parent.region_a",
"admin:region_a:boost": 1,
"admin:admin2:analyzer": "peliasAdmin",
"admin:admin2:field": "admin2",
"admin:admin2:boost": 1,
"admin:county:analyzer": "peliasAdmin",
"admin:county:field": "parent.county",
"admin:county:boost": 1,
"admin:local_admin:analyzer": "peliasAdmin",
"admin:local_admin:field": "local_admin",
"admin:local_admin:boost": 1,
"admin:localadmin:analyzer": "peliasAdmin",
"admin:localadmin:field": "parent.localadmin",
"admin:localadmin:boost": 1,
"admin:locality:analyzer": "peliasAdmin",
"admin:locality:field": "locality",
"admin:locality:field": "parent.locality",
"admin:locality:boost": 1,
"admin:neighborhood:analyzer": "peliasAdmin",
"admin:neighborhood:field": "neighborhood",
"admin:neighborhood:boost": 1,
"admin:neighbourhood:analyzer": "peliasAdmin",
"admin:neighbourhood:field": "parent.neighbourhood",
"admin:neighbourhood:boost": 1,

@@ -81,0 +81,0 @@ "popularity:field": "popularity",

@@ -19,3 +19,3 @@

vs.set({ 'boundary:country': 'USA' });
vs.set({ 'input:admin2': 'New York' });
vs.set({ 'input:county': 'New York' });

@@ -36,10 +36,10 @@ // mandatory matches

// admin components
q.score( query.view.admin('alpha3') )
.score( query.view.admin('admin0') )
.score( query.view.admin('admin1') )
.score( query.view.admin('admin1_abbr') )
.score( query.view.admin('admin2') )
.score( query.view.admin('local_admin') )
q.score( query.view.admin('country_a') )
.score( query.view.admin('country') )
.score( query.view.admin('region') )
.score( query.view.admin('region_a') )
.score( query.view.admin('county') )
.score( query.view.admin('localadmin') )
.score( query.view.admin('locality') )
.score( query.view.admin('neighborhood') );
.score( query.view.admin('neighbourhood') );

@@ -46,0 +46,0 @@ // non-scoring hard filters

{
"name": "pelias-query",
"version": "5.1.0",
"version": "6.0.0",
"description": "An Elasticsearch query builder for Pelias",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -126,10 +126,10 @@ Elasticsearch geospatial and linguistic matching queries used by Pelias.

input:alpha3: "GBR"
input:admin0: "hackney"
input:admin1: "hackney"
input:admin1_abbr: "hackney"
input:admin2: "hackney"
input:local_admin: "hackney"
input:country_a: "GBR"
input:country: "hackney"
input:region: "hackney"
input:region_a: "hackney"
input:county: "hackney"
input:localadmin: "hackney"
input:locality: "hackney"
input:neighborhood: "hackney"
input:neighbourhood: "hackney"

@@ -136,0 +136,0 @@ boundary:circle:lat: 1

@@ -6,4 +6,4 @@

if( !vs.isset('boundary:country') ||
!vs.isset('admin:alpha3:analyzer') ||
!vs.isset('admin:alpha3:field') ){
!vs.isset('admin:country_a:analyzer') ||
!vs.isset('admin:country_a:field') ){
return null;

@@ -16,4 +16,4 @@ }

// match query
view.match[ vs.var('admin:alpha3:field') ] = {
analyzer: vs.var('admin:alpha3:analyzer'),
view.match[ vs.var('admin:country_a:field') ] = {
analyzer: vs.var('admin:country_a:analyzer'),
query: vs.var('boundary:country')

@@ -20,0 +20,0 @@ };

@@ -23,4 +23,4 @@

// { 'type': { 'value': 'locality' } },
// { 'type': { 'value': 'local_admin' } },
// { 'type': { 'value': 'neighborhood' } }
// { 'type': { 'value': 'localadmin' } },
// { 'type': { 'value': 'neighbourhood' } }
// ]

@@ -27,0 +27,0 @@ // },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc