回答您的第一个问题:您正在寻找财产链。在 Protege 中,您可以说这works-in o is-part-of
是一个 subPropertyOf (Chain) works-in
,这将为您提供预期的推论
编辑:我做了以下实验:
a)根据您的描述创建通用本体(在曼彻斯特语法中):
Ontology: <http://www.semanticweb.org/o>
ObjectProperty: <http://www.semanticweb.org/o#works-in>
SubPropertyChain:
<http://www.semanticweb.org/o#works-in> o <http://www.semanticweb.org/o#is-part-of>
ObjectProperty: <http://www.semanticweb.org/o#is-part-of>
Domain:
<http://www.semanticweb.org/o#Department> or <http://www.semanticweb.org/o#Shop>
Range:
<http://www.semanticweb.org/o#Mall> or <http://www.semanticweb.org/o#Shop>
Class: <http://www.semanticweb.org/o#Shop>
Class: <http://www.semanticweb.org/o#Mall>
Class: <http://www.semanticweb.org/o#Department>
Class: <http://www.semanticweb.org/o#Person>
b) 将一些个体添加到该本体以检查推理。用 FaCT++ Protege 分类后显示 person1 与 mall1 通过works-in 关联。附加公理如下:
Individual: <http://www.semanticweb.org/o#shop1>
Types:
<http://www.semanticweb.org/o#Shop>
Facts:
<http://www.semanticweb.org/o#is-part-of> <http://www.semanticweb.org/o#mall1>
Individual: <http://www.semanticweb.org/o#mall1>
Types:
<http://www.semanticweb.org/o#Mall>
Individual: <http://www.semanticweb.org/o#person1>
Types:
<http://www.semanticweb.org/o#Person>
Facts:
<http://www.semanticweb.org/o#works-in> <http://www.semanticweb.org/o#shop1>
c) 添加公理说 Person 在 Shop 中工作,并且 Shop 是 Mall 的一部分到 a) 的本体。在这种情况下, Person 又是 WorksInMall 类的一部分,这表明考虑了属性链公理。其他公理是:
Class: <http://www.semanticweb.org/o#WorksInMall>
EquivalentTo:
<http://www.semanticweb.org/o#works-in> some <http://www.semanticweb.org/o#Mall>
Class: <http://www.semanticweb.org/o#Person>
SubClassOf:
<http://www.semanticweb.org/o#works-in> some <http://www.semanticweb.org/o#Shop>
Class: <http://www.semanticweb.org/o#Shop>
SubClassOf:
<http://www.semanticweb.org/o#is-part-of> some <http://www.semanticweb.org/o#Mall>