Calo   Ontology: Ontology Frequently Asked Questions (FAQ)
 
 

The following is a list of frequently asked questions (FAQ) about the Calo Ontology.

QUESTION: What is the CALO ontology?

The CALO ontology is all of the classes and relations that we intend to share across CALO. These classes and relations are spread across a set of owl files. Note that this does not merely refer to the core-plus-office ontology. There are other owl files some of which are subsidiary to core-plus-office and some which are standalone. A map of these different owl files can be found at ontology-map.shtml.

QUESTION: What is the core-plus-office ontology?

The core-plus-office ontology can be thought of the main, oldest, most globally shared ontology associated with CALO. Its two main parts are the Core Ontology (a.k.a "CLib") and the Office Ontology. When people use the phrase "the CALO ontology" the are likely referring to the core-plus-office ontology. This ontology is expressed as an owl file (called core-plus-office.owl). Aside from owl, this ontology is also expressed the knowledge representation language known as KM, the language used by The Knowledge Machine.

QUESTION: What is the Core Ontology?

The Core Ontology is an ontology created by UT Austin. It is one of the two partitions of the core-plus-office ontology. The other partition is the Office Ontology. It is also known as The Component Library or CLib (pronounced like "sea libe"), for short. The Core Ontology is a library of generic, composable and re-usable knowledge components. Components in this ontology are designed to be highly re-usable across a wide range of different applications. It was created before CALO and has been used in a variety of different projects including RKF, HALO and AURA. As of 2005-11-14 there were 857 core components.

QUESTION: What is the Office ontology?

The Office Ontology is an extension to the Core Ontology (see also) which serves to extend the Core towards the meeting of CALO specific requirements. Almost all of the components in the Office Ontology represent specific office-related related knowledge relevant to meetings, organizational structure, office equipment, etc. In rarer cases, some components in the Office Ontology are quite general (e.g. roleIimeOfExistenceIs) yet are not in the Office Ontology because they were developed at SRI. As of 2005-11-14 there were 108 office components.

QUESTION: How can I see ALL of the slots that apply to instances of a given class?

First off, you can see the slots that apply directly to a class simply by looking at "Domain Of" on a given web page. But, what if you want to see ALL of the slots that apply. In other words you want to see direct plus the inhereted slots. Two techniques come to mind. See Technique 1 "Use Owl Docs 'Manually'" and Technique 2 "Use the Query Manager" below.

Technique 1 : Use Owl Docs 'Manually'

Summary:

Look at a class's webpage on the OwlDocs. Look at the slots on its "domain of." These are some of the slots that apply. Next look at the superclasses of the class recursively.

Detailed Example:

Suppose you wanted to know what slots applied to the class ComputerFile. First, make sure you have logged in to calo.sri.com. Next, point your browser at...

https://calo.sri.com/CALOfiles/owldoc/ComputerFile.html

...Now you should see a webpage that tells you about the class ComputerFile. Look near the bottom of the page where you will see the words "Domain of" in black bold type. There will be a list of a few (six as of 2006-01-19) slots. All of those slots apply to any instance of ComputerFile. directoryPathIs and filenameIs are examples of such slots.

We're not done yet. Note that ComputerFile has ComputerEncodedInformation as one of its superclasses. So, click on that link. Now you should be viewing the webpage for the class ComputerEncodedInformation. Again look at "Domain of." You will see a few more slots (e.g. encodingIs and fileExtensionIs) these slots may apply to any instance of ComputerFile too.

We're still not done. To obtain a complete list of all of the slots that apply, you need to repeat this procedure for every superclass (recursively) of ComputerFile.

Laborious? Yes. Error prone? Yes. That is why we have Technique 2.

Technique 2: Use the Query Manager (QM)

The idea is to issue the following query to QM.

(calo-template-slot-of ?slot CLASS) 

For example, if you wanted to determine all of the applicable slots for ComputerFile you would pose this query to QM:

(calo-template-slot-of ?slot ComputerFile) 

For documentation on how to Use CALO Query Manager via OAA see OAA Query API

QUESTION: What is the difference between the ontology documentation, owldocs, and the ontology usage documentation.?

The ontology documentation is documention about the ontologies in CALO. For example, the ontology documentions tells you about the different classes in the CALO ontology. For each such class it tells you how it is related to other classes and other properties (also known as slots). Where To Find Ontology Documentation:The home page for the Ontology Documentation (also known as "Owldocs") is https://calo.sri.com/CALOfiles/owldoc/home.html.

In contrast, the ontology *usage* documentation provides information about how different ontology components are used in CALO code (actually, only IRIS code as of May 2006). In other words, it tells you what bits of CALO procedural program code (e.g. java code) refer to what bits of the ontology. This can be quite useful, e.g. when debugging 'Why isn't this part of the KB being changed?' If the component is not mentioned in code, then there's no way that assertions mentioning this component will be added to the KB. Where To Find Ontology Usage Documentation: There are two places you can find it. First you can find it on the web here (may take several seconds to load). It can als be found on the CALO desktop. If you go to your Calo Browser Home page you will find a tall orange rectangle with the heading "What's IRS..What's Calo." In this orange rectangle about midway down you fill find a hyperlink labeled "Calo Ontology Usage Documentation."

QUESTION: What are OWLDocs?

OWLDocs refer to ontology documentation pages viewable on an ordinary web-browser. These help you to browse the ontology components in an owl file. This can sometimes be easier or more appropriate than loading it into Protege or viewing it with a plain text editor. OWLDocs are generated by OWLDDoc - a plugin for protege that generates html page documentation for an OWL ontology much like JavaDoc. See ontology-map.html for an OWLDoc-based guide to the various .owl files in the CALO system. Note that as of December 2006 we at SRI have made some modifications to the owldoc plugin code for our own purposes.

QUESTION: Are the days of the week (Monday-Sunday) and Month (Jan-Dec) somewhere in the KB and labeled as such?

Days yes. Months no. Then can be added easily.

To see the Days, e.g. you can go to https://calo.sri.com/CALOfiles/owldoc/components-by-sub-ontology.html.

You will see things like *Monday, *Tuesday, etc..

Note that in the owl file, they are called like so....

carson:~/iris/iris/data jarrold$ grep Monday core-plus-office.owl
  <Day-Constant rdf:ID="asterisk_Monday">
    <name>Monday</name>

....in other words * gets converted to asterisk_ . Why? I'm told that * is illegal in xml. Since owl is based on xml, owl does not allow * in component names.

(The non-enforced convention is that instances should begin with * in km or asterisk_ in owl).

Note that if you query like so...

(instance-of ?x Day-Constant)

...via the query manager, you will see results like so...

?x *Sunday

...etc...

QUESTION:How does one query the IRIS KB for a Webpage that has the URI or URL of, say, http://www.google.com?

(and (Webpage ?webpage) (sourceURIIs ?webpage "http://www.google.com"))

QUESTION:How do you query for the range of a slot? How do you query for the range of a property? How do you query for the arg2 type of a predicate?

Below are two examples of how to query for the range of the slot (a.k.a. property) #$taskEndTimeIs.

The following query:

(TEMPLATE-FACET-VALUE range taskEndTimeIs Event ?x)
returns:
?x = Time-Instant

Found 1 answers in 10 miliseconds
One may try (replacing Event with a variable):
(TEMPLATE-FACET-VALUE range taskEndTimeIs ?y ?x)

?x will be bound to Time-instance; but there are multiple bindings for variable ?y (this is how KM answers this query). So it is important to know that domain of the slot.

(Thanks to Guizhen Yang for this answer.)

QUESTION:How does one associate a project with a meeting? E.g. How do I say that Meeting47 happened as part of the XYZProject.

The answer is to use #$subevent which is a slot (also known as a property).

As per the above example you would assert:

(#$subevent XYZProject Meeting47)

This might seem unintuitive at first blush but it makes sense if you think about it. A meeting is a part of a project - it is one small bit -- a few hours at most -- of a project, i.e. an endeavor that lasts much longer. Since Calo Year 2 at least, #$Project has been ontologized as a kind of #$Event (a full rationale for this is beyond the scope of this FAQ entry - but see further below). Of course, #$Meeting is a kind of #$Event too. Furthermore, an #$Event that is part of an #$Event is a #$subevent. This is why #$subevent is the way to relate a #$Meeting to a #$Project.

The class #$Project is a direct subclass of #$Task. #$Task is an all-subclass of #$Event. A #$Task (and thus a #$Project) should be viewed as 'an undertaking.' Like 'an undertaking', a #$Task is an #$Event that should be done. But, also, like 'an undertaking' a #$Task is an #$Event that has a story behind it. It has a beginning (e.g. when it is assigned or thought up as needing to be done), a middle (e.g. the stuff one does or tries to do to satisfy the requirements of the Task), and an end (e.g. when someone decided that the requirements have been met or when attempts to meet the requirments have completed.)

Consider an event such as FredWalkingOutTheDoor. This event has several subevents such as several instances of TakingAStep. Each such TakingAStep instance is a part of the bigger even of FredWalkingOutTheDoor. In other words, each such instance is a $#subevent of FredWalkingOutTheDoor. Perhaps such an example makes the concept that a #$Meeting is a #$subevent of a #$Project easier to make sense of?

Thus, hopefully by now, you will agree that a #$Meeting should be viewed as a #$subevent of a #$Project.

QUESTION:Are there any tricks one can use to speed up certain types of queries?

Here is one trick that someone found to be useful. Of course, it will only help for certain kinds of queries.

We need to think about this more to be sure it is a bona fide good way. This trick may not offer much improvements as the query manager may eventually perform its own optimizations. As of 2006-10-04 someone was making this query every time the ptime scheduler interface loads, but it was very slow:

(and
(displayNameIs ?x "Fred Jones")
(plays ?x ?role)
(OrganizationalRole ?role)
(occupationalTitleIs ?role ?y)
(Person ?x)
)

It takes up to 2.5 seconds on his/her machine. The reason is that there are a massive number of people in my people database.

Instead, they found that the following query, which is much faster

(and
(displayNameIs ?x "Fred Jones")
(plays ?x ?role)
(OrganizationalRole ?role)
(occupationalTitleIs ?role ?y)
)

Trouble is the faster query is less constrained. It lacks the (instance-of ?x Person) literal. Thus, one wonders, is possible for this query to produce bad results? Are there some other non-person objects that could be bound to ?x ?

The answer to your question is that it is syntactically possible to that other non-person objects would map to ?X. However, it would seem unlikely that this would happen in practice. Thus, I would say that your second query will be a fine substitute.

Is your second query something we can live with into perpetuity? That depends on how paranoid one is and one what kinds of constraint checking we implement in the ontology and in the associated KB (whether that be the IRIS KB or some other KB).

Why did I say it is unlikely that a non-person would be returned as a binding for X? Well, no software module using the IRIS KB should be asserting any non-Persons to play instances of OrganizationalRole. It would be a bug code it is didbecause the code would be violating the definition of OrganizationalRole.

That said, if you were sloppy, inattentive or malicious, you *could* write a software module that asserted weird stuff to the KB and nothing would complain...E.g. you could assert that Rudabega42 plays an OrganizationalRole. In other words, there is currently (circa 2006-10-04) no type checking that will prevent one from asserting non-Persons as playing organizational roles.

One more thing: The definition of OrganizationalRole is that only people should play it. How do we know this? It is stated on the comment of OrganizationalRole. I quote..."Instances of OrganizationalRole are roles that are played with respect to organizations or groups of people." But, like I implied in the immediately above paragraph, this constraint is not enforced now. It is not currently (circa 2006-10-04) enforced because (1) we do not express the constraint in the ontology in a machine readable way (we merely state it in that comment in English) and (2) even if we did express it in the ontology, the current IRIS KB system is not capable of enforcing this constraint.

If you would like a constraint like this to be expressed, let us know. A requirement like this would be important for Y4 planning.

Hope that helps.