Comments inline...
On Mar 16, 2006, at 12:41 PM, Elias Torres wrote:
As you might already know I'm involved with W3C working group for
SPARQL
[1]. I met there Henry Story from Sun who is working on an OWL
Ontology
for Atom [2]. He is very interested in seeing his work made an
specification, but before we support him on that endeavor I would like
to test it first. An idea we had with Dan Connolly was to add a SPARQL
endpoint to Roller and use Henry's ontology to model queries
against the
Roller database.
Here's an example query: (return title and summary for all entries
written by John Doe).
PREFIX atom: <http://www.w3.org/2005/10/23/Atom#>
SELECT ?title ?summary
WHERE {
?feed atom:entry ?entry ;
atom:author [ atom:name "John Doe" ].
?entry atom:title [ atom:value ?title ] ;
atom:summary [ atom:value ?summary ] .
} LIMIT 20
I like the fact that you are querying against the Atom object model
and not the actual Roller table and column names.
For data that looks like this:
[] a :Feed, :Version;
:title [ :value "Example Feed";
:type "text/plain" ];
:link [ :href <http://example.org/>;
:rel iana:alternate ];
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:author [ :name "John Doe" ];
:id <urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6>;
:entry [ a :Entry, :Version;
:title [ :value "Atom-Powered Robots Run Amok";
:type "text/plain" ];
:link [ :href <http://example.org/2003/12/13/
atom03.html>;
:rel iana:alternate ];
:id <urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a>;
:updated "2003-12-13T18:30:02Z"^^xsd:dateTime;
:summary [ :value "some text";
:type "text/plain" ]
] .
More examples [6]
SPARQL defines a protocol [3] that allows GET requests to be submitted
with queries. And it just gets better, I have spec'd out a JSON output
for the SPARQL results [4]. This means that we could have a very open
way to query the Roller database and output JSON for Web 2.0
applications.
Can you give some examples of the types of applications that this
would enable?
I can do all of this without making a single change to the
Roller code or database, except for adding a servlet and a few jars
(jena) [5]. Jena is BSD license (is that ok for Apache projects). It
Yes, BSD is fine for Apache projects.
would be very interesting to test both the Atom+OWL and the SPARQL
query
language on a very popular dataset (JRoller, blogs.sun, etc). I
can do
this in the sandbox at first, but unless the /roller/sparql is being
hit, it should not be a big deal to the Roller codebase. However, I
wanted to get a feel for your thoughts on this one.
I think the sandbox is the right place to start.
- Dave