[Attempto] Generate ACE sinppets for an OWL class

Kaarel Kaljurand kaljurand at gmail.com
Wed Dec 17 14:49:14 CET 2008


Hi,

On Wed, Dec 17, 2008 at 5:30 AM, Jiang, Guoqian, Ph.D.
<Jiang.Guoqian at mayo.edu> wrote:
>
>>2. Write a program using the OWL API which:
>
>>2.1. Loads your OWL ontology
>>2.2. Walks over all the axioms that the ontology contains
>>2.3. If an axiom references your class then places it into a fresh
>>ontology
>>2.4. Serializes this ontology as OWL 2 XML
>>2.5. Sends the serialization to the OWL verbalizer webservice
>>2.6. Gets back the ACE snippet and does something with it
>>2.7. Goes to step 2.3 until done.
>
>
> While this algorithm works well (Thanks a lot), I would like to ask a
> few of questions.
>
> The first question is about the definitions of ace snippet and sentence.
>
> In aceview webpage, I have seen that "Snippet is a short sequence of one
> or more ACE sentences. Usually just one sentence."

Yes.

> Is an ace snippet a set of all sentences generated from an axiom of a
> specific OWL Class?

Yes, but I'm unsure what you mean by "axiom of a class". Axioms are statements
that reference zero or more classes. E.g.

(1) EquivalentProperties(ObjectProperty(p) ObjectProperty(p))
references 0 classes.

(2) SubClassOf(Class(c1) Class(c2)) references 2 classes.

Each axiom corresponds to exactly one snippet, e.g. (2) corresponds to:

(2') Every c1 is a c2.

Some axioms are mapped to more than one sentence (but still one snippet), e.g.

(3) EquivalentClasses(Class(c1) Class(c2))

is verbalized as

(3') Every c1 is a c2. Every c2 is a c1.  (one snippet that contains
two sentences)

The sentences in a snippet have an order, i.e. a snippet is an ordered
list of sentences.

Anaphoric references do not cross snippet borders (in ACE View), e.g.

(4) There is a car. John owns the car.

works if (4) is a snippet, but does not work if (4) is two snippets
(each containing 1 sentence).

In general, for the OWL->ACE direction, a snippet is the output for an
axiom given as input.
For the ACE->OWL direction, a snippet is the input, the output is one
or more axioms.

> The second question is about performance. Put an axiom in a fresh
> ontology and then serialize,  owl verbalize through webservice, it works
> but performance seems not optimal. Any idea about this? I noticed that
> aceview plugin verbalizes the entire ontology while loading the plugin.

Yes. It's very slow like this. Ontologies with several thousands of
axioms can take several
minutes to load. But if you save the ontology after the loading has
finished then
the resulting snippets are saved into axiom annotations. Opening the
ontology next time
is much faster because the verbalization is not redone, instead, the
ACE snippets are taken
from the axiom annotations.

For ACE View, it would be the best if the verbalization was
written in Java (and using OWL-API), then there would be no need to serialize in
XML and communicate with the webservice.
I have no immediate plans though to rewrite it in Java. I you would
like to do it, let me know. :)

--
kaarel



More information about the attempto mailing list