GraphSPARQL
GraphSPARQL copied to clipboard
Documentation on configuraiton
Hi.
Do you have some documentation on how to setup the configuration file? I am looking at your examples but I don't quite understand the setup.
Thanks.
So far the only documentation is in the source and the comments in the examples. PRs are of course always welcome. If I find the time I'll also consider extending the configuration section of the README myself as well.
Setup in general depends on what your schema looks like, or if there even is one. As the program allows for different data sources and a very flexible mapping between GraphQL and RDF, knowledge of said technologies and OWL is a prerequisite to handcraft your own schema.
If you have an OWL schema already, have a look at the sample config.json
file. Change the "EndpointUri"
, "Name"
and "Prefixes"
of the "DataSources"
section to match your SPARQL endpoint, remove the "Definitions"
section containing "Provider": "inline"
, and update "Uri"
and "Location"
to match your OWL schema.
Thanks. I think the part that's most unclear is how to define the schema. Is the graphql schema automatic inferred through the RDF via the SPARQL endpoint?
On Thu, Mar 31, 2022, 2:52 PM Manuel Meitinger @.***> wrote:
So far the only documentation is in the source and the comments in the examples. PRs are of course always welcome. If I find the time I'll also consider extending the configuration section of the README myself as well.
Setup in general depends on what your schema looks like, or if there even is one. As the program allows for different data sources and a very flexible mapping between GraphQL and RDF, knowledge of said technologies and OWL is a prerequisite to handcraft your own schema.
If you have an OWL schema already, have a look at the sample config.json file. Change the "EndpointUri", "Name" and "Prefixes" of the "DataSources" section to match your SPARQL endpoint, remove the "Definitions" section containing "Provider": "inline", and update "Uri" and "Location" to match your OWL schema.
— Reply to this email directly, view it on GitHub https://github.com/Meitinger/GraphSPARQL/issues/2#issuecomment-1085035955, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACN3JAWC7JZ4B5QJTPADPGLVCX673ANCNFSM5SDIINEQ . You are receiving this because you authored the thread.Message ID: @.***>
The schema can be automatically inferred using an OWL file, either stored locally or on the web. Note the dbpedia.owl
file in the example
folder, and how it is referenced in config.json
.
This is an impressive implementation! Probably one of the best I've evaluated so far. My ontology is based on RDFS and some lightweight OWL. Is there a way to declare the Schema?
Have you considered a schema that is inferred based on SHACL? I will see if my team can contribute towards this.
Thanks again for the quick response.
On Fri, Apr 1, 2022 at 1:55 AM Manuel Meitinger @.***> wrote:
The schema can be automatically inferred using an OWL file, either stored locally or on the web. Note the dbpedia.owl https://github.com/Meitinger/GraphSPARQL/blob/main/example/dbpedia.owl file in the example https://github.com/Meitinger/GraphSPARQL/tree/main/example folder, and how it is referenced in config.json https://github.com/Meitinger/GraphSPARQL/blob/main/example/config.json.
— Reply to this email directly, view it on GitHub https://github.com/Meitinger/GraphSPARQL/issues/2#issuecomment-1085501555, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACN3JAU33RRZGKZCPE437RDVC2MUZANCNFSM5SDIINEQ . You are receiving this because you authored the thread.Message ID: @.***>
Thank you, although it does have it's limitations (due to type inferencing) when large amounts of top-level objects are queried without a filter.
RDFS is supported as well, have a look at Rdf.cs to see what RDFS/OWL constructs can be harvested.
SHACL would definitely make a good source for schema harvesting. If you'd like to contribute, have a look at the existing Providers
. They all implement ISchemaProvider.FillSchema(Schema schema)
. The aforementioned RDF provider can serve as a template for a SHACL harvester.
To register a schema provider, add it to SchemaProviderConfiguration.KnownTypes
in Providers.cs.