Try to get it working locally - read and write a file to get it in th
format you want.
https://jena.apache.org/documentation/io/rdf-output.html#json-ld
and the example:
https://github.com/apache/jena/blob/master/jena-arq/src-examples/arq/examples/riot/ExJsonLD.java
It is a long path through Fuseki so its hard to see which code is doing
what.
Note: the json-ld writer is from a different project. Fuseki isn't doing
anything for JSON-LD except passing it to the writer with the same
information that is available with Turtle or any other syntax.
Andy
On 07/10/17 16:24, Laura Morales wrote:
Not talking about proposing Fuseki a context/frame. I'm OK with a
auto-generated context. But Fuseki is creating a new prefix for every URI (see
previous email). Rather than creating 100s of new prefixes, it would be more
useful if Fuseki would reuse the same PREFIXes that were already specified with
my query. To see what I mean, send a DESCRIBE query and compare the Turtle and
JSON-LD outputs. If my query was
PREFIX ex: <http://example.org/vocab/>
DESCRIBE ...
FROM ...
Turtle will return predicates such as
<ex:name> "My name"
then the data has a URI <ex:name> in it.
whereas JSON-LD will return
<name> "My name"
because it creates a new prefix (in the context) called
"name": "http://example.com/vocab/name"
I'm just asking that even the JSON-LD output uses the user defined PREFIXes as
does Turtle.
Makes sense? Please let me know if I wasn't clear.
Sent: Saturday, October 07, 2017 at 4:49 PM
From: [email protected]
To: [email protected]
Subject: Re: Change DESCRIBE @context
There's no way (as far as I know) right now to propose a particular context (or
other profile information) via HTTP when
accepting JSON-LD:
https://github.com/json-ld/json-ld.org/issues/491
Or is your expectation that Jena would somehow figure out to do what you want
unhinted? If you can define a very clear
and specific algorithm by which Jena could conservatively guess at the right
way to build a @context, it might be
implementable.
ajs6f