[Pellet-users] KRSS and Pellet
Hongkai Liu
liuhkai at tcs.inf.tu-dresden.de
Mon Apr 28 09:32:13 UTC 2008
Hello,
I would like to know the way to manipulate the elements of the loaded
knowledgebase. For example, I want to remove some ABox assertions in
kb those safisty some property. To this end, I need to get the set of
assertions in ABox, something like getExplainationSet which returns
"Set<aterm.ATermAppl>". All the assertions in the ABox are in the
returned set.
Is it possible that Pellet can help me on this?
Thanks a lot.
Hongkai Liu
--------------------------
import org.mindswap.pellet.KRSSLoader;
import org.mindswap.pellet.KnowledgeBase;
import org.mindswap.pellet.PelletOptions;
public class Hello {
public static void main( String[] args ) throws Exception {
KRSSLoader loader = new KRSSLoader();
KnowledgeBase kb = new KnowledgeBase();
loader.load( "/home/aat/liuhkai/test/java/pellet-1.5.1/test1", kb );
PelletOptions.USE_UNIQUE_NAME_ASSUMPTION = true;
kb.prepare();
System.out.println( "Expressivity: " + kb.getExpressivity() );
boolean consistent = kb.isConsistent();
System.out.println( "Consistent : " + (consistent?"Yes":"No") );
System.out.println( "Done!");
}
More information about the Pellet-users
mailing list