Closed jamesamcl closed 7 months ago
Hi, I am trying to load RDF/XML files from UniProt and I'm hitting this error:
SourceError(RdfXmlError { kind: InvalidIri { iri: "", error: IriParseError { kind: NoScheme } } })
Here is a minimal example which reproduces the problem:
<?xml version='1.0' encoding='UTF-8'?> <rdf:RDF xmlns="http://purl.uniprot.org/core/" xmlns:owl="http://www.w3.org/2002/07/owl#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"> <owl:Ontology rdf:about=""> <owl:imports rdf:resource="http://purl.uniprot.org/core/"/> </owl:Ontology> </rdf:RDF>
Apparently the document IRI should be used as the base in this case. Here is the n3 representation if I parse it (as a local file) with rapper:
<file:///home/james/grebi/rust/keywords.rdf> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2002/07/owl#Ontology> . <file:///home/james/grebi/rust/keywords.rdf> <http://www.w3.org/2002/07/owl#imports> <http://purl.uniprot.org/core/> .
Parser accepts base field, to customise base uri.
base
Ah that makes sense! thank you
Hi, I am trying to load RDF/XML files from UniProt and I'm hitting this error:
Here is a minimal example which reproduces the problem:
Apparently the document IRI should be used as the base in this case. Here is the n3 representation if I parse it (as a local file) with rapper: