简体   繁体   中英

protege how to add a data property to an object property (from different ontologies)

First I will list how I was doing what I want to do when I had just one Ontology, then I will list my question with two ontologies just to give you the full context of my problem. (and excuse me if i used the words such as properties in wrong context, that is why I will add pictures to support my question)

When I had just one ontology, I had an Object Property, and I could add property (you may call it annotation) for it like this: 在此处输入图片说明

It was simple, just click on add annotation, and create a new annotation called "degreeBy" and set the value.

However, now I have two ontologies (the same example but different name for the properties), where I have a data property in one ontology and an object property in another ontology.

I created a thrid ontology in protege by importing the two ontologies. so now I have in the object property section : 在此处输入图片说明

where hasFeature is an object property coming from the first ontology, and I have in the data property section :

在此处输入图片说明

where hasSimilarityValue is a data property (with range double) coming from the second ontology.

Now I want to say that the hasFeature property has hasSimilarityValue with a specific value. As I showed you, this was easy when I had just on ontology, but now, when I click on the hasFeature property and then click add annotation, i can't see the hasSimilarityValue there, this is why I see:

在此处输入图片说明

could you help me please

This is not possible in OWL 2 DL - you are trying to use a data property as an annotation property. This is called punning - using two entities with the same IRI but different type - and it is only allowed between classes and individuals, or classes and datatypes.

You can do this through code, for example with the OWL API, but your ontology will be OWL 2 Full and tools like Protege might have problems dealing with it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM