VIVO Mapping process


Semantic extraction

Semantic extraction consists in merging all ORCID data files and extracting the list of properties from them

Semantic extraction query
CONSTRUCT {
    ?p a owl:ObjectProperty .
}
WHERE {
     ?subject ?p ?object .
     FILTER regex(str(?p), "uqam") .
}

ORCID to VIVO Mapping

Mapping ORCID data to the VIVO vocabulary consists in associating ORCID statements to VIVO semantics. For demonstration purposes, three concepts are mapped: the person's name including title; his or her skills and the organizations to which he or she belongs.

The mapping is carried out by three SPARQL queries whose semantics are symbolized by the ORCID and VIVO ontologies.

Mapping rules

ORCID Ontology Snap-shot

get_name.sparql

get_comp.sparql (Extract and map competencies )

get_org.sparql (Extract and map organization )

CONSTRUCT {
    ?ID_IRI a core:FacultyMember .
    ?ID_IRI a owl:NamedIndividual .
    ?ID_IRI rdfs:label ?full_name .
    ?ID_IRI obo:ARG_2000028 ?VCARD_ID_IRI .
    ?VCARD_ID_IRI obo:ARG_2000029 ?ID_IRI .
    ?VCARD_ID_IRI a vcard:Individual .
    ?VCARD_ID_IRI vcard:hasName _:b0 .
    ?VCARD_ID_IRI vcard:hasTitle _:b1 .
    _:b1 a vcard:Title .
    _:b1 vcard:title ?title .
    _:b0 a vcard:Name .
    _:b0 vcard:familyName ?fnCA .
    _:b0 vcard:givenName ?gnCA .
}
WHERE {
    ?s orcid:person ?o .
    ?s orcid:orcid-identifier/orcid:path ?ID .
    ?o orcid:name ?oo .
    ?oo orcid:family-name/orcid:value ?fn .
    ?oo orcid:given-names/orcid:value ?gn .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/", "ID-", ?ID))
         AS ?ID_IRI) .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/", "VCARD-", ?ID))
         AS ?VCARD_ID_IRI) .
    BIND (STRLANG(CONCAT(?gn, " ", ?fn), "en-US") AS ?full_name_en) .
    BIND (STRLANG(CONCAT(?gn, " ", ?fn), "fr-CA") AS ?full_name) .
   # For now, everybody is a professor
    BIND (STRLANG("Professeur", "fr-CA") AS ?title) .  
    BIND (STRLANG(?fn, "fr-CA") AS ?fnCA) .
    BIND (STRLANG(?gn, "fr-CA") AS ?gnCA) .
}

CONSTRUCT {
    ?ID_IRI core:hasResearchArea ?comp_iri .
    ?ID_IRI a owl:NamedIndividual .
    ?comp_iri a skos:Concept .
    ?comp_iri rdfs:label ?comp .
    ?comp_iri rdfs:label ?comp_en .
    ?comp_iri core:researchAreaOf ?ID_IRI .
}
WHERE {
    ?s orcid:orcid-identifier/orcid:path ?ID .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/", "ID-", ?ID))
         AS ?ID_IRI) .
    ?ss orcid:keyword ?k .
    ?k orcid:content ?oo .
    BIND (STRLANG(?oo, "fr-CA") AS ?comp) .
    BIND (STRLANG(?oo, "en-US") AS ?comp_en) .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/",
         ENCODE_FOR_URI(CONCAT("COMP_", str(?oo))))) AS ?comp_iri) .
}

CONSTRUCT {
    ?IR_IRI obo:ARG_2000028 ?VCARD_ID_IRI .
    ?VCARD_ID_IRI vcard:hasTitle _:b0 .
    _:b0 a vcard:Title .
    _:b0 vcard:title ?role_lang .
    ?ID_IRI core:relatedBy ?ORG_IRI .
    ?ORG_IRI rdfs:label ?role_lang .
    ?ORG_IRI rdfs:label ?role_lang_en .
    ?ID_IRI a owl:NamedIndividual .
    ?ORG_IRI a core:FacultyPosition .
    ?ORG_IRI vcard:organizationalUnitName ?org_name .
    ?ORG_IRI vcard:title ?role_lang .
    ?ORG_IRI vcard:title ?role_lang_en .
    ?ORG_IRI core:relates ?ID_IRI .
}
WHERE {
    ?s orcid:orcid-identifier/orcid:path ?ID .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/", "ID-", ?ID))
        AS ?ID_IRI) .
    ?x orcid:employments/orcid:affiliation-group ?ag .
    ?ag orcid:summaries/orcid:employment-summary ?es .
    ?es orcid:organization ?org .
    ?org orcid:disambiguated-organization/
        orcid:disambiguated-organization-identifier ?org_id .
    ?org orcid:name ?name .
    ?es orcid:role-title ?role .
    BIND (IRI(CONCAT("http://localhost:8080/vivo_uqam/individual/", ?org_id))
         AS ?ORG_IRI) .
    BIND (IRI(CONCAT("http://localhost:8080/vivo/individual/", "VCARD-", ?ID))
        AS ?VCARD_ID_IRI) .
    BIND (STRLANG(?role, "fr-CA") AS ?role_lang) .
    BIND (STRLANG(?role, "en-US") AS ?role_lang_en) .
    BIND (STRLANG(?name, "fr-CA") AS ?org_name) .
}


Mapping script

orcid_vivo_mapping.sh
#!/bin/bash

###################################################################
# Script Name    : orcid_vivo_mapping.sh
# Description    : Mapping ORCID RDF data to VIVO vocabulary. Results are in n3 format for transmission to Kafka. 
# Args           : 
# Author         : Michel Héon
# Email          : heon.michel@uqam.ca
###################################################################

source environment.sh
cd records
echo "" > $ONTO_ALL_RECORDS 

for n in *.ttl ; do
    ((i=i+1))
    ((j=j+1))
    bn=`basename $n .ttl`
    echo process $i $bn
    (sparql --data=$n  --query=../sparql/get_name.sparql --results=N-Triples > ${bn}_name.n3 ; cat ${bn}_name.n3 >> $ONTO_ALL_RECORDS) &  
    (sparql --data=$n  --query=../sparql/get_org.sparql --results=N-Triples > ${bn}_org.n3; cat ${bn}_org.n3 >> $ONTO_ALL_RECORDS) &  
    (sparql --data=$n  --query=../sparql/get_comp.sparql --results=N-Triples > ${bn}_comp.n3 ; cat ${bn}_comp.n3 >> $ONTO_ALL_RECORDS) &  
    if [ $j = "5" ]; then
    echo 'waiting...'
    wait
    ((j=0))
    fi
done
echo "Done!"







  • No labels