This is an example of a step by step improvement of the basic Reflex-Agent design.
This example is specific to the Wumpus-World - but the results can be related to any world with similar complexity.
scroll down to the reference for a simulation example.
Due to the bad performance of the pure reflex-agent descriped by Russel && Norvig in their book Artificial Intelligenz in the Wumpus-World, two new agents were developed that performe far better in this harsh environmnet.
The main difference to the basic reflex-agent is that these two new agents store the percepts they get from their actions in a some memory-cells. Due to this storage memory the new agents can base their decissions on their previous experiences they made on a field - thereby they incorporate a very simple form of learning.
The two agents differ in the amount of memory cells and capabilties to process the previous experiences.
Therefore the agent can exclude the last move it made from the list of his next moves if it resulted in a bump percept. When the agent fires an arrow at the Wumpus it excludes the field it came from - which must be without a Wumpus - and any shot it just made from the directions it wants to fire at.
Beside the moves and shots the agent also memorizes the death-scream of the Wumpus - this way the agent always knows when it is save or not.
Therefore this agent can exclude all moves that resulted in a bump from his list of next moves. Another advantage is the possibility to shoot only in directions it did not try yet - thereby this agent will always kill the Wumpus with only three arrows/javelins. (The direction it came from is save -> leaving only three more field -> which are marked off one by one by a shot.)
The pure reflex-agent
The second Reflex-Agent - a knowledged Agent: Reflex2
The third Reflex-Agent - the wise Guy:
Reflex3
The ultimate Reflex-Agent: ...
Well?
Know any more possibilities to get more out of the
Reflex-Agent model ?
(And - yes - we know there are still possibilities )
Go on - program an agent - give it a try)
A Reflex Labyrinth with stop/continue possibility
and the same Labyrinth with single stepping
"Tell me - What does it show?"
"What's the point of all this?"
A Resumé:
It is not always enough for a Reflex-Agent to act on his Percepts only. In a complicated world like the Wumpus-World the agent will find it difficult to survive or even grab a single piece of gold. Still the agent has a fair chance - but in the most cases only if it freaks out at the beginning and returns home ("CLIMB") at the starting field...
Therefore the agent should also memorize his last move (even better it when it meorizes the last successful move), to dodge pits and elude the Wumps (if the agent has no arrows left to kill it).
This example also shows the difference
between live and death.
The first agent might fall into a pit or be
gobbled by the Wumpus because of the random
movement it takes upon the "BREEZE" and "STENCH"
Percepts.
The second and third agent know their last move and can
revert/negate it to get to a save place. One might
see it like this - if the latter two agents find their
live is endangered they will be scared, but they will stay calm
enough to always revert their last move. The first agent
is utterly lost in this case and runs away in any
direction - even into deaths hand.
Still even the simplest Reflex-Agent may performe well in a simple environment, where his live is not endangered...