Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-discussion] Exporting the Annotations field

Timothy Redmond tredmond at stanford.edu
Thu Dec 26 17:24:39 PST 2013


It might be possible.

> I'd like to export only the Annotations fields in a relatively large 
> ontology 

This is possible though it appears that the current mechanisms are a bit 
awkward.  There is at least one bug report that I need to write against 
this functionality. The following steps worked for me (I tested with the 
pizza ontology):

 1. Open the ontology in Protege 4.
 2. Create a new empty ontology (File->New) and say yes to put it in the
    current window.  (This step is needed to work around a bug in the
    refactor menus).
 3. Give the new ontology any prefixes that it needs so that the final
    output is pretty.  By default, the "Ontology Prefixes" view appears
    in the "Active Ontology" tab (near the bottom). For the pizza
    ontology I added one mapping
    (pizza->http://www.co-ode.org/ontologies/pizza/pizza.owl#).
 4. Switch back to the original open ontology.
 5. Now use the Refactor->Copy/Move/Delete axioms menu to pull up a
    wizard.  As you work through the wizard you will choose Axioms by
    type, the AnnotationAssertion axiom type, Copy axioms, "Existing
    ontology" and finally select the new empty ontology as the place to
    put the axioms.
 6. Don't panic.  At this point things look very bad.  If you go to the
    Class hierarchy view for instance, none of your classes will be
    visible.  But the annotation assertion axioms are there.  They just
    aren't annotating declared entities that Protege knows how to display.
 7. Save the ontology.  I tried a couple of formats but I am guessing
    that the best one is the OWL functional syntax format.


When I did the above steps, I saw assertions that looked like this:

    AnnotationAssertion(rdfs:label pizza:Caprina "Caprina"@pt)
    AnnotationAssertion(rdfs:label pizza:PrinceCarlo "CoberturaPrinceCarlo"@pt)
    AnnotationAssertion(rdfs:label pizza:ChickenTopping "CoberturaDeFrango"@pt)
    AnnotationAssertion(rdfs:label pizza:SweetPepperTopping "CoberturaDePimentaoDoce"@pt)


When I saved in the LaTeX mode, the result was the empty ontology.  
Again, I suspect that this is because LaTeX uses a frame like display of 
the annotations by entity type and this ontology has no entities, only 
annotations.

> without loosing their classes or properties references.

I am not sure what this means.  If you are referring to the declarations 
of the entities, then I think it would be good if the steps above 
included the declarations.  But such is life.


-Timothy



On 12/26/2013 02:35 PM, André Luiz Tietböhl Ramos wrote:
> Hello,
>
> I'd like to export only the Annotations fields in a relatively large 
> ontology without loosing their classes or properties references. If 
> possible in a ASCII text file for I'll use them in a LaTeX document?  
> Can it be done?
>
> TIA,
>
> Andre Luiz
>
>
> _______________________________________________
> protege-discussion mailing list
> protege-discussion at lists.stanford.edu
> https://mailman.stanford.edu/mailman/listinfo/protege-discussion
>
> Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/protege-discussion/attachments/20131226/89d35264/attachment.html>


More information about the protege-discussion mailing list