sinterface IFactStore { void store(S fact); void deleteAll(IPred filter); } svoid philosophyBot1_factStore(PhilosophyBot1 bot, IFactStore factStore) { bot.addNativePredicate("delete all $x", (map) -> { S pat = map.get("$x"); factStore.deleteAll(s -> bot.zipIt(pat, s) != null); true; }); bot.addNativePredicate("store $x", (map) -> { factStore.store(map.get("$x")); true; }); }