Linked Data Step 2
02 Apr 2018In Linked Data Step 1 I ended by saying that the next step
was to perform reconciliation on selected object metadata terms and to add the resulting links to the object’s RDF output.
In fact, looking at the RDF snippets given as examples, you can see that this was already done. The fields I reconciled
were dc:creator
, dc:subject
and dc:spatial
. To do this those terms were exported from all the objects
contained in one collection and then imported as a project in OpenRefine. Using OpenRefine together
with the RDF extension I reconciled these against DBpedia, LCSH (for subjects) and Linked Logainm (for places). The
RDF extension allows you to build a skeleton (a template for the RDF output) for exporting to either RDF/XML or TTL. The exported RDF
can then be imported to a SPARQL endpoint.
Here, for example, is the generated RDF output for a reconciled subject term, based on the skeleton that I defined:
You can see that the subject term value Easter Rising 1916
has been linked to an LCSH subject and a
DBpedia entry. Now when you view the RDF format output of an object containing this value, you see the link
to the RDF resource instead of the literal:
When generating an object’s RDF output, RDF subject URIs are retrieved by the RDF formatter code by issuing a SPARQL query to the SPARQL endpoint.
This method takes the literal value, e.g. ‘Easter Rising 1916’, and queries for the subject of a triple that has this value as a preferred label. If one is found, this is used in place of the literal value.
The final step then is to take the RDF output for each object in a collection, including the new reconciled URIs and import them into the SPARQL endpoint.