[Pellet-users] rbox change 1.4 to 1.5?

Alan Ruttenberg alanruttenberg at gmail.com
Fri Sep 14 16:28:48 UTC 2007


Thanks Evren. I was missing the getEquivalents.
-Alan

On Sep 14, 2007, at 8:15 AM, Evren Sirin wrote:

> On 9/13/07 9:55 PM, Alan Ruttenberg wrote:
>> In pellet 1.4 I used code based on starting at    
>> (#"getTop" (#"getTaxonomy" (#"getRBox" (kb-kb kb)))) and then  
>> calling  getSubs recursively to walk down the property hierarchy.
>>
>> In 1.5 this no longer works. Some properties are missed when I do   
>> this. Is there some optimization, perhaps, where only one of a   
>> property and it's inverse is stored in the rbox taxonomy?
> The change is role hierarchy will now always include the anonymous  
> inverse property (as InverseObjectProperty(p) in OWL 1.1 syntax)  
> whereas this information was not stored in earlier versions if  
> there was a named inverse property (defined with inverseOf axiom).  
> So you should get more properties in the hierarchy not less. Most  
> functions like kb.getObjectProperties(), kb.getSubProperties(p),  
> TaxonomyPrinters will filter those anonymous properties so they are  
> not visible to users directly (unless you go into the guts of the  
> reasoner as you do :)
>
>> If so, what  would you suggest as a way to walk down the property  
>> hierarchy?
>>
>
> I'm not sure what is the problem in your case. Example code and  
> ontology would be helpful. For example, passing kb.getRBox 
> ().getTaxonomy().getTop() to  the following function prints the all  
> the properties for couple of ontologies I tried:
>
>    protected static void printNode(TaxonomyNode node, String indent) {
>        if( node.isBottom() )
>            return;
>               System.out.println( indent + node.getEquivalents() );
>
>        for( TaxonomyNode child : node.getSubs() )
>            printNode( child, indent + "   " );
>    }
>
> Note that each node in the hierarchy represents a set of equivelant  
> properties so if you use node.getName() in the above example  
> instead of node.getEquivalants() you will miss some of the  
> properties in the output.
>
> Hope this helps,
> Evren
>
>> -Alan
>>
>> _______________________________________________
>> Pellet-users mailing list
>> Pellet-users at lists.owldl.com
>> http://lists.owldl.com/mailman/listinfo/pellet-users
>> _______________________________________________
>>
>> Sponsored by Clark & Parsia, LLC http://clarkparsia.com/
>>
>



More information about the Pellet-users mailing list