pml mappings
authorJim McCusker <mccusj@rpi.edu>
Wed, 06 Jun 2012 13:47:33 -0400
changeset 3203 2f792ee1d903
parent 3201 e058b347b933
child 3204 b1a6e029a53c
pml mappings
examples/eg-29-pml-mappings/rdf/create/rdf/class_Association.ttl
examples/eg-29-pml-mappings/rdf/create/rdf/class_Communication.ttl
examples/eg-29-pml-mappings/rdf/create/rdf/class_Plan.ttl
examples/eg-29-pml-mappings/rdf/create/rdf/class_Role.ttl
examples/eg-29-pml-mappings/rdf/create/rdf/class_Source.ttl
examples/eg-29-pml-mappings/rdf/create/rdf/property_dictionary.ttl
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/class_Association.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/class_Association.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -2,8 +2,46 @@
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
+@prefix pmlp: <http://inference-web.org/2.0/pml-provenance.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+:illustrating
+    a prov:Activity; 
+    prov:wasAssociatedWith :derek, 
+                           :steve;
+    prov:qualifiedAssociation [
+        a prov:Association;
+        prov:agent   :derek;
+        prov:hadRole :illustrationist;
+    ];
+    prov:qualifiedAssociation [
+        a prov:Association;
+        prov:agent   :steve;
+        prov:hadRole :stylist;
+        prov:hadPlan :style-guide;
+        rdfs:comment "Steve helped Derek conform with the publisher's style guide."@en;
+    ];
+.
+
+:derek a pmlp:Person, pmlj:InferenceEngine .
+:steve a pmlp:Person, pmlj:InferenceEngine .
+
+:illustratonist a prov:Role .
+:stylist        a prov:Role .
+
+:style-guide a pml, prov:Entity .
+
+:illustrating 
+   a pmlj:InferenceStep;
+   pmlj:hasInferenceEngine :steve;
+   pmlj:hasInferenceRule :style-guide;
+   prov:qualifiedAssociation :steve-checking-style-guide;
+   rdfs:comment "Steve followed the publisher's style guide"@en;
+.
+
+:style-guide
+   a pmlj:InferenceRule, pmlp:Information;
+   rdfs:comment "Use blue graphs for positive spin, red for negative"@en;
+.
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/class_Communication.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/class_Communication.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -1,9 +1,32 @@
 @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
+@prefix pmlp: <http://inference-web.org/2.0/pml-provenance.owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+
+:writing-celebrity-gossip 
+   a pmlj:InferenceStep;
+   pmlj:hasInferenceEngine [ a pmlp:Person];
+   pmlj:hasSourceUsage [ 
+      a pmlj:SourceUsage; 
+      pmlp:hasSource [ a pmlp:Person;]
+   ];
+   pmlj:hasAntecedentList ([
+       a pmlj:NodeSet; 
+       pmlj:isConsequentOf :voicemail-interception
+   ]);
+   prov:atLocation :unknown-location;
+.
+
+:voicemail-interception a pmlj:InferenceStep;
+   pmlj:hasInferenceEngine [ a pmlp:Person];
+.
+
+:unknown-location 
+   a prov:Location;
+   rdfs:label "Location unknown"@en;
+.
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/class_Plan.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/class_Plan.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -2,8 +2,20 @@
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
+@prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+:illustrating 
+   a pmlj:InferenceStep;
+   pmlj:hasInferenceEngine :steve;
+   pmlj:hasInferenceRule :style-guide;
+   prov:qualifiedAssociation :steve-checking-style-guide;
+   rdfs:comment "Steve followed the publisher's style guide"@en;
+.
+
+:style-guide
+   a pmlj:InferenceRule, pmlp:Information;
+   rdfs:comment "Use blue graphs for positive spin, red for negative"@en;
+.
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/class_Role.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/class_Role.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -2,8 +2,9 @@
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
+@prefix pmlp: <http://inference-web.org/2.0/pml-provenance.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+# PML 2.0, as released, doesn't yet support roles.
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/class_Source.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/class_Source.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -1,9 +1,16 @@
 @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
+@prefix pmlp: <http://inference-web.org/2.0/pml-provenance.owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+:myPost 
+   a pmlp:Information;
+   pmlp:hasSource :donQuixote;
+.
+
+:donQuixote a pmlp:Document.
+
--- a/examples/eg-29-pml-mappings/rdf/create/rdf/property_dictionary.ttl	Wed Jun 06 19:28:02 2012 +0200
+++ b/examples/eg-29-pml-mappings/rdf/create/rdf/property_dictionary.ttl	Wed Jun 06 13:47:33 2012 -0400
@@ -1,9 +1,38 @@
 @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
 @prefix xsd:  <http://www.w3.org/2001/XMLSchema#> .
 @prefix owl:  <http://www.w3.org/2002/07/owl#> .
+@prefix pmlp: <http://inference-web.org/2.0/pml-provenance.owl#> .
 @prefix pmlj: <http://inference-web.org/2.0/pml-justification.owl#> .
 @prefix pmlt: <http://inference-web.org/2.0/pml-trust.owl#> .
 @prefix prov: <http://www.w3.org/ns/prov#> .
 @prefix :     <http://example.com/> .
 
-# TODO
+:e1 a pmlp:Information .
+
+:c  a prov:Mapping .
+
+:c1NS a pmlj:NodeSet;
+   pmlj:isConsequentOf [
+      a pmlj:InferenceStep;
+      pmlj:hasAntecedentList ([
+          a pmlj:NodeSet;
+          pmlj:hasConclusion :c1;
+      ]);
+      pmlj:hasInferenceRule prov:Insertion;
+   ];
+   pmlj:hasConclusion :c1;
+.
+   
+# This itself isn't mappable since Mapping only maps strings to strings.
+:c1 a prov:Mapping;
+   prov:derivedByInsertionFrom :c;
+   prov:qualifiedInsertion [ 
+      a prov:Insertion;
+      prov:dictionary :c;
+      prov:inserted [ 
+         a prov:KeyValuePair;
+         prov:key   "k1"^^xsd:string;
+         prov:value :e1;
+      ];
+   ]; 
+.