OpenCogPrime:Combo and Inference

From OpenCog
Jump to: navigation, search

We now shift attention to a slightly different issue: the representation of Combo tree internals using inferential data structures. This is important if we want OCP to inferentially understand what goes on inside Combo trees.

First, note that each of the entities that can live at an internal node of a Combo tree, can also live in its own Atom. For example, a number in a Combo tree corresponds to a NumberNode; an NMArgument in a Combo tree already corresponds to some Atom; and an operator in a Combo tree can be wrapped up in a SchemaNode all its own, and considered as a one-leaf Combo tree.

Thus, one can build a kind of virtual, distributed Combo tree by linking a number of ProcedureNodes together. All one needs in order to achieve this is an analogue of the @ symbol for relating ProcedureNodes. This is provided by the ExecutionLink link type, where

(ExecutionLink f g)

essentially means the same as

f g

in curried notation or

  / \
 x   y

The same generalized evaluation rules used inside Combo trees may be thought of in terms of ExecutionLinks; formally, they are crisp ExtensionalImplicationLinks among ExecutionLinks.

Note that we are here using ExecutionLink as a curried function; that is, we are looking at (ExecutionLink f g) as a function that takes an argument x, where the truth value of

(ExecutionLink f g) x

represents the probability that executing f, on input g, will give output x.

One may then construct combinator expressions linking multiple ExecutionLinks together; these are the analogues of Combo trees.

For example, using ExecutionLinks, one equivalent of y = x + x^2 is:

            List v1 2
            List v1 v2

Here the v1, v2, v3 are variables which may be internally represented via combinators. This AND is sequential in case the evaluation order inside the Combo tree interpreter makes a difference.

As a practical matter, it seems there is no purpose to explicitly storing Combo trees in conjunction-of-ExecutionLinks form. The information in the ExecutionLink conjunct is already there in the Combo tree. The PLN reasoning system, when reasoning on Combo trees, may carry out this kind of expansion internally as part of its analytical process.