Trouble Inferring Properties for Classes/Individuals in Protege 5/OWL

佐手、 提交于 2020-01-06 03:45:10

问题


I want to be able to infer which ingredients go well together given...their properties and which properties complement each other.

I have an ontology like,

owl:Thing
    Ingredient
        Kale
        Pear
    Taste
        Bitter
        Sweet

owl:topObjectProperty
    hasTaste
    tasteComplements
    goesWellWith

Individuals: (*would rather work with just classes)
    kale a Kale
    pear a Pear
    bitter a Bitter
    sweet a Sweet

I've asserted,

Kale subClassOf hasTaste some Bitter
Pear subClassOf hasTaste some Sweet
Bitter subClassOf tasteComplements some Sweet

tasteComplements a owl:SymmetricProperty
goesWellWith a owl:SymmetricProperty

And a general axiom:

(hasTaste some Bitter) SubClassOf: goesWellWith some (hasTaste some Sweet)

First of all, I'd like Protege to be able to infer that also Sweet tasteComplements some Bitter. Although I understand why symmetric properties in existential restrictions don't work that way. So I'll settle for

sweet tasteComplements bitter
bitter tasteComplements sweet

But surprisingly neither of these are inferred. I must manually specify one of them first, then the other is inferred.

More importantly I want to infer:

Kale goesWellWith some Pear
Pear goesWellWith some Kale

while failing in this, I'd at least like:

kale goesWellWith pear

But this is not inferred either. From my general axiom, it should be the case that since kale a Kale, there necessarily must be at least one triple:

kale hasTaste [b]    <!-- where [b] is of type Bitter -->

Therefore, we have should another triple too:

kale goesWellWith [y]

where

[y] hasTaste [s]   <!-- and [s] is of type Sweet --> 
[y] is pear        <!-- the only available option in this case -->
kale goesWellWith pear

How can I make these inferences happen between individuals as expected? Something between classes would be even better.*

More generally, I'd like to be able to assert:

if XXX tasteComplements YYY then:
    (hasTaste some XXX) SubClassOf: goesWellWith some (hasTaste some YYY)

Is there some sneaky way to achieve this with rolification like in this answer? (I'd rather avoid SWRL rules...)

* NOTE

I would rather infer triples between classes rather than individuals, although I know of no way to make this logically happen. Individuals feel like a laundry list/dump of every concept in my ingredients & properties taxonomy with no hierarchy -- redundant and impossible to keep organized. Ideally this taxonomy will provide an interface for someone to describe the characteristics of ingredients that complement each other.

来源:https://stackoverflow.com/questions/51683587/trouble-inferring-properties-for-classes-individuals-in-protege-5-owl

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!