wiki:Plugins/clips-agent
Last modified 4 years ago Last modified on 03.02.2015 17:09:50

CLIPS-based Agent Plugin

The agent is the task-level executive component which decides what goals to accomplish and how so. The clips-agent plugin is one implementation which builds on the rule-based production system CLIPS. It provides an environment in which to run a domain-, platform-, and task-specific set of rules that together model the knowledge to reason about how to accomplish some given goals. This plugins uses the clips plugin to create a CLIPS environment and in addition to available CLIPS features in particular provides an easy way to execute skills through the Lua-based Behavior Engine.

The main project page is at CLIPS-based Task Coordination project page. The plugin has been used in particular to create the task-level executive for the Carologistics RoboCup team to win the RoboCup Logistics Challenge, a multi-robot industrial scenario, in 2014.

Requires

BlackBoard Interfaces

No particular interface is required, but any can be opened for reading or writing.

Configuration

Below is the default configuration of the CLIPS agent with explanation for the config values as comments.

clips-agent:
  # If true, will enable watching of facts and rules
  clips-debug: true

  # If CLIPS debugging is enabled, certain rules and facts can be excluded
  # from watching, e.g. if they are showing up at too high frequencies or
  # are not of interest.
  unwatch-facts: ["time"]
  unwatch-rules: ["time-retract"]

  # If true, simulate skills (assuming they always succeed) instead of
  # actually executing the skills. The time indicates how long it should
  # take to declare success on skill execution. Note that this cannot
  # simulate side effects, like a called component writing to an interface
  skill-sim: true
  skill-sim-time: 2.0

  # debug level is a number of: 0 ~ none, 1 ~ minimal, 2 ~ more, 3 ~ maximum
  debug-level: 3

  # automatically pre-require redefine-warning feature? Enabling
  # this in the plugin instead of in the initial code (init.clp) is
  # beneficial because it already catches errors in said file.
  request-redefine-warning-feature: false

  # Automatically assert the (start) fact after successful initialization,
  # otherwise wait until the an enalble message has been received
  auto-start: true

  # If set to true, will trigger the assertion of a (time (now)) fact in
  # each loop. This can be used to trigger loop events in CLIPS.
  assert-time-each-loop: true

  # If set to true will force the acquisition of the skiller control.
  # This is particularly useful to kick an SkillGUI which is holding
  # the lock just due to an oversight.
  steal-skiller-control: true

  # Directory where to look for CLIPS files
  clips-dirs: ["@BASEDIR@/src/clips-agents", "@BASEDIR@/testagent"]

  # Agent name. On startup the clips-agent will try to resolve a file named
  # <agent name>.clp. It must be in the CLIPS path directories.
  agent: test

  # Agent-specific configuration values, the path depends on the agent name
  # configured above
  test:
    myvalue: true

Provides

BlackBoard Interfaces

  • SwitchInterface::Clips Agent Start (reading): if enabled first, asserts a (start) fact. It thus allows to give a start signal to the agent.

Compilation and Runtime Requirements

BlackBoard Interfaces

  • SkillerInterface::Skiller: used to execute skills through the skiller.

Usage Instructions

Running the plugin

When the plugin is loaded it will try to load a file named agent-name.clp (where agent-name is the name from the configuration).