# GPS schema -- Jos De Roo

@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
@prefix owl: <http://www.w3.org/2002/07/owl#>.
@prefix log: <http://www.w3.org/2000/10/swap/log#>.
@prefix e: <http://eulersharp.sourceforge.net/2003/03swap/log-rules#>.
@prefix gps: <https://eyereasoner.github.io/eye/reasoning/gps/gps-schema#>.

### classes ###

gps:Action a rdfs:Class;
    rdfs:comment "class of state transition actions";
    rdfs:subClassOf rdfs:Resource.

gps:Actions a rdfs:Class;
    rdfs:comment "class of sequences of state transition actions";
    rdfs:subClassOf rdf:List;
    e:listType gps:Action.

gps:Comfort a rdfs:Class;
    rdfs:comment "class of state transition comforts";
    rdfs:subClassOf e:Number.

gps:Cost a rdfs:Class;
    rdfs:comment "class of state transition costs";
    rdfs:subClassOf e:Number.

gps:Description a rdfs:Class;
    rdfs:comment "class of state transition descriptions";
    rdfs:subClassOf e:Tuple;
    e:tupleTypes (gps:From gps:Transition gps:To gps:Action gps:Duration gps:Cost gps:Belief gps:Comfort).

gps:Duration a rdfs:Class;
    rdfs:comment "class of state transition durations";
    rdfs:subClassOf e:Number.

gps:FindPath a rdfs:Class;
    rdfs:comment "class of gps findpath arguments";
    rdfs:subClassOf e:Tuple;
    e:tupleTypes (gps:Goal gps:Actions gps:Duration gps:Cost gps:Belief gps:Comfort gps:Limits).

gps:ValidatePath a rdfs:Class;
    rdfs:comment "class of gps validatepath arguments";
    rdfs:subClassOf e:Tuple;
    e:tupleTypes (gps:Goal gps:Actions gps:Duration gps:Cost gps:Belief gps:Comfort gps:Limits).

gps:From a rdfs:Class;
    rdfs:comment "class of state transition origin states";
    rdfs:subClassOf log:Formula.

gps:Goal a rdfs:Class;
    rdfs:comment "class of gps goals";
    rdfs:subClassOf log:Formula.

gps:Limits a rdfs:Class;
    rdfs:comment "class of gps limits";
    rdfs:subClassOf e:Tuple;
    e:tupleTypes (gps:MaxDuration gps:MaxCost gps:MinBelief gps:MinComfort gps:MaxStagecount).

gps:Map a rdfs:Class;
    rdfs:comment "class of gps maps";
    rdfs:subClassOf rdfs:Resource.

gps:MaxCost a rdfs:Class;
    rdfs:comment "class of maximum cost limits";
    rdfs:subClassOf e:Number.

gps:MaxDuration a rdfs:Class;
    rdfs:comment "class of maximum duration limits";
    rdfs:subClassOf e:Number.

gps:MaxStagecount a rdfs:Class;
    rdfs:comment "class of maximum stagecount limits (a stage is a sequence of steps in the same map)";
    rdfs:subClassOf e:Number.

gps:MinBelief a rdfs:Class;
    rdfs:comment "class of minimum success rate limits";
    rdfs:subClassOf e:Number.

gps:MinComfort a rdfs:Class;
    rdfs:comment "class of minimum comfort limits";
    rdfs:subClassOf e:Number.

gps:Path a rdfs:Class;
    rdfs:comment "class of gps paths";
    rdfs:subClassOf e:Tuple;
    e:tupleTypes (gps:Actions gps:Duration gps:Cost gps:Belief gps:Comfort).

gps:Belief a rdfs:Class;
    rdfs:comment "class of state transition success rates";
    rdfs:subClassOf e:Number.

gps:To a rdfs:Class;
    rdfs:comment "class of state transition destination states";
    rdfs:subClassOf log:Formula.

gps:Transition a rdfs:Class;
    rdfs:comment "class of state transition in between states";
    rdfs:subClassOf log:Formula.

### properties ###

gps:description a rdf:Property;
    rdfs:comment "the state transition description";
    rdfs:domain gps:Map;
    rdfs:range gps:Description.

gps:findpath a rdf:Property, e:Component;
    rdfs:comment "the EYE component predicate to find a path in the state space from initial state to goal state";
    rdfs:comment "a reference implementation can be found at https://eyereasoner.github.io/eye/reasoning/gps/gps-plugin.n3";
    rdfs:domain e:Scope;
    rdfs:range gps:FindPath.
	
gps:validatepath a rdf:Property, e:Component;
    rdfs:comment "the EYE component predicate to validate a path in the state space from initial state to goal state";
    rdfs:domain e:Scope;
    rdfs:range gps:ValidatePath.	

gps:path a rdf:Property;
    rdfs:comment "the path in the state space from initial state to goal state";
    rdfs:domain rdfs:Resource;
    rdfs:range gps:Path.
