OpenProv
The following files are available:
This is required for specifications that contain normative material.
The following namespaces prefixes are used throughout this document. Namespace
prefix namespace IRI definition prov http://www.w3.org/ns/prov# The PROV namespace [[PROV-DM]] openprov https://openprovenance.org/ns/openprov# The OpenProv namespace defined by this specification provext https://openprovenance.org/ns/provext# Extension namespace for PROV used in the [[PROV-JSONLD]] specification xsd http://www.w3.org/2000/10/XMLSchema# XML Schema Namespace [[XMLSCHEMA11-2]]] rdf http://www.w3.org/1999/02/22-rdf-syntax-ns# The RDF namespace [[RDF-CONCEPTS]] (others) (various) All other namespace prefixes are used in examples only.
In particular, IRIs starting with "http://example.com" represent some application-dependent IRI [[RFC3987]]
In this section, we provide details about OpenProv Ontology ... .
The ontology is identified by https://openprovenance.org/ns/openprov#; its terms are in the
namespace https://openprovenance.org/ns/openprov#, prefix openprov.
The vocabulary the OpenProvenance template library and ProvToolbox use in provenance documents beyond PROV-DM and provext: the statements a summarising relation was folded from, the roles of the parties to a change of collection, and the kinds of activity and derivation that change a collection. Distinct from provext, the minimal extension PROV-JSONLD needs for its regular JSON shape, whose classes this vocabulary builds on.
The ontology imports https://openprovenance.org/ns/provext#.
Each property is declared as owl:ObjectProperty; it is optional on the
relation named by its domain and points at a statement that relation summarises.
On prov:Attribution and provext:Membership
| rdfs:label | had activity |
|---|---|
| rdfs:comment | The activity the relation arose from: for an attribution, the activity that generated, invalidated or derived the entity while the agent was associated with it; for a membership, the activity that placed the member in the collection. A sub-property of prov:hadActivity, whose domain PROV-O states as prov:Influence and, more precisely, as the union of Delegation, Derivation, End and Start; an attribution or membership carrying this property is therefore entailed to be an Influence, and, under the precise domain, a member of that union, which PROV-O declares nothing to contradict. |
| rdfs:subPropertyOf | prov:hadActivity |
| rdfs:domain | prov:Attribution ∪ provext:Membership |
| rdfs:range | prov:Activity |
On prov:Attribution
| rdfs:label | had agent derivation |
|---|---|
| rdfs:comment | The derivation of the agent, from its earlier version, by the activity the attribution arose from. |
| rdfs:domain | prov:Attribution |
| rdfs:range | prov:Derivation |
| rdfs:label | had association |
|---|---|
| rdfs:comment | The association of the agent with the activity the attribution arose from. |
| rdfs:domain | prov:Attribution |
| rdfs:range | prov:Association |
| rdfs:label | had entity derivation |
|---|---|
| rdfs:comment | The derivation of the attributed entity, from its earlier version, by the activity the attribution arose from. |
| rdfs:domain | prov:Attribution |
| rdfs:range | prov:Derivation |
| rdfs:label | had invalidation |
|---|---|
| rdfs:comment | The invalidation of the attributed entity by the activity the attribution arose from. |
| rdfs:domain | prov:Attribution |
| rdfs:range | prov:Invalidation |
On provext:Membership
| rdfs:label | had collection generation |
|---|---|
| rdfs:comment | The generation of the collection by the activity the membership arose from. |
| rdfs:domain | provext:Membership |
| rdfs:range | prov:Generation |
| rdfs:label | had item generation |
|---|---|
| rdfs:comment | The generation of the member by the activity the membership arose from. |
| rdfs:domain | provext:Membership |
| rdfs:range | prov:Generation |
On provext:Specialization
| rdfs:label | had derivation |
|---|---|
| rdfs:comment | The derivation of the specific entity from the entity the specialization arose from. |
| rdfs:domain | provext:Specialization |
| rdfs:range | prov:Derivation |
| rdfs:label | had previous entity |
|---|---|
| rdfs:comment | The previous entity, from which the specific entity was derived, itself a specialization of the same general entity. Named previous, not entity, beside the specific and general entities of the specialization. |
| rdfs:domain | provext:Specialization |
| rdfs:range | prov:Entity |
| rdfs:label | had specialization |
|---|---|
| rdfs:comment | The specialization, of the entity the specific entity was derived from, to the same general entity. |
| rdfs:domain | provext:Specialization |
| rdfs:range | provext:Specialization |
On prov:Communication
| rdfs:label | had entity |
|---|---|
| rdfs:comment | The entity a communication arose from: generated by the informant activity and used by the informed one. The counterpart, for a communication, of the activity a derivation arose from, prov:hadActivity. |
| rdfs:domain | prov:Communication |
| rdfs:range | prov:Entity |
On prov:Attribution and provext:Membership and prov:Communication and prov:Start and prov:End
| rdfs:label | had generation |
|---|---|
| rdfs:comment | For an attribution, the generation of the attributed entity by the activity it arose from; for a membership, the generation of the collection by that activity; for a communication, the generation, by the informant, of the entity the informed activity used; for a start or an end, the generation of the trigger entity by the starter or ender activity. |
| rdfs:domain | prov:Attribution ∪ provext:Membership ∪ prov:Communication ∪ prov:Start ∪ prov:End |
| rdfs:range | prov:Generation |
On provext:Membership and prov:Communication
| rdfs:label | had usage |
|---|---|
| rdfs:comment | For a membership, the usage of the member by the activity the membership arose from; for a communication, the usage, by the informed activity, of the entity the informant generated. |
| rdfs:domain | provext:Membership ∪ prov:Communication |
| rdfs:range | prov:Usage |
Each role is an individual of type prov:Role, for use as the
prov:role of a usage or generation.
| rdfs:label | as collection |
|---|---|
| rdfs:comment | The role of a collection in the usage or generation by an activity that inserts into it or removes from it. |
| rdf:type | prov:Role |
| rdfs:label | as entity |
|---|---|
| rdfs:comment | The role of the entity an activity acts upon, when no more specific role applies. |
| rdf:type | prov:Role |
| rdfs:label | as item |
|---|---|
| rdfs:comment | The role of the item an activity takes in and hands on, as in an assignment or a handover. |
| rdf:type | prov:Role |
| rdfs:label | as member |
|---|---|
| rdfs:comment | The role of a member in the usage or generation by an activity that inserts it into, or removes it from, a collection. |
| rdf:type | prov:Role |
Each type is declared as owl:Class, for use as a prov:type.
| rdfs:label | Inserting element |
|---|---|
| rdfs:comment | The membership that an insertion establishes, alongside prov:Derivation; used by ProvToolbox's collection scenarios. |
| rdfs:label | Inserting into: collection |
|---|---|
| rdfs:comment | The derivation of the new collection from the old one by an insertion. |
| rdfs:subClassOf | prov:Derivation |
| rdfs:label | Inserting into: item |
|---|---|
| rdfs:comment | The derivation of the inserted item, as it is in the collection, from the item that was inserted. |
| rdfs:subClassOf | prov:Derivation |
| rdfs:label | Inserting item into collection |
|---|---|
| rdfs:comment | The insertion of an item into a collection: the type of the activity that uses the collection and the item and generates the new collection, and of the derivations it accounts for. |
| rdfs:label | Removing element |
|---|---|
| rdfs:comment | The derivation of the collection, as it is once the element is removed, from the element that was removed. |
| rdfs:subClassOf | prov:Derivation |
| rdfs:label | Removing element from collection |
|---|---|
| rdfs:comment | The removal of an element from a collection: the type of the activity that uses the collection and generates the new one, and of the derivations it accounts for. |
In this section, we provide a description of the JSON-LD context [PROV-JSONLD]... .
The context builds on https://openprovenance.org/prov-jsonld/context.jsonld.
The context declares @version 1.1.
It declares the following prefixes.
| prefix | namespace IRI |
|---|---|
openprov | https://openprovenance.org/ns/openprov# |
Each of the following keys names a type of relation and carries a scoped context: the keys it lists are defined only inside an object of that type; a key mapped as a property gives the IRI as predicate, a reverse property as the predicate pointing back at the object.
Attributionstands for prov:Attribution| key | IRI | mapping | @type |
|---|---|---|---|
entity | prov:qualifiedAttribution | reverse property | @id |
activity | openprov:hadActivity | property | @id |
association | openprov:hadAssociation | property | @id |
generation | openprov:hadGeneration | property | @id |
invalidation | openprov:hadInvalidation | property | @id |
entityDerivation | openprov:hadEntityDerivation | property | @id |
agentDerivation | openprov:hadAgentDerivation | property | @id |
Membershipstands for provext:Membership| key | IRI | mapping | @type |
|---|---|---|---|
collection | provext:qualifiedMembership | reverse property | @id |
entity | provext:member | property | @id |
activity | openprov:hadActivity | property | @id |
generation | openprov:hadGeneration | property | @id |
usage | openprov:hadUsage | property | @id |
collectionGeneration | openprov:hadCollectionGeneration | property | @id |
itemGeneration | openprov:hadItemGeneration | property | @id |
Specializationstands for provext:Specialization| key | IRI | mapping | @type |
|---|---|---|---|
specificEntity | provext:qualifiedSpecialization | reverse property | @id |
generalEntity | provext:generalEntity | property | @id |
previousEntity | openprov:hadPreviousEntity | property | @id |
derivation | openprov:hadDerivation | property | @id |
specialization | openprov:hadSpecialization | property | @id |
Communicationstands for prov:Communication| key | IRI | mapping | @type |
|---|---|---|---|
informed | prov:qualifiedCommunication | reverse property | @id |
informant | prov:activity | property | @id |
entity | openprov:hadEntity | property | @id |
generation | openprov:hadGeneration | property | @id |
usage | openprov:hadUsage | property | @id |
Startstands for prov:Start| key | IRI | mapping | @type |
|---|---|---|---|
activity | prov:qualifiedStart | reverse property | @id |
trigger | prov:entity | property | @id |
starter | prov:hadActivity | property | @id |
time | prov:atTime | property | xsd:dateTime |
generation | openprov:hadGeneration | property | @id |
Endstands for prov:End| key | IRI | mapping | @type |
|---|---|---|---|
activity | prov:qualifiedEnd | reverse property | @id |
trigger | prov:entity | property | @id |
ender | prov:hadActivity | property | @id |
time | prov:atTime | property | xsd:dateTime |
generation | openprov:hadGeneration | property | @id |
{
"@context": [
"https://openprovenance.org/prov-jsonld/context.jsonld",
{
"@version": 1.1,
"openprov": "https://openprovenance.org/ns/openprov#",
"Attribution": {
"@id": "prov:Attribution",
"@context": {
"entity": { "@reverse": "prov:qualifiedAttribution", "@type": "@id" },
"activity": { "@id": "openprov:hadActivity", "@type": "@id" },
"association": { "@id": "openprov:hadAssociation", "@type": "@id" },
"generation": { "@id": "openprov:hadGeneration", "@type": "@id" },
"invalidation": { "@id": "openprov:hadInvalidation", "@type": "@id" },
"entityDerivation": { "@id": "openprov:hadEntityDerivation", "@type": "@id" },
"agentDerivation": { "@id": "openprov:hadAgentDerivation", "@type": "@id" }
}
},
"Membership": {
"@id": "provext:Membership",
"@context": {
"collection": { "@reverse": "provext:qualifiedMembership", "@type": "@id" },
"entity": { "@id": "provext:member", "@type": "@id" },
"activity": { "@id": "openprov:hadActivity", "@type": "@id" },
"generation": { "@id": "openprov:hadGeneration", "@type": "@id" },
"usage": { "@id": "openprov:hadUsage", "@type": "@id" },
"collectionGeneration": { "@id": "openprov:hadCollectionGeneration", "@type": "@id" },
"itemGeneration": { "@id": "openprov:hadItemGeneration", "@type": "@id" }
}
},
"Specialization": {
"@id": "provext:Specialization",
"@context": {
"specificEntity": { "@reverse": "provext:qualifiedSpecialization", "@type": "@id" },
"generalEntity": { "@id": "provext:generalEntity", "@type": "@id" },
"previousEntity": { "@id": "openprov:hadPreviousEntity", "@type": "@id" },
"derivation": { "@id": "openprov:hadDerivation", "@type": "@id" },
"specialization": { "@id": "openprov:hadSpecialization", "@type": "@id" }
}
},
"Communication": {
"@id": "prov:Communication",
"@context": {
"informed": { "@reverse": "prov:qualifiedCommunication", "@type": "@id" },
"informant": { "@id": "prov:activity", "@type": "@id" },
"entity": { "@id": "openprov:hadEntity", "@type": "@id" },
"generation": { "@id": "openprov:hadGeneration", "@type": "@id" },
"usage": { "@id": "openprov:hadUsage", "@type": "@id" }
}
},
"Start": {
"@id": "prov:Start",
"@context": {
"activity": { "@reverse": "prov:qualifiedStart", "@type": "@id" },
"trigger": { "@id": "prov:entity", "@type": "@id" },
"starter": { "@id": "prov:hadActivity", "@type": "@id" },
"time": { "@id": "prov:atTime", "@type": "xsd:dateTime" },
"generation": { "@id": "openprov:hadGeneration", "@type": "@id" }
}
},
"End": {
"@id": "prov:End",
"@context": {
"activity": { "@reverse": "prov:qualifiedEnd", "@type": "@id" },
"trigger": { "@id": "prov:entity", "@type": "@id" },
"ender": { "@id": "prov:hadActivity", "@type": "@id" },
"time": { "@id": "prov:atTime", "@type": "xsd:dateTime" },
"generation": { "@id": "openprov:hadGeneration", "@type": "@id" }
}
}
}
]
}
The PROV-JSONLD schema [PROV-JSONLD] closes every relation to the properties it names and to
prefixed attributes, so a document using the terms above does not validate against it. The OpenProv
schema, https://openprovenance.org/ns/openprov-schema.json,
extends the PROV-JSONLD schema, https://openprovenance.org/prov-jsonld/schema.json,
by reference: every definition that does not change is a $ref into the PROV-JSONLD
schema, and only what changes is restated: the relations the context scopes terms to, each the
PROV-JSONLD definition plus one property per term, a qualified name or an array of them
(QualifiedName+) since the terms are @type: @id; and the chain from a
document to its statements (Document, Bundle, StatementOrBundle,
Statement), which otherwise would route a relation to the PROV-JSONLD definition of it.
A validator must therefore resolve the PROV-JSONLD schema, from its URL or a local copy:
ajv validate -s openprov-schema.json -r schema.json -d document.jsonld. The schema is
generated from the two files it extends, by script/schema-extend.py.
In this section, we provide a description of how PROV-N supports the OpenProv Extension .