[MOBY-dev] Printing shorthand BioMOBY RDF notation

Gary Schiltz gss at ncgr.org
Thu Mar 2 19:17:20 UTC 2006


If I submit the first example LSID ( 
urn:lsid:biomoby.org:servicetype:Retrieval) on the page, I get the 
following as RDF:

<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
    xmlns:serviceInstances="http://biomoby.org/RESOURCES/MOBY-S/ServiceInstances#"
    xmlns:moby="http://biomoby.org/RESOURCES/MOBY-S/Predicates#"
    xmlns:mobyObject="http://biomoby.org/RESOURCES/MOBY-S/Objects#"
    xmlns:mobyNamespace="http://biomoby.org/RESOURCES/MOBY-S/Namespaces#"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
    xmlns:mobyService="http://biomoby.org/RESOURCES/MOBY-S/Services#">
     <rdfs:Class rdf:about="http://biomoby.org/RESOURCES/MOBY-S/Services#Retrieval">
          <rdfs:comment xml:lang="en">The base retrieval type</rdfs:comment>
          <rdfs:subClassOf>
               <rdfs:Class rdf:about="http://biomoby.org/RESOURCES/MOBY-S/Services#Service"/>
          </rdfs:subClassOf>
          <rdfs:label xml:lang="en">Retrieval</rdfs:label>
     </rdfs:Class>
     <rdfs:Class rdf:about="http://biomoby.org/RESOURCES/MOBY-S/Services#Service">
          <rdfs:comment xml:lang="en">a base Service class, never instantiated</rdfs:comment>
          <rdfs:label xml:lang="en">Service</rdfs:label>
     </rdfs:Class>
</rdf:RDF>

I can then paste that RDF into the converter at 
http://www.semanticmoby.org/developer/dev-tools.jsp, select RDF/XML as 
input format and N3 as output format, press the Convert Graph button, 
and get the following N3:

@prefix mobyService:  <http://biomoby.org/RESOURCES/MOBY-S/Services#> .
@prefix mobyObject:  <http://biomoby.org/RESOURCES/MOBY-S/Objects#> .
@prefix mobyNamespace:  <http://biomoby.org/RESOURCES/MOBY-S/Namespaces#> .
@prefix serviceInstances:  <http://biomoby.org/RESOURCES/MOBY-S/ServiceInstances#> .
@prefix moby:    <http://biomoby.org/RESOURCES/MOBY-S/Predicates#> .
@prefix rdfs:    <http://www.w3.org/2000/01/rdf-schema#> .
@prefix rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

mobyService:Retrieval
      a       rdfs:Class ;
      rdfs:comment "The base retrieval type"@en ;
      rdfs:label "Retrieval"@en ;
      rdfs:subClassOf mobyService:Service .

mobyService:Service
      a       rdfs:Class ;
      rdfs:comment "a base Service class, never instantiated"@en ;
      rdfs:label "Service"@en .

Not many fewer lines, but the N3 is to my eyes more readable.

// Gary

Duncan Hull wrote:
> Hello
>
> Can anyone recommend any tools for printing shorthand notation of 
> BioMOBY RDF service descriptions, e.g. that output from 
> http://mobycentral.icapture.ubc.ca/LSID_resolver.html ?
>
> I was thinking of N3 [1] or something similar, but maybe someone on 
> moby-dev knows better?
>
> Fitting all that lovely RDF onto a sheet of A4 paper is a challenging 
> task...so I could use a shorthand notation.
>
> Duncan
>
> [1] http://infomesh.net/2001/cwm/ looks very old
>
>   



More information about the MOBY-dev mailing list