- A production system has 3 components:
- A set of
**rules** - A
**working memory**, hereafter called WM - An
**algorithm**for applying the rules to the contents of working memory

- A set of
- A formal system has 2 components:
- A set of
**rules** - A set of
**axioms**

- A set of

- MI
- UUIIMMIII
- III

- MIU
- UUIIMMIIIU
- IIIU

- IF(*I) THEN(*IU)
- *I -> *IU
- NULL -> U / I_#
(if ((ends-with-i ?string)) (then (add-u-to-end ?string))

This system, the **pq** system, is very simple. There
are only 3 symbols in this world:

There is only one rule too:p,q,and-

Let ?x, ?y, and ?z all be strings of hyphens. If ?xInitially WM contains only one string (there is only one axiom):p?yq?z is in WM, then add ?xp?y-q?z-

With this rule we can produce many more strings, all of which get added to WM. This formal system is interestingly similar to a system you are familiar with. What is it?---p-q----

In a production system we have some algorithm which tells us which rule to apply at any given time. Choosing the rule and its operand (the string or symbol sequence it is applied to) is usually governed by system goals, which appear in WM. Here is an informal example of a production system which might help to account for the rather stupid behavior of the Sphex wasp:

Rules: 1)if((goal (in_nest cricket) n)) then((goal (at_door cricket) n+1) and (goal (safe nest) n+1) and (do drag_in cricket n+1)) 2)if((goal (at_door cricket) n) then((do get cricket n+1)) 3)if((goal (safe nest) n)) then((do checknest n+1)) WM: (goal (in_nest cricket) 1)Algorithm:

- Find the highest ranked goal or action in WM. If there is a tie, simply take the first such goal or action.
- Satisfy that goal or action
- An action is satisfied by doing it.
- When action (do x n) is satisfied, delete it from WM
- A goal is satisfied by satisfying each bit of the RHS of the corresponding rule
- When (goal x n) is satisfied, remove the goal and add x

1) (goal (in_nest cricket) 1) 2) (goal (in_nest cricket) 1) (goal (at_door cricket) 2) (goal (safe nest) 2) (drag_in cricket 2) 3) (goal (in_nest cricket) 1) (goal (at_door cricket) 2) (get cricket 3) (goal (safe nest) 2) (drag_in cricket 2) 4) (goal (in_nest cricket) 1) (at_door cricket) (goal (safe nest) 2) (drag_in cricket 2) 5) (goal (in_nest cricket) 1) (at_door cricket) (goal (safe nest) 2) (checknest 3) (drag_in cricket 2) 6) (goal (in_nest cricket) 1) (at_door cricket) (safe nest) (drag_in cricket 2) 7) (in_nest cricket) (at_door cricket) (safe nest)We have left out many details here. For example, we have left WM in a state in which it appears that the cricket is both at the door and in the nest... However, there are now no more applicable rules and the initial goal has been satisfied.

When a researcher interferes with this system by moving the cricket while the Sphex wasp is checking the nest, she is effectively resetting WM from stage 5 back to stage 3. The wasp blindly follows the algorithm and never progresses beyond stage 5.

- p = '+'
- q = '='
- n hyphens stands for the number 'n'

- p = '='
- q = 'subtracted from'
- n hyphens stands for the number 'n'

- p = 'is the son of'
- q = 'and'
- n hyphens stands for the person mentioned in the n-th entry in the Bloomington phone book

*Take me back to the E105
Page.*

URL: http://www.indiana.edu/~gasser/prodsys.html

Last updated: 14 November 1995

Comments: fcummins@cs.indiana.edu

Copyright 1995, The Trustees of
Indiana University