From f14cf9f29286286c80317675438ba4abc8ea506c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Tue, 20 Jul 2021 17:10:34 +0200 Subject: [PATCH 001/361] web: Add french fields to the index. * web/src/main/webResources/WEB-INF/data/config/index/records.json: Add fields langfre and anyfre with french analyzer. --- .../WEB-INF/data/config/index/records.json | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records.json b/web/src/main/webResources/WEB-INF/data/config/index/records.json index 5f151ad9235..30a8c819fa8 100644 --- a/web/src/main/webResources/WEB-INF/data/config/index/records.json +++ b/web/src/main/webResources/WEB-INF/data/config/index/records.json @@ -997,6 +997,19 @@ } } }, + "langfre": { + "type": "text", + "analyzer": "french", + "copy_to": [ + "anyfre" + ], + "fields": { + "keyword": { + "type": "keyword", + "ignore_above": 256 + } + } + }, "link": { "type": "keyword" } @@ -1220,6 +1233,10 @@ "type": "text", "analyzer": "${es.index.analyzer.default}" }, + "anyfre": { + "type": "text", + "analyzer": "french" + }, "anytext": { "type": "search_as_you_type" }, From a04c57aeccf6dee7b4353e1041ce6fbf659ae6be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Tue, 20 Jul 2021 17:12:16 +0200 Subject: [PATCH 002/361] WIP: Use the anyfre field for Queries. Testing french stopwords. --- web-ui/src/main/resources/catalog/js/CatController.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web-ui/src/main/resources/catalog/js/CatController.js b/web-ui/src/main/resources/catalog/js/CatController.js index 2b4db1df15c..86f45b45d8f 100644 --- a/web-ui/src/main/resources/catalog/js/CatController.js +++ b/web-ui/src/main/resources/catalog/js/CatController.js @@ -146,7 +146,8 @@ goog.require('gn_alert'); // Full text on all fields // 'queryBase': '${any}', // Full text but more boost on title match - 'queryBase': 'any:(${any}) resourceTitleObject.\\*:(${any})^2', + 'queryBase': 'anyfre:(${any})', + //'queryBase': 'any:(${any}) resourceTitleObject.\\*:(${any})^2', 'queryTitle': '${any}', 'searchOptions': true, // Score query may depend on where we are in the app? From d5538fa902e5a4dd66445d0fcc988ead4eb30740 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Thu, 22 Jul 2021 18:11:01 +0200 Subject: [PATCH 003/361] Add translation fields to es-index. records.json: Add properties lang... for different languages. copy_to to these properties. --- .../WEB-INF/data/config/index/records.json | 68 +++++++++++++++---- 1 file changed, 54 insertions(+), 14 deletions(-) diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records.json b/web/src/main/webResources/WEB-INF/data/config/index/records.json index 30a8c819fa8..6e11912d6dc 100644 --- a/web/src/main/webResources/WEB-INF/data/config/index/records.json +++ b/web/src/main/webResources/WEB-INF/data/config/index/records.json @@ -2,7 +2,7 @@ "settings": { "index": { "max_result_window": ${es.index.max_result_window.limit}, - "query.default_field": "any", + "query.default_field": "any.default", "mapping.total_fields.limit": ${es.index.mapping.total_fields.limit}, "analysis": { "analyzer": { @@ -979,7 +979,12 @@ "type": "text", "analyzer": "${es.index.analyzer.default}", "copy_to": [ - "any", + "any.default", + "any.langeng", + "any.langfre", + "any.langger", + "any.langita", + "any.langroh", "anytext" ], "fields": { @@ -1083,7 +1088,12 @@ "default": { "type": "keyword", "copy_to": [ - "any", + "any.default", + "any.langeng", + "any.langfre", + "any.langger", + "any.langita", + "any.langroh", "anytext" ] }, @@ -1230,12 +1240,37 @@ ], "properties": { "any": { - "type": "text", - "analyzer": "${es.index.analyzer.default}" - }, - "anyfre": { - "type": "text", - "analyzer": "french" + "type": "object", + "properties": { + "default": { + "type": "text", + "analyzer": "${es.index.analyzer.default}" + }, + "common": { + "type": "text", + "analyzer": "${es.index.analyzer.default}" + }, + "langeng": { + "type": "text", + "analyzer": "english" + }, + "langfre": { + "type": "text", + "analyzer": "french" + }, + "langger": { + "type": "text", + "analyzer": "german" + }, + "langita": { + "type": "text", + "analyzer": "italian" + }, + "langroh": { + "type": "text", + "analyzer": "${es.index.analyzer.default}" + } + } }, "anytext": { "type": "search_as_you_type" @@ -1246,7 +1281,12 @@ "default": { "type": "keyword", "copy_to": [ - "any", + "any.default", + "any.langeng", + "any.langfre", + "any.langger", + "any.langita", + "any.langroh", "anytext" ] }, @@ -1307,7 +1347,7 @@ }, "uuid": { "type": "keyword", - "copy_to": "any" + "copy_to": "any.common" }, "id": { "type": "keyword" @@ -1358,14 +1398,14 @@ "properties": { "protocol": { "type": "keyword", - "copy_to": "any" + "copy_to": "any.common" }, "link": { "type": "text" }, "name": { "type": "text", - "copy_to": "any" + "copy_to": "any.common" }, "description": { "type": "text" @@ -1483,7 +1523,7 @@ "properties": { "code": { "type": "keyword", - "copy_to": "any" + "copy_to": "any.common" }, "codeSpace": { "type": "keyword" From 9f66a89033c4cdfaf91a59a3b8b31c53f5bbaf40 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Thu, 22 Jul 2021 18:16:53 +0200 Subject: [PATCH 004/361] Add more language fields to es index. --- .../WEB-INF/data/config/index/records.json | 54 ++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records.json b/web/src/main/webResources/WEB-INF/data/config/index/records.json index 6e11912d6dc..6d6aab33af2 100644 --- a/web/src/main/webResources/WEB-INF/data/config/index/records.json +++ b/web/src/main/webResources/WEB-INF/data/config/index/records.json @@ -1002,11 +1002,63 @@ } } }, + "langeng": { + "type": "text", + "analyzer": "english", + "copy_to": [ + "any.langeng" + ], + "fields": { + "keyword": { + "type": "keyword", + "ignore_above": 256 + } + } + }, "langfre": { "type": "text", "analyzer": "french", "copy_to": [ - "anyfre" + "any.langfre" + ], + "fields": { + "keyword": { + "type": "keyword", + "ignore_above": 256 + } + } + }, + "langger": { + "type": "text", + "analyzer": "german", + "copy_to": [ + "any.langger" + ], + "fields": { + "keyword": { + "type": "keyword", + "ignore_above": 256 + } + } + }, + "langita": { + "type": "text", + "analyzer": "italian", + "copy_to": [ + "any.langita" + ], + "fields": { + "keyword": { + "type": "keyword", + "ignore_above": 256 + } + } + }, + "langroh": { + "type": "text", + "analyzer": "${es.index.analyzer.default}", + "copy_to": [ + "any.langroh" ], "fields": { "keyword": { From e21e10cc233be28d19043e273eaabeeaa162819b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Thu, 22 Jul 2021 18:47:37 +0200 Subject: [PATCH 005/361] WIP: CatController.js: Change quryBase to FRE. --- web-ui/src/main/resources/catalog/js/CatController.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web-ui/src/main/resources/catalog/js/CatController.js b/web-ui/src/main/resources/catalog/js/CatController.js index 86f45b45d8f..0ddc21d694e 100644 --- a/web-ui/src/main/resources/catalog/js/CatController.js +++ b/web-ui/src/main/resources/catalog/js/CatController.js @@ -146,7 +146,7 @@ goog.require('gn_alert'); // Full text on all fields // 'queryBase': '${any}', // Full text but more boost on title match - 'queryBase': 'anyfre:(${any})', + 'queryBase': 'any.fre:(${any}) any.common:(${any})', //'queryBase': 'any:(${any}) resourceTitleObject.\\*:(${any})^2', 'queryTitle': '${any}', 'searchOptions': true, From df4645694995a089bcacba74d00302ecacc3eb96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn=20H=C3=B6fling?= Date: Thu, 22 Jul 2021 23:01:27 +0200 Subject: [PATCH 006/361] Remove fields that are too much. --- .../main/webResources/WEB-INF/data/config/index/records.json | 5 ----- 1 file changed, 5 deletions(-) diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records.json b/web/src/main/webResources/WEB-INF/data/config/index/records.json index 6d6aab33af2..1ae740c62be 100644 --- a/web/src/main/webResources/WEB-INF/data/config/index/records.json +++ b/web/src/main/webResources/WEB-INF/data/config/index/records.json @@ -980,11 +980,6 @@ "analyzer": "${es.index.analyzer.default}", "copy_to": [ "any.default", - "any.langeng", - "any.langfre", - "any.langger", - "any.langita", - "any.langroh", "anytext" ], "fields": { From 70f92eda2e233b927a255294760ffc8b878c1518 Mon Sep 17 00:00:00 2001 From: Francois Prunayre Date: Wed, 11 Aug 2021 07:56:50 +0200 Subject: [PATCH 007/361] Index / Multilingual / Per field analyzer config improvements. * Remove schema for french only. * Add asciifolding in french for better support of accents * Update doc * Dispatch keywords in proper full text lang field. --- es/README.md | 25 +- .../WEB-INF/data/config/index/records.json | 105 +- .../data/config/index/records_french.json | 1613 ----------------- 3 files changed, 100 insertions(+), 1643 deletions(-) delete mode 100644 web/src/main/webResources/WEB-INF/data/config/index/records_french.json diff --git a/es/README.md b/es/README.md index 00edc947c0f..bf4b377379d 100644 --- a/es/README.md +++ b/es/README.md @@ -81,24 +81,23 @@ curl -X DELETE http://localhost:9200/$IDX_PREFIX-features curl -X DELETE http://localhost:9200/$IDX_PREFIX-searchlogs ``` -## Multilingual configuration (beta) +## Multilingual configuration -* Stop Elasticsearch -* Define which analyzer to use https://www.elastic.co/guide/en/elasticsearch/reference/current/analysis-analyzers.html depending on the language(s) used in your catalogue -* Build the application with the default analyzer to use (or configure it in `data/index/records.json`) +Default index is configured with analyzer for the following languages: +* English +* French +* German +* Italian + +To add a new language, update the index schema in `datadir/config/index/records.json` and update the fields containing fields starting with `lang`. - ```shell script - mvn clean install -Des.default.analyzer=french_heavy - ``` +First create a full text search field for the new language in the `any` object field eg. `any.langfre` and define the proper analyzer. -* Install ICU plugin (if needed) +Then add the new language like others. - ```shell script - elasticsearch-plugin install analysis-icu - ``` +From the admin console > tools, Delete index and reindex. -* Start Elasticsearch -* Drop and rebuild your index +Don't hesitate to propose a Pull Request with the new language. # Production use diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records.json b/web/src/main/webResources/WEB-INF/data/config/index/records.json index 1ae740c62be..71cce9376ce 100644 --- a/web/src/main/webResources/WEB-INF/data/config/index/records.json +++ b/web/src/main/webResources/WEB-INF/data/config/index/records.json @@ -20,6 +20,17 @@ "reverse" ] }, + "french_rebuilt": { + "tokenizer": "standard", + "filter": [ + "french_elision", + "lowercase", + "french_stop", + "asciifolding", + "french_keywords", + "french_stemmer" + ] + }, "synInspireAnnexes": { "tokenizer": "keyword", "filter": [ @@ -71,6 +82,27 @@ "min_shingle_size": 2, "max_shingle_size": 3 }, + "french_elision": { + "type": "elision", + "articles_case": true, + "articles": [ + "l", "m", "t", "qu", "n", "s", + "j", "d", "c", "jusqu", "quoiqu", + "lorsqu", "puisqu" + ] + }, + "french_stop": { + "type": "stop", + "stopwords": "_french_" + }, + "french_keywords": { + "type": "keyword_marker", + "keywords": [] + }, + "french_stemmer": { + "type": "stemmer", + "language": "light_french" + }, "keepInspireServiceTypes": { "type": "keep", "keep_words": [ @@ -1012,7 +1044,7 @@ }, "langfre": { "type": "text", - "analyzer": "french", + "analyzer": "french_rebuilt", "copy_to": [ "any.langfre" ], @@ -1135,13 +1167,31 @@ "default": { "type": "keyword", "copy_to": [ - "any.default", - "any.langeng", - "any.langfre", - "any.langger", - "any.langita", - "any.langroh", - "anytext" + "any.default" + ] + }, + "langeng": { + "type": "keyword", + "copy_to": [ + "any.langeng" + ] + }, + "langfre": { + "type": "keyword", + "copy_to": [ + "any.langfre" + ] + }, + "langger": { + "type": "keyword", + "copy_to": [ + "any.langger" + ] + }, + "langita": { + "type": "keyword", + "copy_to": [ + "any.langita" ] }, "text": { @@ -1303,7 +1353,7 @@ }, "langfre": { "type": "text", - "analyzer": "french" + "analyzer": "french_rebuilt" }, "langger": { "type": "text", @@ -1329,16 +1379,32 @@ "type": "keyword", "copy_to": [ "any.default", - "any.langeng", - "any.langfre", - "any.langger", - "any.langita", - "any.langroh", "anytext" ] }, - "text": { - "type": "keyword" + "langeng": { + "type": "keyword", + "copy_to": [ + "any.langeng" + ] + }, + "langfre": { + "type": "keyword", + "copy_to": [ + "any.langfre" + ] + }, + "langger": { + "type": "keyword", + "copy_to": [ + "any.langger" + ] + }, + "langita": { + "type": "keyword", + "copy_to": [ + "any.langita" + ] }, "link": { "type": "keyword" @@ -1448,7 +1514,8 @@ "copy_to": "any.common" }, "link": { - "type": "text" + "type": "text", + "copy_to": "any.common" }, "name": { "type": "text", @@ -1613,6 +1680,10 @@ } } }, + "email": { + "type": "keyword", + "copy_to": "any.common" + }, "groupPublished": { "type": "keyword" }, diff --git a/web/src/main/webResources/WEB-INF/data/config/index/records_french.json b/web/src/main/webResources/WEB-INF/data/config/index/records_french.json deleted file mode 100644 index 47e3324e375..00000000000 --- a/web/src/main/webResources/WEB-INF/data/config/index/records_french.json +++ /dev/null @@ -1,1613 +0,0 @@ -{ - "settings": { - "index": { - "query.default_field": "any", - "mapping.total_fields.limit": ${es.index.mapping.total_fields.limit}, - "analysis": { - "analyzer": { - "trigram": { - "type": "custom", - "tokenizer": "standard", - "filter": [ - "shingle" - ] - }, - "reverse": { - "type": "custom", - "tokenizer": "standard", - "filter": [ - "reverse" - ] - }, - "french_heavy": { - "tokenizer": "icu_tokenizer", - "filter": [ - "lowercase", - "french_synonym", - "french_elision", - "french_stop", - "icu_folding", - "french_stemmer" - ] - }, - "french_light": { - "tokenizer": "icu_tokenizer", - "filter": [ - "lowercase", - "french_elision", - "french_stop", - "icu_folding" - ] - }, - "synInspireAnnexes": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "synInspireThemes", - "synInspireAnnexes", - "keepInspireAnnexes" - ] - }, - "synInspireThemeUris": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "synInspireThemeUris" - ] - }, - "synInspireThemes": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "synInspireThemes" - ] - }, - "keepInspireServiceTypes": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "keepInspireServiceTypes" - ] - }, - "keepInspireAnnexes": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "keepInspireAnnexes" - ] - }, - "keepInspireThemes": { - "tokenizer": "keyword", - "filter": [ - "lowercase", - "keepInspireThemes" - ] - } - }, - "filter": { - "shingle": { - "type": "shingle", - "min_shingle_size": 2, - "max_shingle_size": 3 - }, - "french_stop": { - "type": "stop", - "stopwords": "_french_" - }, - "french_elision": { - "type": "elision", - "articles_case": true, - "articles": [ - "l", - "m", - "t", - "qu", - "n", - "s", - "j", - "d", - "c", - "jusqu", - "quoiqu", - "lorsqu", - "puisqu" - ] - }, - "french_synonym": { - "type": "synonym", - "expand": true, - "synonyms": [ - "sig, systeme d'information geographique, ids, gis, sdi", - "shp, shapefile", - "raster, image" - ] - }, - "french_stemmer": { - "type": "stemmer", - "language": "light_french" - }, - "keepInspireServiceTypes": { - "type": "keep", - "keep_words": [ - "discovery", - "view", - "download", - "invoke", - "transformation", - "other" - ] - }, - "keepInspireAnnexes": { - "type": "keep", - "keep_words": [ - "i", - "ii", - "iii" - ] - }, - "keepInspireThemes": { - "type": "keep", - "keep_words": [ - "Coordinate reference systems", - "Elevation", - "Land cover", - "Orthoimagery", - "Geology", - "Statistical units", - "Buildings", - "Soil", - "Land use", - "Human health and safety", - "Utility and governmental services", - "Geographical grid systems", - "Environmental monitoring facilities", - "Production and industrial facilities", - "Agricultural and aquaculture facilities", - "Population distribution — demography", - "Area management/restriction/regulation zones and reporting units", - "Natural risk zones", - "Atmospheric conditions", - "Meteorological geographical features", - "Oceanographic geographical features", - "Sea regions", - "Geographical names", - "Bio-geographical regions", - "Habitats and biotopes", - "Species distribution", - "Energy resources", - "Mineral resources", - "Administrative units", - "Addresses", - "Cadastral parcels", - "Transport networks", - "Hydrography", - "Protected sites" - ] - }, - "synInspireAnnexes": { - "type": "synonym", - "tokenizer": "keyword", - "synonyms": [ - "coordinate reference systems => i", - "elevation => ii", - "land cover => ii", - "orthoimagery => ii", - "geology => ii", - "statistical units => iii", - "buildings => iii", - "soil => iii", - "land use => iii", - "human health and safety => iii", - "utility and governmental services => iii", - "geographical grid systems => i", - "environmental monitoring facilities => iii", - "production and industrial facilities => iii", - "agricultural and aquaculture facilities => iii", - "population distribution — demography => iii", - "area management/restriction/regulation zones and reporting units => iii", - "natural risk zones => iii", - "atmospheric conditions => iii", - "meteorological geographical features => iii", - "oceanographic geographical features => iii", - "sea regions => iii", - "geographical names => i", - "bio-geographical regions => iii", - "habitats and biotopes => iii", - "species distribution => iii", - "energy resources => iii", - "mineral resources => iii", - "administrative units => i", - "addresses => i", - "cadastral parcels => i", - "transport networks => i", - "hydrography => i", - "protected sites => i" - ] - }, - "synInspireThemes": { - "type": "synonym", - "tokenizer": "keyword", - "synonyms": [ - "referenskoordinatsystem => coordinate reference systems", - "referenčni koordinatni sistemi => coordinate reference systems", - "súradnicové referenčné systémy => coordinate reference systems", - "sisteme de coordonate de referință => coordinate reference systems", - "sisteme de coordonate de referinţă => coordinate reference systems", - "systemy odniesienia za pomocą współrzędnych => coordinate reference systems", - "sistemas de referencia => coordinate reference systems", - "systemen voor verwijzing door middel van coördinaten => coordinate reference systems", - "sistemi ta' referenza ta' koordinati => coordinate reference systems", - "koordinātu atskaites sistēmas => coordinate reference systems", - "koordinačių atskaitos sistemos => coordinate reference systems", - "sistemi di coordinate => coordinate reference systems", - "koordinátarendszerek => coordinate reference systems", - "référentiels de coordonnées => coordinate reference systems", - "koordinaattijärjestelmät => coordinate reference systems", - "sistemas de coordenadas de referencia => coordinate reference systems", - "koordinaatsüsteemid => coordinate reference systems", - "συστήματα συντεταγμένων => coordinate reference systems", - "koordinatenreferenzsysteme => coordinate reference systems", - "координатни справочни системи => coordinate reference systems", - "koordinatsystemer => coordinate reference systems", - "souřadnicové referenční systémy => coordinate reference systems", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/1 => coordinate reference systems", - "höjd => elevation", - "altitude => elevation", - "elevaţie => elevation", - "elevație => elevation", - "digitalni model višin => elevation", - "výška => elevation", - "ukształtowanie terenu => elevation", - "hoogte => elevation", - "elevazzjoni => elevation", - "augstums => elevation", - "aukštis => elevation", - "elevazione => elevation", - "korkeus => elevation", - "domborzat => elevation", - "υψομετρία => elevation", - "elevaciones => elevation", - "kõrgused => elevation", - "höhe => elevation", - "højde => elevation", - "nadmořská výška => elevation", - "релеф => elevation", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/10 => elevation", - "landtäcke => land cover", - "pokrovnost tal => land cover", - "ocupação do solo => land cover", - "krajinná pokrývka (land cover) => land cover", - "acoperire terestră => land cover", - "bodemgebruik => land cover", - "użytkowanie terenu => land cover", - "zemes virsma => land cover", - "kopertura ta' l-art => land cover", - "žemės danga => land cover", - "a felszín borítása => land cover", - "occupation des terres => land cover", - "copertura del suolo => land cover", - "cubierta terrestre => land cover", - "maakate => land cover", - "maanpeite => land cover", - "κάλυψη γης => land cover", - "bodenbedeckung => land cover", - "krajinný pokryv => land cover", - "arealdække => land cover", - "земна покривка => land cover", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/11 => land cover", - "ortofoto => orthoimagery", - "ortoimagini => orthoimagery", - "ortometria => orthoimagery", - "sporządzanie ortoobrazów => orthoimagery", - "ortoimagens => orthoimagery", - "orthobeeldvorming => orthoimagery", - "orthoimagery => orthoimagery", - "ortofotogrāfija => orthoimagery", - "ortofotografinis vaizdavimas => orthoimagery", - "orto immagini => orthoimagery", - "ortofotók => orthoimagery", - "ortho-imagerie => orthoimagery", - "ortoimágenes => orthoimagery", - "ortoilmakuvat => orthoimagery", - "ortokujutised => orthoimagery", - "ορθοφωτογραφία => orthoimagery", - "orthofotografie => orthoimagery", - "ortofotosnímky => orthoimagery", - "ортоизображение => orthoimagery", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/12 => orthoimagery", - "geologia => geology", - "geologie => geology", - "geológia => geology", - "geologija => geology", - "geologi => geology", - "ġeologija => geology", - "ģeoloģija => geology", - "földtan => geology", - "géologie => geology", - "geología => geology", - "geoloogia => geology", - "γεωλογία => geology", - "геология => geology", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/13 => geology", - "unidades estatísticas => statistical units", - "unităţi statistice => statistical units", - "štatistické jednotky => statistical units", - "statistični okoliši => statistical units", - "statistiska enheter => statistical units", - "statistische eenheden => statistical units", - "jednostki statystyczne => statistical units", - "statistiniai vienetai => statistical units", - "unitajiet statistiċi => statistical units", - "unități statistice => statistical units", - "statistikas vienības => statistical units", - "unità statistiche => statistical units", - "tilastoyksiköt => statistical units", - "unités statistiques => statistical units", - "statisztikai egységek => statistical units", - "unidades estadísticas => statistical units", - "statistilised üksused => statistical units", - "statistische einheiten => statistical units", - "στατιστικές μονάδες => statistical units", - "statistické jednotky => statistical units", - "statistiske enheder => statistical units", - "статистически единици => statistical units", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/14 => statistical units", - "stavbe => buildings", - "byggnader => buildings", - "clădiri => buildings", - "stavby => buildings", - "edifícios => buildings", - "budynki => buildings", - "ēkas => buildings", - "bini => buildings", - "gebouwen => buildings", - "κτίρια => buildings", - "edificios => buildings", - "ehitised => buildings", - "rakennukset => buildings", - "pastatai => buildings", - "edifici => buildings", - "épületek => buildings", - "bâtiments => buildings", - "сгради => buildings", - "budovy => buildings", - "bygninger => buildings", - "gebäude => buildings", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/15 => buildings", - "tla => soil", - "mark => soil", - "soluri => soil", - "gleba => soil", - "pôda => soil", - "solo => soil", - "augsne => soil", - "bodem => soil", - "ħamrija => soil", - "suolo => soil", - "dirvožemis => soil", - "talaj => soil", - "sols => soil", - "maaperä => soil", - "pinnas => soil", - "suelo => soil", - "έδαφος => soil", - "boden => soil", - "jord => soil", - "půda => soil", - "почва => soil", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/16 => soil", - "markanvändning => land use", - "namenska raba tal => land use", - "zagospodarowanie przestrzenne => land use", - "uso do solo => land use", - "utilizarea terenului => land use", - "využitie územia => land use", - "zemes izmantošana => land use", - "użu ta' l-art => land use", - "landgebruik => land use", - "földhasználat => land use", - "žemės naudojimas => land use", - "utilizzo del territorio => land use", - "maakasutus => land use", - "maankäyttö => land use", - "usage des sols => land use", - "χρήσεις γης => land use", - "uso del suelo => land use", - "ползване на земята => land use", - "využití území => land use", - "arealanvendelse => land use", - "bodennutzung => land use", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/17 => land use", - "människors hälsa och säkerhet => human health and safety", - "zdravje in varnost prebivalstva => human health and safety", - "ľudské zdravie a bezpečnosť => human health and safety", - "zdrowie i bezpieczeństwo ludzi => human health and safety", - "sănătate şi siguranţă umană => human health and safety", - "sănătate și siguranță umană => human health and safety", - "saúde humana e segurança => human health and safety", - "žmonių sveikata ir sauga => human health and safety", - "cilvēku veselība un drošība => human health and safety", - "is-saħħa u s-siġurtà tal-bniedem => human health and safety", - "menselijke gezondheid en veiligheid => human health and safety", - "salute umana e sicurezza => human health and safety", - "emberi egészség és biztonság => human health and safety", - "santé et sécurité des personnes => human health and safety", - "väestön terveys ja turvallisuus => human health and safety", - "salud y seguridad humanas => human health and safety", - "inimeste tervis ja ohutus => human health and safety", - "sikkerhed => human health and safety", - "gesundheit und sicherheit => human health and safety", - "ανθρώπινη υγεία και ασφάλεια => human health and safety", - "здраве и безопасност на човека => human health and safety", - "lidské zdraví a bezpečnost => human health and safety", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/18 => human health and safety", - "allmännyttiga och offentliga tjänster => utility and governmental services", - "komunalne in javne storitve => utility and governmental services", - "servicii de utilitate publică şi servicii publice => utility and governmental services", - "servicii de utilitate publică și servicii publice => utility and governmental services", - "verejné a štátne služby => utility and governmental services", - "usługi użyteczności publicznej i służby państwowe => utility and governmental services", - "serviços de utilidade pública e do estado => utility and governmental services", - "nutsdiensten en overheidsdiensten => utility and governmental services", - "komunalinės įmonės ir valstybės tarnybos => utility and governmental services", - "servizzi ta' utilità u tal-gvern => utility and governmental services", - "komunālie un valsts dienesti => utility and governmental services", - "servizi di pubblica utilità e servizi amministrativi => utility and governmental services", - "services d'utilité publique et services publics => utility and governmental services", - "közüzemi és közszolgáltatások => utility and governmental services", - "yleishyödylliset ja muut julkiset palvelut => utility and governmental services", - "servicios de utilidad pública y estatales => utility and governmental services", - "kommunaal- ja riiklikud teenused => utility and governmental services", - "offentlig forsyningsvirksomhed og offentlige tjenesteydelser => utility and governmental services", - "versorgungswirtschaft und staatliche dienste => utility and governmental services", - "комунално-битови и обществени услуги => utility and governmental services", - "επιχειρήσεις κοινής ωφελείας και κρατικές υπηρεσίες => utility and governmental services", - "veřejné služby a služby veřejné správy => utility and governmental services", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/19 => utility and governmental services", - "geografska koordinatna mreža => geographical grid systems", - "geografiska rutnätssystem => geographical grid systems", - "sisteme de caroiaj geografic => geographical grid systems", - "geografické systémy sietí => geographical grid systems", - "systemy siatek geograficznych => geographical grid systems", - "sistemas de quadrículas geográficas => geographical grid systems", - "sistemi ta' grilji ġeografiċi => geographical grid systems", - "geografisch rastersysteem => geographical grid systems", - "ģeogrāfisko koordinātu tīklu sistēmas => geographical grid systems", - "geografinio tinklelio sistemos => geographical grid systems", - "sistemi di griglie geografiche => geographical grid systems", - "systèmes de maillage géographique => geographical grid systems", - "földrajzi rácsrendszerek => geographical grid systems", - "paikannusruudustot => geographical grid systems", - "sistema de cuadrículas geográficas => geographical grid systems", - "geograafilised ruutvõrgud => geographical grid systems", - "συστήματα γεωγραφικού καννάβου => geographical grid systems", - "geografiske kvadratnetsystemer => geographical grid systems", - "geografische gittersysteme => geographical grid systems", - "географски координатни системи => geographical grid systems", - "zeměpisné soustavy souřadnicových sítí => geographical grid systems", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/2 => geographical grid systems", - "anläggningar för miljöövervakning => environmental monitoring facilities", - "naprave in objekti za monitoring okolja => environmental monitoring facilities", - "zariadenia na monitorovanie životného prostredia => environmental monitoring facilities", - "instalações de monitorização do ambiente => environmental monitoring facilities", - "milieubewakingsvoorzieningen => environmental monitoring facilities", - "urządzenia do monitorowania środowiska => environmental monitoring facilities", - "instalaţii de supraveghere a mediului => environmental monitoring facilities", - "instalații de supraveghere a mediului => environmental monitoring facilities", - "faċilitajiet ta' monitoraġġ ambjentali => environmental monitoring facilities", - "aplinkos stebėsenos priemonės => environmental monitoring facilities", - "vides monitoringa iekārtas => environmental monitoring facilities", - "környezetvédelmi monitoringlétesítmények => environmental monitoring facilities", - "impianti di monitoraggio ambientale => environmental monitoring facilities", - "installations de suivi environnemental => environmental monitoring facilities", - "keskkonnaseirerajatised => environmental monitoring facilities", - "ympäristön tilan seurantalaitteet => environmental monitoring facilities", - "instalaciones de observación del medio ambiente => environmental monitoring facilities", - "εγκαταστάσεις παρακολούθησης του περιβάλλοντος => environmental monitoring facilities", - "miljøovervågningsfaciliteter => environmental monitoring facilities", - "umweltüberwachung => environmental monitoring facilities", - "zařízení pro sledování životního prostředí => environmental monitoring facilities", - "съоръжения за управление на околната среда => environmental monitoring facilities", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/20 => environmental monitoring facilities", - "produktions- och industrianläggningar => production and industrial facilities", - "instalaţii de producţie şi industriale => production and industrial facilities", - "instalații de producție și industriale => production and industrial facilities", - "proizvodni in industrijski objekti in naprave => production and industrial facilities", - "výrobné a priemyselné zariadenia => production and industrial facilities", - "faciliteiten voor productie en industrie => production and industrial facilities", - "instalações industriais e de produção => production and industrial facilities", - "obiekty produkcyjne i przemysłowe => production and industrial facilities", - "ražošanas un rūpniecības iekārtas => production and industrial facilities", - "faċilitajiet ta' produzzjoni u industrijali => production and industrial facilities", - "produzione e impianti industriali => production and industrial facilities", - "gamybos ir pramonės įrenginiai => production and industrial facilities", - "tuotanto- ja teollisuuslaitokset => production and industrial facilities", - "lieux de production et sites industriels => production and industrial facilities", - "termelő és ipari létesítmények => production and industrial facilities", - "tootmis- ja tööstusrajatised => production and industrial facilities", - "instalaciones de producción e industriales => production and industrial facilities", - "εγκαταστάσεις παραγωγής και βιομηχανικές εγκαταστάσεις => production and industrial facilities", - "produktions- und industrieanlagen => production and industrial facilities", - "výrobní a průmyslová zařízení => production and industrial facilities", - "produktions- og industrifaciliteter => production and industrial facilities", - "производствени и промишлени съоръжения => production and industrial facilities", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/21 => production and industrial facilities", - "jordbruks- och vattenbruksanläggningar => agricultural and aquaculture facilities", - "objekti in naprave za kmetijstvo in ribogojstvo => agricultural and aquaculture facilities", - "poľnohospodárske zariadenia a zariadenia akvakultúry => agricultural and aquaculture facilities", - "instalações agrícolas e aquícolas => agricultural and aquaculture facilities", - "instalaţii agricole şi pentru acvacultură => agricultural and aquaculture facilities", - "instalații agricole și pentru acvacultură => agricultural and aquaculture facilities", - "obiekty rolnicze oraz akwakultury => agricultural and aquaculture facilities", - "faċilitajiet agrikoli u ta' l-akwakultura => agricultural and aquaculture facilities", - "faciliteiten voor landbouw en aquacultuur => agricultural and aquaculture facilities", - "lauksaimniecības un akvakultūras iekārtas => agricultural and aquaculture facilities", - "žemės ūkio ir akvakultūros infrastruktūra => agricultural and aquaculture facilities", - "impianti agricoli e di acquacoltura => agricultural and aquaculture facilities", - "γεωργικές εγκαταστάσεις και εγκαταστάσεις υδατοκαλλιέργειας => agricultural and aquaculture facilities", - "mezőgazdasági és akvakultúra-ágazati létesítmények => agricultural and aquaculture facilities", - "installations agricoles et aquacoles => agricultural and aquaculture facilities", - "maatalous- ja vesiviljelylaitokset => agricultural and aquaculture facilities", - "põllumajandus- ja vesiviljelusrajatised => agricultural and aquaculture facilities", - "instalaciones agrícolas y de acuicultura => agricultural and aquaculture facilities", - "селскостопански и водностопански съоръжения => agricultural and aquaculture facilities", - "zemědělská a akvakulturní zařízení => agricultural and aquaculture facilities", - "landwirtschaftliche anlagen und aquakulturanlagen => agricultural and aquaculture facilities", - "landbrugs- og akvakulturanlæg => agricultural and aquaculture facilities", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/22 => agricultural and aquaculture facilities", - "befolkningsfördelning – demografi => population distribution — demography", - "porazdelitev prebivalstva – demografski podatki => population distribution — demography", - "repartizarea populaţiei – demografie => population distribution — demography", - "repartizarea populației – demografie => population distribution — demography", - "rozmiestnenie obyvateľstva – demografia => population distribution — demography", - "distribuição da população — demografia => population distribution — demography", - "spreiding van de bevolking — demografie => population distribution — demography", - "rozmieszczenie ludności – demografia => population distribution — demography", - "iedzīvotāju sadalījums – demogrāfija => population distribution — demography", - "distribuzzjoni tal-popolazzjoni – demografija => population distribution — demography", - "distribuzione della popolazione — demografia => population distribution — demography", - "gyventojų pasiskirstymas – demografija => population distribution — demography", - "répartition de la population — démographie => population distribution — demography", - "a népesség eloszlása – demográfia => population distribution — demography", - "elanikkonna jaotumine – demograafia => population distribution — demography", - "väestöjakauma – demografia => population distribution — demography", - "distribución de la población — demografía => population distribution — demography", - "κατανομή πληθυσμού — δημογραφία => population distribution — demography", - "rozložení obyvatelstva – demografie => population distribution — demography", - "verteilung der bevölkerung — demografie => population distribution — demography", - "befolkningsfordeling — demografi => population distribution — demography", - "разпределение на населението — демография => population distribution — demography", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/23 => population distribution — demography", - "spravované/obmedzené/regulované zóny a jednotky podávajúce správy => area management/restriction/regulation zones and reporting units", - "områden med särskild förvaltning/begränsningar/reglering samt enheter för rapportering => area management/restriction/regulation zones and reporting units", - "območja upravljanja/zaprta območja/regulirana območja in poročevalske enote => area management/restriction/regulation zones and reporting units", - "zone de administrare/restricţie/reglementare şi unităţi de raportare => area management/restriction/regulation zones and reporting units", - "zone de administrare/restricție/reglementare și unități de raportare => area management/restriction/regulation zones and reporting units", - "gebiedsbeheer gebieden waar beperkingen gelden gereguleerde gebieden en rapportage-eenheden => area management/restriction/regulation zones and reporting units", - "zonas de gestão/restrição/regulamentação e unidades de referência => area management/restriction/regulation zones and reporting units", - "gospodarowanie obszarem/strefy ograniczone/regulacyjne oraz jednostki sprawozdawcze => area management/restriction/regulation zones and reporting units", - "apgabala pārvaldības/ierobežojumu/reglamentētas zonas un ziņošanas vienības => area management/restriction/regulation zones and reporting units", - "zone sottoposte a gestione/limitazioni/regolamentazione e unità con obbligo di comunicare dati => area management/restriction/regulation zones and reporting units", - "amministrazzjoni ta' żoni/restrizzjoni/żoni regolati u unitajiet ta' rapportar => area management/restriction/regulation zones and reporting units", - "tvarkomos teritorijos ribojamos ir reglamentuojamos zonos bei vienetai už kuriuos atsiskaitoma => area management/restriction/regulation zones and reporting units", - "területgazdálkodási/-korlátozási/-szabályozási övezetek és adatszolgáltató egységek => area management/restriction/regulation zones and reporting units", - "zones de gestion de restriction ou de réglementation et unités de déclaration => area management/restriction/regulation zones and reporting units", - "aluesuunnittelun rajoitusten ja sääntelyn piiriin kuuluvat alueet ja raportointiyksiköt => area management/restriction/regulation zones and reporting units", - "üldplaneering/piirangu-/reguleeritud tsoonid ja aruandlusüksused => area management/restriction/regulation zones and reporting units", - "zonas sujetas a ordenación a restricciones o reglamentaciones y unidades de notificación => area management/restriction/regulation zones and reporting units", - "bewirtschaftungsgebiete/schutzgebiete/geregelte gebiete und berichterstattungseinheiten => area management/restriction/regulation zones and reporting units", - "ζώνες διαχείρισης/περιορισμού/ρύθμισης εκτάσεων και μονάδες αναφοράς => area management/restriction/regulation zones and reporting units", - "forvaltede og regulerede områder samt områder med brugsbegrænsning og indberetningsenheder => area management/restriction/regulation zones and reporting units", - "správní oblasti/chráněná pásma/regulovaná území a jednotky podávající hlášení => area management/restriction/regulation zones and reporting units", - "управление на територията/ограничени/регулирани зони и отчетни единици => area management/restriction/regulation zones and reporting units", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/24 => area management/restriction/regulation zones and reporting units", - "območja nevarnosti naravnih nesreč => natural risk zones", - "naturliga riskområden => natural risk zones", - "zóny prírodného rizika => natural risk zones", - "zone de risc natural => natural risk zones", - "zonas de risco natural => natural risk zones", - "strefy zagrożenia naturalnego => natural risk zones", - "żoni ta' riskju naturali => natural risk zones", - "gebieden met natuurrisico'es => natural risk zones", - "gebieden met natuurrisico's => natural risk zones", - "dabas apdraudējuma zonas => natural risk zones", - "gamtinių pavojų zonos => natural risk zones", - "természeti kockázati zónák => natural risk zones", - "zone a rischio naturale => natural risk zones", - "zones à risque naturel => natural risk zones", - "luonnonriskialueet => natural risk zones", - "looduslikud ohutsoonid => natural risk zones", - "zonas de riesgos naturales => natural risk zones", - "ζώνες φυσικών κινδύνων => natural risk zones", - "природни рискови зони => natural risk zones", - "områder med naturlige risici => natural risk zones", - "gebiete mit naturbedingten risiken => natural risk zones", - "oblasti ohrožené přírodními riziky => natural risk zones", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/25 => natural risk zones", - "ozračje => atmospheric conditions", - "atmosfäriska förhållanden => atmospheric conditions", - "condiţii atmosferice => atmospheric conditions", - "condiții atmosferice => atmospheric conditions", - "atmosférické podmienky => atmospheric conditions", - "warunki atmosferyczne => atmospheric conditions", - "condições atmosféricas => atmospheric conditions", - "atmosferische omstandigheden => atmospheric conditions", - "kondizzjonijiet atmosferiċi => atmospheric conditions", - "atmosfēras apstākļi => atmospheric conditions", - "condizioni atmosferiche => atmospheric conditions", - "atmosferos sąlygos => atmospheric conditions", - "conditions atmosphériques => atmospheric conditions", - "légköri viszonyok => atmospheric conditions", - "atmosfääritingimused => atmospheric conditions", - "ilmakehän tila => atmospheric conditions", - "condiciones atmosféricas => atmospheric conditions", - "atmosphärische bedingungen => atmospheric conditions", - "ατμοσφαιρικές συνθήκες => atmospheric conditions", - "stav ovzduší => atmospheric conditions", - "atmosfæriske forhold => atmospheric conditions", - "атмосферни условия => atmospheric conditions", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/26 => atmospheric conditions", - "meteorološke značilnosti => meteorological geographical features", - "geografiska meteorologiska förhållanden => meteorological geographical features", - "meteorologické geografické prvky => meteorological geographical features", - "características geometeorológicas => meteorological geographical features", - "caracteristici geografice meteorologice => meteorological geographical features", - "warunki meteorologiczno-geograficzne => meteorological geographical features", - "meteorologische geografische kenmerken => meteorological geographical features", - "karatteristiċi ġeografiċi meteoroloġiċi => meteorological geographical features", - "meteoroloģiski ģeogrāfiskie raksturlielumi => meteorological geographical features", - "meteorologinės geografinės sąlygos => meteorological geographical features", - "elementi geografici meteorologici => meteorological geographical features", - "meteorológiai földrajzi jellemzők => meteorological geographical features", - "ilmaston maantieteelliset ominaispiirteet => meteorological geographical features", - "caractéristiques géographiques météorologiques => meteorological geographical features", - "meteoroloogilis-geograafilised tunnusjooned => meteorological geographical features", - "μετεωρολογικά γεωγραφικά χαρακτηριστικά => meteorological geographical features", - "aspectos geográficos de carácter meteorológico => meteorological geographical features", - "meteorologisch-geografische kennwerte => meteorological geographical features", - "meteorologisk-geografiske forhold => meteorological geographical features", - "метеорологични географски характеристики => meteorological geographical features", - "zeměpisné meteorologické prvky => meteorological geographical features", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/27 => meteorological geographical features", - "geografiska oceanografiska förhållanden => oceanographic geographical features", - "oceanogeografske značilnosti => oceanographic geographical features", - "características oceanográficas => oceanographic geographical features", - "caracteristici geografice oceanografice => oceanographic geographical features", - "oceánografické geografické prvky => oceanographic geographical features", - "warunki oceanograficzno-geograficzne => oceanographic geographical features", - "karatteristiċi ġeografiċi oċeanografiċi => oceanographic geographical features", - "oceanografische geografische kenmerken => oceanographic geographical features", - "okeanogrāfiski ģeogrāfiskie raksturlielumi => oceanographic geographical features", - "elementi geografici oceanografici => oceanographic geographical features", - "okeanografinės geografinės sąlygos => oceanographic geographical features", - "oceanográfiai földrajzi jellemzők => oceanographic geographical features", - "caractéristiques géographiques océanographiques => oceanographic geographical features", - "merentutkimuksen maantieteelliset ominaispiirteet => oceanographic geographical features", - "okeanograafilis-geograafilised tunnusjooned => oceanographic geographical features", - "rasgos geográficos oceanográficos => oceanographic geographical features", - "oceanografiske/geografiske forhold => oceanographic geographical features", - "ozeanografisch-geografische kennwerte => oceanographic geographical features", - "ωκεανογραφικά γεωγραφικά χαρακτηριστικά => oceanographic geographical features", - "zeměpisné oceánografické prvky => oceanographic geographical features", - "океанографски географски характеристики => oceanographic geographical features", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/28 => oceanographic geographical features", - "havsområden => sea regions", - "morske regije => sea regions", - "morské regióny => sea regions", - "regiuni maritime => sea regions", - "zeegebieden => sea regions", - "regiony morskie => sea regions", - "regiões marinhas => sea regions", - "reġjuni tal-baħar => sea regions", - "jūru reģioni => sea regions", - "jūrų regionai => sea regions", - "regioni marine => sea regions", - "tengeri régiók => sea regions", - "régions maritimes => sea regions", - "merepiirkonnad => sea regions", - "merialueet => sea regions", - "regiones marinas => sea regions", - "θαλάσσιες περιοχές => sea regions", - "mořské oblasti => sea regions", - "havområder => sea regions", - "meeresregionen => sea regions", - "морски региони => sea regions", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/29 => sea regions", - "zemljepisna imena => geographical names", - "geografiska namn => geographical names", - "zemepisné názvy => geographical names", - "denumiri geografice => geographical names", - "nazwy geograficzne => geographical names", - "toponímia => geographical names", - "toponīmi => geographical names", - "ismijiet ġeografiċi => geographical names", - "geografische namen => geographical names", - "dénominations géographiques => geographical names", - "földrajzi nevek => geographical names", - "nomi geografici => geographical names", - "geografiniai pavadinimai => geographical names", - "paikannimet => geographical names", - "geograafilised nimed => geographical names", - "nombres geográficos => geographical names", - "τοπωνύμια => geographical names", - "geografische bezeichnungen => geographical names", - "географски наименования => geographical names", - "zeměpisné názvy => geographical names", - "stednavne => geographical names", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/3 => geographical names", - "biogeografiska regioner => bio-geographical regions", - "biogeografske regije => bio-geographical regions", - "biogeografické regióny => bio-geographical regions", - "regiuni biogeografice => bio-geographical regions", - "regiony biogeograficzne => bio-geographical regions", - "regiões biogeográficas => bio-geographical regions", - "biogeografische gebieden => bio-geographical regions", - "biogeografiniai regionai => bio-geographical regions", - "bioģeogrāfiskie reģioni => bio-geographical regions", - "reġjuni bijo-ġeografiċi => bio-geographical regions", - "regioni biogeografiche => bio-geographical regions", - "biogeográfiai régiók => bio-geographical regions", - "régions biogéographiques => bio-geographical regions", - "biomaantieteelliset alueet => bio-geographical regions", - "bio-geograafilised piirkonnad => bio-geographical regions", - "regiones biogeográficas => bio-geographical regions", - "βιογεωγραφικές περιοχές => bio-geographical regions", - "biogeografische regionen => bio-geographical regions", - "biogeografiske regioner => bio-geographical regions", - "bioregiony => bio-geographical regions", - "биогеографски региони => bio-geographical regions", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/30 => bio-geographical regions", - "naturtyper och biotoper => habitats and biotopes", - "habitati in biotopi => habitats and biotopes", - "habitaty a biotopy => habitats and biotopes", - "habitate şi biotopuri => habitats and biotopes", - "habitate și biotopuri => habitats and biotopes", - "habitats e biótopos => habitats and biotopes", - "siedliska i obszary przyrodniczo jednorodne => habitats and biotopes", - "habitats en biotopen => habitats and biotopes", - "l-abitati naturali u l-bijotopi => habitats and biotopes", - "dzīvotnes un biotopi => habitats and biotopes", - "buveinės ir biotopai => habitats and biotopes", - "habitat e biotopi => habitats and biotopes", - "élőhelyek és biotópok => habitats and biotopes", - "habitats et biotopes => habitats and biotopes", - "elinympäristöt ja biotoopit => habitats and biotopes", - "elupaigad ja biotoobid => habitats and biotopes", - "hábitats y biotopos => habitats and biotopes", - "ενδιαιτήματα και βιότοποι => habitats and biotopes", - "lebensräume und biotope => habitats and biotopes", - "levesteder og biotoper => habitats and biotopes", - "местообитания и биотопи => habitats and biotopes", - "stanoviště a biotopy => habitats and biotopes", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/31 => habitats and biotopes", - "arters utbredning => species distribution", - "porazdelitev vrst => species distribution", - "výskyt druhov => species distribution", - "repartizarea speciilor => species distribution", - "distribuição das espécies => species distribution", - "rozmieszczenie gatunków => species distribution", - "spreiding van soorten => species distribution", - "distribuzzjoni ta' l-ispeċi => species distribution", - "sugu izplatība => species distribution", - "rūšių pasiskirstymas => species distribution", - "distribuzione delle specie => species distribution", - "a fajok megoszlása => species distribution", - "répartition des espèces => species distribution", - "lajien levinneisyys => species distribution", - "liikide jaotumine => species distribution", - "distribución de las especies => species distribution", - "κατανομή ειδών => species distribution", - "verteilung der arten => species distribution", - "rozložení druhů => species distribution", - "artsfordeling => species distribution", - "разпределение на видовете => species distribution", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/32 => species distribution", - "zdroje energie => energy resources", - "energetski viri => energy resources", - "energiresurser => energy resources", - "recursos energéticos => energy resources", - "resurse energetice => energy resources", - "zasoby energetyczne => energy resources", - "energiebronnen => energy resources", - "enerģijas resursi => energy resources", - "riżorsi ta' enerġija => energy resources", - "energijos ištekliai => energy resources", - "risorse energetiche => energy resources", - "energiaforrások => energy resources", - "sources d'énergie => energy resources", - "energiavarat => energy resources", - "energiaressursid => energy resources", - "ενεργειακοί πόροι => energy resources", - "energiequellen => energy resources", - "energiressourcer => energy resources", - "energetické zdroje => energy resources", - "енергийни източници => energy resources", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/33 => energy resources", - "mineralni viri => mineral resources", - "mineralfyndigheter => mineral resources", - "zdroje nerastných surovín => mineral resources", - "resurse minerale => mineral resources", - "recursos minerais => mineral resources", - "zasoby mineralne => mineral resources", - "minerale bronnen => mineral resources", - "riżorsi minerali => mineral resources", - "derīgo izrakteņu resursi => mineral resources", - "naudingosios iškasenos => mineral resources", - "risorse minerarie => mineral resources", - "ásványi nyersanyagok => mineral resources", - "ressources minérales => mineral resources", - "mineraalivarat => mineral resources", - "maavarad => mineral resources", - "recursos minerales => mineral resources", - "ορυκτοί πόροι => mineral resources", - "mineralische bodenschätze => mineral resources", - "mineralressourcer => mineral resources", - "nerostné suroviny => mineral resources", - "минерални ресурси => mineral resources", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/34 => mineral resources", - "upravne enote => administrative units", - "administrativa enheter => administrative units", - "správne jednotky => administrative units", - "unităţi administrative => administrative units", - "unități administrative => administrative units", - "jednostki administracyjne => administrative units", - "unidades administrativas => administrative units", - "administratieve eenheden => administrative units", - "unitajiet amministrattivi => administrative units", - "administratīvas vienības => administrative units", - "közigazgatási egységek => administrative units", - "unità amministrative => administrative units", - "administraciniai vienetai => administrative units", - "unités administratives => administrative units", - "hallinnolliset yksiköt => administrative units", - "haldusüksused => administrative units", - "διοικητικές ενότητες => administrative units", - "verwaltungseinheiten => administrative units", - "administrative enheder => administrative units", - "административни единици => administrative units", - "správní jednotky => administrative units", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/4 => administrative units", - "adrese => addresses", - "adresy => addresses", - "naslovi => addresses", - "adresser => addresses", - "endereços => addresses", - "indirizzi => addresses", - "adressen => addresses", - "adresai => addresses", - "adreses => addresses", - "címek => addresses", - "adresses => addresses", - "osoitteet => addresses", - "direcciones => addresses", - "aadressid => addresses", - "διευθύνσεις => addresses", - "адреси => addresses", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/5 => addresses", - "fastighetsområden => cadastral parcels", - "katastrske parcele => cadastral parcels", - "katastrálne parcely => cadastral parcels", - "parcele cadastrale => cadastral parcels", - "pakketti katastali => cadastral parcels", - "kadastrale percelen => cadastral parcels", - "działki katastralne => cadastral parcels", - "parcelas cadastrais => cadastral parcels", - "kadastrāli zemes gabali => cadastral parcels", - "kadastro sklypai => cadastral parcels", - "parcelle catastali => cadastral parcels", - "parcelles cadastrales => cadastral parcels", - "kataszteri parcellák => cadastral parcels", - "γεωτεμάχια κτηματολογίου => cadastral parcels", - "parcelas catastrales => cadastral parcels", - "katastriüksused => cadastral parcels", - "kiinteistöt => cadastral parcels", - "кадастрални парцели => cadastral parcels", - "katastrální parcely => cadastral parcels", - "matrikulære parceller => cadastral parcels", - "flurstücke/grundstücke (katasterparzellen) => cadastral parcels", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/6 => cadastral parcels", - "transportnät => transport networks", - "prometna omrežja => transport networks", - "dopravné siete => transport networks", - "reţele de transport => transport networks", - "rețele de transport => transport networks", - "redes de transporte => transport networks", - "sieci transportowe => transport networks", - "transporta tīkli => transport networks", - "networks tat-trasport => transport networks", - "vervoersnetwerken => transport networks", - "transporto tinklai => transport networks", - "közlekedési hálózatok => transport networks", - "reti di trasporto => transport networks", - "liikenneverkot => transport networks", - "réseaux de transport => transport networks", - "transpordivõrgud => transport networks", - "δίκτυα μεταφορών => transport networks", - "verkehrsnetze => transport networks", - "transportnet => transport networks", - "транспортни мрежи => transport networks", - "dopravní sítě => transport networks", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/7 => transport networks", - "hidrografija => hydrography", - "hydrografi => hydrography", - "hydrografia => hydrography", - "hidrografia => hydrography", - "hidrografie => hydrography", - "hydrografie => hydrography", - "idrografija => hydrography", - "hidrogrāfija => hydrography", - "hydrographie => hydrography", - "idrografia => hydrography", - "vízrajz => hydrography", - "hüdrograafia => hydrography", - "hidrografía => hydrography", - "υδρογραφία => hydrography", - "gewässernetz => hydrography", - "hydrograf => hydrography", - "vodopis => hydrography", - "хидрография => hydrography", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/8 => hydrography", - "zavarovana območja => protected sites", - "skyddade områden => protected sites", - "zone protejate => protected sites", - "chránené územia => protected sites", - "obszary chronione => protected sites", - "sítios protegidos => protected sites", - "beschermde gebieden => protected sites", - "siti protetti => protected sites", - "saugomos teritorijos => protected sites", - "aizsargājamas teritorijas => protected sites", - "suojellut alueet => protected sites", - "sites protégés => protected sites", - "védett helyek => protected sites", - "kaitsealused kohad => protected sites", - "lugares protegidos => protected sites", - "προστατευόμενες τοποθεσίες => protected sites", - "beskyttede lokaliteter => protected sites", - "schutzgebiete => protected sites", - "chráněná území => protected sites", - "защитени обекти => protected sites", - "http://rdfdata.eionet.europa.eu/inspirethemes/themes/9 => protected sites" - ] - }, - "synInspireThemeUris": { - "type": "synonym", - "tokenizer": "keyword", - "synonyms": [ - "coordinate reference systems => http://inspire.ec.europa.eu/theme/rs", - "geographical grid systems => http://inspire.ec.europa.eu/theme/gg", - "geographical names => http://inspire.ec.europa.eu/theme/gn", - "administrative units => http://inspire.ec.europa.eu/theme/au", - "addresses => http://inspire.ec.europa.eu/theme/ad", - "cadastral parcels => http://inspire.ec.europa.eu/theme/cp", - "transport networks => http://inspire.ec.europa.eu/theme/tn", - "hydrography => http://inspire.ec.europa.eu/theme/hy", - "protected sites => http://inspire.ec.europa.eu/theme/ps", - "elevation => http://inspire.ec.europa.eu/theme/el", - "land cover => http://inspire.ec.europa.eu/theme/lc", - "orthoimagery => http://inspire.ec.europa.eu/theme/oi", - "geology => http://inspire.ec.europa.eu/theme/ge", - "statistical units => http://inspire.ec.europa.eu/theme/su", - "buildings => http://inspire.ec.europa.eu/theme/bu", - "soil => http://inspire.ec.europa.eu/theme/so", - "land use => http://inspire.ec.europa.eu/theme/lu", - "human health and safety => http://inspire.ec.europa.eu/theme/hh", - "utility and governmental services => http://inspire.ec.europa.eu/theme/us", - "environmental monitoring facilities => http://inspire.ec.europa.eu/theme/ef", - "production and industrial facilities => http://inspire.ec.europa.eu/theme/pf", - "agricultural and aquaculture facilities => http://inspire.ec.europa.eu/theme/af", - "population distribution — demography => http://inspire.ec.europa.eu/theme/pd", - "area management/restriction/regulation zones and reporting units => http://inspire.ec.europa.eu/theme/am", - "natural risk zones => http://inspire.ec.europa.eu/theme/nz", - "atmospheric conditions => http://inspire.ec.europa.eu/theme/ac", - "meteorological geographical features => http://inspire.ec.europa.eu/theme/mf", - "oceanographic geographical features => http://inspire.ec.europa.eu/theme/of", - "sea regions => http://inspire.ec.europa.eu/theme/sr", - "bio-geographical regions => http://inspire.ec.europa.eu/theme/br", - "habitats and biotopes => http://inspire.ec.europa.eu/theme/hb", - "species distribution => http://inspire.ec.europa.eu/theme/sd", - "energy resources => http://inspire.ec.europa.eu/theme/er", - "mineral resources => http://inspire.ec.europa.eu/theme/mr" - ] - } - } - } - } - }, - "mappings": { - "dynamic_templates": [ - { - "numbers": { - "match": "*Number", - "mapping": { - "type": "short" - } - } - }, - { - "textField": { - "match": "*Object", - "mapping": { - "type": "object", - "properties": { - "default": { - "type": "text", - "analyzer": "french_light", - "copy_to": [ - "any", - "anytext" - ], - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - }, - "trigram": { - "type": "text", - "analyzer": "trigram" - }, - "reverse": { - "type": "text", - "analyzer": "reverse" - } - } - }, - "link": { - "type": "keyword" - } - } - } - } - }, - { - "codelist": { - "match": "cl_*", - "mapping": { - "type": "object", - "properties": { - "key": { - "type": "keyword" - }, - "default": { - "type": "text" - }, - "text": { - "type": "text" - }, - "link": { - "type": "keyword" - } - } - } - } - } - }, - { - "linkUrlProtocol": { - "match": "linkUrlProtocol*", - "mapping": { - "type": "keyword" - } - } - }, - { - "org": { - "match": "*Org*", - "mapping": { - "type": "keyword" - } - } - }, - { - "tree": { - "match": "th_*_tree", - "mapping": { - "type": "object", - "properties": { - "default": { - "type": "keyword" - }, - "key": { - "type": "keyword" - } - } - } - } - }, - { - "tag": { - "match": "th_*", - "mapping": { - "type": "object", - "copy_to": [ - "th_tag" - ], - "properties": { - "default": { - "type": "keyword", - "copy_to": [ - "any", - "anytext" - ] - }, - "text": { - "type": "keyword" - }, - "link": { - "type": "keyword" - } - } - } - } - }, - { - "keywordType": { - "match": "keywordType-*", - "mapping": { - "type": "object", - "properties": { - "default": { - "type": "keyword" - }, - "text": { - "type": "keyword" - }, - "link": { - "type": "keyword" - } - } - } - } - }, - { - "contact": { - "match": "*contact*", - "mapping": { - "type": "nested", - "properties": { - "org": { - "type": "keyword" - }, - "role": { - "type": "keyword" - } - } - } - } - }, - { - "integerRange": { - "match": "*IntegerRange", - "mapping": { - "type": "integer_range" - } - } - }, - { - "dateRange": { - "match": "*DateRange", - "mapping": { - "type": "date_range", - "format": "date_optional_time||yyyy-MM-dd||yyyy-MM||yyyy||epoch_millis" - } - } - }, - { - "date": { - "match": "*Date*", - "mapping": { - "type": "date" - } - } - }, - { - "dateMonth": { - "match": "*Month*", - "mapping": { - "type": "keyword" - } - } - }, - { - "dateYear": { - "match": "*Year*", - "mapping": { - "type": "short" - } - } - }, - { - "measure": { - "match": "measure_*", - "mapping": { - "type": "keyword" - } - } - }, - { - "operationAllowed": { - "match": "op*", - "mapping": { - "type": "keyword" - } - } - }, - { - "validationStatus": { - "match": "valid*", - "mapping": { - "type": "keyword" - } - } - }, - { - "synInspireAnnexesType": { - "match": "inspireAnnex*", - "mapping": { - "type": "keyword", - "fielddata": true, - "analyzer": "synInspireAnnexes", - "search_analyzer": "keyword" - } - } - }, - { - "synInspireThemeType": { - "match": "inspireTheme*", - "mapping": { - "type": "keyword", - "fielddata": true, - "analyzer": "synInspireThemes", - "search_analyzer": "keyword" - } - } - }, - { - "inspireServiceType": { - "match": "inspireServiceType", - "mapping": { - "type": "keyword", - "fielddata": true, - "analyzer": "keepInspireServiceTypes", - "search_analyzer": "keyword" - } - } - } - ], - "properties": { - "any": { - "type": "text", - "analyzer": "french_light", - "fields": { - "stemmed": { - "type": "text", - "analyzer": "french_heavy" - } - } - }, - "anytext": { - "type": "search_as_you_type" - }, - "tag": { - "type": "object", - "properties": { - "default": { - "type": "keyword", - "copy_to": [ - "any", - "anytext" - ] - }, - "text": { - "type": "keyword" - }, - "link": { - "type": "keyword" - } - } - }, - "dateStamp": { - "type": "date" - }, - "changeDate": { - "type": "date" - }, - "document": { - "type": "text", - "index": false, - "doc_values": false - }, - "documentStandard": { - "type": "keyword" - }, - "docType": { - "type": "keyword" - }, - "sourceCatalogue": { - "type": "keyword" - }, - "geom": { - "type": "geo_shape" - }, - "shape": { - "type": "geo_shape" - }, - "location": { - "type": "geo_point" - }, - "bbox_xmin": { - "type": "double" - }, - "bbox_xmax": { - "type": "double" - }, - "bbox_ymin": { - "type": "double" - }, - "bbox_ymax": { - "type": "double" - }, - "harvesterId": { - "type": "keyword" - }, - "harvesterUuid": { - "type": "keyword" - }, - "uuid": { - "type": "keyword", - "copy_to": "any" - }, - "id": { - "type": "keyword" - }, - "hasInspireTheme": { - "type": "boolean" - }, - "hasBoundingPolygon": { - "type": "boolean" - }, - "hasOverview": { - "type": "boolean" - }, - "isValid": { - "type": "boolean" - }, - "isValidInspire": { - "type": "keyword" - }, - "isSchemaValid": { - "type": "boolean" - }, - "isAboveThreshold": { - "type": "boolean" - }, - "isOpenData": { - "type": "keyword" - }, - "lineage": { - "type": "text" - }, - "resolutionScaleDenominator": { - "type": "integer" - }, - "resourceDate": { - "type": "nested", - "properties": { - "type": { - "type": "keyword" - }, - "date": { - "type": "date" - } - } - }, - "link": { - "type": "nested", - "properties": { - "protocol": { - "type": "keyword", - "copy_to": "any" - }, - "link": { - "type": "text" - }, - "name": { - "type": "text", - "copy_to": "any" - }, - "description": { - "type": "text" - } - } - }, - "linkProtocol": { - "type": "keyword" - }, - "linkUrl": { - "type": "keyword" - }, - "coordinateSystem": { - "type": "text", - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - } - } - }, - "accessConstraints": { - "type": "text", - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - } - } - }, - "mainLanguage": { - "type": "keyword" - }, - "metadataIdentifier": { - "type": "keyword" - }, - "otherConstraints": { - "type": "text", - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - } - } - }, - "overviewUrl": { - "type": "text", - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - } - } - }, - "pointOfTruthURL": { - "type": "text" - }, - "recordOperateOn": { - "type": "keyword" - }, - "parentUuid": { - "type": "keyword" - }, - "recordGroup": { - "type": "keyword" - }, - "recordJoin": { - "type": "join", - "relations": { - "record": [ - "children", - "dataset", - "sibling", - "feature" - ] - } - }, - "recordLink": { - "type": "nested", - "properties": { - "type": { - "type": "keyword" - }, - "subtype": { - "type": "keyword" - }, - "created": { - "type": "keyword" - }, - "to": { - "type": "keyword" - }, - "url": { - "type": "keyword" - }, - "title": { - "type": "keyword" - }, - "origin": { - "type": "keyword" - } - } - }, - "resolutionDistance": { - "type": "keyword" - }, - "resourceLanguage": { - "type": "keyword" - }, - "resourceType": { - "type": "keyword" - }, - "resourceIdentifier": { - "type": "keyword", - "copy_to": "any" - }, - "serviceType": { - "type": "keyword" - }, - "format": { - "type": "keyword" - }, - "spatialRepresentationType": { - "type": "keyword" - }, - "standardName": { - "type": "keyword" - }, - "schema": { - "type": "keyword" - }, - "allKeywords": { - "type": "object", - "enabled": false - }, - "scope": { - "type": "keyword" - }, - "validReport": { - "type": "text", - "index": false, - "doc_values": false - }, - "useLimitation": { - "type": "text", - "fields": { - "keyword": { - "type": "keyword", - "ignore_above": 256 - } - } - }, - "groupPublished": { - "type": "keyword" - }, - "isPublishedToAll": { - "type": "keyword" - }, - "groupOwner": { - "type": "keyword" - }, - "recordOwner": { - "type": "keyword" - }, - "hasxlinks": { - "type": "boolean" - }, - "isTemplate": { - "type": "keyword" - }, - "draft": { - "type": "keyword" - }, - "isHarvested": { - "type": "boolean" - }, - "popularity": { - "type": "long" - }, - "rating": { - "type": "short" - }, - "mdStatus": { - "type": "short" - }, - "owner": { - "type": "keyword" - }, - "xlink": { - "type": "keyword" - }, - "root": { - "type": "keyword" - } - } - } -} From 49ec9b7a1b45e2b1ea95fd79f1ec0154d1f06f85 Mon Sep 17 00:00:00 2001 From: Francois Prunayre Date: Wed, 11 Aug 2021 11:19:22 +0200 Subject: [PATCH 008/361] Subtemplate / Improve indexing. --- .../plugin/iso19139/index-fields/index-subtemplate.xsl | 7 +++---- .../main/resources/catalog/js/edit/DirectoryController.js | 5 +++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/schemas/iso19139/src/main/plugin/iso19139/index-fields/index-subtemplate.xsl b/schemas/iso19139/src/main/plugin/iso19139/index-fields/index-subtemplate.xsl index d50a4b47fb1..94441e9fe20 100644 --- a/schemas/iso19139/src/main/plugin/iso19139/index-fields/index-subtemplate.xsl +++ b/schemas/iso19139/src/main/plugin/iso19139/index-fields/index-subtemplate.xsl @@ -99,10 +99,9 @@ - - - - + {"common": ""} + diff --git a/web-ui/src/main/resources/catalog/js/edit/DirectoryController.js b/web-ui/src/main/resources/catalog/js/edit/DirectoryController.js index 8e771c287a7..3fd000aa868 100644 --- a/web-ui/src/main/resources/catalog/js/edit/DirectoryController.js +++ b/web-ui/src/main/resources/catalog/js/edit/DirectoryController.js @@ -184,7 +184,7 @@ // in the template dropdown $http.post('../api/search/records/_search', { "_source": {"includes": [ - "uuid", "root", "resourceTitle", "isTemplate"]}, + "uuid", "root", "resourceTitle*", "isTemplate"]}, "query": { "bool" : { "must": [ @@ -201,7 +201,8 @@ edit: md._source.edit, selected: md._source.selected, isTemplate: md._source.isTemplate, - resourceTitle: md._source.resourceTitle + resourceTitle: md._source.resourceTitleObject + ? md._source.resourceTitleObject.default : md._source.resourceTitle }; }); } From c8c6ad3205e14223278b5e608c19a709a64a1dfc Mon Sep 17 00:00:00 2001 From: Francois Prunayre Date: Wed, 11 Aug 2021 11:20:05 +0200 Subject: [PATCH 009/361] CSW / Fix some field mapping. Needs improvement in multilingual conditions. --- web/src/main/webapp/WEB-INF/config-csw.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/src/main/webapp/WEB-INF/config-csw.xml b/web/src/main/webapp/WEB-INF/config-csw.xml index 27ed9aeb815..fa24c1ad7fa 100644 --- a/web/src/main/webapp/WEB-INF/config-csw.xml +++ b/web/src/main/webapp/WEB-INF/config-csw.xml @@ -39,7 +39,7 @@ - + @@ -53,7 +53,7 @@ path="gmd:identificationInfo/gmd:MD_DataIdentification/gmd:abstract/gco:CharacterString"/> - + Date: Wed, 11 Aug 2021 11:20:49 +0200 Subject: [PATCH 010/361] Search / Multilingual / Add default config and example for french. --- web-ui/src/main/resources/catalog/js/CatController.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/web-ui/src/main/resources/catalog/js/CatController.js b/web-ui/src/main/resources/catalog/js/CatController.js index 0ddc21d694e..39cb1995909 100644 --- a/web-ui/src/main/resources/catalog/js/CatController.js +++ b/web-ui/src/main/resources/catalog/js/CatController.js @@ -146,8 +146,10 @@ goog.require('gn_alert'); // Full text on all fields // 'queryBase': '${any}', // Full text but more boost on title match - 'queryBase': 'any.fre:(${any}) any.common:(${any})', - //'queryBase': 'any:(${any}) resourceTitleObject.\\*:(${any})^2', + // * Search in all languages + 'queryBase': 'any.\\*:(${any}) any.common:(${any}) resourceTitleObject.\\*:(${any})^2', + // * Search in French fields (with french analysis) + // 'queryBase': 'any.langfre:(${any}) any.common:(${any}) resourceTitleObject.langfre:(${any})^2', 'queryTitle': '${any}', 'searchOptions': true, // Score query may depend on where we are in the app? From 7ed8040e68ba06b56afbd3acea92910b1776d37e Mon Sep 17 00:00:00 2001 From: Francois Prunayre Date: Thu, 12 Aug 2021 12:03:27 +0200 Subject: [PATCH 011/361] Search / Multilingual / Add search options. * If records are in one language, the record language is used by default (and no options are proposed to users) * if records are in various languages, the following options are available: Languages are ordered by frequency in records. Languages proposed does not take into account templates. Language detection is made on the list of record's languages. The more languages you have, the more the language detection precision decrease. Catalogue administrator can define the language strategy to use by default in UI configuration: * queryBase: to adjust query * searchOptions.language: to display language options * languageStrategy Language strategies: * searchInUILanguage: search in UI languages eg. full text field is any.langfre if French * searchInAllLanguages: search using any.* fields (no analysis is done, more records are returned) * searchInDetectedLanguage: restrict the search to the language detected based on user search. If language detection fails, search in all languages. * forceALanguage: depending on user selection, force a language. --- .../components/elasticsearch/EsService.js | 58 +- .../searchmanager/SearchFormDirective.js | 53 +- .../searchoptions/SearchOptionsDirective.js | 81 ++- .../searchoptions/partials/searchoptions.html | 62 +- .../resources/catalog/js/CatController.js | 18 +- .../catalog/lib/franc-min/franc-min.js | 575 ++++++++++++++++++ .../resources/catalog/locales/en-editor.json | 1 - .../main/resources/catalog/locales/en-v4.json | 8 +- .../WEB-INF/data/config/index/records.json | 3 + .../webapp/xslt/base-layout-cssjs-loader.xsl | 1 + 10 files changed, 840 insertions(+), 20 deletions(-) create mode 100644 web-ui/src/main/resources/catalog/lib/franc-min/franc-min.js diff --git a/web-ui/src/main/resources/catalog/components/elasticsearch/EsService.js b/web-ui/src/main/resources/catalog/components/elasticsearch/EsService.js index f83b3221bb2..64ef9687dfd 100644 --- a/web-ui/src/main/resources/catalog/components/elasticsearch/EsService.js +++ b/web-ui/src/main/resources/catalog/components/elasticsearch/EsService.js @@ -49,6 +49,20 @@ return gnEsLuceneQueryParser.facetsToLuceneQuery(facetsState); } + function autoDetectLanguage(any, languageWhiteList) { + var whitelist = + languageWhiteList + || Object.keys(gnGlobalSettings.gnCfg.mods.header.languages); + var detectedLanguage = franc.all(any, { + whitelist: whitelist, + minLength: 10 + }), + firstLanguage = detectedLanguage[0]; + // console.log('Detecting language for "', p.any, '" in ', languageWhitelist); + // console.log(' => Detection failed: ', failedToDetect, ' / First match: ', firstLanguage); + // console.log(detectedLanguage); + return firstLanguage[0]; + } /** * Build all clauses to be added to the Elasticsearch @@ -60,7 +74,8 @@ * @param {boolean} exactMatch search for exact value * @param {boolean} titleOnly search in title only */ - this.buildQueryClauses = function(queryHook, p, luceneQueryString, exactMatch, titleOnly) { + this.buildQueryClauses = function(queryHook, p, luceneQueryString, + state) { var excludeFields = ['_content_type', 'fast', 'from', 'to', 'bucket', 'sortBy', 'sortOrder', 'resultType', 'facet.q', 'any', 'geometry', 'query_string', 'creationDateFrom', 'creationDateTo', 'dateFrom', 'dateTo', 'geom', 'relation', @@ -82,10 +97,41 @@ 'Using default value \'${any}\'.'); queryBase = defaultQuery; } + + var languageFound = false, + searchLanguage = 'lang' + state.forcedLanguage, + uiLanguage = 'lang' + gnGlobalSettings.iso3lang; + state.detectedLanguage = undefined; + if (state.forcedLanguage !== undefined) { + searchLanguage = 'lang' + state.forcedLanguage; + languageFound = true; + } else if (state.languageStrategy === 'searchInDetectedLanguage') { + searchLanguage = autoDetectLanguage(p.any, state.languageWhiteList); + state.detectedLanguage = searchLanguage; + languageFound = searchLanguage !== 'und'; + searchLanguage = languageFound ? 'lang' + searchLanguage : '\\*'; + } else if (state.languageStrategy === 'searchInUILanguage') { + searchLanguage = uiLanguage; + languageFound = true; + } else if (state.languageStrategy === 'searchInAllLanguages') { + languageFound = false; + searchLanguage = '\\*'; + uiLanguage = '\\*'; + } + var searchString = escapeSpecialCharacters(p.any), - q = queryBase.replace( + q = queryBase + .replace( + /\$\{uiLang\}/g, + uiLanguage) + .replace( + /\$\{searchLang\}/g, + languageFound && searchLanguage + ? searchLanguage : '\\*') + .replace( /\$\{any\}/g, - exactMatch === true ? '\"' + searchString + '\"' : searchString); + state.exactMatch === true + ? '\"' + searchString + '\"' : searchString); queryStringParams.push(q); } else { queryStringParams.push(queryExpression[1]); @@ -96,14 +142,14 @@ queryStringParams.push(luceneQueryString); } - if (titleOnly) { + if (state.titleOnly) { var query = gnGlobalSettings.gnCfg.mods.search.queryTitle.replace( /\$\{any\}/g, escapeSpecialCharacters(p.any)); queryHook.must.push({ query_string: { fields: ["resourceTitleObject.*"], - query: exactMatch === true ? '\"' + query + '\"' : query + query: state.exactMatch === true ? '\"' + query + '\"' : query } }); } else { @@ -274,7 +320,7 @@ } var queryHook = query.function_score.query.bool; - this.buildQueryClauses(queryHook, p, luceneQueryString, searchState.exactMatch, searchState.titleOnly); + this.buildQueryClauses(queryHook, p, luceneQueryString, searchState); if(p.from) { params.from = p.from - 1; diff --git a/web-ui/src/main/resources/catalog/components/search/searchmanager/SearchFormDirective.js b/web-ui/src/main/resources/catalog/components/search/searchmanager/SearchFormDirective.js index 26deb3a2ea4..a916564ef8c 100644 --- a/web-ui/src/main/resources/catalog/components/search/searchmanager/SearchFormDirective.js +++ b/web-ui/src/main/resources/catalog/components/search/searchmanager/SearchFormDirective.js @@ -354,7 +354,11 @@ $scope.searchObj.state = { filters: {}, exactMatch: false, - titleOnly: false + titleOnly: false, + languageStrategy: 'searchInAllLanguages', + forcedLanguage: undefined, + languageWhiteList: undefined, + detectedLanguage: undefined, }; $scope.triggerSearch(); $scope.$broadcast('resetSelection'); @@ -558,6 +562,53 @@ return $scope.searchObj.state.titleOnly; }; + + /** + * @param {string} value + */ + this.setLanguageStrategy = function(value) { + $scope.searchObj.state.languageStrategy = value; + }; + + /** + * @return {string} + */ + this.getLanguageStrategy = function() { + return $scope.searchObj.state.languageStrategy; + }; + + /** + * @param {string} value + */ + this.setForcedLanguage = function(value) { + $scope.searchObj.state.forcedLanguage = value; + }; + + /** + * @return {string} + */ + this.getForcedLanguage = function() { + return $scope.searchObj.state.forcedLanguage; + }; + + /** + * @param {array} value + */ + this.setLanguageWhiteList = function(value) { + $scope.searchObj.state.languageWhiteList = value; + }; + + /** + * @return {array} + */ + this.getLanguageWhiteList = function() { + return $scope.searchObj.state.languageWhiteList; + }; + + this.getDetectedLanguage = function() { + return $scope.searchObj.state.detectedLanguage; + }; + /** * @param {boolean} value */ diff --git a/web-ui/src/main/resources/catalog/components/search/searchoptions/SearchOptionsDirective.js b/web-ui/src/main/resources/catalog/components/search/searchoptions/SearchOptionsDirective.js index a921b1a7fa4..611a16e3f63 100644 --- a/web-ui/src/main/resources/catalog/components/search/searchoptions/SearchOptionsDirective.js +++ b/web-ui/src/main/resources/catalog/components/search/searchoptions/SearchOptionsDirective.js @@ -26,7 +26,9 @@ var module = angular.module('gn_searchoptions_directive', []); - module.directive('gnSearchOptions', ['$rootScope', 'gnGlobalSettings', function($rootScope, gnGlobalSettings) { + module.directive('gnSearchOptions', [ + '$rootScope', '$http', 'gnGlobalSettings', + function($rootScope, $http, gnGlobalSettings) { return { restrict: 'E', @@ -37,11 +39,46 @@ 'searchoptions.html', link: function(scope, element, attrs, controller) { scope.user = $rootScope.user; - scope.initOnlyMyRecord = function() { - scope.onlyMyRecord = gnGlobalSettings.gnCfg.mods.editor.isUserRecordsOnly - + scope.optionsConfig = gnGlobalSettings.gnCfg.mods.search.searchOptions; + scope.init = function() { + scope.onlyMyRecord = gnGlobalSettings.gnCfg.mods.editor.isUserRecordsOnly; + scope.languageStrategy = gnGlobalSettings.gnCfg.mods.search.languageStrategy; + scope.languagesAvailable = []; + scope.languagesStats = {}; + $http.post('../api/search/records/_search', { + size: 0, + query: { + terms: {isTemplate: ['n']} + }, + aggregations: { + mainLanguage: { + terms: { + field: 'mainLanguage', + size: 10, + exclude: '' + } + }, + otherLanguage: { + terms: { + field: 'otherLanguage', + size: 10, + exclude: '' + } + } + } + }). + success(function(data) { + angular.forEach(data.aggregations.mainLanguage.buckets, function(i) { + scope.languagesStats[i.key] = i.doc_count; + }); + angular.forEach(data.aggregations.otherLanguage.buckets, function(i) { + scope.languagesStats[i.key] = i.doc_count; + }); + scope.languagesAvailable = Object.keys(scope.languagesStats); + controller.setLanguageWhiteList(scope.languagesAvailable); + }); }; - scope.initOnlyMyRecord(); + // this enables to keep the dropdown active when we click on the label element.find('label > span').each(function(i, e) { $(e).on('click', function () { @@ -66,6 +103,33 @@ } }); + Object.defineProperty(scope, 'languageStrategy', { + get: function() { + return controller.getLanguageStrategy(); + }, + set: function(value) { + controller.setLanguageStrategy(value); + } + }); + + Object.defineProperty(scope, 'forcedLanguage', { + get: function() { + return controller.getForcedLanguage(); + }, + set: function(value) { + controller.setForcedLanguage(value); + } + }); + + Object.defineProperty(scope, 'languageWhiteList', { + get: function() { + return controller.getLanguageWhiteList(); + }, + set: function(value) { + controller.setLanguageWhiteList(value); + } + }); + Object.defineProperty(scope, 'onlyMyRecord', { get: function() { return controller.getOnlyMyRecord(); @@ -74,6 +138,13 @@ controller.setOnlyMyRecord(value); } }); + + scope.$watch('languageStrategy', function(n, o) { + if (o === 'forceALanguage') { + controller.setForcedLanguage(undefined); + } + }) + scope.init(); } }; }]); diff --git a/web-ui/src/main/resources/catalog/components/search/searchoptions/partials/searchoptions.html b/web-ui/src/main/resources/catalog/components/search/searchoptions/partials/searchoptions.html index f381a547d6e..8706e2a63f4 100644 --- a/web-ui/src/main/resources/catalog/components/search/searchoptions/partials/searchoptions.html +++ b/web-ui/src/main/resources/catalog/components/search/searchoptions/partials/searchoptions.html @@ -1,4 +1,5 @@ -
+
-
+
+
+
+ searchWithLang +
+
+ + + +
+
+ + +
+
+