<?xml version="1.0" encoding="UTF-8" ?>
<!--RDF based XML document generated By OpenLink Virtuoso-->
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
 <rss:channel xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/">
  <rss:title>Orri Erling&#39;s Weblog</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/</rss:link>
  <rss:description />
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-05-17T03:27:01Z</dc:date>
  <dc:rights xmlns:dc="http://purl.org/dc/elements/1.1/" />
  <dc:language xmlns:dc="http://purl.org/dc/elements/1.1/">en-us</dc:language>
  <rss:items>
   <rdf:Seq>
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1358" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1353" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1347" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1346" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1345" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1337" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1336" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1335" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1326" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1321" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1312" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1308" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1304" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1302" />
      <rdf:li rdf:resource="http://www.openlinksw.com/weblog/oerling/?id=1296" />
   </rdf:Seq>
  </rss:items>
 </rss:channel>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1358">
  <rss:title>DBpedia Benchmark Revisited</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1358</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1358</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1358</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-05-09T19:27:00Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">We ran the DBpedia benchmark queries again with different configurations of Virtuoso. I had not studied the details of the matter previously but now did have a closer look at the queries. Comparing numbers given by different parties is a constant problem. In the case reported here, we loaded the full DBpedia 3, all languages, with about 198M triples, onto Virtuoso v5 and Virtuoso Cluster v6, all on the same 4 core 2GHz Xeon with 8G RAM. All databases were striped on 6 disks. The Cluster configuration was with 4 processes in the same box. We ran the queries in two variants: With graph specified in the SPARQL FROM clause, using the default indices. With no graph specified anywhere, using an alternate indexing scheme. The times below are for the sequence of 5 queries; individual query times are not reported. I did not do a line-by-line review of the execution plans since they seem to run well enough. We could get some extra mileage from cost model tweaks, especially for the numeric range conditions, but we will do this when somebody comes up with better times. First, about Virtuoso v5: Because there is a query in the set that specifies no condition on S or O and only P, this simply cannot be done with the default indices. With Virtuoso Cluster v6 it sort-of can, because v6 is more space efficient. So we added the index: create bitmap index rdf_quad_pogs on rdf_quad (p, o, g, s);   Virtuoso v5 with gspo, ogps, pogs Virtuoso Cluster v6 with gspo, ogps Virtuoso Cluster v6 with gspo, ogps, pogs cold 210 s 136 s 33.4 s warm 0.600 s 4.01 s 0.628 s OK, so now let us do it without a graph being specified. For all platforms, we drop any existing indices, and -- create table r2 (g iri_id_8, s, iri_id_8, p iri_id_8, o any, primary key (s, p, o, g)) alter index R2 on R2 partition (s int (0hexffff00)); log_enable (2); insert into r2 (g, s, p, o) select g, s, p, o from rdf_quad; drop table rdf_quad; alter table r2 rename RDF_QUAD; create bitmap index rdf_quad_opgs on rdf_quad (o, p, g, s) partition (o varchar (-1, 0hexffff)); create bitmap index rdf_quad_pogs on rdf_quad (p, o, g, s) partition (o varchar (-1, 0hexffff)); create bitmap index rdf_quad_gpos on rdf_quad (g, p, o, s) partition (o varchar (-1, 0hexffff)); The code is identical for v5 and v6, except that with v5 we use iri_id (32 bit) for the type, not iri_id_8 (64 bit). We note that we run out of IDs with v5 around a few billion triples, so with v6 we have double the ID length and still manage to be vastly more space efficient. With the above 4 indices, we can query the data pretty much in any combination without hitting a full scan of any index. We note that all indices that do not begin with s end with s as a bitmap. This takes about 60% of the space of a non-bitmap index for data such as DBpedia. If you intend to do completely arbitrary RDF queries in Virtuoso, then chances are you are best off with the above index scheme.   Virtuoso v5 with gspo, ogps, pogs Virtuoso Cluster v6 with spog, pogs, opgs, gpos warm 0.595 s 0.617 s The cold times were about the same as above, so not reproduced. Graph or No Graph? It is in the SPARQL spirit to specify a graph and for pretty much any application, there are entirely sensible ways of keeping the data in graphs and specifying which ones are concerned by queries. This is why Virtuoso is set up for this by default. On the other hand, for the open web scenario, dealing with an unknown large number of graphs, enumerating graphs is not possible and questions like which graph of which source asserts x become relevant. We have two distinct use cases which warrant different setups of the database, simple as that. The latter use case is not really within the SPARQL spec, so implementations may or may not support this. For example Oracle or Vertica would not do this well since they partition data according to graph or predicate, respectively. On the other hand, stores that work with one quad table, which is most of the ones out there, should do it maybe with some configuring, as shown above. Frameworks like Jena are not to my knowledge geared towards having a wildcard for graph, although I would suppose this can be arranged by adding some &quot;super-graph&quot; object, a graph of all graphs. I don&#39;t think this is directly supported and besides most apps would not need it. Once the indices are right, there is no difference between specifying a graph and not specifying a graph with the queries considered. With more complex queries, specifying a graph or set of graphs does allow some optimizations that cannot be done with no graph specified. For example, bitmap intersections are possible only when all leading key parts are given. Conclusions The best warm cache time is with v5; the five queries run under 600 ms after the first go. This is noted to show that all-in-memory with a single thread of execution is hard to beat. Cluster v6 performs the same queries in 623 ms. What is gained in parallelism is lost in latency if all operations complete in microseconds. On the other hand, Cluster v6 leaves v5 in the dust in any situation that has less than 100% hit rate. This is due to actual benefit from parallelism if operations take longer than a few microseconds, such as in the case of disk reads. Cluster v6 has substantially better data layout on disk, as well as fewer pages to load for the same content. This makes it possible to run the queries without the pogs index on Cluster v6 even when v5 takes prohibitively long. The morale of the story is to have a lot of RAM and space-efficient data representation. The DBpedia benchmark does not specify any random access pattern that would give a measure of sustained throughput under load, so we are left with the extremes of cold and warm cache of which neither is quite realistic. Chris Bizer and I have talked on and off about benchmarks and I have made suggestions that we will see incorporated into the Berlin SPARQL benchmark, which will, I believe, be much more informative. Appendix: Query Text For reference, the query texts specifying the graph are below. To run without specifying the graph, just drop the FROM &lt;http://dbpedia.org&gt; from each query. The returned row counts are indicated below each query&#39;s text. sparql SELECT ?p ?o FROM &lt;http://dbpedia.org&gt; WHERE { &lt;http://dbpedia.org/resource/Metropolitan_Museum_of_Art&gt; ?p ?o }; -- 1337 rows sparql PREFIX p: &lt;http://dbpedia.org/property/&gt; SELECT ?film1 ?actor1 ?film2 ?actor2 FROM &lt;http://dbpedia.org&gt; WHERE { ?film1 p:starring &lt;http://dbpedia.org/resource/Kevin_Bacon&gt; . ?film1 p:starring ?actor1 . ?film2 p:starring ?actor1 . ?film2 p:starring ?actor2 . }; -- 23910 rows sparql PREFIX p: &lt;http://dbpedia.org/property/&gt; SELECT ?artist ?artwork ?museum ?director FROM &lt;http://dbpedia.org&gt; WHERE { ?artwork p:artist ?artist . ?artwork p:museum ?museum . ?museum p:director ?director }; -- 303 rows sparql PREFIX geo: &lt;http://www.w3.org/2003/01/geo/wgs84_pos#&gt; PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/&gt; PREFIX xsd: &lt;http://www.w3.org/2001/XMLSchema#&gt; SELECT ?s ?homepage FROM &lt;http://dbpedia.org&gt; WHERE { &lt;http://dbpedia.org/resource/Berlin&gt; geo:lat ?berlinLat . &lt;http://dbpedia.org/resource/Berlin&gt; geo:long ?berlinLong . ?s geo:lat ?lat . ?s geo:long ?long . ?s foaf:homepage ?homepage . FILTER ( ?lat &lt;= ?berlinLat + 0.03190235436 &amp;&amp; ?long &gt;= ?berlinLong - 0.08679199218 &amp;&amp; ?lat &gt;= ?berlinLat - 0.03190235436 &amp;&amp; ?long &lt;= ?berlinLong + 0.08679199218) }; -- 56 rows sparql PREFIX geo: &lt;http://www.w3.org/2003/01/geo/wgs84_pos#&gt; PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/&gt; PREFIX xsd: &lt;http://www.w3.org/2001/XMLSchema#&gt; PREFIX p: &lt;http://dbpedia.org/property/&gt; SELECT ?s ?a ?homepage FROM &lt;http://dbpedia.org&gt; WHERE { &lt;http://dbpedia.org/resource/New_York_City&gt; geo:lat ?nyLat . &lt;http://dbpedia.org/resource/New_York_City&gt; geo:long ?nyLong . ?s geo:lat ?lat . ?s geo:long ?long . ?s p:architect ?a . ?a foaf:homepage ?homepage . FILTER ( ?lat &lt;= ?nyLat + 0.3190235436 &amp;&amp; ?long &gt;= ?nyLong - 0.8679199218 &amp;&amp; ?lat &gt;= ?nyLat - 0.3190235436 &amp;&amp; ?long &lt;= ?nyLong + 0.8679199218) }; -- 13 rows</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>We ran the <a href="http://dbpedia.org/resource/DBpedia" id="link-id0x1b7f9688">DBpedia</a> benchmark queries again with different
configurations of <a href="http://virtuoso.openlinksw.com" id="link-id0x1cca2e00">Virtuoso</a>. I had not studied the details of the
matter previously but now did have a closer look at the
queries.</p>
<p>Comparing numbers given by different parties is a constant
problem. In the case reported here, we loaded the full DBpedia 3,
all languages, with about 198M triples, onto Virtuoso v5 and Virtuoso Cluster v6,
all on the same 4 core 2GHz Xeon with 8G RAM. All databases were
striped on 6 disks. The Cluster configuration was with 4 processes
in the same box.</p>
<p>We ran the queries in two variants:</p> 
<ul>
<li>With graph
specified in the <a href="http://dbpedia.org/resource/SPARQL" id="link-id0x1b77f758">SPARQL</a> <code>FROM</code> clause, using the default indices.</li>
<li>With no graph specified anywhere, using an
alternate indexing scheme.</li>
</ul>
<p>The times below are for the sequence of 5 queries; individual
query times are not reported. I did not do a line-by-line review of
the execution plans since they seem to run well enough. We could
get some extra mileage from cost model tweaks, especially for the
numeric range conditions, but we will do this when somebody comes up
with better times.</p>
<p>First, about Virtuoso v5: Because there is a query in the set that
specifies no condition on S or O and only P, this simply cannot be
done with the default indices. With Virtuoso Cluster v6 it sort-of can, because v6 is
more space efficient.</p>
<p>So we added the index:</p>
<blockquote>
<code>
create bitmap index <a href="http://dbpedia.org/resource/Resource_Description_Framework" id="link-id0x1cb0b180">rdf</a>_quad_pogs on rdf_quad (p, o, g, s);
</code>
</blockquote>

<table>
 <tr>
  <td> </td>
  <td align="center"><b>Virtuoso v5 with<br /> gspo, ogps, pogs</b>
  </td>
  <td align="center"><b>Virtuoso Cluster v6 with <br />gspo, ogps</b>
  </td>
  <td align="center"><b>Virtuoso Cluster v6 with <br />gspo, ogps, pogs</b>
  </td>
 </tr>
<tr>
  <td><b>cold</b>
  </td>
  <td align="center">210 s</td>
  <td align="center">136 s</td>
  <td align="center">33.4 s</td>
</tr>
<tr>
  <td><b>warm</b>
  </td>
  <td align="center">0.600 s</td>
  <td align="center">4.01 s</td>
  <td align="center">0.628 s</td>
</tr>
</table>

<p>OK, so now let us do it without a graph being specified. For
all platforms, we drop any existing indices, and --</p>
<blockquote>
<code>
create table r2 (g iri_id_8, s, iri_id_8, p iri_id_8, o any, primary key (s, p, o, g)) <br />
alter index R2 on R2 partition (s int (0hexffff00)); <br />
 <br />
log_enable (2); <br />
insert into r2 (g, s, p, o) select g, s, p, o from rdf_quad; <br />
 <br />
drop table rdf_quad; <br />
alter table r2 rename RDF_QUAD; <br />
create bitmap index rdf_quad_opgs on rdf_quad (o, p, g, s) partition (o varchar (-1, 0hexffff)); <br />
create bitmap index rdf_quad_pogs on rdf_quad (p, o, g, s) partition (o varchar (-1, 0hexffff)); <br />
create bitmap index rdf_quad_gpos on rdf_quad (g, p, o, s) partition (o varchar (-1, 0hexffff));
</code>
</blockquote>
<p>The code is identical for v5 and v6, except that with v5 we use
<code>iri_id (32 bit)</code> for the type, not <code>iri_id_8 (64 bit)</code>. We note that
we run out of IDs with v5 around a few billion triples, so with v6
we have double the ID length and still manage to be vastly more
space efficient.</p>
<p>With the above 4 indices, we can query the <a href="http://dbpedia.org/resource/Data" id="link-id0x6339b80">data</a> pretty much in
any combination without hitting a full scan of any index. We note
that all indices that do not begin with s end with s as a bitmap.
This takes about 60% of the space of a non-bitmap index for data such
as DBpedia.</p>
<p>If you intend to do completely arbitrary RDF queries in
Virtuoso, then chances are you are best off with the above index
scheme.</p>

<table>
 <tr>
  <td> </td>
  <td align="center"><b> Virtuoso v5 with<br /> gspo, ogps, pogs</b>
  </td>
  <td align="center"><b> Virtuoso Cluster v6 with <br /> spog, pogs, opgs, gpos </b>
  </td>
 </tr>
<tr>
  <td><b>warm</b>
  </td>
  <td align="center">0.595 s</td>
  <td align="center">0.617 s</td>
</tr>
</table>

<p>The cold times were about the same as above, so not
reproduced.</p>
<h3>Graph or No Graph?</h3>
<p>It is in the SPARQL spirit to specify a graph and for pretty
much any application, there are entirely sensible ways of keeping
the data in graphs and specifying which ones are concerned by
queries. This is why Virtuoso is set up for this by default.</p>
<p>On the other hand, for the open web scenario, dealing with an
unknown large number of graphs, enumerating graphs is not possible
and questions like which graph of which source asserts x become
relevant. We have two distinct use cases which warrant different
setups of the database, simple as that.</p>
<p>The latter use case is not really within the SPARQL spec, so
implementations may or may not support this. For example <a href="http://dbpedia.org/resource/Oracle_Database" id="link-id0x11ed7028">Oracle</a> or
Vertica would not do this well since they partition data according
to graph or predicate, respectively. On the other hand, stores that
work with one quad table, which is most of the ones out there,
should do it maybe with some configuring, as shown above.</p>
<p>Frameworks like Jena are not to my <a href="http://dbpedia.org/resource/Knowledge" id="link-id0x1a49ded0">knowledge</a> geared towards
having a wildcard for graph, although I would suppose this can be
arranged by adding some &quot;super-graph&quot; object, a graph of all
graphs. I don&#39;t think this is directly supported and besides most
apps would not need it.</p>
<p>Once the indices are right, there is no difference between
specifying a graph and not specifying a graph with the queries considered. With
more complex queries, specifying a graph or set of graphs does
allow some optimizations that cannot be done with no graph specified.
For example, bitmap intersections are possible only when all
leading key parts are given.</p>
<h3>Conclusions</h3>
<p>The best warm cache time is with v5; the five queries run under
600 ms after the first go. This is noted to show that all-in-memory with
a single thread of execution is hard to beat.</p>
<p>Cluster v6 performs the same queries in 623 ms. What is gained in
parallelism is lost in latency if all operations complete in
microseconds. On the other hand, Cluster v6 leaves v5 in the dust in
any situation that has less than 100% hit rate. This is due to
actual benefit from parallelism if operations take longer than a
few microseconds, such as in the case of disk reads. Cluster v6 has
substantially better data layout on disk, as well as fewer pages to
load for the same content.</p>
<p>This makes it possible to run the queries without the pogs
index on Cluster v6 even when v5 takes prohibitively long.</p>
<p>The morale of the story is to have a lot of RAM and space-efficient data representation.</p>
<p>The DBpedia benchmark does not specify any random access
pattern that would give a measure of sustained throughput under
load, so we are left with the extremes of cold and warm cache of
which neither is quite realistic.</p>
<p>Chris Bizer and I have talked on and off about benchmarks and
I have made suggestions that we will see incorporated into the
Berlin SPARQL benchmark, which will, I believe, be much more
informative.</p>
<h3>Appendix: Query Text</h3>
<p>For reference, the query texts specifying the graph are below. To
run without specifying the graph, just drop the <code>FROM
&lt;<a href="http://dbpedia.org/resource/Hypertext_Transfer_Protocol" id="link-id0x1905bfd0">http</a>://dbpedia.org&gt;</code> from each query. The returned row counts are indicated
below each query&#39;s text.</p>
<blockquote>
 <code><pre>
sparql SELECT ?p ?o FROM &lt;http://dbpedia.org&gt; WHERE {
  &lt;http://dbpedia.org/resource/Metropolitan_Museum_of_Art&gt; ?p ?o };

-- 1337 rows

sparql PREFIX p: &lt;http://dbpedia.org/property/&gt;
SELECT ?film1 ?actor1 ?film2 ?actor2
FROM &lt;http://dbpedia.org&gt; WHERE {
  ?film1 p:starring &lt;http://dbpedia.org/resource/Kevin_Bacon&gt; .
  ?film1 p:starring ?actor1 .
  ?film2 p:starring ?actor1 .
  ?film2 p:starring ?actor2 . };

--  23910 rows

sparql PREFIX p: &lt;http://dbpedia.org/property/&gt;
SELECT ?artist ?artwork ?museum ?director FROM &lt;http://dbpedia.org&gt; 
WHERE {
  ?artwork p:artist ?artist .
  ?artwork p:museum ?museum .
  ?museum p:director ?director };

-- 303 rows

sparql PREFIX geo: &lt;http://www.w3.org/2003/01/geo/wgs84_pos#&gt;
PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/&gt;
PREFIX xsd: &lt;http://www.w3.org/2001/XMLSchema#&gt;
SELECT ?s ?homepage FROM &lt;http://dbpedia.org&gt;  WHERE {
   &lt;http://dbpedia.org/resource/Berlin&gt; geo:lat ?berlinLat .
   &lt;http://dbpedia.org/resource/Berlin&gt; geo:long ?berlinLong . 
   ?s geo:lat ?lat .
   ?s geo:long ?long .
   ?s foaf:homepage ?homepage .
   FILTER (
     ?lat        &lt;=     ?berlinLat + 0.03190235436 &amp;&amp;
     ?long       &gt;=     ?berlinLong - 0.08679199218 &amp;&amp;
     ?lat        &gt;=     ?berlinLat - 0.03190235436 &amp;&amp; 
     ?long       &lt;=     ?berlinLong + 0.08679199218) };

-- 56 rows

sparql PREFIX geo: &lt;http://www.w3.org/2003/01/geo/wgs84_pos#&gt;
PREFIX foaf: &lt;http://xmlns.com/foaf/0.1/&gt;
PREFIX xsd: &lt;http://www.w3.org/2001/XMLSchema#&gt;
PREFIX p: &lt;http://dbpedia.org/property/&gt;
SELECT ?s ?a ?homepage FROM &lt;http://dbpedia.org&gt;  WHERE {
   &lt;http://dbpedia.org/resource/New_York_City&gt; geo:lat ?nyLat .
   &lt;http://dbpedia.org/resource/New_York_City&gt; geo:long ?nyLong . 
   ?s geo:lat ?lat .
   ?s geo:long ?long .
   ?s p:architect ?a .
   ?a foaf:homepage ?homepage .
   FILTER (
     ?lat        &lt;=     ?nyLat + 0.3190235436 &amp;&amp;
     ?long       &gt;=     ?nyLong - 0.8679199218 &amp;&amp;
     ?lat        &gt;=     ?nyLat - 0.3190235436 &amp;&amp; 
     ?long       &lt;=     ?nyLong + 0.8679199218) };

-- 13 rows
</pre>
 </code>
</blockquote>
]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1353">
  <rss:title>SPARQL at WWW 2008</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1353</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1353</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1353</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-30T15:59:15Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">Andy Seaborne and Eric Prud&#39;hommeaux, editors of the SPARQL recommendation, convened a SPARQL birds of a feather session at WWW 2008. The administrative outcome was that implementors could now experiement with extensions, hopefully keeping each other current about their efforts and that towards the end of 2008, a new W3C working group might begin formalizing the experiences into a new SPARQL spec. The session drew a good crowd, including many users and developers. The wishes were largely as expected, with a few new ones added. Many of the wishes already had diverse implementations, however most often without interop. I will below give some comments on the main issues discussed. - SPARQL Update - This is likely the most universally agreed upon extension. Implementations exist, largely along the lines of Andy Seaborne&#39;s SPARUL spec, which is also likely material for a W3C member submission. The issue is without much controverse, transactions fall outside the scope, which is reasonable enough. With triple stores, we can define things as combinations of inserts and deletes and isolation we just leave aside. If anything, operating on a transactional platform such as Virtuoso, one wishes to disable transactions for any operations such as bulk loads and long running inserts and deletes. Transactionality has pretty much no overhead for a few hundred rows but for a few hundred million rows the cost of locking and rollback is prohibitive. With Virtuoso, we have a row autocommit mode which we recommend for use with RDF: It commits by itself now and then, optionally keeping a roll forward log and is transactional enough not to leave half triples around,i.e. inserted in one index but not another. As far as we are concerned, updating physical triples along the SPARUL lines is pretty much a done deal. The matter of updating relational data mapped to RDF is a whole other kettle of fish. On this, I should say that RDF has no special virtues for expressing transactions but rather has a special genius for integration. Updating is best left to web service interfaces that use SQL on the inside. Anyway, updating union views, which most mappings will be, is complicated. Besides, for transactions, one usually knows exactly what one wishes to update. Full Text - Many people expressed a desire for full text access. Here we run into a deplorable confusion with regexps. The closest SPARQL has to full text in its native form is regexps, but these are not really mappable to full text except in rare special cases and I would despair of explaining to an end user what exactly these cases are. So, in principle, some regexps are equivalent to full text but in practice I find it much preferrable to keep these entirely separate. It was noted that what the users want is a text box for search words. This is a front end to the CONTAINS predicate of most SQL implementations. Ours is MS SQL Server compatible and has a SPARQL version called bif:contains. One must still declare which triples one wants indexed for full text, though. This admin overhead seems inevitable, as text indexing is a large overhead and not needed by all applications. Also, text hits are not boolean, usually they come with a hit score. Thus, aa SPARQL extension for this could look like select * where { ?thing has_description ?d . ?d ftcontains &quot;gizmo&quot; ftand &quot;widget&quot; score ?score . } This would return all the subjects, descriptions and scores from subjects with a has_description property containing widget and gizmo. Extending the basic pattern is better than having the match in a filter, since the match binds a variable. The XQuery/XPATH groups have recently come up with a full text spec, so I used their style of syntax above. We already have a full text extension, as do some others. but for standardization, it is probably most appropriate to take the XQuery work as a basis. The XQuery full text spec is quite complex but I would expect most uses to get by with a small subset and the structure seems better thought out, at first glance, than the more ad hoc implementations in diverse SQL&#39;s. Again, declaring any text index to support the search, as well as its timeliness or transactionality, are best left to implementations. Federation - This is a tricky matter. ARQ has a SPARQL extension for sending a nested set of triple patterns to a specific end point. The DARQ project has something more, including a selectivity model for SPARQL. With federated SQL, life is simpler since after the views are expanded, we have a query where each table is at a known server and has more or less known statistics. Generally, execution plans where as much work as possible is pushed to the remote servers are preferred and modeling the latencies is not overly hard. With SPARQL, each triple pattern could in principle come from any of the federated servers. Associating a specific end point to a fragment of the query just passes the problem to the user. It is my guess that this is the best we can do without getting very elaborate, and possibly buggy, end point content descriptions for routing federated queries. Having said this, there remains the problem of join order. I suggested that we enhance the protocol by allowing asking an end point for the query cost for a given SPARQL query. Since they all must have a cost model for optimization, this should not be an imposssible request. A time cost and estimated cardinality would be enough. Making statistics available a la DARQ was also discussed. Being able to declare cardinalities expected of a remote end point is probably necessary anyway, since not all will implement the cost model interface. For standardization, agreeing of what is a proper description of content and cardinality and how fine grained this must be will be so difficult that I would not wait for it. A cost model interface would nicely hide this within the end point itself. With Virtuoso, we do not have a federated SPARQL scheme but we could have the ARQ-like service construct. We&#39;d use our own cost model with explicit declarations of cardinalities of the remote data for guessing a join order. Still, this is a bit of work. We&#39;ll see. For practicality, the service construct coupled with join order hints is the best short term bet. Making this pretty enough for standardization is not self-evident, as it requires end point description and/or cost model hooks for things to stay declarative. - End point description - This question has been around for a while, I have blogged about it earlier but we are not really at a point where there would be even rough consensus about an end point ontology. We should probably do something on our own to demonstrate some application of this, as we host lots of linked open data sets. - SQL equivalence - There were many requests for aggregation, some for subqueries and nesting, expressions in select, negation, existence and so on. I would call these all SQL equivalence. One use case was taking all the teams in the database and for all with over 5 members, add the big_team class and a property for member count. With Virtuoso, we could write this as construct { ?team a big_team . ?team member_count ?ct } from ... where {?team a team . { select ?team2 count (*) as ?ct where { ?m member_of ?team2 } . filter (?team = ?team2 and ? ct &gt; 5) }} We have pretty much all the SQL equivalence features, as we have been working for some time at translating the TPC H workload into SPARQL. The usefulness of these things is uncontested but standardization could be hard as there are subtle questions about variable scope and the like. - Inference - The SPARQLL spec does not deal with transitivity or such matters because it is assumed that these are handled by an underlying inference layer. This is however most often not so. There was interest in more fine grained control of inference, for example declaring that just one property in a query would be transitive or that subclasses should be taken into account in only one triple pattern. As far as I am concerned, this is very reasonable and we even offer extensions for this sort of thing in Virtuoso&#39;s SPARQL. This however only makes sense if the inference is done at query time and pattern by pattern. For instance, if forward chaining is used, this no longer makes sense. Specifying that some forward chaining ought to be done at query time is impractical, as the operation can be very large and time consuming and it is the dba&#39;s task to determine what should be stored and for how long, how changes should be propagated and so on. All these are application dependent and standardizing will be difficult. Support for RDF features like lists and bags would all fall under the functions an underlying inference layer should perform. These thiings are of special interest when querying OWL models, for example. Path expressions - Path expressions were requested by a few people. We have implemented some, as in ?product+?has_supplier+&gt;s_name = &quot;Gizmos, Inc.&quot;. This means that one supplier of product has name &quot;Gizmo, Inc.&quot;. This is a nice shorthand but we run into problems if we start supporting repetitive steps, optional steps and the like. In conclusion, update, full text and basic counting and grouping would seem straightforward at this point. Nesting queries, value subqueries, views and the like should not be too hard if an agreement is reached on scope rules. Inference and federation will probably need more experimentation but a lot can be had already with very simple fine grained control of backward chaining, if such applies or with explicit end point refernces and explicit join order. These are practical butr not pretty enough for committee consensus, would be my guess. Anyway, it will be a few months before anything formal will happen.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<div>
<div>
Andy Seaborne and Eric Prud&#39;hommeaux, editors of the <a href="http://dbpedia.org/resource/SPARQL" id="link-id10830dd8">SPARQL</a>
recommendation, convened a <a href="http://dbpedia.org/resource/SPARQL" id="link-id0xa3028e8">SPARQL</a> birds of a feather session at <a href="http://www2008.org/" id="link-id16b82f18">WWW
2008</a>.  The administrative outcome was that implementors could now
experiement with extensions, hopefully keeping each other current
about their efforts and that towards the end of 2008, a new W3C
working group might begin formalizing the experiences into a new
SPARQL spec.
</div>

<div>
The session drew a good crowd, including many users and developers.
The wishes were largely as expected, with a few new ones added.  Many
of the wishes already had diverse implementations, however most often
without interop.  I will below give some comments on the main issues discussed.
</div>

<div>
- SPARQL Update - This is likely the most universally agreed upon
  extension.  Implementations exist, largely along the lines of Andy
  Seaborne&#39;s SPARUL spec, which is also likely material for a W3C
  member submission.  The issue is without much controverse,
  transactions fall outside the scope, which is reasonable enough.
  With triple stores, we can define things as combinations of inserts
  and deletes and isolation we just leave aside.  If anything,
  operating on a transactional platform such as <a href="http://virtuoso.openlinksw.com" id="link-id103979f0">Virtuoso</a>, one wishes
  to disable transactions for any operations such as bulk loads and
  long running inserts and deletes.  Transactionality has pretty much
  no overhead for a few hundred rows but for a few hundred million
  rows the cost of locking and rollback is prohibitive.  With
  <a href="http://virtuoso.openlinksw.com" id="link-id0x15b9ff70">Virtuoso</a>, we have a row autocommit mode which we recommend for use
  with <a href="http://dbpedia.org/resource/Resource_Description_Framework" id="link-id109a9d50">RDF</a>: It commits by itself now and then, optionally keeping a roll forward log and  is transactional
  enough not to leave half triples around,i.e.  inserted in one index
  but not another.
</div>

<div>
As far as we are concerned, updating physical  triples along the SPARUL lines is pretty much a done deal.
</div>

<div>
The matter of updating relational <a href="http://dbpedia.org/resource/Data" id="link-id106f05e0">data</a> mapped to <a href="http://dbpedia.org/resource/Resource_Description_Framework" id="link-id0xa00f0a70">RDF</a> is a whole other
kettle of fish. On this, I should say that RDF has no special virtues
for expressing transactions but rather has a special genius for
integration.  Updating is best left to web service interfaces that use
<a href="http://dbpedia.org/resource/SQL" id="link-id10aab0a8">SQL</a> on the inside.  Anyway, updating union views, which most mappings will be, is complicated.  Besides, for transactions, one usually knows exactly what one wishes to update.
</div>

<div>
Full Text - Many people expressed a desire for full text access.  Here
we run into a deplorable confusion with regexps.  The closest SPARQL
has to full text in its native form is regexps, but these are not
really mappable to full text except in rare special cases and I would
despair of explaining to an end user what exactly these cases are.
So, in principle, some regexps are equivalent to full text but in practice I find it much preferrable to keep these entirely separate.
</div>

<div>
It was noted that what the users want is a text box for search words.
This is a front end to the CONTAINS predicate of most <a href="http://dbpedia.org/resource/SQL" id="link-id0x14d45478">SQL</a>
implementations.  Ours is MS SQL Server compatible and has a SPARQL
version called bif:contains.  One must still declare which triples one
wants indexed for full text, though.  This admin overhead seems
inevitable, as text indexing is a large overhead and not needed by all
applications.
</div>

<div>
Also, text hits are not boolean, usually they come with a hit score.  Thus, aa SPARQL extension for this could look like 
select * where { ?thing has_description ?d . ?d ftcontains &quot;gizmo&quot; ftand &quot;widget&quot; score ?score . }
</div>

<div>
This would return all the subjects, descriptions and scores  from subjects  with a has_description property containing widget and gizmo. Extending the basic pattern is better than having the match in a filter, since the match binds a variable.
</div>

<div>
The <a href="http://dbpedia.org/resource/XQuery" id="link-id106517a0">XQuery</a>/<a href="http://dbpedia.org/resource/XPath" id="link-id10d04ae0">XPATH</a> groups have recently come up with a full text spec,
so I used their style of syntax above.  We already have a full text
extension, as do some others. but for standardization, it is probably
most appropriate to take the <a href="http://dbpedia.org/resource/XQuery" id="link-id0xa27b3a98">XQuery</a> work as a basis.  The XQuery full
text spec is quite complex but I would expect most uses to get by with
a small subset and the structure seems better thought out, at first
glance, than the more ad hoc implementations in diverse SQL&#39;s.
</div>

<div>
Again, declaring any text index to support the search, as well as its timeliness or transactionality, are best left to implementations.
</div>

<div>
Federation - This is a tricky matter.  ARQ has a SPARQL extension for
sending a nested set of triple patterns to a specific end point.  The
DARQ project has something more, including a selectivity model for
SPARQL.
</div>

<div>
With federated SQL, life is simpler since after the views are
expanded, we have a query where each table is at a known server and
has more or less known statistics. Generally, execution plans where as
much work as possible is pushed to the remote servers are preferred
and modeling the latencies is not overly hard.  With SPARQL, each
triple pattern could in principle come from any of the federated
servers.  Associating a specific end point to a fragment of the query
just passes the problem to the user.  It is my guess that this is the
best we can do without getting very elaborate, and possibly buggy, end
point content descriptions for routing federated queries.
</div>

<div>
Having said this, there remains the problem of join order.  I
suggested that we enhance the protocol by allowing asking an end point
for the query cost for a given SPARQL query.  Since they all must have
a cost model for optimization, this should not be an imposssible
request.  A time cost and estimated cardinality would be enough.
Making statistics available a la DARQ was also discussed.  Being able
to declare cardinalities expected of a remote end point is probably
necessary anyway, since not all will implement the cost model
interface.  For standardization, agreeing of what is a proper
description of content and cardinality and how fine grained this
must be will be so difficult that I would not wait for it.  A cost model interface would nicely hide this within the end point itself.
</div>

<div>
With Virtuoso, we do not have a federated SPARQL scheme but we could
 have the ARQ-like service construct.  We&#39;d use our own
cost model with explicit declarations of cardinalities of the remote
<a href="http://dbpedia.org/resource/Data" id="link-id0xa496840">data</a> for guessing a join order.  Still, this is a bit of work.  We&#39;ll see.  
</div>

<div>
For practicality, the service construct coupled with join order hints is the best short term bet.  Making this pretty enough for standardization is not self-evident, as it requires end point description and/or cost model hooks  for things to stay declarative.
</div>

<div>
- End point description - This question has been around for a while, I
  have blogged about it earlier but we are not really at a point where
  there would be even rough consensus about an end point ontology.  We
  should probably do something on our own to demonstrate some
  application of this, as we host lots of <a href="http://community.linkeddata.org/dataspace/organization/lod#this" id="link-id10cdd138">linked open data</a> sets.
</div>

<div>
- SQL equivalence - There were many requests for aggregation, some for
  subqueries and nesting, expressions in select, negation, existence
  and so on.  I would call these all SQL equivalence.  One use case
  was taking all the teams in the database and for all with over 5
  members, add the big_team class and a property for member count.
</div>

<div>
With Virtuoso, we could write this as 
</div>

<pre>
construct { ?team a big_team . ?team member_count ?ct } from ... where {?team a team . { select ?team2 count (*) as ?ct where { ?m member_of ?team2 } . filter (?team = ?team2 and ? ct &gt; 5) }}
</pre>

<div>
We have pretty much all the SQL equivalence features, as we have been working for some time at translating the <a href="http://dbpedia.org/resource/TPC-H" id="link-id13a7ad70">TPC H</a> workload into SPARQL. 
</div>

<div>
The usefulness of these things is uncontested but standardization could be hard as there are subtle questions about variable scope and the like.
</div>


<div>
- Inference - The SPARQLL spec does not deal with transitivity or such
  matters because it is assumed that these are handled by an
  underlying inference layer.  This is however most often not so.
  There was  interest in more fine grained control of
  inference, for example declaring that just one property in a query
  would be transitive or that subclasses should be taken into account
  in only one triple pattern.  As far as I am concerned, this is very
  reasonable and we even offer extensions for this sort of thing in
  Virtuoso&#39;s SPARQL.  This however only makes sense if the inference
  is done at query time and pattern by pattern.  For instance, if
  forward chaining is used, this no longer makes sense.  Specifying
  that some forward chaining ought to be done at query time is
  impractical, as the operation can be very large and time consuming
  and it is the dba&#39;s task to determine what should be stored and for
  how long, how changes should be propagated and so on.  All these are application dependent and standardizing will be difficult.
</div>

<div>
Support for RDF features like lists and bags would all fall under the functions an underlying inference layer should perform.  These thiings are of special interest when querying OWL models, for example.
</div>


<div>
Path expressions - Path expressions were requested by a few people.
We have implemented some, as in ?product+?has_supplier+&gt;s_name =
&quot;Gizmos, Inc.&quot;.  This means that one supplier of product has name
&quot;Gizmo, Inc.&quot;.  This is a nice shorthand but we run into problems if
we start supporting repetitive steps, optional steps and the like.
</div>

<div>
In conclusion, update, full text and basic counting and grouping would
seem straightforward at this point.  Nesting queries, value
subqueries, views and the like should not be too hard if an agreement
is reached on scope rules.  Inference and federation will probably
need more experimentation but a lot can be had already with very
simple fine grained control of backward chaining, if such applies or
with explicit end point refernces and explicit join order.  These are
practical butr not pretty enough for committee consensus, would be my
guess.  Anyway, it will be a few months before anything formal will
happen.
</div>

</div>
]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1347">
  <rss:title>Linked Data and Information Architecture</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1347</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1347</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1347</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-29T12:08:24Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">We had a workshop on Linked Open Data (LOD) last week in Beijing. You can see the papers in the program. The event was a success with plenty of good talks and animated conversation. I will not go into every paper here but will comment a little on the conversation and draw some technology requirements going forward. Tim Berners-Lee showed a read-write version of Tabulator. This raises the question of updating on the Data Web. The consensus was that one could assert what one wanted in one&#39;s own space but that others&#39; spaces would be read-only. What spaces one considered relevant would be the user&#39;s or developer&#39;s business, as in the document web. It seems to me that a significant use case of LOD is an open-web situation where the user picks a broad read-only &quot;data wallpaper&quot; or backdrop of assertions, and then uses this combined with a much smaller, local, writable data set. This is certainly the case when editing data for publishing, as in Tim&#39;s demo. This will also be the case when developing mesh-ups combining multiple distinct data sets bound together by sets of SameAs assertions, for example. Questions like, &quot;What is the minimum subset of n data sets needed for deriving the result?&quot; will be common. This will also be the case in applications using proprietary data combined with open data. This means that databases will have to deal with queries that specify large lists of included graphs, all graphs in the store or all graphs with an exclusion list. All this is quite possible but again should be considered when architecting systems for an open linked data web. &quot;There is data but what can we really do with it? How far can we trust it, and what can we confidently decide based on it?&quot; As an answer to this question, Zitgist has compiled the UMBEL taxonomy using SKOS. This draws on Wikipedia, Open CYC, Wordnet, and YAGO, hence the acronym WOWY. UMBEL is both a taxononmy and a set of instance data, containing a large set of named entities, including persons, organizations, geopolitical entities, and so forth. By extracting references to this set of named entities from documents and correlating this to the taxonomy, one gets a good idea of what a document (or part thereof) is about. Kingsley presented this in the Zitgist demo. This is our answer to the criticism about DBpedia having errors in classification. DBpedia, as a bootstrap stage, is about giving names to all things. Subsequent efforts like UMBEL are about refining the relationships. &quot;Should there be a global URI dictionary?&quot; There was a talk by Paolo Bouquet about Entity Name System, a a sort of data DNS, with the purpose of associating some description and rough classification to URIs. This would allow discovering URIs for reuse. I&#39;d say that this is good if it can cut down on the SameAs proliferation and if this can be widely distributed and replicated for resilience, à la DNS. On the other hand, it was pointed out that this was not quite in the LOD spirit, where parties would mint their own dereferenceable URIs, in their own domains. We&#39;ll see. &quot;What to do when identity expires?&quot; Giovanni of Sindice said that a document should be removed from search if it was no longer available. Kingsley pointed out that resilience of reference requires some way to recover data. The data web cannot be less resilient than the document web, and there is a point to having access to history. He recommended hooking up with the Internet Archive, since they make long term persistence their business. In this way, if an application depends on data, and the URIs on which it depends are no longer dereferenceable or or provide content from a new owner of the domain, those who need the old version can still get it and host it themselves. It is increasingly clear that OWL SameAs is both the blessing and bane of linked data. We can easily have tens of URIs for the same thing, especially with people. Still, these should be considered the same. Returning every synonym in a query answer hardly makes sense but accepting them as input seems almost necessary. This is what we do with Virtuoso&#39;s SameAs support. Even so, this can easily double query times even when there are no synonyms. Be that as it may, SameAs is here to stay; just consider the mapping of DBpedia to Geonames, for example. Also, making aberrant SameAs statements can completely poison a data set and lead to absurd query results. Hence choosing which SameAs assertions from which source will be considered seems necessary. In an open web scenario, this leads inevitably to multi-graph queries that can be complex to write with regular SPARQL. By extension, it seems that a good query would also include the graphs actually used for deriving each result row. This is of course possible but has some implications on how databases should be organized. Yves Raymond gave a talk about deriving identity between Musicbrainz and Jamendo. I see the issue as a core question of linked data in general. The algorithm Yves presented started with attribute value similarities and then followed related entities. Artists would be the same if they had similar names and similar names of albums with similar song titles, for example. We can find the same basic question in any analysis, for example, looking at how news reporting differs between media, supposing there is adequate entity extraction. There is basic graph diffing in RDFSync, for example. But here we are expanding the context significantly. We will traverse references to some depth, allow similarity matches, SameAs, and so forth. Having presumed identity of two URIs, we can then look at the difference in their environment to produce a human readable summary. This could then be evaluated for purposes of analysis or of combining content. At first sight, these algorithms seem well parallelizable, as long as all threads have access to all data. For scaling, this means a probably message-bound distributed algorithm. This is something to look into for the next stage of linked data. Some inference is needed, but if everybody has their own choice of data sets to query, then everybody would also have their own entailed triples. This will make for an explosion of entailed graphs if forward chaining is used. Forward chaining is very nice because it keeps queries simple and easy to optimize. With Virtuoso, we still favor backward chaining since we expect a great diversity of graph combinations and near infinite volume in the open web scenario. With private repositories of slowly changing data put together for a special application, the situation is different. In conclusion, we have a real LOD movement with actual momentum and a good idea of what to do next. The next step is promoting this to the broader community, starting with Linked Data Planet in New York in June.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>We had a workshop on <a href="http://community.linkeddata.org/dataspace/organization/lod#this" id="link-id0x9e7e5098">Linked Open Data</a> (<a href="http://community.linkeddata.org/dataspace/organization/lod#this" id="link-id0xb9e86c8">LOD</a>) last week in <a href="http://www2008.org/" id="link-id0x131a72a0">Beijing</a>. You can see the papers in <a href="http://events.linkeddata.org/ldow2008/#program" id="link-id10651ab8">the program</a>. The event was a success with plenty of good talks and animated conversation. I will not go into every paper here but will comment a little on the conversation and draw some technology requirements going forward.</p>
<p>Tim Berners-Lee showed a read-write version of <a href="http://dig.csail.mit.edu/2005/ajar/release/tabulator/0.8/tab.html" id="link-id0x9da015a0">Tabulator</a>. This raises the question of updating on the <a href="http://dbpedia.org/resource/Data" id="link-id0x14813578">Data</a> Web. The consensus was that one could assert what one wanted in one&#39;s own space but that others&#39; spaces would be read-only. What spaces one considered relevant would be the user&#39;s or developer&#39;s business, as in the document web.</p>
<p>It seems to me that a significant use case of LOD is an open-web situation where the user picks a broad read-only &quot;data wallpaper&quot; or backdrop of assertions, and then uses this combined with a much smaller, local, writable data set. This is certainly the case when editing data for publishing, as in Tim&#39;s demo. This will also be the case when developing mesh-ups combining multiple distinct data sets bound together by sets of SameAs assertions, for example. Questions like, &quot;What is the minimum subset of n data sets needed for deriving the result?&quot; will be common. This will also be the case in applications using proprietary data combined with open data.</p>
<p>This means that databases will have to deal with queries that specify large lists of included graphs, all graphs in the store or all graphs with an exclusion list. All this is quite possible but again should be considered when architecting systems for an open <a href="http://dbpedia.org/resource/Linked_Data" id="link-id0x9f1a1d8">linked data</a> <a href="http://dbpedia.org/resource/Giant_Global_Graph" id="link-id0xa5a3e1b0">web</a>.</p>
<p>&quot;There is data but what can we really do with it? How far can we trust it, and what can we confidently decide based on it?&quot;</p>
<p>As an answer to this question, <a href="http://zitgist.com/about/" id="link-id0xad44dc0">Zitgist</a> has compiled the <a href="http://umbel.org/about/" id="link-id0x9ebde358">UMBEL</a> taxonomy using <a href="http://dbpedia.org/resource/SKOS" id="link-id0xa04a85c0">SKOS</a>. This draws on Wikipedia, Open CYC, Wordnet, and <a href="http://www.mpi-inf.mpg.de/~suchanek/downloads/yago/" id="link-id0x9fdd9018">YAGO</a>, hence the acronym WOWY. UMBEL is both a taxononmy and a set of instance data, containing a large set of <a href="http://dbpedia.org/resource/Named_entity_recognition" id="link-id0xa0b9cb70">named entities</a>, including persons, organizations, geopolitical entities, and so forth. By extracting references to this set of named entities from documents and correlating this to the taxonomy, one gets a good idea of what a document (or part thereof) is about.</p>
<p>Kingsley presented this in the Zitgist demo. This is our answer to the criticism about <a href="http://dbpedia.org/resource/DBpedia" id="link-id0xdc5d940">DBpedia</a> having errors in classification. DBpedia, as a bootstrap stage, is about giving names to all things. Subsequent efforts like UMBEL are about refining the relationships.</p>
<p>&quot;Should there be a global <a href="http://dbpedia.org/resource/Uniform_Resource_Identifier" id="link-id0xa0aa2cc0">URI</a> dictionary?&quot;</p>
<p>There was a talk by Paolo Bouquet about <a href="http://dbpedia.org/resource/Entity" id="link-id0x9e6f4b28">Entity</a> Name System, a a sort of data DNS, with the purpose of associating some description and rough classification to URIs. This would allow discovering URIs for reuse. I&#39;d say that this is good if it can cut down on the SameAs proliferation and if this can be widely distributed and replicated for resilience, <i>à la</i> DNS. On the other hand, it was pointed out that this was not quite in the LOD spirit, where parties would mint their own dereferenceable URIs, in their own domains. We&#39;ll see.</p>
<p>&quot;What to do when identity expires?&quot;</p>
<p>Giovanni of Sindice said that a document should be removed from search if it was no longer available. Kingsley pointed out that resilience of reference requires some way to recover data. The data web cannot be less resilient than the document web, and there is a point to having access to history. He recommended hooking up with the <a href="http://dbpedia.org/resource/Internet" id="link-id0xcc203f8">Internet</a> Archive, since they make long term persistence their business. In this way, if an application depends on data, and the URIs on which it depends are no longer dereferenceable or or provide content from a new owner of the domain, those who need the old version can still get it and host it themselves.</p>
<p>It is increasingly clear that OWL SameAs is both the blessing and bane of linked data. We can easily have tens of URIs for the same thing, especially with people. Still, these should be considered the same.</p>
<p>Returning every synonym in a query answer hardly makes sense but accepting them as input seems almost necessary. This is what we do with <a href="http://virtuoso.openlinksw.com" id="link-id0xa0d28c98">Virtuoso</a>&#39;s SameAs support. Even so, this can easily double query times even when there are no synonyms.</p>
<p>Be that as it may, SameAs is here to stay; just consider the mapping of DBpedia to Geonames, for example.</p>
<p>Also, making aberrant SameAs statements can completely poison a data set and lead to absurd query results. Hence choosing which SameAs assertions from which source will be considered seems necessary. In an open web scenario, this leads inevitably to multi-graph queries that can be complex to write with regular <a href="http://dbpedia.org/resource/SPARQL" id="link-id0xc89a768">SPARQL</a>. By extension, it seems that a good query would also include the graphs actually used for deriving each result row. This is of course possible but has some implications on how databases should be organized.</p>
<p>Yves Raymond gave a talk about deriving identity between Musicbrainz and Jamendo. I see the issue as a core question of linked data in general. The algorithm Yves presented started with attribute value similarities and then followed related entities. Artists would be the same if they had similar names and similar names of albums with similar song titles, for example. We can find the same basic question in any analysis, for example, looking at how news reporting differs between media, supposing there is adequate entity extraction.</p>
<p>There is basic graph diffing in <a href="http://data.semanticweb.org/conference/iswc-aswc/2007/tracks/research/papers/533/html" id="link-id0x9fe62620">RDFSync</a>, for example. But here we are expanding the context significantly. We will traverse references to some depth, allow similarity matches, SameAs, and so forth. Having presumed identity of two URIs, we can then look at the difference in their environment to produce a human readable summary. This could then be evaluated for purposes of analysis or of combining content.</p>
<p>At first sight, these algorithms seem well parallelizable, as long as all threads have access to all data. For scaling, this means a probably message-bound distributed algorithm. This is something to look into for the next stage of linked data.</p>
<p>Some inference is needed, but if everybody has their own choice of data sets to query, then everybody would also have their own entailed triples. This will make for an explosion of entailed graphs if forward chaining is used. Forward chaining is very nice because it keeps queries simple and easy to optimize. With Virtuoso, we still favor backward chaining since we expect a great diversity of graph combinations and near infinite volume in the open web scenario. With private repositories of slowly changing data put together for a special application, the situation is different.</p>
<p>In conclusion, we have a real LOD movement with actual momentum and a good idea of what to do next. The next step is promoting this to the broader community, starting with <a href="http://www.linkeddataplanet.com/" id="link-id0xa16319a8">Linked Data Planet</a> in New York in June.</p>]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1346">
  <rss:title>On Sem Web Search</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1346</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1346</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1346</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-29T12:03:47Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">&quot;I give the search keywords and you give me a SPARQL end-point and a query that will get the data.&quot; Thus did one SPARQL user describe the task of a semantic/data web search engine. In a previous post, I suggested that if the data web were the size of the document web, we&#39;d be looking at two orders of magnitude more search complexity. It just might be so. In the conversation, I pointed out that a search engine might have a copy of everything and even a capability to do SPARQL and full text on it all, yet still the users would be better off doing the queries against the SPARQL end-points of the data publishers. It is a bit like the fact that not all web browsing runs off Google&#39;s cache. With the data web, the point is even more pronounced, as serving a hit from Google&#39;s cache is a small operation but a complex query might be a very large one. Yet, the data web is about ad-hoc joining between data sets of different origins. Thus a search engine of the data web ought to be capable of joining also, even if large queries ought to be run against individual publishers&#39; end-points or the user&#39;s own data warehouse. For ranking, the general consensus was that no single hit-ranking would be good for the data web. Thus word frequency-based hit-scores are OK for text hits but more is not obvious. I would think that some link analysis could apply but this will take some more experimentation. For search summaries, if we have splitting of data sets into small fragments à la Sindice, search summaries are pretty much the same as with just text search. If we store triples, then we can give text style summaries of text hits in literals and Fresnel lens views of the structured data around the literal. For showing a page of hits, the lenses must abbreviate heavily but this is still feasible. The engine would know about the most common ontologies and summarize instance data accordingly. Chris Bizer pointed out that trust and provenance are critical, especially if an answer is arrived at by joining multiple data sets. The trust of the conclusion is no greater than that of the weakest participating document. Different users will have different trusted sources. A mature data web search engine would combine a provenance/trust specification, a search condition consisting of SPARQL or full text or both, and a specification for hit rank. Again, most searches would use defaults, but these three components should in principle be orthogonally specifiable. Many places may host the same data set either for download or SPARQL access. The URI of the data set is not its URL. Different places may further host multiple data sets on one end-point. Thus the search engine ought to return all end-points where the set is to be found. The end-points themselves ought to be able to say what data sets they contain, under what graph IRIs. Since there is no consensus about end-point self description, this too would be left to the search engine. In practice, this could be accomplished by extending Sindice&#39;s semantic site map specification. A possible query would be to find an end-point containing a set of named data sets. If none were found, the search engine itself could run a query joining all the sets since it at least would hold them all. Since many places will host sets like Wordnet or Uniprot, indexing these once for each copy hardly makes sense. Thus a site should identify its data by the data set&#39;s URI and not the copy&#39;s URL. It came up in the discussion that search engines should share a ping format so that a single message format would be enough to notify any engine about data being updated. This is already partly the case with Sindice and PTSW (Ping The Semantic Web) sharing a ping format. Further, since it is no trouble to publish a copy of the 45G Uniprot file but a fair amount of work to index it, search engines should be smart about processing requests to index things, since these can amount to a denial of service attack. Probably very large data sets should be indexed only in the form supplied by their publisher, and others hosting copies would just state that they hold a copy. If the claim to the copy proved false, users could complain and the search engine administrator would remove the listing. It seems that some manual curating cannot be avoided here. On Data Web Search Business Model It seems there can be an overlap between the data web search and the data web hosting businesses. For example, Talis rents space for hosting RDF data with SPARQL access. A search engine should offer basic indexing of everything for free, but could charge either data publishers or end users for running SPARQL queries across data sets. These do not have the nicely anticipatable and fairly uniform resource consumption of text lookups. In this manner, a search provider could cost-justify the capacity for allowing arbitrary queries. The value of the data web consists of unexpected joining. Such joining takes place most efficiently if the sources are at least in some proximity, for example in the same data center. Thus the search provider could monetize functioning as the database provider for mesh-ups. In the document web, publishing pages is very simple and there is no great benefit from co-locating search and pages, rather the opposite. For the data web, the hosting with SPARQL and all is more complex and resembles providing search. Thus providing search can combine with providing SPARQL hosting, once we accept in principle that search should have arbitrary inter-document joining, even if it is at an extra premium. The present search business model is advertising. If the data web is to be accessed by automated agents such as mesh-up code, display of ads is not self-evident. This is quite separate from the fact that semantics can lead to better ad targeting. One model would be to do text lookups for free from a regular web page but show ads, just a la Google search ads. Using the service via web services for text or SPARQL would have a cost paid by the searching or publishing party and would not be financed by advertising. In the case of data used in value-add data products (mesh-ups) that have financial value to their users, the original publisher of the data could even be paid for keeping the data up-to-date. This would hold for any time-sensitive feeds like news or financial feeds. Thus the hosting/search provider would be a broker of data-use fees and the data producer would be in the position of an AdSense inventory owner, i.e., a web site which shows AdSense ads. Organizing this under a hub providing back-office functions similar to an ad network could make sense even if the actual processing were divided among many sites. Kingsley has repeatedly formulated the core value proposition of the semantic web in terms of dealing with information overload: There is the real-time enterprise and the real-time individual and both are beasts of perception. Their image is won and lost in the Internet online conversation space. We know that allegations, even if later proven false, will stick if left unchallenged. The function of semantics on the web is to allow one to track and manage where one stands. In fact, Garlic has made a business of just this, but now from a privacy and security angle. Garlic&#39;s Data Patrol harvests data from diverse sources and allows assessing vulnerability to identity theft, for example. If one is in the business of collating all the structured data in the world, as a data web search engine is, then providing custom alerts for both security or public image management is quite natural. This can be a very valuable service if it works well. At OpenLink, we will now experiment with the Sindice/Zitgist/PingTheSemanticWeb content. This is a regular part of the productization of Virtuoso&#39;s cluster edition. We expect to release some results in the next 4 weeks.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>&quot;I give the search keywords and you give me a <a href="http://dbpedia.org/resource/SPARQL" id="link-id0x14996288">SPARQL</a> end-point and a query that will get the <a href="http://dbpedia.org/resource/Data" id="link-id0x1f490388">data</a>.&quot;</p>
<p>Thus did one SPARQL user describe the task of a semantic/data web search engine.</p>
<p>In <a href="http://www.openlinksw.com/weblog/oerling/?id=1336" id="link-idff98750">a previous post</a>, I suggested that if the data web were the size of the document web, we&#39;d be looking at two orders of magnitude more search complexity. It just might be so.</p>
<p>In the conversation, I pointed out that a search engine might have a copy of everything and even a capability to do SPARQL and full text on it all, yet still the users would be better off doing the queries against the SPARQL end-points of the data publishers. It is a bit like the fact that not all web browsing runs off Google&#39;s cache. With the data web, the point is even more pronounced, as serving a hit from Google&#39;s cache is a small operation but a complex query might be a very large one.</p>
<p>Yet, the data web is about ad-hoc joining between data sets of different origins. Thus a search engine of the data web ought to be capable of joining also, even if large queries ought to be run against individual publishers&#39; end-points or the user&#39;s own data warehouse.</p>
<p>For ranking, the general consensus was that no single hit-ranking would be good for the data web. Thus word frequency-based hit-scores are OK for text hits but more is not obvious. I would think that some link analysis could apply but this will take some more experimentation.</p>
<p>For search summaries, if we have splitting of data sets into small fragments <i>à la</i> Sindice, search summaries are pretty much the same as with just text search. If we store triples, then we can give text style summaries of text hits in literals and Fresnel lens views of the structured data around the literal. For showing a page of hits, the lenses must abbreviate heavily but this is still feasible. The engine would know about the most common ontologies and summarize instance data accordingly.</p>
<p>Chris Bizer pointed out that trust and provenance are critical, especially if an answer is arrived at by joining multiple data sets. The trust of the conclusion is no greater than that of the weakest participating document. Different users will have different trusted sources.</p>
<p>A mature data web search engine would combine a provenance/trust specification, a search condition consisting of SPARQL or full text or both, and a specification for hit rank. Again, most searches would use defaults, but these three components should in principle be orthogonally specifiable.</p>
<p>Many places may host the same data set either for download or SPARQL access. The <a href="http://dbpedia.org/resource/Uniform_Resource_Identifier" id="link-id0xa0dcaac0">URI</a> of the data set is not its <a href="http://dbpedia.org/resource/Uniform_Resource_Locator" id="link-id0x14a6f7b8">URL</a>. Different places may further host multiple data sets on one end-point. Thus the search engine ought to return all end-points where the set is to be found. The end-points themselves ought to be able to say what data sets they contain, under what graph IRIs. Since there is no consensus about end-point self description, this too would be left to the search engine. In practice, this could be accomplished by extending Sindice&#39;s semantic site map specification. A possible query would be to find an end-point containing a set of named data sets. If none were found, the search engine itself could run a query joining all the sets since it at least would hold them all.</p>
<p>Since many places will host sets like Wordnet or Uniprot, indexing these once for each copy hardly makes sense. Thus a site should identify its data by the data set&#39;s URI and not the copy&#39;s URL.</p>
<p>It came up in the discussion that search engines should share a ping format so that a single message format would be enough to notify any engine about data being updated. This is already partly the case with Sindice and <a href="http://www.pingthesemanticweb.com/" id="link-id0x13b30e40">PTSW</a> (Ping The <a href="http://dbpedia.org/resource/Semantic_Web" id="link-id0x15c86818">Semantic Web</a>) sharing a ping format. </p>
<p>Further, since it is no trouble to publish a copy of the 45G Uniprot file but a fair amount of work to index it, search engines should be smart about processing requests to index things, since these can amount to a denial of service attack. </p>
<p>Probably very large data sets should be indexed only in the form supplied by their publisher, and others hosting copies would just state that they hold a copy. If the claim to the copy proved false, users could complain and the search engine administrator would remove the listing. It seems that some manual curating cannot be avoided here. </p>
<h2>On Data Web Search Business Model</h2>
<p>It seems there can be an overlap between the data web search and the data web hosting businesses. For example, Talis rents space for hosting <a href="http://dbpedia.org/resource/Resource_Description_Framework" id="link-id0x1f49fc50">RDF</a> data with SPARQL access. A search engine should offer basic indexing of everything for free, but could charge either data publishers or end users for running SPARQL queries across data sets. These do not have the nicely anticipatable and fairly uniform resource consumption of text lookups. In this manner, a search provider could cost-justify the capacity for allowing arbitrary queries. </p>
<p>The value of the data web consists of unexpected joining. Such joining takes place most efficiently if the sources are at least in some proximity, for example in the same data center. Thus the search provider could monetize functioning as the database provider for mesh-ups. In the document web, publishing pages is very simple and there is no great benefit from co-locating search and pages, rather the opposite. For the data web, the hosting with SPARQL and all is more complex and resembles providing search. Thus providing search can combine with providing SPARQL hosting, once we accept in principle that search should have arbitrary inter-document joining, even if it is at an extra premium.</p>
<p>The present search business model is advertising. If the data web is to be accessed by automated agents such as mesh-up code, display of ads is not self-evident. This is quite separate from the fact that semantics can lead to better ad targeting.</p>
<p>One model would be to do text lookups for free from a regular web page but show ads, just a la Google search ads. Using the service via web services for text or SPARQL would have a cost paid by the searching or publishing party and would not be financed by advertising.</p>
<p>In the case of data used in value-add data products (mesh-ups) that have financial value to their users, the original publisher of the data could even be paid for keeping the data up-to-date. This would hold for any time-sensitive feeds like news or financial feeds. Thus the hosting/search provider would be a broker of data-use fees and the data producer would be in the position of an AdSense inventory owner, i.e., a web site which shows AdSense ads. Organizing this under a hub providing back-office functions similar to an ad network could make sense even if the actual processing were divided among many sites.</p>
<p>Kingsley has repeatedly formulated the core value proposition of the semantic web in terms of dealing with <a href="http://dbpedia.org/resource/Information" id="link-id0x13952238">information</a> overload: There is the real-time enterprise and the real-time individual and both are beasts of perception. Their image is won and lost in the Internet online conversation space. We know that allegations, even if later proven false, will stick if left unchallenged. The function of semantics on the web is to allow one to track and manage where one stands. In fact, Garlic has made a business of just this, but now from a privacy and security angle. Garlic&#39;s Data Patrol harvests data from diverse sources and allows assessing vulnerability to identity theft, for example.</p>
<p>If one is in the business of collating all the structured data in the world, as a data web search engine is, then providing custom alerts for both security or public image management is quite natural. This can be a very valuable service if it works well.</p>
<p>At OpenLink, we will now experiment with the Sindice/<a href="http://zitgist.com/about/" id="link-id0x9d82e3f8">Zitgist</a>/<a href="http://www.pingthesemanticweb.com/" id="link-id0xd1ed7a0">PingTheSemanticWeb</a> content. This is a regular part of the productization of <a href="http://virtuoso.openlinksw.com" id="link-id0xcdd57c0">Virtuoso</a>&#39;s cluster edition. We expect to release some results in the next 4 weeks.   
</p>]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1345">
  <rss:title>WWW 2008</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1345</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1345</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1345</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-29T11:59:16Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">Following my return from WWW 2008 in Beijing, I will write a series of blog posts discussing diverse topics that were brought up in presentations and conversations during the week. Linked data was our main interest in the conference and there was a one day workshop on this, unfortunately overlapping with a day of W3C Advisory Committee meetings. Hence Tim Berners-Lee, one of the chairs of the workshop, could not attend for most of the day. Still, he was present to say that &quot;Linked open data is the semantic web and the web done as it ought to be done.&quot; For my part, I will draw some architecture conclusions from the different talks and extrapolate about the requirements on database platforms for linked data. Chris Bizer predicted that 2008 would be the year of data web search, if 2007 was the year of SPARQL. This may be the case, as linked data is now pretty much a reality and the questions of discovery become prevalent. There was a birds-of-a-feather session on this and I will make some comments on what we intend to explore in bridging between the text index based semantic web search engines and SPARQL. Andy Seaborne convened a birds-of-a-feather session on the future of SPARQL. Many of the already anticipated and implemented requirements were confirmed and a few were introduced. A separate blog post will discuss these further. From the various discussions held throughout the conference, we conclude that plug-and-play operation with the major semantic web frameworks of Jena, Sesame, and Redland, is our major immediate-term deliverable. Our efforts in this direction thus far are insufficient and we will next have these done with the right supervision and proper interop testing. The issues are fortunately simple but doing things totally right require some small server side support and some JDBC/ODBC tweaks, so to the interested, we advise to wait for an update to be published on this blog. I further had a conversation with Andy Seaborne about using Jena reasoning capabilities with Virtuoso and generally the issues of &quot;impedance mismatch&quot; between reasoning and typical database workloads. More on this later.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Following my return from WWW 2008 in <a href="http://www2008.org/" id="link-id0xa1901330">Beijing</a>, I will write a series of <a href="http://dbpedia.org/resource/Blog" id="link-id0xd356660">blog</a> posts discussing diverse topics that were brought up in presentations and conversations during the week.</p>
<a href="http://dbpedia.org/resource/Linked_Data" id="link-id0x1290cb78">Linked data</a> was our main interest in the conference and there was a one day workshop on this, unfortunately overlapping with a day of W3C Advisory Committee meetings.  Hence Tim Berners-Lee, one of the chairs of the workshop, could not attend for most of the day.  Still, he was present to say that &quot;<a href="http://community.linkeddata.org/dataspace/organization/lod#this" id="link-id0xa2754050">Linked open data</a> is the <a href="http://dbpedia.org/resource/Semantic_Web" id="link-id0xa099dea8">semantic web</a> and the web done as it ought to be done.&quot;
<p>For my part, I will draw some architecture conclusions from the different talks and extrapolate about the requirements on database platforms for linked data.</p>
<p>Chris Bizer predicted that 2008 would be the year of <a href="http://dbpedia.org/resource/Data" id="link-id0x9e0f0a98">data</a> web search, if 2007 was the year of <a href="http://dbpedia.org/resource/SPARQL" id="link-id0xd9e64a0">SPARQL</a>.  This may be the case, as linked data is now pretty much a reality and the questions of discovery become prevalent.  There was a birds-of-a-feather session on this and I will make some comments on what we intend to explore in bridging between the text index based semantic web search engines and SPARQL.</p>
<p>Andy Seaborne convened a birds-of-a-feather session on the future of SPARQL.  Many of the already anticipated and implemented requirements were confirmed and a few were introduced.  A separate blog post will discuss these further.</p>
<p>From the various discussions held throughout the conference, we conclude that plug-and-play operation with the major semantic web frameworks of Jena, Sesame, and Redland, is our major immediate-term deliverable.  Our efforts in this direction thus far are insufficient and we will next have these done with the right supervision and  proper interop testing.  The issues are fortunately simple but doing things totally right require some small server side support and some <a href="http://dbpedia.org/resource/Java_Database_Connectivity" id="link-id0xacc8c7e8">JDBC</a>/<a href="http://dbpedia.org/resource/Open_Database_Connectivity" id="link-id0x9e48d258">ODBC</a> tweaks, so to the interested, we advise to wait for an update to be published on this blog.</p>
<p>I further had a conversation with Andy Seaborne about using Jena reasoning capabilities with <a href="http://virtuoso.openlinksw.com" id="link-id0x134b8e98">Virtuoso</a> and generally the issues of &quot;impedance mismatch&quot; between reasoning and typical database workloads. More on this later.   
</p>]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1337">
  <rss:title>Partitioning and Cluster Config</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1337</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1337</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1337</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-14T09:37:29Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">Now that it is time to nail down the final database format and configuration steps for Virtuoso Cluster, we have to make a couple of small choices. Design Objective While fixed partitioning is good for testing, it is impractical even for measuring scalability, let alone deployment. So fixed partitioning is really a no-go. The best would be entirely dynamic partitioning where the data file split after reaching a certain size and where data files migrated between any number of heterogeneous boxes, so as to equalize pressure, like a liquid fills a container. It would have to be a sluggish cool liquid with a high surface tension, else we would get &quot;Brownian motion&quot; in trying to equalize the pressure too often. But a liquid still. Sure. Now go implement this with generic RDBMS ACID semantics and the works. Feasible. But while I am a fair-to-good geek, I don&#39;t have time for this right now. So something in between, then. The auto-migrating files are really a problem for keeping locks, keeping tractable roll forward, special cases in message routing etc. The papers by Google and Amazon allude to this and they stop far short of serializable transaction semantics. So what is the design target? In practice, running a few hundred database nodes with fault tolerance. The nodes must be allowed to be of different sizes since a one time replace of hundreds of PC&#39;s fits ill with the economy. Addition and removal of nodes must be without global downtime but putting some partitions in read only mode for restricted periods is OK. Assigning the percentages of the data mass to the nodes can be a DBA task with a utility making suggestions based on measured disk cache hit rates and the like. Partitions and the makeup of the cluster must be maintainable from a single place, no copying of config files or such, nobody can get this right and the screw ups from having cluster nodes disagree about some part of the partition map are so untractable you don&#39;t even want to go there. So, how is this done? Divide the space of partitioning hashes into say 1K slices. For each slice, give the node numbers that hold this slice of the partitioning space. If there are more nodes, just divide the space in more slices. When a node comes new to the cluster, it manages no slices. Slices from other nodes can be offloaded to the new one by copying their contents. The slice holders put the slice in read only mode and the new node just does an insert-select of the partitions it is meant to take over, no logs or locks needed and all comes in order so insert is 100% in processor cache. When the copy is complete, the slice comes back in read write mode in its new location and the old holders of the slices delete theirs in the background. This is not as quick as shifting database files around but takes far less programming. To remove a node, reassign its slices and have the assignees read the data, as above. When the copy is done, the node can go off line. A slight modification of this is for cases where a slice always has more than one holder. Now, if we allocate slices to nodes on the go, keeping would-be replicas on different machines but otherwise equalizing load, we run into a problem with redundancy when we perform an operation that has no specific recipient: Suppose we count a table&#39;s rows, we should send the count request once per every slice. Now, the slice is not the recipient of the request, the cluster node hosting the slice is. We should either qualify the request with what slices it pertains to, which means extra reading and filtering or have it so that no matter the choice of replicas for any operation, there is no overlap between their contents, yet the contents cover every slice. The only simple way to enforce the latter is to have cluster nodes pair-wise as each others&#39; replicas. Nodes will be adding nodes in pairs or threes or whatever number of replicas there will be. Google&#39;s GFS, the file system redundancy layer under Bigtable or Dynamo do not have this problem since they do not deal with generic DBMS semantics. The downside is that if a pair has two different types of boxes, the sizing should go according to the smaller one. No big deal. If replicas are assigned box by box instead of slice by slice, life is also simpler in terms of roll forward and reconstituting lost nodes. The complete list of cluster nodes and their slice allocations are kept on a master node. Each node also knows which slices it holds. With the loss of the master the situation can be reconstructed from the others. For normal boot, the nodes get the cluster layout, slice allocation and some config parameters from the master, so that if network addresses change they do not have to be written to each node. These are remembered by each node though, for the event of master failure. When a Virtuoso 6 database is made, the system objects are partitioned from the get-go. On a single process this has no effect. But since all the data structures exist, the transition from a single process to cluster and back is smooth. At any time, a database, whether single or cluster, is a self-contained unit. One server process serves one database. It is one-to-many from database to server process. A server process will not mount multiple databases. This could be done but then this would be more changes than fit in the time available so this will not be supported. One can always have multiple server processes and attached tables for genuinely inter-database operations. This said, a single database holds arbitrarily many catalogs and schemas and application objects of all sorts. In terms of schedule, we do the single copy per partition right now. Duplicate and triplicate copies of partitions are needed as we do some of our web scale things in the pipeline. So a degree of this supported even now but without seamless recovery, so when a replica is offline, the remaining copy is read only. Making this read-write is a matter of a little programming. DDL operations will continue to require all nodes to be online. As of this writing, we are making the regular test suite run on a cluster with the above described partitioning, a single copy per partition. After this, the database layout will stay constant. The first deployments will go out without replicated partitions. Replicated partitions will follow shortly, together with some of the optimizations mentioned in previous posts.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Now that it is time to nail down the final database format and configuration steps for <a href="http://data.openlinksw.com/oplweb/product_family/virtuoso#this" id="link-id0x16952828">Virtuoso</a> Cluster, we have to make a couple of small choices.</p>
<h3>Design Objective</h3>
<p>While fixed partitioning is good for testing, it is impractical even for measuring scalability, let alone deployment.  So fixed partitioning is really a no-go.  The best would be entirely dynamic partitioning where the data file split after reaching a certain size and where data files migrated between any number of heterogeneous boxes, so as to equalize pressure, like a liquid fills a container. It would have to be a sluggish cool liquid with a high surface tension, else we would get &quot;Brownian motion&quot; in trying to equalize the pressure too often.  But a liquid still.</p>
<p>Sure.  Now go implement this with generic RDBMS ACID semantics and the works.  Feasible.   But while I am a fair-to-good geek, I don&#39;t have time for this right now.</p>
<p>So something in between, then.  The auto-migrating files are really a problem for keeping locks, keeping tractable roll forward, special cases in message routing etc.  The papers by Google and Amazon allude to this and they stop far short of serializable transaction semantics.</p>
<p>So what is the design target?  In practice, running a few hundred database nodes with fault tolerance.  The nodes must be allowed to be of different sizes since a one time replace of hundreds of PC&#39;s fits ill with the economy.</p>
<p>Addition and removal of nodes must be without global downtime but putting some partitions in read only mode for restricted periods is OK.  Assigning the percentages of the data mass to the nodes can be a DBA task with a utility making suggestions based on measured disk cache hit rates and the like.  Partitions and the makeup of the cluster must be maintainable from a single place, no copying of config files or such, nobody can get this right and the screw ups from  having cluster nodes disagree about some part of the partition map are so untractable you don&#39;t even want to go there.</p>
<p>So, how is this done?  Divide the space of partitioning hashes into say 1K slices.  For each slice, give the node numbers that hold this slice of the partitioning space.  If there are more nodes, just divide the space in more slices.  When a node comes new to the cluster, it manages no slices.  Slices from other nodes can be offloaded to the new one by copying their contents.  The slice holders put the slice in read only mode and the new node just does an insert-select of the partitions it is meant to take over, no logs or locks needed and all comes in order so insert is 100% in processor cache. When the copy is complete, the slice comes back in read write mode in its new location and the old holders of the slices delete theirs in the background.  This is not as quick as shifting database files around but takes far less programming.</p>
<p>To remove a node, reassign its slices and have the assignees read the data, as above.  When the copy is done, the node can go off line.</p>
<p>A slight modification of this is for cases where a slice always has more than one holder.  Now, if we allocate slices to nodes on the go, keeping would-be replicas on different machines but otherwise equalizing load, we run into a problem with redundancy when we perform an operation that has no specific recipient: Suppose we count a table&#39;s rows, we should send the count request once per every slice.  Now, the slice is not the recipient of the request, the cluster node hosting the slice is.  We should either qualify the request with what slices it pertains to, which means extra reading and filtering  or have it so that no matter the choice of replicas for any operation, there is no overlap between their contents, yet the contents cover every slice.  The only simple way to enforce the latter is to have cluster nodes pair-wise as each others&#39; replicas.  Nodes will be adding nodes  in pairs or threes or whatever number of replicas there will be.  Google&#39;s GFS, the file system redundancy layer under Bigtable or Dynamo do not have this problem since they do not deal with generic DBMS semantics.  The downside is that if a pair has two different types of boxes, the sizing should go according to the smaller one.  No big deal.</p>
<p>If replicas are assigned box by box instead of slice by slice, life is also simpler in terms of roll forward and reconstituting lost nodes.</p>
<p>The complete list of cluster nodes and their slice allocations are kept on a master node.  Each node also knows which slices it holds. With the loss of the master the situation can be reconstructed from the others.  For normal boot, the nodes get the cluster layout, slice allocation and some config parameters from the master, so that if network addresses change they do not have to be written to each node.  These are remembered by each node though, for the event of master failure.</p>
<p>When a Virtuoso 6 database is made, the system objects are partitioned from the get-go.  On a single process this has no effect.  But since all the data structures exist, the transition from a single process to cluster and back is smooth.</p>
<p>At any time, a database, whether single or cluster, is a self-contained unit.  One server process serves one database.  It is one-to-many from database to server process.  A server process will not mount multiple databases.  This could be done but then this would be more changes than fit in the time available so this will not be supported.  One can always have multiple server processes and attached tables for genuinely inter-database operations.  This said, a single database holds arbitrarily many catalogs and schemas and application objects of all sorts.</p>
<p>In terms of schedule, we do the single copy per partition right now. Duplicate and triplicate copies of partitions are needed as we do some of our web scale things in the pipeline.  So a degree of this  supported even now but without seamless recovery, so when a replica is offline, the remaining copy is read only.  Making this read-write is a matter of a little programming.  DDL operations will continue to require all nodes to be online.</p>
<p>As of this writing, we are making the regular test suite run on a cluster with the above described partitioning, a single copy per partition.  After this, the database layout will stay constant.  The first deployments will go out without replicated partitions. Replicated partitions will follow shortly, together with some of the optimizations mentioned in previous posts.</p>
]]></content:encoded>
  <dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Orri Erling &lt;oerling@openlinksw.com&gt;</dc:creator>
 </rss:item>
 <rss:item xmlns:rss="http://purl.org/rss/1.0/" rdf:about="http://www.openlinksw.com/weblog/oerling/?id=1336">
  <rss:title>Architectures for Infinity</rss:title>
  <rss:link>http://www.openlinksw.com/weblog/oerling/?id=1336</rss:link>
  <wfw:comment xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/mt-tb/Http/comments?id=1336</wfw:comment>
  <wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://www.openlinksw.com/weblog/oerling/gems/rsscomment.xml?:id=1336</wfw:commentRss>
  <dc:date xmlns:dc="http://purl.org/dc/elements/1.1/">2008-04-14T09:32:40Z</dc:date>
  <dc:description xmlns:dc="http://purl.org/dc/elements/1.1/">A while back, a friend suggested he and I go check out the Singularity Summit, a conference where they talk of strong AI. Well, I am not a singularist. But since singularists are so brazenly provocative, I looked a little to see if there is anything there, engineering-wise. So, for a change, we&#39;ll be visionary. Read on, I also mention RDF at the end. I will not even begin with arguments about indefinitely continuing a trend. I will just say that nature has continuous and discontinuous features. Computing is at a qualitative bend and things are not as simple as they are blithely cracked up to be. Read HEC, the high end crusader; he has good commentary on architecture. Having absorbed and understood this, you can talk again about a billion-fold increase in computing price/performance. When I looked further, about uploading, i.e., the sci-fi process of scanning a brain and having it continue its function inside a computer simulation, I actually found some serious work. Dharmendra Modha at IBM had made a rat-scale cortical simulator running on a 32K node IBM BlueGene, with a 9x slowdown from real time. This is real stuff and in no way meant to be associated with singularism by being mentioned in the same paragraph. Anyway, I was intrigued. So I asked myself if I could do better. I gave it a fair try, as fair as can be without an actual experiment. The end result is that latency rules. To have deterministic semantics, one must sync across tens of thousands of processors and one cannot entirely eliminate multi-hop messages on the interconnect fabric. If one optimistically precalculates and spreads optimistic results over the cluster, rolling them back will be expensive. Local optimistic computation may have little point since most data points will directly depend on non local data. One needs two sets of wiring, a 3D torus for predominantly close range bulk and a tree for sync, just like the BlueGene has. Making the same from newer hardware makes it more economical but there&#39;s another 8 or so orders of magnitude to go before energy efficiency parity with biology. Anyway, a many-times-over qualitative gap. Human scale in real time might be just there somewhere in reach with the stuff now in pre-release if there were no bounds on cost or power consumption. We&#39;d be talking billions at least and even then it is iffy. But this is of little relevance as long as the rat scale is at the level of a systems test for the platform and not actually simulating a plausible organism in some sort of virtual environment. Anyway, of biology I cannot judge and for the computer science, Modha et al have it figured out about as well as can. Simulation workloads are not the same as database. Database is easier in a way since any global sync is very rare. 2PC seldom touches every partition and if it does, the time to update was anyway greater than the time to commit. Databases are generally multi-user, with a low level of sync between users and a lot of asynchrony. On the other hand, the general case of database does not have predictable cluster locality. Well, if one has an OLTP app with a controlled set of transactions and reports, then one can partition just for that and have almost 100% affinity between the host serving the connection and the data. With RDF for example, such is not generally possible or would require such acrobatics of data layout that a DBA would not even begin. So, for database, there is a pretty much even probability for any connection between the node running the query and any other. True, function shipping can make the messages large and fairly async and latency tolerant. On the simulation side, it would seem that the wiring can mimic locality of the simulated process. Messages to neighbors are more likely than messages to remote nodes. So a 3D torus works well there, complemented by a tree for control messages, like sending all nodes the count of messages to expect. Of course, the control wiring (reduce tree) must have far less latency than a long path through the torus wiring and steps with long message deliveries on the torus must be rare for this to bring any profit. Also, long distance messages can go through the tree wiring if the volume is not excessive, else the tree top gets congested. So, looking past the multicore/multithread and a single level switched interconnect, what would the architecture of the total knowledge machine be? For the neural simulation, the above-described is the best I can come up with and IBM already has come up with it anyway. But here I am more concerned with a database/symbol processing workload than about physical simulation. For the record, I&#39;ll say that I expect no strong AI to emerge from these pursuits but that they will still be useful, basically as a support for a linked data &quot;planetary datasphere.&quot; Like Google, except it supports arbitrary queries joining arbitrary data at web scale. This would be a couple of orders of magnitude above the text index of same. Now, in practice, most queries will be rather trivial, so it is not that the 2 orders of magnitude are always realized. This would also involve a bit more updating than the equivalent text index since reports would now and then include private materialized inference results. As a general rule, backward chaining would be nicer, since this is read only but some private workspaces for distilling data cannot be avoided. So, given this general spec, where should architecture go? We can talk of processors, networks and software in turn. Processors For evaluating processors, the archetypal task is doing a single random lookup out of a big index. Whether it is a B tree or hash is not really essential since both will have to be built of fixed size pages and will have more than one level. Both need some serialization for checking if things are in memory and for pinning them in cache for the duration of processing. This is eternally true as long as updates are permitted, even if RAM were the bottom of the hierarchy. And if not, then there is the checking of whether a page is in memory and the logic for pinning it. This means critical sections on shared data structures with small memory writes inside. This is anathema, yet true. So, what the processor needs is shared memory for threads and if possible an instruction for entry into a read-write lock. If the lock is busy, there should be a settable interval before the thread is removed from the core. With a multithread core, this should be just like a memory cache miss. Only if this were really prolonged would there be an interrupt to run the OS scheduler to vacate the thread and load something else, and not even this if the number of executable threads were less or equal the number of threads on the cores. For thread sync structures, the transactional memory ideas on the SPARC ROC might be going in this direction. For on-core threading, I have not tried how well SPARC T2 does but with the right OS support, it might be in the ballpark. The X86_64 chips have nice thread speed but the OS, whether Solaris or Linux, is a disaster if a mutex is busy. Don&#39;t know why but so it is. Things like IBM Cell, with multiple integrated distributed memory processors on a chip might be workable if they had hardware for global critical sections and if sub-microsecond tasks could be profitably dispatched to the specialized cores (synergistic unit in Cell terminology). If an index lookup, about 2-4 microseconds of real time, could be profitably carried out on a synergistic core without sinking it all in sync delays on the main core, there might be some gain to this. Still, operations like cache lookups tend to be pointer chasing and latency of small memory reads and sometimes writes is a big factor. I have not measured Cell for this but it is not advertised for this sort of workload. It might do nicely for the neuron simulator but not for generic database, I would guess. Networks and Data Center The point at which distributed memory wins over shared determines the size of the single compute node. Problems of threads and critical sections fall off but are replaced by network and the troubles of scheduling and serializing and de-serializing messages. There are really huge shared memory systems (by Cray, for example) but even there, hitting the wrong address sends a high latency message over an internal switched fabric, a bit like a network page fault. Well, if one has millions of threads runnable for catching the slack of memory access over interconnect, this might not be so bad, but this is not really the architecture for a general purpose database. So, at some point, we have clearly demarcated distributed memory with affinity of data to processor, simple as that. For now, the high end clustered database benchmarks run off 1 Gbit ethernet fabrics with some 30 compute nodes on a single switch. This is for shared nothing systems. For shared disk, cache fusion systems like Oracle RAC, we have more heavy duty networking like Infiniband, as one would expect. I have discussed the merits of cache fusion vs shared nothing partitioning on in a previous post. As long as we are at a scale that fits on a single switch with even port to port latency, we are set. For an RDF workload, throughput is not really the issue but latency can be. With today&#39;s technology, nodes with 4-8 cores and 16G RAM are practical and their number is most often not really large. Adding two orders of magnitude, we get more questions. Let&#39;s say that 2 billion triples fit with relative comfort but not without disk on a 16G RAM node. This would make 500 nodes for a trillion triples. This is an entirely relevant and reasonable scale, considering that loading all public biomedical sets plus a pharma company&#39;s in house data could approach this ballpark. Let alone anything on the scale of the social web, i.e., the online conversation space. So how to manage clusters like this? The current cluster gear is oriented toward switch trees and is fairly expensive, about $1000 per node. To make this easy, we would need a wiring free, modular architecture. Picture a shelf with SATA drive size bays, each would get a compute node of 8 cores and 16G plus interconnect. To simplify the network, the module would have a laser on each side, for a cube network topology, the enclosure could connect the edges with fiber optics for the 3D torus. Mass storage would be in the same form factor, as disks or flashes to be interspersed in the proper ratio with compute nodes. All would have the same communication chip, something like a Cray SeaStar with 6 or 7 external ports. A seventh port could be used for a reduce tree. The rack would provide cooling on the shelves by circulating a coolant fluid. Reconfiguring and scaling would be a matter of adding shelves to the cabinet and laying out Lego bricks, blue for compute and red for storage. The network could achieve a latency for an arbitrary point to point message of no more than 10-20 microseconds by the right mix of cube and tree. This in a box of thousands of nodes. This type of layout would accommodate web scale without needing rows and rows of rack cabinets. The external interfaces for web requests and replies are no big deal after this, since the intra-cluster traffic is orders of magnitude higher than the result set traffic. After all, the end user does not want dumps of the database but highly refined and ranked results. Software We have previously talked about dynamic partitions a la Google Bigtable or Amazon Dynamo. These techniques are entirely fine and will serve for the universal knowledge store. But what about query logic? OK, having a consistent map of partitions shared over tens of thousands of nodes is entirely possible. So is replication and logic for using a spatially closer partition when multiple copies are know to exist. These things take some programming but there is nothing really new about them. These are a direct straightforward extension of what we do for clustering right now. But look to windward. How to run complex queries and inference on the platform outlined above? There are some features of RDF querying like same-as that can be easily parallelized, backward-chaining style: Just proceed with the value at hand and initiate the lookup of synonyms and let them get processed when they become available. Same for subclass and sub-property. We already do this, but could do it with more parallelism. No matter what advances in architecture take place, I do not see a world where every user materializes the entailment of their own same-as-es and rules over a web scale data set. So, backward chaining approaches to inference must develop. Luckily, what most queries need is simple. A rule-oriented language, like Prolog without cut will parallelize well enough. Some degree of memoization may be appropriate for cutting down on re-proving the same thing over and over. Memoization over a cluster is a problem though, since this involves messages. I should say that one should not go looking for pre-proven things beyond the node at hand and that computation should not spread too quickly or too promiscuously so as not to make long message paths. We must remember that a totally even round trip time on a large cluster just will not happen. Query planning on any system critically depends on correct ballpark guesses on cardinality. If predicates are amplified with transitivity and same-as at run time, the cardinality guessing becomes harder. This can kill any plan no matter the hardware. Probably, an executing query must be annotated with the underlying cardinality assumptions. If these prove radically false, the execution may abort and a new plan be made to better match what was found out. This bears some looking into. There are some network algorithms like shortest path, traveling salesman and similar that probably deserve a special operator in the query language. These can benefit from parallelization and a sequential implementation running on a cluster with latency will be a disaster. Expressing the message flow in a rule language is not really simple and pretty much no programmer will either appreciate the necessity or go to the trouble. Therefore such things should likely be offered by the platform and made by the few people who understand such matters. For forward chaining, it seems that any results should generally go into their own graph so as not to pollute the base data. This graph, supposing it is small enough, can have different partitioning from the large base data set. If the data comes from far and wide but results are local, there is better usage of a RETE like algorithm for triggering inference when data comes in. RETE will parallelize well enough, also for clusters,results just have to be broadcast to the nodes that may have a use for them. The programming model will typically be using a set of local overlays on a large shared data set. Queries will most often not be against a single graph. Strict transactionality will be the exception rather than the rule. At the database node level, there must be real transactionality even if the whole system most often did not run with strict ACID semantics. This is due to ACID requirements of some internal ops, e.g., some bitmap index operations, log checkpoints, DDL changes, etc. For procedural tasks, map-reduce is OK. We have it even in our SQL. Map-reduce is not the basis for making a DBMS but it is a nice feature for some parts of query evaluation and application logic. We have not talked about linking the data itself, but there is a whole workshop on this next week in Beijing; I will write about it separately. Let this just serve to state that we are serious about the platform for this, present and future. Conclusion The web scale database, the Google with arbitrary joining and inference, is one generation away, talking of economical implementation. Today, a price tag of $100K will buy some 50-100 billion triples worth with reasonable query response. Unlimited budget will take this a bit further, like one order of magnitude. and then, returns might be decreasing. Of course, this is worth nothing if the software isn&#39;t there. Virtuoso with its cluster edition will allow one to use unlimited RAM and processors. The frontier is now at getting just the right parallelism for each task, including inference ones.</dc:description>
  <content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>A while back, a friend suggested he and I go check out the <a href="http://www.kurzweilai.net/" id="link-idfed3e58">Singularity
Summit</a>, a conference where they talk of strong AI.  Well, I am not a
singularist.  But since singularists are so brazenly provocative, I
looked a little to see if there is anything there, engineering-wise.</p>
<p>So, for a change, we&#39;ll be visionary.  Read on, I also mention <a href="http://dbpedia.org/resource/RDF" id="link-id109a58e8">RDF</a> at the end.</p>
<p>I will not even begin with arguments about indefinitely continuing a
trend.  I will just say that nature has continuous and discontinuous
features.  Computing is at a qualitative bend and things are not as
simple as they are blithely cracked up to be.  Read HEC, the high end
crusader; he has good commentary on architecture.  Having absorbed and
understood this, you can talk again about a billion-fold increase in
computing price/performance.</p>
<p>When I looked further, about uploading, i.e., the sci-fi process of
scanning a brain and having it continue its function inside a
computer simulation, I actually found some serious work.  <a href="http://p9.hostingprod.com/@modha.org/" id="link-id10bf26d0">Dharmendra
Modha</a> at IBM had made a rat-scale cortical simulator running on a 32K
node IBM BlueGene, with a 9x slowdown from real time.  This is real
stuff and in no way meant to be associated with singularism by being
mentioned in the same paragraph.  Anyway, I was intrigued.</p>
<p>So I asked myself if I could do better.  I gave it a fair try, as fair
as can be without an actual experiment.  The end result is that
latency rules.  To have deterministic semantics, one must sync across
tens of thousands of processors and one cannot entirely eliminate
multi-hop messages on the interconnect fabric.  If one optimistically
precalculates and spreads optimistic results over the cluster, rolling
them back will be expensive.  Local optimistic computation may have
little point since most data points will directly depend on non local
data.  One needs two sets of wiring, a 3D torus for predominantly
close range bulk and a tree for sync, just like the BlueGene has.
Making the same from newer hardware makes it more economical but
there&#39;s another 8 or so orders of magnitude to go before energy
efficiency parity with biology.  Anyway, a many-times-over
qualitative gap.  Human scale in real time might be just there
somewhere in reach with the stuff now in pre-release if there were no
bounds on cost or power consumption.  We&#39;d be talking billions at
least and even then it is iffy.  But this is of little relevance as
long as the rat scale is at the level of a systems test for the
platform and not actually simulating a plausible organism in some sort
of virtual environment.  Anyway, of biology I cannot judge and for the
computer science, Modha et al have it figured out about as well as can.</p>
<p>Simulation workloads are not the same as database.  Database is easier
in a way since any global sync is very rare.  2PC seldom touches every
partition and if it does, the time to update was anyway greater than
the time to commit.  Databases are generally multi-user, with a low
level of sync between users and a lot of asynchrony.  On the
other hand, the general case of database does not have predictable
cluster locality.  Well, if one has an OLTP app with a controlled set
of transactions and reports, then one can partition just for that and
have almost 100% affinity between the host serving the connection and
the data.  With <a href="http://dbpedia.org/resource/RDF" id="link-id10c92378">RDF</a> for example, such is not generally possible or
would require such acrobatics of data layout that a DBA would not even
begin.</p>
<p>So, for database, there is a pretty much even probability for any
connection between the node running the query and any other.  True,
function shipping can make the messages large and fairly async and
latency tolerant.</p>
<p>On the simulation side, it would seem that the wiring can mimic
locality of the simulated process.  Messages to neighbors are more
likely than messages to remote nodes.  So a 3D torus works well there,
complemented by a tree for control messages, like sending all nodes
the count of messages to expect.  Of course, the control wiring
(reduce tree) must have far less latency than a long path through the
torus wiring and steps with long message deliveries on the torus must
be rare for this to bring any profit.  Also, long distance messages
can go through the tree wiring if the volume is not excessive, else
the tree top gets congested.</p>
<p>So, looking past the multicore/multithread and a single level switched
interconnect, what would the architecture of the total knowledge
machine be?  For the neural simulation, the above-described is the
best I can come up with and IBM already has come up with it anyway.
But here I am more concerned with a database/symbol processing
workload than about physical simulation.  For the record, I&#39;ll say
that I expect no strong AI to emerge from these pursuits but that they
will still be useful, basically as a support for a linked data
&quot;planetary datasphere.&quot;  Like Google, except it supports arbitrary
queries joining arbitrary data at web scale.  This would be a couple
of orders of magnitude above the text index of same.  Now, in
practice, most queries will be rather trivial, so it is not that the 2
orders of magnitude are always realized.  This would also involve a
bit more updating than the equivalent text index since reports would
now and then include private materialized inference results.  As a
general rule, backward chaining would be nicer, since this is read
only but some private workspaces for distilling data cannot be
avoided.</p>
<p>So, given this general spec, where should architecture go?  We can talk of processors, networks and software in turn.</p>
<h3>Processors </h3>
<p>For evaluating processors, the archetypal task is doing a single
random lookup out of a big index.  Whether it is a B tree or hash is not
really essential since both will have to be built of fixed size pages
and will have more than one level.  Both need some serialization for
checking if things are in memory and for pinning them in cache for the
duration of processing.  This is eternally true as long as updates are
permitted, even if RAM were the bottom of the hierarchy.  And if not,
then there is the checking of whether a page is in memory and the
logic for pinning it.</p>
<p>This means critical sections on shared data structures with  small memory writes inside.  This is
anathema, yet true.  So, what the processor needs is shared memory for
threads and if possible an instruction for entry into a read-write
lock.  If the lock is busy, there should be a settable interval before
the thread is removed from the core.  With a multithread core, this
should be just like a memory cache miss.  Only if this were really
prolonged would there be an interrupt to run the OS scheduler to
vacate the thread and load something else, and not even this if the
number of executable threads were less or equal the number of threads
on the cores.  </p>
<p>For thread sync structures, the transactional memory ideas on the SPARC ROC
might be going in this direction.  For on-core threading, I have not
tried how well SPARC T2 does but with the right OS support, it might
be in the ballpark.  The X86_64 chips have nice thread speed but the
OS, whether Solaris or Linux, is a disaster if a mutex is busy.  Don&#39;t
know why but so it is.</p>
<p>Things like IBM Cell, with multiple integrated distributed memory
processors on a chip might be workable if they had hardware for global
critical sections and if sub-microsecond tasks could be profitably
dispatched to the specialized cores (synergistic unit in Cell
terminology).  If an index lookup, about 2-4 microseconds of real
time, could be profitably carried out on a synergistic core without
sinking it all in sync delays on the main core, there might be some
gain to this.  Still, operations like cache lookups tend to be pointer
chasing and latency of small memory reads and sometimes writes is a
big factor.  I have not measured Cell for this but it is not
advertised for this sort of workload.  It might do nicely for the
neuron simulator but not for generic database, I would
guess.</p>
<h3>Networks and Data Center </h3>
<p>The point at which distributed memory wins over shared determines the
size of the single compute node.  Problems of threads and critical
sections fall off but are replaced by network and the troubles of
scheduling and serializing and de-serializing messages.  There are
really huge shared memory systems (by Cray, for example) but even there,
hitting the wrong address sends a high latency message over an
internal switched fabric, a bit like a network page fault.  Well, if
one has millions of threads runnable for catching the slack of memory access over interconnect,
this might not be so bad, but this is not really the
architecture for a general purpose database.  So, at some point, we
have clearly demarcated distributed memory with affinity of data to processor, simple as that.</p>
<p>For now, the high end clustered database benchmarks run off 1 Gbit
ethernet fabrics with some 30 compute nodes on a single switch.  This
is for shared nothing systems.  For shared disk, cache fusion systems
like Oracle RAC, we have more heavy duty networking like Infiniband,
as one would expect.  I have discussed the merits of cache fusion vs
shared nothing partitioning on in a previous post.</p>
<p>As long as we are at a scale that fits on a single switch with even
port to port latency, we are set.  For an <a href="http://dbpedia.org/resource/RDF" id="link-id0x1830ce48">RDF</a> workload, throughput is
not really the issue but latency can be.  With today&#39;s technology,
nodes with 4-8 cores and 16G RAM are practical and their number is
most often not really large.  Adding two orders of magnitude, we get
more questions.  Let&#39;s say that 2 billion triples fit with relative
comfort but not without disk on a 16G RAM node.  This would make 500 nodes for a trillion triples. </p>
<p>This is an entirely relevant and reasonable scale, considering that
loading all public biomedical sets plus a pharma company&#39;s in house
data could approach this ballpark.  Let alone anything on the scale of
the social web, i.e., the online conversation space.</p>
<p>So how to manage clusters like this?  The current cluster gear is
oriented toward switch trees and is fairly expensive, about $1000 per
node.  To make this easy, we would need a wiring free, modular
architecture.  Picture a shelf with SATA drive size bays, each would
get a compute node of 8 cores and 16G plus interconnect.  To simplify
the network, the module would have a laser on each side, for a cube
network topology, the enclosure could connect the edges with fiber
optics for the 3D torus.  Mass storage would be in the same form
factor, as disks or flashes to be interspersed in the proper ratio
with compute nodes.  All would have the same communication chip,
something like a Cray SeaStar with 6 or 7 external ports.  A seventh
port could be used for a reduce tree.  The rack would provide cooling
on the shelves by circulating a coolant fluid.  Reconfiguring and
scaling would be a matter of adding shelves to the cabinet and laying
out Lego bricks, blue for compute and red for storage.  The network
could achieve a latency for an arbitrary point to point message of no more than 10-20
microseconds by the right mix of cube and tree.  This in a box of
thousands of nodes.</p>
<p>This type of layout would accommodate web scale without needing rows and rows of rack cabinets.</p>
<p>The external interfaces for web requests and replies are no big deal
after this, since the intra-cluster traffic is orders of magnitude
higher than the result set traffic.  After all, the end user does not
want dumps of the database but highly refined and ranked results.</p>
<h3>Software </h3>
<p>We have previously talked about dynamic partitions a la Google
Bigtable or Amazon Dynamo.  These techniques are entirely fine and
will serve for the universal knowledge store.  </p>
<p>But what about query logic?  OK, having a consistent map of partitions
shared over tens of thousands of nodes is entirely possible.  So is
replication and logic for using a spatially closer partition when
multiple copies are know to exist.  These things take some programming
but there is nothing really new about them.  These are a direct straightforward extension of what we do for clustering right now. </p>
<p>But look to windward.  How to run complex queries and inference on the
platform outlined above?  There are some features of RDF querying like
same-as that can be easily parallelized, backward-chaining style: Just
proceed with the value at hand and initiate the lookup of synonyms and
let them get processed when they become available.  Same for subclass
and sub-property.  We already do this, but could do it with more
parallelism.</p>
<p>No matter what advances in architecture take place, I do not see a
world where every user materializes the entailment of their own
same-as-es and rules over a web scale data set.  So, backward chaining
approaches to inference must develop.  Luckily, what most queries need
is simple.  A rule-oriented language, like Prolog without cut will
parallelize well enough.  Some degree of memoization may be
appropriate for cutting down on re-proving the same thing over and
over.  Memoization over a cluster is a problem though, since this
involves messages.  I should say that one should not go looking for
pre-proven things beyond the node at hand and that computation should
not spread too quickly or too promiscuously so as not to make long
message paths.  We must remember that a totally even round trip time
on a large cluster just will not happen.</p>
<p>Query planning on any system critically depends on correct ballpark
guesses on cardinality.  If predicates are amplified with transitivity
and same-as at run time, the cardinality guessing becomes harder.
This can kill any plan no matter the hardware.  Probably, an executing
query must be annotated with the underlying cardinality assumptions.
If these prove radically false, the execution may abort and a new plan
be made to better match what was found out.  This bears some looking into.  </p>
<p>There are some network algorithms like shortest path, traveling
salesman and similar that probably deserve a special operator in the
query language.  These can benefit from parallelization and a
sequential implementation running on a cluster with latency will be a
disaster.  Expressing the message flow in a rule language is not
really simple and pretty much no programmer will either appreciate the necessity
or go to the trouble.  Therefore such things should likely be offered by the platform and made by the few people who understand such matters.</p>
<p>For forward chaining, it seems that any results should generally go
into their own graph so as not to pollute the base data.  This graph,
supposing it is small enough, can have different partitioning from
the large base data set.  If the data comes from fa