Index of /2001_2006/spring03/ai-stuff/gary2/wumpus

[ICO]NameLast modifiedSizeDescription

[PARENTDIR]Parent Directory  -  
[TXT]README.html2018-01-26 19:54 2.2K 
[TXT]wumpustest.pl2018-01-26 19:54 3.6K 
[TXT]WumpusWorld.pm2018-01-26 19:54 17K 

Project: Propositional Logic in the Wumpus World
Class: Artificial Intelligence
Semester: Spring 2003
Author: Gary W. Johnson, Jr.

The two files contained in this directory have extensive documentation, 
which should answer any questions that the user may have about my implementation
of a propositional logic model in the Wumpus World game.  Nonetheless, for quick
reference, the purposes of these two files are listed below.

WumpusWorld.pm :

	Summary: Package definitions for the Environment and Agent objects.
		 Used by wumpustest.pl.

wumpustest.pl :

	Run as: bash$ ./wumpustest.pl

	Summary: Command-line interface game that implements the package
		 definitions given in WumpusWorld.pm.  The real state of
		 the world is shown first, followed by the agent's current
		 percepts.  Below this, the agent's beliefs about the world
		 and the propositions in his knowledge base are displayed.

		 The user enters one of five commands for the agent to perform,
			 f = stepForward
			 l = turnLeft
			 r = turnRight
			 g = grabGold
			 s = shootArrow
		 after which he will check for new percepts and update his 
		 knowledge base accordingly.

		 The game ends when the agent grabs the gold, falls down a pit,
		 or is eaten by the wumpus.

	Important Note: There is a rather bizarre bug that occurs in the contents
			of my knowledge base once every few times I run the game,
			in which some propositions in the KB disappear and reappear
			in alternating rounds.  This will usually only affect one
			adjacent square, but if you press the enter key once, the
			agent will reperceive his environment and usually add the
			missing statements back into the KB.  I really have no idea
			why this is occurring though it may be related to two
			similar processes in the Agent::updateKB() function (1 and 4).

	Example output:

		Wumpus World:

		|P     |B     |S     |W     |
		|B     |P     |B     |S     |
		|      |GB    |P     |B     |
		|B>    |P     |B     |      |

		I feel a breeze.

		Agent State:

		|     |     |     |     |
		|     |     |     |     |
		|~WP? |     |     |     |
		|~P~W>|~WP? |     |     |

		Knowledge Base:

		~W10 ~W01 P10vP01 ~P00 ~W00 

		[(f)orward,(l)eft,(r)ight,(g)rab,(s)hoot]
		Command?