RDFLib / prez

Prez is a data-configurable Linked Data API framework that delivers profiles of Knowledge Graph data according to the Content Negotiation by Profile standard.
BSD 3-Clause "New" or "Revised" License
22 stars 8 forks source link

Demonstrate Framed JSON-LD #44

Closed nicholascar closed 3 days ago

nicholascar commented 2 years ago

Demonstrate Prez service Framed JSON-LD. The first such content will be for:

Implementation Questions:

@jamiefeiss @rob-metalinkage @avillar

recalcitrantsupplant commented 1 year ago

Have looked at using JSON-LD, To use in BE would require writing a JSON-LD context -> SPARQL mapping the way we currently have for SHACL -> SPARQL. This could work as an alternative to using the SHACL profiles. Another option would be to do the JSON-LD profiles on the frontend using a JS library.

rob-metalinkage commented 1 year ago

Having looked into this I've given up on a decent framing solution driven by a top-down model in the short term - and am working on the OGC building blocks approach - json schema snippets bound to JSON-LD contexts. You can see the spike solution here https://github.com/avillar/bblock-template (we are moving to an official OGC repo once we have completed more testing and documentation review) - or this one in development https://github.com/opengeospatial/ogcapi-sosa

Note this provide granular control over re-usable patterns, and avoids the potential for complex framing specifications to re-invent the wheel each time.

recalcitrantsupplant commented 3 days ago

There's not current plan to integrate framing. Having attempted this a few times the main issue I see is it would be difficult to use framing to replace SHACL for describing the CBD to retrieve - I think the intended use is a complete graph or document is the input and the framing acts on that.