Next: , Up: Multinode Model   [Contents][Index]


4.1 Principle of Operation

A schematic diagram of a multinode model implementation is in Figure 4.1.

An environment state identification engine, instruction emitting engine, and instruction execution environment are main model components taking part in model execution.

The environment state identification engine is a small or large actor keeping the adaptive state model of an environment and identifying node states according to that model. This identification is a bidirectional process: the current state of a node depends on the state of the environment and needs identification; conversely, the node acts on the environment, and, therefore, the state of the environment depends on an identified node state. For a single-node model, its node corresponds to the entire environment. For a multinode model, a node corresponds to part of the environment.

Along with the adaptive state model, the environment state identification engine keeps the identifier of a currently executed node, the index of its previous state, an optional array of identifiers of look-ahead signals (see Setting Look-ahead Signals), and, as an actor, it keeps the current values of spur and continuous time.

The structures of tuples encoding the action choice states of an environment state identification engine for a single-node model and a multinode model are in Figure 4.2. The environment state identification engine identifies a current node state based on a previous node state and an array of input signals specifying last instruction emitted by the instruction emitting engine, the outcome of this instruction, and optional look-ahead signals. For a multinode model, the identifier of a currently executed node takes part in identifying the current node state.

The environment state identification engine sends the identifier of a currently executed node and the index of its current identified state to the instruction emitting engine. The latter engine is a small or large actor keeping an adaptive model of emitting various assembler instructions in various node states. As an actor, the instruction emitting engine keeps the current values of spur and continuous time, and they can be different from those values for the environment state identification engine.

The structures of tuples encoding the action choice states of an instruction emitting engine for a single-node model and a multinode model are in Figure 4.3. The instruction emitting engine selects an output signal encoding an assembler instruction. A current node state received from the environment state identification engine takes part in selecting the output signal. For a multinode model, the identifier of a currently executed node received from the environment state identification engine also takes part in selecting the output signal.

The instruction emitting engine sends a selected assembler instruction to the instruction execution environment for performing effective work and to the environment state identification engine for identifying the next node state. That instruction execution environment represents everything else in the multinode model, interacts with application logic or incorporates it, and is aware of all parameters of the environment state identification engine and instruction emitting engine. An assembler instruction returns an instruction outcome after execution. The instruction execution environment sends the outcome to the environment state identification engine for identifying the next node state.

The instruction execution environment keeps a node call stack for the execution of nodes to be similar to the execution of program subroutines (functions or procedures) calling each other and returning control to caller subroutines. An executed assembler instruction can push the identifier of a currently executed node and the index of its current state to the node call stack and transfer control to another node with resetting the current node state to the initial node state corresponding to the beginning of execution of a subroutine. The assembler instruction can also return control to a previously executed node by popping the identifier of this node and the index of its current state from the stack.

The assembler instruction can change look-ahead signals taking part in identifying the next node state and increment the current values of spur and continuous time tracked by the environment state identification engine and instruction emitting engine.

multinode model implementation

Figure 4.1: multinode model implementation

action choice states of an environment state identification engine

Figure 4.2: action choice states of an environment state identification engine

action choice states of an instruction emitting engine

Figure 4.3: action choice states of an instruction emitting engine

A helpful feature of a multinode model is the ability to convert internal data stored in its environment state identification engine and instruction emitting engine to a representation in the form of an assembler program (see Assembler Programs). One can think about this feature as automatic synthesis of an assembler program solving an assigned task.

An important point the developer should realize is that automatic program synthesis may work only if there exists a steady state model solving an assigned task. Steady state model is a model where states have predictable input from an environment.

Below there is a list of concepts for enabling the automatic synthesis of assembler programs.

Instruction meta-class

Represents an instruction name without taking into account optional instruction parameters following the instruction name after a whitespace character. The name of an instruction meta-class is the name of an instruction without including instruction parameters. Example:

move

This instruction meta-class might represent an instruction that moves an agent in an environment one step in a specific direction. The name of this instruction meta-class does not include a movement direction.

Instruction class

Represents an instruction name optionally followed by instruction parameters. Distinct strings, where every string consists of an instruction name and instruction parameters in canonical form (see Setting Text Instruction Parameters), identify distinct instruction classes. Example:

move north

This instruction class might represent an instruction that moves an agent in the environment one step in the north direction.

Instruction outcome

An instruction class has a specific number of instruction outcomes. An environment state identification engine uses the outcome of an emitted instruction to identify the next node state. The instruction emitting engine uses that next node state to select the next instruction.

For example, the instruction ‘move north’ as well as other movement instructions might return a bitmask of four bits (i.e. an integer number in the range 0 to 15) after performing a move. A bit of this bitmask equal to 0 might indicate that there is an obstacle in a corresponding direction, thus giving a piece of information to the agent about the configuration of an environment. It might also be useful to return special outcome 16 if there is an obstacle in a direction specified by an emitted instruction, and this obstacle disallows the agent to move.

Instruction class set

Represents a set of instruction classes and its properties and is a class for nodes. For example, the instruction class set ‘walker’ intended for investigating an environment might contain the instruction classes

move north
move east
move south
move west

A node belonging to this node class might represent an agent investigating the environment.

Instruction instance

An instance of an instruction class in an assembler program. For example, in the assembler program fragment

        move north
        joe  14, return_back
        move north
        ...
return_back:
        move south
        ...

there are two instances of ‘move north’ instruction class.


Next: , Up: Multinode Model   [Contents][Index]