# Shacl
```
@prefix dash: <http://datashapes.org/dash#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix schema: <http://schema.org/> .
@prefix sh: <http://www.w3.org/ns/shacl#> .
@prefix ex: <http://example.org/> .
@prefix traffic: <http://example.org/traffic#> .
ex:priority_to_right_shape a sh:NodeShape;
sh:targetClass ex:crossroad_observation;
sh:not [
sh:or (
[
sh:path ex:observation_results ;
sh:hasValue traffic:stop_sign1 ;
]
[
sh:path ex:observation_results ;
sh:hasValue traffic:traffic_light1 ;
])
].
ex:Robot_Motion_Path a sh:NodeShape;
sh:targetClass ex:Robot_Motion ;
sh:property [
sh:path ex:destination ;
sh:class ex:Suggested_Stop_Position ;
sh:minCount 1 ;
sh:maxCount 1 ;
].
ex:Suggested_Stop_Position_Choice a sh:NodeShape;
sh:targetClass ex:Suggested_Stop_Position ;
sh:property [
sh:path ex:ideal_stop_position ;
sh:class ex:stop_position ;
sh:minCount 1;
sh:maxCount 1;
sh:in (ex:Stop_Line_Specified_Position:ideal_area ex:CV_Suggested_Stop_Position:ideal_area);
sh:lessThan ex:CV_Suggested_Stop_Position;
sh:lessThan ex:Stop_Line_Specified_Position;
].
ex:Priority_To_Right_Motion_Strategy_Wait a sh:NodeShape;
sh:targetClass ex:Priority_To_Right_Motion_Strategy;
sh:property [
sh:path ex:traffic_rule ;
sh:class ex:Traffic_Rule ;
sh:minCount 1 ;
sh:maxCount 1 ;
sh:equals ex:Priority_to_Right ;
],
[
sh:path ex:Car_Perception;
sh:minLength 1;
],
[
sh:path ex:Car_Intention_Prediction;
sh:or (
[
sh:path ex:Intention;
sh:hasValue ex:Turn_Left;
]
[
sh:path ex:Intention;
sh:hasValue ex:Move_Forward;
]
)
].
```
knowledge graph
```json
{
"@context": {
"brick": "https://brickschema.org/schema/Brick#",
"csvw": "http://www.w3.org/ns/csvw#",
"dc": "http://purl.org/dc/elements/1.1/",
"dcam": "http://purl.org/dc/dcam/",
"dcat": "http://www.w3.org/ns/dcat#",
"dcmitype": "http://purl.org/dc/dcmitype/",
"dcterms": "http://purl.org/dc/terms/",
"doap": "http://usefulinc.com/ns/doap#",
"ex": "http://example.org/",
"foaf": "http://xmlns.com/foaf/0.1/",
"odrl": "http://www.w3.org/ns/odrl/2/",
"org": "http://www.w3.org/ns/org#",
"owl": "http://www.w3.org/2002/07/owl#",
"prof": "http://www.w3.org/ns/dx/prof/",
"prov": "http://www.w3.org/ns/prov#",
"qb": "http://purl.org/linked-data/cube#",
"rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#",
"rdfs": "http://www.w3.org/2000/01/rdf-schema#",
"schema": "https://schema.org/",
"sh": "http://www.w3.org/ns/shacl#",
"skos": "http://www.w3.org/2004/02/skos/core#",
"sosa": "http://www.w3.org/ns/sosa/",
"ssn": "http://www.w3.org/ns/ssn/",
"time": "http://www.w3.org/2006/time#",
"traffic": "http://example.org/traffic#",
"traffic_rule": "http://example.org/traffic-rule#",
"vann": "http://purl.org/vocab/vann/",
"void": "http://rdfs.org/ns/void#",
"xsd": "http://www.w3.org/2001/XMLSchema#"
},
"@graph": [
{
"@id": "ex:car1",
"ex:position": {
"@id": "ex:position1"
},
"ex:speed": {
"@id": "ex:speed1"
}
},
{
"@id": "traffic:stop_sign1",
"@type": "traffic:stop_sign",
"ex:crossroad": {
"@id": "ex:crossroad1"
}
},
{
"@id": "ex:area2",
"@type": "ex:stop_position"
},
{
"@id": "ex:Motion_Strategy1",
"@type": "ex:Motion_Strategy",
"ex:traversals": [
{
"@id": "ex:Relation1"
},
{
"@id": "ex:Relation2"
}
]
},
{
"@id": "ex:crossroad_observation1",
"@type": "ex:crossroad_observation",
"ex:crossroad": {
"@id": "ex:crossroad1"
},
"ex:observation_results": [
{
"@id": "traffic:stop_sign1"
},
{
"@id": "traffic:traffic_light1"
}
]
},
{
"@id": "ex:Car_Intention_Prediction",
"@type": "ex:Car_Intention_Prediction",
"ex:Blinker_Detection": {
"@id": "ex:Blinker_Detection1"
},
"ex:intention": {
"@id": "ex:turn_left"
}
},
{
"@id": "ex:area1",
"@type": "ex:stop_position"
},
{
"@id": "ex:Robot_Base_Motion_in_Cross1",
"@type": "ex:Robot_Base_Motion_in_Cross",
"ex:Robot": {
"@id": "ex:Robot_A"
},
"ex:Suggested_Time_Cost": 600,
"ex:crossroad": {
"@id": "ex:crossroad_A"
}
},
{
"@id": "ex:CV_Suggested_Stop_Position1",
"@type": "ex:CV_Suggested_Stop_Position",
"ex:Robot_Perception_System": {
"@id": "ex:Robot_Perception_System1"
}
},
{
"@id": "ex:Stop_Line_Specified_Position1",
"@type": "ex:Stop_Line_Specified_Position",
"ex:CV_Stop_Line_Specified_Position": {
"@id": "ex:area2"
},
"ex:Robot_Perception_System": {
"@id": "ex:Robot_Perception_System1"
}
},
{
"@id": "ex:Car_Perception_A",
"@type": "ex:Car_Perception",
"ex:Identified_Cars": {
"@id": "ex:car1"
},
"ex:on_the_right": {
"@id": "ex:on_the_right_A"
}
},
{
"@id": "traffic:traffic_light1",
"@type": "traffic:traffic_light",
"ex:crossroad": {
"@id": "ex:crossroad1"
}
}
]
}
```