使用值列表为OWL数据类型属性限制建模 [英] Modelling OWL datatype property restrictions with a list of values

查看:105
本文介绍了使用值列表为OWL数据类型属性限制建模的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个名为ResponseInformation的类,该类具有一个名为 hasResponseType 的数据类型属性,该属性只能具有以下字符串值:"Accept","Decline"和"Provisional".

I have class called ResponseInformation that a has a datatype property called hasResponseType, which must have only the following string values: "Accept", "Decline" and "Provisional".

我知道我可以将此模型建模为一个名为ResponseType的类的一组个体,然后分别将其称为接受,拒绝和临时,以及一个owl:oneOf公理,该类声明类ResponseType完全等于其中一个"这组实例.但是,我意识到OWL 2支持值列表作为数据类型属性的范围.例如,我可以将以下内容指定为Protege中我的 hasResponseType 属性的范围:{"Accept","Decline","Provisional"}

I understand that I can model this as a set of individuals of a class called ResponseType which are then called accept, decline, and provisional respectively, and an owl:oneOf axiom stating that the class ResponseType is equivalent to exactly "one of" this set of instances. However, I came to realise that OWL 2 supports lists of values as ranges for datatype properties. For example, I can specify the following as the range of my hasResponseType property in Protege: {"Accept" , "Decline" , "Provisional"}

这似乎是两个选择中比较容易的一个,因为它不涉及创建额外的类,个人等.我想知道如果我选择第二个选择是否存在潜在的权衡,即是否有其他优点或缺点,而不是方便吗?

This seems like the easier of the two options, as it does not involve creating extra classes, individuals etc. I was wondering about the potential tradeoffs if I take the second option, i.e. is there any other advantage, or disadvantage other than the convenience?

推荐答案

我认为 Antoine Zimmermann的答案涵盖了如何,您可以做到这一点.我确实同意,实施这两种方法所需的工作是相似的.我希望,尽管我尚未对此进行测试,但是某些类型的推理在数据类型选项上会更有效,因为我希望对类型化的文字进行相等性和不平等性的比较比对个人进行比较要快得多.

I think that Antoine Zimmermann's answer covers how you can do this fairly well. I do agree that effort required to implement the two approaches is similar. I expect, though I haven't tested this, that some types of reasoning will be more efficient on the datatype option, since I expect that typed literals can be compared for equality and inequality much faster than individuals can be.

但是,我认为出于至少两个原因,我还是建议采用枚举的个体(这样, hasResponseType 是一个对象属性)方法

However, I think that I'd still suggest taking the enumerated individuals (so that hasResponseType is an object property) approach for at least two reasons:

  1. 正如Atoine的答案所指出的,响应类型实际上是一个字符串,这有点可疑.相反,响应类型似乎将带有一个字符串的标签(或多个标签,例如,使用不同的语言).
  2. (这是我的主要观点.)如果您想说关于响应类型的任何内容,则它们必须是个人.例如,当响应类型为个人时,您可以为他们提供其他类型,例如

  1. As Atoine's answer points out, it is somewhat dubious that the response type is actually a character string. Instead, it seems like the response type would have a label (or multiple labels, e.g., in different languages) that's a character string.
  2. (This is my primary point.) If you want to say anything about response types, they need to be individuals. For instance, when response types are individuals, you can give them additional types, e.g.,

Accept a GuaranteedResponse
Decline a not GuaranteedResponse
Provisional a not GuaranteedResponse

,然后您可以问,例如,给定的轮询者收集了多少not GuaranteedRepsonses个.您还可以将代码与每种响应类型相关联,例如

and then you could ask, for instance, how many not GuaranteedRepsonses a given poller collected. You could also associate a code with each response type, e.g.,

Accept hasCode "x789"
Decline hasCode "x234"
Provisional hasCode "x900"

,然后将其传递给响应:

and then pass this on to the responses:

hasResponseCode subPropertyOf hasResponseType o hasCode

如果您的ResponseTypes是文字,那么您将无法执行此操作,因为文字不能成为语句的主题.

You won't be able to do this if your ResponseTypes are literals, because literals can't be the subject of statements.

这篇关于使用值列表为OWL数据类型属性限制建模的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆