Hi,
I'm trying to figure out, whether input bindings for CompositeProcesses and AtomicProcesses in OWL-S can be defined externally.
Example
The OWL-S CompositeProcess has the rdf:ID "CompositeProcess
". The two OWL-S AtomicProcesses are identified by "AtomicProcess_1
" and "AtomicProcess_2
" respectively. Each OWL-S Process has one input parameter and one output parameter. The binding of input and output parameters across OWL-S Processes is as follows:
Input_3
fromCompositeProcess
is bound toInput_1
fromAtomicProcess_1
;Output_1
fromAtomicProcess_1
is bound toInput_2
fromAtomicProcess_2
;Output_2
fromAtomicProcess_2
is bound toOutput_3
fromCompositeProcess
.
Here's the code:
<?xml version="1.0"?>
<rdf:RDF xmlns:service="http://www.daml.org/services/owl-s/1.2/Service.owl#" xmlns:swrl="http://www.w3.org/2003/11/swrl#" xmlns:time="http://www.isi.edu/~pan/damltime/time-entry.owl#" xmlns:list="http://www.daml.org/services/owl-s/1.2/generic/ObjectList.owl#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:owl="http://www.w3.org/2002/07/owl#" xmlns:expr="http://www.daml.org/services/owl-s/1.2/generic/Expression.owl#" xmlns="http://example.com/my.owl#" xmlns:swrlb="http://www.w3.org/2003/11/swrlb#" xmlns:profile="http://www.daml.org/services/owl-s/1.2/Profile.owl#" xmlns:process="http://www.daml.org/services/owl-s/1.2/Process.owl#" xmlns:grounding="http://www.daml.org/services/owl-s/1.2/Grounding.owl#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:xsd="http://www.w3.org/2001/XMLSchema#" xml:base="http://example.com/my.owl">
<owl:Ontology rdf:about="">
<owl:imports rdf:resource="http://www.w3.org/2003/11/swrl"/>
<owl:imports rdf:resource="http://www.daml.org/services/owl-s/1.2/Grounding.owl"/>
<owl:imports rdf:resource="http://www.daml.org/services/owl-s/1.2/Profile.owl"/>
<owl:imports rdf:resource="http://www.w3.org/2003/11/swrlb"/>
</owl:Ontology>
<owl:Class rdf:ID="Class_1"/>
<process:CompositeProcess rdf:ID="CompositeProcess">
<process:hasInput>
<process:Input rdf:ID="Input_3">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Input>
</process:hasInput>
<process:hasOutput>
<process:Output rdf:ID="Output_3">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Output>
</process:hasOutput>
<process:hasResult>
<process:Result rdf:ID="Result_3">
<process:withOutput>
<process:OutputBinding>
<process:valueSource>
<process:ValueOf rdf:ID="ValueOf_Output_2">
<process:theVar rdf:resource="#Output_2"/>
<process:fromProcess rdf:resource="#Perform_2"/>
</process:ValueOf>
</process:valueSource>
<process:toParam rdf:resource="#Output3"/>
</process:OutputBinding>
</process:withOutput>
<process:inCondition rdf:resource="http://www.daml.org/services/owl-s/1.2/generic/Expression.owl#AlwaysTrue"/>
</process:Result>
</process:hasResult>
<process:composedOf>
<process:Sequence>
<process:components>
<process:ControlConstructList>
<list:first rdf:resource="#Perform_1"/>
<list:rest>
<process:ControlConstructList>
<list:first rdf:resource="#Perform_2"/>
<list:rest rdf:resource="http://www.daml.org/services/owl-s/1.2/generic/ObjectList.owl#nil"/>
</process:ControlConstructList>
</list:rest>
</process:ControlConstructList>
</process:components>
</process:Sequence>
</process:composedOf>
</process:CompositeProcess>
<process:Perform rdf:ID="Perform_1">
<process:process>
<process:AtomicProcess rdf:ID="AtomicProcess_1">
<process:hasInput>
<process:Input rdf:ID="Input_1">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Input>
</process:hasInput>
<process:hasOutput>
<process:Output rdf:ID="Output_1">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Output>
</process:hasOutput>
</process:AtomicProcess>
</process:process>
<process:hasDataFrom>
<process:InputBinding>
<process:toParam rdf:resource="#Input_1"/>
<process:valueSource>
<process:ValueOf rdf:ID="ValueOf_Input_3">
<process:theVar rdf:resource="#Input_3"/>
<process:fromProcess rdf:resource="http://www.daml.org/services/owl-s/1.2/Process.owl#TheParentPerform"/>
</process:ValueOf>
</process:valueSource>
</process:InputBinding>
</process:hasDataFrom>
</process:Perform>
<process:Perform rdf:ID="Perform_2">
<process:process>
<process:AtomicProcess rdf:ID="AtomicProcess_2">
<process:hasInput>
<process:Input rdf:ID="Input_2">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Input>
</process:hasInput>
<process:hasOutput>
<process:Output rdf:ID="Output_2">
<process:parameterType rdf:datatype="http://www.w3.org/2001/XMLSchema#anyURI">http://example.com/my.owl#Class_1</process:parameterType>
</process:Output>
</process:hasOutput>
</process:AtomicProcess>
</process:process>
<process:hasDataFrom>
<process:InputBinding>
<process:toParam rdf:resource="#Input_2"/>
<process:valueSource>
<process:ValueOf rdf:ID="ValueOf_Output_1">
<process:theVar rdf:resource="#Output_1"/>
<process:fromProcess rdf:resource="#Perform_1"/>
</process:ValueOf>
</process:valueSource>
</process:InputBinding>
</process:hasDataFrom>
</process:Perform>
</rdf:RDF>
Problem
Now my problem is that the input binding from Input_3
to Input_1
is defined inside AtomicProcess_1
.
Is it possible to define this binding outside of AtomicProcess_1
, e.g., in CompositeProcess
?
I want to avoid that AtomicProcess_1
needs to have knowledge about the composition. Ideally, I would want to define AtomicProcess_1
in a separate file and than define multiple CompositeProcesses that use AtomicProcess_1
in different contexts and with different input bindings.
The same goes for the input binding from Output_1
to Input_2
.
Can this binding be defined externally?
Or is OWL-S the wrong language for my needs?
Thanks, MyKey_