<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Yuzu: Publishing Any Data as Linked Data</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>John P. McCrae</string-name>
          <email>john@mccr.ae</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Insight Centre for Data Analytics, National University of Ireland</institution>
          ,
          <addr-line>Galway</addr-line>
        </aff>
      </contrib-group>
      <abstract>
        <p>Linked data is one of the most important methods for improving the applicability of data, however most data is not in linked data formats and raising it to linked data is still a signi cant challenge. We present Yuzu, an application that makes it easy to host legacy data in JSON, XML or CSV as linked data, while providing a clean interface with advanced features. The ease-of-use of this framework is shown by its adoption for a number of existing datasets including WordNet.</p>
      </abstract>
      <kwd-group>
        <kwd>linked data</kwd>
        <kwd>data frontend</kwd>
        <kwd>data conversion</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>Introduction</title>
      <p>
        Linked data [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ] has been identi ed as one of the major ways to present data
for knowledge discovery and has been shown to improve the quality and the
usefulness of datasets [
        <xref ref-type="bibr" rid="ref12">12</xref>
        ]. However, a major challenge remains the conversion
of datasets into linked data [
        <xref ref-type="bibr" rid="ref10 ref5">5, 10</xref>
        ]. This is frequently caused by the fact that
data is in legacy formats such as CSV, XML or JSON and the conversion from
these formats into RDF often represents much of the e ort of a project. In recent
years, a number of e orts have been made to make RDF and linked data work
with these formats in particular, CSV on the Web [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ] and JSON-LD [
        <xref ref-type="bibr" rid="ref13">13</xref>
        ], and
these formats should lower the barrier to entry to users of linked data.
      </p>
      <p>
        In this paper, we present the Yuzu platform1, a frontend for linked data, like
Pubby [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ] or LodLive [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. This platform can, in contrast to existing systems, aims
to be free from strict restrictions about the format of the data, instead assuming
that the data can be understood even in legacy formats with a small amount
of metadata. This system also removes the need to run a separate SPARQL
database and instead allows simple SPARQL access to data with some
limitations `out-of-the-box'. In addition, this platform implements many features that
are required to make data easy-to-work with including content negotiation and
automatic backups based on hashes [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ].
      </p>
    </sec>
    <sec id="sec-2">
      <title>Handling data in legacy formats</title>
      <p>Data can be structured in three main ways: rstly tabular data which is serialized
by means of table format where data is separated typically by a tab or comma.</p>
      <sec id="sec-2-1">
        <title>1 Yuzu is available at https://github.com/jmccrae/yuzu</title>
        <p>
          Secondly, hierarchical data is structured in a at tree and XML and JSON are
the two most popular serialization methods. Finally, graph structured data has
the most freedom in its representation, and RDF is the most commonly found
form of this data, but databases based on this model can have a signi cant
performance gap, which is called the \RDF tax" [
          <xref ref-type="bibr" rid="ref2">2</xref>
          ]. The Yuzu model is to keep
documents in the format that is created but enable querying over them as if
they were graph-based linked data. All conversions are provided using existing
standards such wherever possible. and as such the input to Yuzu is the dataset
as a single ZIP le containing all the data les in a some mix of XML, CSV and
JSON.
2.1
        </p>
        <p>
          JSON-LD and XML
JSON documents in Yuzu can be understood by means of a context document
and it is required that each data either is a JSON-LD document with a @context
element or that in the containing folder there is a context.json, which is used
for indexing and is returned with the Link header [13, x6.8]. XML is mapped
also using the JSON-LD context le and we assume a simple generic mapping
method, whereby attributes and subtags (if there is no text context) are treated
as name/value pairs in an object. If this is not possible the @value special
property is used. Alternatively, a mapping may be provided using the LIXR
mapping language [
          <xref ref-type="bibr" rid="ref9">9</xref>
          ].
2.2
        </p>
        <p>
          CSV
CSV conversion is based on the CSV on the Web standard's recipe for creating
RDF data [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ], which we implement as part of the Yuzu model. Generation of
RDF data from this CSV is provided in standard mode such that extra data
for querying is available to the user. Each CSV le is described by means of an
extra metadata le in the form of the Tabular Data Metadata Vocabulary [
          <xref ref-type="bibr" rid="ref11">11</xref>
          ],
which is in fact another JSON-LD le. In the case where no mapping is found
a default empty tabular metadata le is created and used to map the CSV into
RDF. In the interface, data that was originally in CSV is presented to the user
in a tabular form, however the RDF data can be obtained by means of content
negotiation.
3
        </p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>Cheap, robust SPARQL querying</title>
      <p>SPARQL provides a powerful and e ective method for querying data on the
Web, however it provides signi cant challenges for hosts wishing to provide fast
access with limited resources. SPARQL is a very free query language and it is
easy to devise queries that are very hard to answer, and even worse this can
easily be caused by typos2.
2 e.g., a typo in a variable name will not be detected in SPARQL and will turn a query
that could be answered with an inner join to a query that can only be answered with
the more expensive cross join</p>
      <p>We employ a pre-processor that attempts to nd a xed subset of documents
that have a given property and then creating a mini-dataset to evaluate the
query on. This means certain queries, for example those which rely on FILTER
constraints to do most of the document selection, will not be possible to execute,
but more typical queries, such as documents with a list of properties can be more
readily executed. We believe that this provides a good perfomance balance and
will continue to evaluate this balance in our deployed instances. Of course, a
full SPARQL endpoint can be used along with our this method to support all
SPARQL queries.
4</p>
    </sec>
    <sec id="sec-4">
      <title>Hashing, permalinks and backups</title>
      <p>A major issue that faces data users is that data frequently becomes unavailable
or has changed in a manner that makes it di cult to reuse. In order to combat
this, Yuzu takes a hash of the overall dataset and a hash of each individual
le in the dataset. The hash of each individual le can be used to look up any
individual resource.</p>
      <p>
        Secondly, each Yuzu instance may allocate a certain amount of space to back
up parts of other resources. This back-up procedure is implemented by a method
based on the Kademlia [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] protocol. Each Yuzu instance generates at start-up a
unique identi er and checks the identi er of each of its peers (from a xed list of
peers). Then the les in the dataset are posted to each of the peers and the peers
store those les that are closest in the XOR distance between the le's hash and
the instance's hash, up to the limit of les that are there for back-up. Then when
resolving a `permalink', if the hash does not correspond to any of the le in this
resources dataset the system redirects to another host, whose instance hash is
closer to the requested hash.
5
      </p>
    </sec>
    <sec id="sec-5">
      <title>Conclusions and current deployments</title>
      <p>
        The ease-of-use of the Yuzu system has been deployed to host a number of
datasets: originally it was developed for the WordNet dataset3, and this is still
a supported theme of the system. Since then, Yuzu has been applied to large
datasets, such as Linghub [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ], and has been used to host a large number of
smaller datasets. The robust theming and stability of the interface has allowed
datasets to be hosted even on very low-resourced virtual machines, even while
allowing querying using SPARQL.
      </p>
    </sec>
    <sec id="sec-6">
      <title>Acknowledgements</title>
      <p>This research was supported by the Science Foundation Ireland under Grant
Number SFI/12/RC/2289 (Insight)</p>
      <sec id="sec-6-1">
        <title>3 http://wordnet-rdf.princeton.edu</title>
      </sec>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <surname>Bizer</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Heath</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Berners-Lee</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          :
          <article-title>Linked data-the story so far</article-title>
          .
          <source>Semantic Services, Interoperability and Web Applications: Emerging Concepts</source>
          pp.
          <volume>205</volume>
          {
          <issue>227</issue>
          (
          <year>2009</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Boncz</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Erling</surname>
            ,
            <given-names>O.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pham</surname>
          </string-name>
          , M.D.:
          <article-title>Advances in large-scale RDF data management</article-title>
          .
          <source>In: Linked Open Data{Creating Knowledge Out of Interlinked Data</source>
          , pp.
          <volume>21</volume>
          {
          <fpage>44</fpage>
          . Springer (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Camarda</surname>
            ,
            <given-names>D.V.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mazzini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Antonuccio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>LodLive, exploring the web of data</article-title>
          .
          <source>In: Proceedings of the 8th International Conference on Semantic Systems</source>
          . pp.
          <volume>197</volume>
          {
          <fpage>200</fpage>
          .
          <string-name>
            <surname>ACM</surname>
          </string-name>
          (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Cyganiak</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Bizer</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          :
          <article-title>Pubby-a linked data frontend for sparql endpoints (</article-title>
          <year>2008</year>
          ), http://www4.wiwiss.fu-berlin.de/pubby/
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Ehrmann</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Ceconi</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Vannella</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>McCrae</surname>
            ,
            <given-names>J.P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Cimiano</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Navigli</surname>
          </string-name>
          , R.:
          <article-title>Representing Multilingual Data as Linked Data: the Case of BabelNet 2.0</article-title>
          .
          <source>In: Proceedings of the 9th Language Resource and Evaluation Conference</source>
          . pp.
          <volume>401</volume>
          {
          <issue>408</issue>
          (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <surname>Maymounkov</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mazieres</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          :
          <article-title>Kademlia: A peer-to-peer information system based on the xor metric</article-title>
          . In: Peer-to-
          <source>Peer Systems</source>
          , pp.
          <volume>53</volume>
          {
          <fpage>65</fpage>
          . Springer (
          <year>2002</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <surname>McCrae</surname>
            ,
            <given-names>J.P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Bordea</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Buitelaar</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Linked data and text mining as an enabler for reproducible research</article-title>
          .
          <source>In: Proceedings of the Workshop on Cross-Platform Text Mining and Natural Language Processing Interoperability</source>
          (
          <year>2016</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <surname>McCrae</surname>
            ,
            <given-names>J.P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Cimiano</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Linghub: a linked data based portal supporting the discovery of language resources</article-title>
          .
          <source>In: Joint Proceedings of the Posters and Demos Track of 11th International Conference on Semantic Systems-SEMANTiCS 2015 and 1st Workshop on Data Science: Methods, Technology and Applications (DSci15)</source>
          . pp.
          <volume>88</volume>
          {
          <issue>91</issue>
          (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <surname>McCrae</surname>
            ,
            <given-names>J.P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Cimiano</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          : LIXR:
          <article-title>Quick, succinct conversion of XML to RDF and back again</article-title>
          .
          <source>In: Proceedings of the ISWC 2016 Posters and Demo Track</source>
          (
          <year>2016</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <given-names>O</given-names>
            <surname>'Riain</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            ,
            <surname>Curry</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E.</given-names>
            ,
            <surname>Harth</surname>
          </string-name>
          ,
          <string-name>
            <surname>A.</surname>
          </string-name>
          :
          <article-title>XBRL and open data for global nancial ecosystems: A linked data approach</article-title>
          .
          <source>International Journal of Accounting Information Systems</source>
          <volume>13</volume>
          (
          <issue>2</issue>
          ),
          <volume>141</volume>
          {
          <fpage>162</fpage>
          (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <surname>Pollock</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tennison</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kellogg</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Herman</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          :
          <article-title>Metadata vocabulary for tabular data</article-title>
          .
          <source>W3C recommendation, World Wide Web Consortium</source>
          (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <surname>Schultz</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Matteini</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Isele</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mendes</surname>
            ,
            <given-names>P.N.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Bizer</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Becker</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          :
          <article-title>Ldifa framework for large-scale linked data integration</article-title>
          .
          <source>In: 21st International World Wide Web Conference (WWW</source>
          <year>2012</year>
          ), Developers Track, Lyon, France (
          <year>2012</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <surname>Sporny</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Longley</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kellogg</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Lanthaler</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Lindstrm</surname>
          </string-name>
          , N.:
          <article-title>Json-ld 1.0</article-title>
          . W3C recommendation,
          <source>World Wide Web Consortium</source>
          (
          <year>2014</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <surname>Tandy</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Herman</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kellogg</surname>
          </string-name>
          , G.:
          <article-title>Generating RDF from tabular data on the web</article-title>
          .
          <source>W3C recommendation, World Wide Web Consortium</source>
          (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15.
          <string-name>
            <surname>Tennison</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kellogg</surname>
            ,
            <given-names>G.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Herman</surname>
            ,
            <given-names>I.</given-names>
          </string-name>
          :
          <article-title>Model for tabular data and metadata on the web</article-title>
          .
          <source>W3C recommendation, World Wide Web Consortium</source>
          (
          <year>2015</year>
          )
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>