1

我已经开发了一个本体,我想在 protege 中添加以下 SWRL:

Divider_intersection(?node), is_extent_of(?node, ?s), builds(?s, ?l),Segment(?s),Lane(?l),detailed_partition(?d), builds(?l, ?d)-> is_divided_at(?d, ?node)

有了这个,我希望在来自detailed_pa​​rtition (?d) 的个体和被分类为divider_intersection 的节点之间添加一个对象属性is_divided_at,如果它是构建车道(?l) 的段(?s) 的范围然后构建详细的?分区(?d)。如此处所述,我正在寻找 NamedIndividuals,因此我认为 SWRL 应该可以完成这项工作。

进一步研究,我发现 Rolification ( 1 , 2 , 3 ) 作为一个可能的答案,但是我以前从未使用过它,但我做了以下链:

r_Divider_intersection o is_extent_of o r_Segment o builds o r_Lane o builds o r_detailed_partition

我仍然没有得到答案。知道有什么问题吗?

4

1 回答 1

1

您的方法有效,并且没有看到您的本体(您的链接需要权限,并且非现场链接无论如何都不是很有帮助),我们看不出您的特定构造为什么有效。从您的问题中跳出来的一件事是,看起来您的is_divided_at属性的参数(?d,?node)的顺序与属性链公理产生的顺序相反。无论如何,这是一个工作示例。

protege 中的截图

@prefix :      <urn:ex:#> .
@prefix ex:    <urn:ex:#> .
@prefix rdf:   <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix owl:   <http://www.w3.org/2002/07/owl#> .
@prefix xsd:   <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs:  <http://www.w3.org/2000/01/rdf-schema#> .

ex:isDividedAt  a               owl:ObjectProperty ;
        owl:propertyChainAxiom  ( ex:_DividerIntersection ex:isExtentOf ex:_Segment ex:builds ex:_Lane ex:builds ex:_DetailedPartition ) .

ex:Segment  a                owl:Class ;
        owl:equivalentClass  [ a               owl:Restriction ;
                               owl:hasSelf     true ;
                               owl:onProperty  ex:_Segment
                             ] .

ex:_DetailedPartition
        a       owl:ObjectProperty .

ex:DividerIntersection
        a                    owl:Class ;
        owl:equivalentClass  [ a               owl:Restriction ;
                               owl:hasSelf     true ;
                               owl:onProperty  ex:_DividerIntersection
                             ] .

ex:_Segment  a  owl:ObjectProperty .

ex:_Lane  a     owl:ObjectProperty .

ex:builds  a    owl:ObjectProperty .

ex:dividerIntersection0
        a              owl:NamedIndividual , ex:DividerIntersection ;
        ex:isExtentOf  ex:segment0 .

<urn:ex:>  a    owl:Ontology .

ex:detailedPartition0
        a       owl:NamedIndividual , ex:DetailedPartition .

ex:_DividerIntersection
        a       owl:ObjectProperty .

ex:segment0  a     owl:NamedIndividual , ex:Segment ;
        ex:builds  ex:lane0 .

ex:DetailedPartition  a      owl:Class ;
        owl:equivalentClass  [ a               owl:Restriction ;
                               owl:hasSelf     true ;
                               owl:onProperty  ex:_DetailedPartition
                             ] .

ex:isExtentOf  a  owl:ObjectProperty .

ex:lane0  a        owl:NamedIndividual , ex:Lane ;
        ex:builds  ex:detailedPartition0 .

ex:Lane  a                   owl:Class ;
        owl:equivalentClass  [ a               owl:Restriction ;
                               owl:hasSelf     true ;
                               owl:onProperty  ex:_Lane
                             ] .
于 2015-07-21T14:20:03.620 回答