Skip to content

Commit

Permalink
improvements ot context and examples
Browse files Browse the repository at this point in the history
  • Loading branch information
rob-metalinkage committed May 28, 2024
1 parent be2b56f commit 0d224fb
Show file tree
Hide file tree
Showing 5 changed files with 38 additions and 12 deletions.
8 changes: 8 additions & 0 deletions _sources/context.jsonld
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,14 @@
"@id": "prov:hadActivity",
"@type": "@id"
},
"activity": {
"@id": "prov:activity",
"@type": "@id"
},
"agent": {
"@id": "prov:agent",
"@type": "@id"
},
"hadGeneration": {
"@id": "prov:hadGeneration",
"@type": "@id"
Expand Down
24 changes: 17 additions & 7 deletions _sources/examples.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
- title: Example Entities with Provenance Chains
content: |-
See panel to right - note that a more user friendly "collapsable" version is in development.
- title: Simple relationships
snippets:
- language: json
ref: examples/example.json
base-uri: http://www.example.com/exampleEntity/
ref: examples/simple-rel.json
base-uri: http://www.example.com/exampleEntities/

- title: Activity
content: |-
this is a simple activity referencing some relevant document
- title: Example Activity
snippets:
- language: json
# this is referenced from complete examples using a $ref pattern following JSON schema approach
Expand All @@ -16,4 +16,14 @@
# how to reference a schema from a different bblock?
schema-ref: "#/$defs/Activity"

- title: Provenance Chain
content: |-
DAG defined by an object list.
snippets:
- language: json
ref: examples/example.json
base-uri: http://www.example.com/exampleEntity/



6 changes: 3 additions & 3 deletions _sources/examples/example-activity.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
{
"provType": "Activity",
"id": "surveyreg-nz:DP-1-S2",
"id": "someActivity_1",
"endedAtTime": "2029-01-01T22:05:19+02:00",
"wasAssociatedWith": "linz-registered-surveyors:bc-3",
"wasAssociatedWith": "eg_agents:bc-3",
"used": {
"provType": "Entity",
"id": "Act3",
"wasAttributedTo": "icsm-jurisdictions:nz",
"wasAttributedTo": "eg_agents:Gov1",
"links": [
{
"href": "https://some.gov/linktoact/",
Expand Down
8 changes: 8 additions & 0 deletions _sources/examples/simple-rel.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"id": "Object2",
"wasDerivedFrom": "Object1"
}




4 changes: 2 additions & 2 deletions bblocks-config.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
identifier-prefix: ogc.ogc-utils.prov

name: JSON schema for W3C PROV model
abstract: Defines a graph structure based on an array of objects implementing PROV defined classes with object cross references
abstract: Defines a standardised JSON schema for PROV ontology elements - supporting a graph structure based on an array of objects implementing PROV defined classes with object cross references.
description: |
Provenance defined using the [W3C PROV-O model](https://www.w3.org/TR/prov-o/) is a DAG (non-cyclic graph) based on three main object types: Entity, Activity and Agent.
This repository defines a JSON schema and matching JSON-LD context for this model, using the canonical terminology used in the PROV ontology as element names.
It also defines a context for an optional schema property "has_provenance" that can be used to wrap a provenance graph as an array of such objects, to extend the prov:wasGeneratedBy (whose range is one or more Entity objects) with an explicit schema.
It also defines a context for an optional schema property "has_provenance" that can be used to wrap a provenance graph as an array of such objects, to extend the property prov:wasGeneratedBy (whose range is one or more Entity objects) with an explicit schema.
![](https://www.w3.org/TR/prov-o/diagrams/starting-points.svg)
Expand Down

0 comments on commit 0d224fb

Please sign in to comment.