Protege - DL Query and subclasses - owl

I'm using protege to test OWL Ontologies for my program.
Is there a way to ask in the DL Query tab if an entity is a subclass of another entity?
The autocomplete tab does not suggest the keyword subclass.

There is no concept of ASK queries in the DL Query Tab. The idea is to write Class Expressions and then do inferences based on what you selected in the check box section.
Thus, to check if a class A is a subclass of a class B, the idea would be to use A and then compute the super classes and check if B is contained in the result.
See the documentation
An alternative query language would be SPARQL.

Protégé 5.5. :
In the DL query window :
enter the entity name
In the "Query for"
check "Subclasses"
Press execute

Related

abp.io - extend user profile

Working with abp.io (free framework version), how to add custom properties to User profile ?
Such a BirthDate, Gender etc.
I saw this doc about ExtraProperties, but it does not explain when/how to use it, and I'd rather have a Custom User class with my properties :
https://docs.abp.io/en/abp/5.0/Object-Extensions
I saw another doc stating that you want to extend the "AppUser" class, but in my template (v5.0-rc), there is no such a class in the *.Domain project.
What would be the "preferred" way ?
A separate article will be written for this soon, but until then, you can read the parts of this article after the "The AppUser Entity & Custom Properties" heading.
On GitHub:
https://github.com/abpframework/abp/blob/dev/docs/en/Community-Articles/2021-05-24-Removing-EfCore-Migrations/POST.md#the-appuser-entity--custom-properties
On Community:
https://community.abp.io/articles/unifying-dbcontexts-for-ef-core-removing-the-ef-core-migrations-project-nsyhrtna
Also, this article shows how you can query on custom properties added under the heading "Querying Based on a Custom Property".
In fact, as you will see, the absence of AppUser means almost nothing. Almost all the written codes are the same :)

Conversation - using entities values/size as a condition

I'd like to know how to use the values from the entity as a IF bot recognizes
condition on Watson Conversation.
I have one menu for the users choose one option. And all of these options are inside one Entity called #optionsNumbers with the values: 1, 2, 3, 4, 5.
And I want to make one condition that will verify if user chooses more than one option.
E.g:
Watson: Hello, welcome to the Official Virtual Assistant from the Company XX. You can choose this options above:
1. About products 2. About Services 3. Exit
User: I want the option 1 and 2
So, the entity #sys-number have 2 values, and not just one, like I need.
As you can see, the user types 2 values of the entity #option. And I'd like to know how to recognize if the user typed more than one value for this particular entity, also #sys-number, cause the user can type just ONE option (business rules).
I'm enthusiast about Watson and pretty sure I read all documentation. So, what I have tried and does not work (I saw these methods with Intents examples):
if bot recognizes entities.sys-number[1].value
if bot recognizes entities['sys-number'].size > 1
And I know that I can create two conditions, but if my Options menu have more than 20 options? That's why my asking.
First, you could use the system number entity built-in type provided by Watson :
Entities > System Entities > Enable System Number
Your intent should now be able to recognize it easily by default, let's check the following intent :
And you test it with the sandbox, it works as expected
EDIT: Using Dialog to add a condition on sys-number
Create new dialog node for matching the intent :
Then enable the Multiple Responses for this node ( click Customize ) :
Add your conditions as part of the responses :
Then test your dialog :

Protege reasoner's equivalent conclusion

I have found this issue while developing an ontology. I am making ontology over the basic family relations.
I have a main class called Person, which contain sub-classes like Son, Daughter, Wife etc.
Along with this I defined object properties like isGrandsonOf and isGranddaughterOf to show the relation grandparent-grandchild.
Issue is that whenever I start the reasoner, it tell me that isGranddaughter and isGrandson is exactly the same. It vary is such aspects as: Domain (female subclasses are disjoint with male one) and Disjoints, as the screens shows. Could someone please explain this to me? I am not sure how to declare these two object properties being unequal. I am using either FaCT++ or Pellet reasoner.
Both first and second image shows how object property, in inferred as equal, meanwhile I do not want isGrandsonOf and isGranddaughterOf to be the same object property. They both refer to people with different sex:
image 1
image 2

How to make a classfication attribute as searchble in hybris?

I have created a classification class and classification attribute and linked to some products in features. I even added that attribute to solrindexedproperty. But the OOTB solr search not providing any results for my attribute. How to make my classification attribute searchable using solr.
Please use CommerceClassificationPropertyValueProvider.
Here is example Impex snippet.
# Define macros needed to select proper classification system
$classificationCatalog=trainingClassification
$classSystemVersion=systemVersion(catalog(id[default='$classificationCatalog']),version[default='1.0'])
$classCatalogVersion=catalogVersion(catalog(id[default='$classificationCatalog']),version[default='1.0'])
$classAttribute=classificationAttribute(code,$classSystemVersion)
$classClass=classificationClass(code,$classCatalogVersion)
$classAttributeAssignment=classAttributeAssignment($classClass,$classAttribute,$classSystemVersion)
INSERT_UPDATE SolrIndexedProperty;solrIndexedType(identifier)[unique=true];name[unique=true];type(code);sortableType(code);currency[default=false];localized[default=false];multiValue[default=false];facet[default=false];facetType(code);facetSort(code);priority;fieldValueProvider;customFacetSortProvider;rangeSets(name);$classAttributeAssignment
#;$solrIndexedType;CLASSIFICATION_ATTRIBUTE_CODE;SOLR_INDEXED_PROPERTY_TYPE;;;;;true;FACET_TYPE;FACET_SORT;PRIORITY;commerceClassificationPropertyValueProvider;;SOLR_RANGE;CLASSIFICATION_CLASS_CODE:::CLASSIFICATION_ATTRIBUTE_CODE::::
;$solrIndexedType;puzzlePieces;string;;;;;true;Refine;Alpha;1000;commerceClassificationPropertyValueProvider;;;puzzles:::puzzlePieces::::
;$solrIndexedType;puzzlePieceSize;string;;;;;true;Refine;Alpha;900;commerceClassificationPropertyValueProvider;;;puzzles:::puzzlePieceSize::::

How to get individual results while solving Einstein's riddle with OWL in Protégé?

I would like to better understand ontologies and reasoning. There is an interesting puzzle called Einstein's riddle on the net that can be solved with the help of ontologies and reasoning. I downloaded the OWL ontology from that site and imported it into Protege 4.0.2 (does not work with 4.1). I can start a reasoner by Reasoner → FaCT++, Reasoner → Classify…, but i don't know, how to visualize the individual results. How can I do this?
There are two ways in which you can visualise the results. Firstly, when you select the "Classes" Tab, you will see that there are two views available to you: the "Class hierarchy" view, which is the asserted taxonomy and the "Class Hierarchy View (inferred)", which is, as the name suggests, the inferred one. That gives you the class views. As Kaarel suggests, you can visualise the individuals reasoning in the Individuals tab.
Protege also allows you to add a number of other individuals views to the UI: make a new empty tab and then choose a view from the "Individuals View" sub-menue under the "Views" menue. Finally, you can use a number of external graphical tools to visualise: if you assert the inferred hierarchy and save it out to a file (in RDF-XML), you can then use tools such as Welkin, IsaViz etc. to get graphical representations.
After the reasoner has finished go to the Individuals-tab and look for axioms that have a yellow background. These axioms are the entailed ones. If the components of the puzzle (i.e. the men, pets, drinks, etc.) have been modeled as OWL individuals then you would see some new object property assertions that the reasoner has found between these individuals.
There are also other options for seeing the entailments:
View -> Ontology views -> Classification Results will show the list of entailed axioms. It might not show all the entailed axioms though, e.g. I've tried it with Protege 4.1 and didn't see any entailed object property assertions.
In the DL Query tab you can type in a class expression and have all its subclasses and individuals (including the entailed ones) listed. This might be the most natural way of exploring the entailments.
See also:
ACE View examples: contains the "Zebra Puzzle" example, works in Protege 4.1
Stackoverflow question: Solving “Who owns the Zebra” programmatically?: doesn't yet contain the OWL-based solution :(

Resources