Artificial Intelligence, Informatics, Language, Uncategorized

Blocks world in Prolog

Terry Winograd’s SHRDLU is a well known system that generates and understands natural language refering to objects and actions in a simple blocks world. It was written at the MIT Artificial Intelligence Laboratory in 1968-70 in MACLISP for the Incompatible Time Sharing System.

Project SHRDLU is an attempt at the University of Missouri-Rolla to breath new life into the classic AI program by porting it from MACLISP to Common LISP. Besides porting the LISP code, a graphical 3D Java layer was also created.

blocksworld.png

I took this 3D Java layer and hacked together some extra code to turn it into a server program listening on port 8008. Then I wrote some Prolog code to act as a client to be able to send commands to the server program from prolog like this:

:- sendcommands([move(300,500,200), grasp('B3'), move(500, 600, 200), ungrasp('B3')]).

I wrote this code, because last year I programmed a small chatbot in Prolog and I plan to incorporate the blocks world code in my chatbot program. 

Let me know if you do anything useful with it or make improvements.

speak up

Add your comment below, or trackback from your own site.

Subscribe to these comments.

Be nice. Keep it clean. Stay on topic. No spam.

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*Required Fields