model.interaction module

Module to hold interaction classes.

class model.interaction.CompositeInteraction(pre, post)

Bases: model.interaction.Interaction

get_post()
get_pre()
reconstruct_from_hierarchy(sequence)
to_json()
unwrap()

Unwrap the composite interaction.

Returns:A list of primitive interactions.
class model.interaction.Interaction(name)

Bases: object

get_name()

Get the name of this interaction.

Returns:The name of this interaction.
Return type:basestring
reconstruct_from_hierarchy(sequence)

Reconstruct a sequence of enacted (primitive) interactions into the hierarchical structure represented by this interaction.

See section 4.2 of: Georgeon, O. L., & Ritter, F. E. (2012). An intrinsically-motivated schema mechanism to model and simulate emergent cognition. Cognitive Systems Research, 15, 73-92.

Parameters:sequence – The sequence of primitive interactions to turn into a composite/primitive interaction.
Returns:The composite/primitive interaction reconstructed from the sequence.
unwrap()

Get the sequence of interactions represented by this interaction.

Returns:The sequence of interactions represented by this itneraction.
class model.interaction.PrimitiveInteraction(name, result)

Bases: model.interaction.Interaction

get_result()

Get the result of the interaction this primitive represents.

Returns:The resut of the interaction this primitive represents.
reconstruct_from_hierarchy(sequence)
to_json()
unwrap()

Get the primitive interaction as a singleton.

Returns:The primitive interaction as a singleton.
class model.interaction.PrimitivePerceptionInteraction(interaction, perception)

Bases: model.interaction.Interaction

A primitive perception interaction is a construct containing both a primitive interaction and a perception.

get_name()
get_primitive_interaction()
reconstruct_from_hierarchy(sequence)
to_json()
unwrap()

Get the primitive interaction and perception in the perception interaction as a singleton.

Returns:The primitive interaction and perception in the perception interaction as a singleton.