Saturday, August 08, 2009

Getting Ready for Inference Collection 3.0

I've been working on improvements to the inference collection now that we are actually using it (and the simulation collection) on a regular basis for agent-based simulation work. There will be in Version 3.0 of the inference collection. This is just to put forward some of the changes I'm planning on including.
The major change affecting user code is that Version 3.0 is that only (immutable) lists will be used to represent facts. This includes association lists for named slots. [Previously, vectors and structures could also be used.] Immutability simplifies many things associates with truth maintenance and explanation.
An ontology capability will be added that allows the user to define a set of taxonomies for the facts in the knowledge base. [Actually, this capability is already in Version 2.2 of the inference collection, but isn't released to PLaneT yet.] Taxonomic relations are asserted (much the same as facts) and these relations are used in matching rule preconditions. For example, (assert '(#:class hunter ())) and (assert '(#:class duck-hunter (hunter))) specifies that facts about hunters also apply to duck hunters. Classes may be generalizations of multiple parent classes. Basically, when a fact is asserted, it matched precondition clauses for its own class and (recursively) its parent classes. So, (duck-hunter clyde) would match both (duck-hunter ?x) and (hunter ?x) patterns as preconditions in rules.
Backward chaining is better integrated with forward chaining. When propogating assertions (or retractions) through the rule network, backward chaining will be automatically invoked. [Currently, backward chaining is only invoked when explicitly requested - via (query fact).]
Rulesets have a run-time instantiation now. [They were just collections of rules before.] When a ruleset is activated, a ruleset instance is created. The ruleset instance contains the agenda (for rule instances from the ruleset). This allows different conflict resolution strategies to be applied to rulesets within a single inference environment. [It will also allow us to experiment with conflict resolution among rulesets in the future.]
Certainty values for facts are implemented. A certainty may be specified when a fact is asserted and these are maintained as facts are inferred via rule firings.
Boolean connectives are allowed among rule preconditions. This simplifies writing complex rules.
This is a fairly substantial rewrite of the inference collection and should result in a better package all around. Our agent-based simulation work is leading us to look at less monolithic knowledge bases and more distributed ones. Although Version 3.0 is not truly distributed, it should help us along those lines as PLT Scheme continues to mature.
I'm not aware of any regular users outside of our small cadre of agent-based simulation folks. But, if there are, I'd like to solicit your inputs on any changes you might like and also make you aware of specific changes to the collection.

Labels: