Please avoid RDF/XML [was Re: RDF/XML syntax for quads]

On 06/09/2016 02:20 PM, Martynas Jusevičius wrote:
> Honestly I don't understand why RDF/XML is getting such a bad rap :)

Key reasons:

  1. Other (more modern) RDF serializations are far more
human friendly, such as Turtle or even JSON-LD.

  2. RDF/XML does not play well with standard XML tooling,
such as XSLT, XML Schema or RelaxNG.

  3. RDF/XML misleads people into thinking that RDF is a
dialect of XML, and it is not.

As Kingsley stated on 3 September 2015:
 > The problem with RDF/XML is that it had an exalted position
 > in the Semantic Web realm for way too long. To this very day,
 > many of us are still trying to get folks to understand that
 > RDF is neither a format nor a dialect of XML.

I too have spent too many painful hours coaching XML ninjas
who were misled in exactly that way, and were performing all
sorts of unnatural acts in XSLT in ultimately doomed efforts
to process RDF/XML as though it were "regular" XML.

I don't mean to disparage RDF/XML.  RDF/XML was the best that
we had when it was created.  But we have much better serializations
for RDF now, such as Turtle/TriG and JSON-LD.

> Sure, the spec could have been better with fewer variations, but if
> you don't do nesting and keep descriptions "flat", the output is
> perfectly predictable. That is the default Jena output and we have
> been transforming it for years.

Then you are using a particular, restricted dialect of RDF/XML that 
happens to be produced by Jena -- not RDF/XML in general.

David Booth

>
> It is a convenient XML structure when related stuff is grouped under a
> parent element, such as properties of a resource, or resources of a
> graph. RDF/XML can provide that, TriX and SPARQL XML results cannot.
>
> On Thu, Jun 9, 2016 at 8:06 PM, David Booth <david@dbooth.org> wrote:
>> On 06/09/2016 11:44 AM, Martynas Jusevičius wrote:
>>>
>>> Hey,
>>>
>>> we have a use case where we need an RDF format in XML syntax that
>>> 1. supports named graphs
>>> 2. has a convenient structure for XSLT transformations
>>>
>>> RDF/XML fails at #1, TriX fails at #2.
>>>
>>> I suggest extending RDF/XML with a concept of named graph,
>>
>>
>> Please don't.  The more we can get away from RDF/XML the better.
>>
>> How about using the W3C standard SPARQL 1.1 XML results format, with quads:
>> subject, predicate, object and graph?
>> https://www.w3.org/TR/rdf-sparql-XMLres/
>>
>> David Booth
>
>
>

Received on Thursday, 9 June 2016 19:29:38 UTC