830 lines
20 KiB
Python
830 lines
20 KiB
Python
|
|
mappings = {}
|
|
|
|
mappings['datasource'] = {
|
|
"properties": {
|
|
"data_source_classification": {
|
|
"type": "keyword"
|
|
},
|
|
"jurisdiction": {
|
|
"type": "keyword"
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"eoscId": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"research_product_type": {
|
|
"type": "keyword"
|
|
},
|
|
"thematic": {
|
|
"type": "boolean"
|
|
},
|
|
"version_control": {
|
|
"type": "boolean"
|
|
},
|
|
|
|
# TODO: THOSE WERE NOT INFERREd AUTOMATICALLY
|
|
"submission_policy_url": {
|
|
"type": "text"
|
|
},
|
|
"preservation_policy_url": {
|
|
"type": "text"
|
|
},
|
|
"persistent_identity_systems": {
|
|
"type": "object",
|
|
"properties": {
|
|
"product_type": {
|
|
"type": "keyword"
|
|
},
|
|
"pid_schemes": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"research_product_license": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "text"
|
|
},
|
|
"url": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"research_product_access_policy": {
|
|
"type": "keyword"
|
|
},
|
|
"research_metadata_license": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "text"
|
|
},
|
|
"url": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"research_metadata_access_policy": {
|
|
"type": "keyword"
|
|
},
|
|
}
|
|
}
|
|
|
|
mappings['venues'] = {
|
|
"properties": {
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"publisher": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['topics'] = {
|
|
"properties": {
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['persons'] = {
|
|
"properties": {
|
|
"family_name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"full_name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"given_name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['organizations'] = {
|
|
"properties": {
|
|
"country": {
|
|
"type": "keyword"
|
|
},
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"other_names": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"short_name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['grants'] = {
|
|
"properties": {
|
|
"acronym": { # TODO: could be keyword only??
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"currency": {
|
|
"type": "keyword"
|
|
},
|
|
"end_date": {
|
|
"type": "date",
|
|
"ignore_malformed": "true"
|
|
},
|
|
"funded_amount": {
|
|
"type": "double"
|
|
},
|
|
"funder": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"funding_stream": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"grantCode": {
|
|
"type": "keyword"
|
|
},
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"start_date": {
|
|
"type": "date",
|
|
"ignore_malformed": "true"
|
|
},
|
|
"summary": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"title": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"website": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['products'] = {
|
|
"properties": {
|
|
### Syntethic fields
|
|
"accessRights": {
|
|
"type": "keyword"
|
|
},
|
|
"domain": {
|
|
"type": "object",
|
|
"properties": {
|
|
"domain": {
|
|
"type": "keyword"
|
|
},
|
|
"subdomain": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"firstPublishDate": {
|
|
"type": "date"
|
|
},
|
|
"keyword": {
|
|
"type": "keyword"
|
|
},
|
|
###
|
|
"abstracts": {
|
|
"type": "object",
|
|
"properties": {
|
|
# TODO: other languages via index templates
|
|
"none": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
# "accessRights": {
|
|
# "type": "keyword"
|
|
# },
|
|
"contributions": {
|
|
"type": "object",
|
|
"properties": {
|
|
"person": {
|
|
"type": "object",
|
|
"properties": {
|
|
"full_name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"orcid": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"declared_affiliations": {
|
|
"type": "keyword" # TODO: ask to Miriam, not mapped automatically
|
|
},
|
|
"rank": {
|
|
"type": "long"
|
|
},
|
|
"roles": {
|
|
"type": "keyword" # TODO: ask to Miriam, not mapped automatically
|
|
}
|
|
}
|
|
},
|
|
"funding": {
|
|
"type": "object",
|
|
"properties": {
|
|
"code": {
|
|
"type": "keyword"
|
|
},
|
|
"funder": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"title": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"identifiers": {
|
|
"type": "object",
|
|
"properties": {
|
|
"scheme": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"manifestations": {
|
|
"type": "object",
|
|
"properties": {
|
|
"access_right": {
|
|
"type": "keyword"
|
|
},
|
|
"biblio": {
|
|
"type": "object",
|
|
"properties": {
|
|
"end_page": {
|
|
"type": "text"
|
|
},
|
|
"publisher": {
|
|
"type": "text"
|
|
},
|
|
"start_page": {
|
|
"type": "text"
|
|
},
|
|
"volume": {
|
|
"type": "text"
|
|
},
|
|
"issue": {
|
|
"type": "text"
|
|
},
|
|
"edition": {
|
|
"type": "text"
|
|
},
|
|
"number": {
|
|
"type": "text"
|
|
},
|
|
"hosting_data_source": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"dates": {
|
|
"type": "object",
|
|
"properties": {
|
|
"type": {
|
|
"type": "text"
|
|
},
|
|
"value": {
|
|
"type": "date"
|
|
}
|
|
}
|
|
},
|
|
"hosting_datasource": {
|
|
"type": "object",
|
|
"properties": {
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"licence": {
|
|
"type": "text"
|
|
},
|
|
"metadata_curation": {
|
|
"type": "keyword"
|
|
},
|
|
"peer_review": {
|
|
"type": "keyword"
|
|
},
|
|
"pid": {
|
|
"type": "keyword"
|
|
},
|
|
"product_local_type": {
|
|
"type": "text"
|
|
},
|
|
"product_local_type_schema": {
|
|
"type": "text"
|
|
},
|
|
"url": {
|
|
"type": "text"
|
|
},
|
|
"venue": {
|
|
"type": "object",
|
|
"properties": {
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
"product_type": {
|
|
"type": "keyword"
|
|
},
|
|
"related_products": {
|
|
"type": "object",
|
|
"properties": {
|
|
"product_list": {
|
|
"type": "object",
|
|
"properties": {
|
|
"doi": {
|
|
"type": "keyword"
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"title": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"relation_type": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"relevant_organizations": {
|
|
"type": "object",
|
|
"properties": {
|
|
"isni": {
|
|
"type": "keyword"
|
|
},
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"type": "text"
|
|
},
|
|
"ror": {
|
|
"type": "keyword"
|
|
},
|
|
"wikidata": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"titles": {
|
|
"type": "object",
|
|
#TODO: other languages ??
|
|
"properties": {
|
|
"none": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
},
|
|
"type": {
|
|
"type": "alias",
|
|
"path": "product_type"
|
|
},
|
|
"topics": {
|
|
"type": "object",
|
|
"properties": {
|
|
"provenance": {
|
|
"type": "object",
|
|
"properties": {
|
|
"trust": {
|
|
"type": "keyword",
|
|
"index": "false"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"topic": {
|
|
"type": "object",
|
|
"properties": {
|
|
"local_identifier": {
|
|
"type": "keyword"
|
|
},
|
|
"value": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword"
|
|
}
|
|
},
|
|
"type": "text"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
#
|
|
# EOSC CATALOG
|
|
#
|
|
mappings['services'] = {
|
|
"properties": {
|
|
"category": {
|
|
"type": "object",
|
|
"properties": {
|
|
"category": {
|
|
"type": "keyword"
|
|
},
|
|
"subcategory": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"description": {
|
|
"type": "text"
|
|
},
|
|
"domain": {
|
|
"type": "object",
|
|
"properties": {
|
|
"domain": {
|
|
"type": "keyword"
|
|
},
|
|
"subdomain": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"horizontal": {
|
|
"type": "boolean"
|
|
},
|
|
"id": {
|
|
"type": "keyword"
|
|
},
|
|
"interoperabilityGuidelines": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"language": {
|
|
"type": "keyword"
|
|
},
|
|
"name": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"organization": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"providers": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"tags": {
|
|
"type": "keyword"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
},
|
|
"webpage": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['interoperability'] = {
|
|
"properties": {
|
|
"description": {
|
|
"type": "text"
|
|
},
|
|
"id": {
|
|
"type": "keyword"
|
|
},
|
|
"license": {
|
|
"type": "keyword"
|
|
},
|
|
"organization": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"publicationYear": {
|
|
"type": "long"
|
|
},
|
|
"services": {
|
|
"type": "object",
|
|
"properties": {
|
|
"name": {
|
|
"type": "keyword"
|
|
},
|
|
"organization": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"title": {
|
|
"type": "text"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
}
|
|
|
|
mappings['training'] = {
|
|
"properties": {
|
|
"accessRights": {
|
|
"type": "keyword"
|
|
},
|
|
"authors": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"contentResourceType": {
|
|
"type": "keyword"
|
|
},
|
|
"description": {
|
|
"type": "text"
|
|
},
|
|
"duration": {
|
|
"type": "keyword"
|
|
},
|
|
"domain": {
|
|
"type": "object",
|
|
"properties": {
|
|
"domain": {
|
|
"type": "keyword"
|
|
},
|
|
"subdomain": {
|
|
"type": "keyword"
|
|
}
|
|
}
|
|
},
|
|
"expertiseLevel": {
|
|
"type": "keyword"
|
|
},
|
|
"id": {
|
|
"type": "keyword"
|
|
},
|
|
"keyword": {
|
|
"type": "keyword"
|
|
},
|
|
"language": {
|
|
"type": "keyword"
|
|
},
|
|
"learningResourceType": {
|
|
"type": "keyword"
|
|
},
|
|
"license": {
|
|
"type": "keyword"
|
|
},
|
|
"organization": {
|
|
"fields": {
|
|
"keyword": {
|
|
"type": "keyword",
|
|
"ignore_above": 256
|
|
}
|
|
},
|
|
"type": "text"
|
|
},
|
|
"qualifications": {
|
|
"type": "keyword"
|
|
},
|
|
"title": {
|
|
"type": "text"
|
|
},
|
|
"targetGroup": {
|
|
"type": "keyword"
|
|
},
|
|
"type": {
|
|
"type": "keyword"
|
|
},
|
|
"url": {
|
|
"type": "text"
|
|
}
|
|
}
|
|
} |