AI project: "world state" seems to be required.

Joshua 'Schwa' Gargus schwa at cc.gatech.edu
Sun Sep 8 18:04:28 UTC 2002


Hi all,

On Sat, Sep 07, 2002 at 02:32:54PM -0700, Alan Grimes wrote:
> I have been looking at the possibility of using a raw paste-up morph
> without a world state. It doesn't appear to be viable because there
> doesn't appear to be a way to have the facility of hands and the control
> of time through the manipulation of the time stepping without it. 
> 
> Now that I know that I can obtain a copy of the screen without
> "ImageMorph" the necessity or utility of image morph is unclear.
> 
> My previous question about how to "start the clock" of world morph and
> cause it to function so that it can support normal squeak functionality
> (or some restricted version thereof) remains open. 

Why not just hook into the World state of the current project?  The
user is interacting with the whole World, not just a PasteUpMorph in
the World, so it makes sense for your AI's input/output to be through
the World (note: capitalization of "World" refers to the global
variable with that name)

The World already has a world state ticking, so you don't have to
worry about the hassles involved with hooking up your World with
mouse/keyboard input, etc.  Just use the one that is already there.

Here's how I might approach the implementation:

You could make a subclass of PasteUpMorph, AIPasteUpMorph, that could
be used for the World of newly created Projects.  An item in the World
menu could tell the AI to become active or inactive.  When the
AIPasteUpMorph initializes itself, it does everything necessary to
begin to sense input from the user, munch on it, and react to it.

You might also have to subclass WorldState, and perhaps HandMorph.
Take a look at the method WorldState>>doOneCycleNowFor:.  The line 'h
processEvents' is where your AI should tap into the user input.  The
AI's actions might occur between 'aWorld runStepMethods' and 'self
displayWorldSafely: aWorld'

> 
> I have not devoted very much time to the project reciently which is why
> this response has been somewhat delayed. 
> 
> 
> My usual review of the project's requirements follows: 
> 
> AI testbench is to be a medium for communication between human and AI
> and must also ficilitate the development and growth of said AI. 
> 
> It must provide the AI with the ability to interract with sequeak
> software in a fairly ordinary manner as well as the ability to
> comumnicate with the user/teacher. 
> 
> The system will function through a system by which the AI will recive
> input from the screen and have the ability to move a mouse "hand" as
> well as type on an immaginary keyboard. 
> 

Does what I wrote above make sense?  If not, ask and I will clarify.  If
so, does it not meet the requirements you've described above?


Joshua


> -- 
> Latancy is your enemy.
> Bandwidth is your friend.
> http://users.rcn.com/alangrimes/



More information about the Squeak-dev mailing list