Sunday, April 17, 2011

Intelligent Computer Chess, Part IX

In Part VIII, I explained the difference between long-term and short-term memory. I described how effectors and actuators work and I wrote that the concept of complementarity can be used to design a coordinated motor system free of conflicts. In today's post, I explain how to connect the tree of knowledge to the motor system in a way that will generate intelligent motor behavior in a changing environment.

The Intelligent Behaving System

Intelligent sensorimotor behavior is a process that involves a feedback loop as follows:

Changes in the environment are picked up by complementary sensors.

The sensors generate signal streams that are fed into a signal separator.

The separator separates the streams into meaningful signals which are fed into a pattern recognizer.

The recognizer detects patterns and generates signals that are sent to a stream assembler.

The assembler combines the signals into streams which are fed to complementary effectors.

The effectors cause changes in the environment and the cycle begins anew.

The following diagram shows the bare minimum that is necessary for coherent behavior.

The important thing to note in the above diagram is that the system is not just what is in the brain. The environment is an integral part of it. The assembler must insure that motor command signals fed to the effectors are not in conflict with each other. The pattern recognizer is, of course, none other than the tree of knowledge. The system is highly symmetric. Notice that the environment and the TOK are complements of each other. In this light, behavior is seen to involve not just what an intelligent agent does to the environment, but also what the environment does to the agent. If you think about it for as long as I have, it will eventually dawn on you that the intelligence of an organism really resides in the environment.

Sensorimotor Pathways

The question that immediately comes to mind is, how does the TOK generate motor signals? The answer is that every time a low level node detects a sequential pattern, a signal is emitted. This signal can serve as a motor command that can be sent directly to an effector. But why are only the low level nodes allowed to generate motor signals? Why can't the higher level nodes also generate them? The main reason has to do with the need for fast actions in response to environmental stimuli. Survival demands quick reactions which, in turn, depend on having very short sensorimotor pathways. The tree of knowledge is not a signal processor in the normal sense of the word. That is to say, signals do not come in at one end (the lower level), go through various processing layers and finally come out at the other end (top level). That would be way too slow.

Note: Over the years, various AI researchers, especially starting with Rodney Brooks in the 1980s, have warmed up to the idea that motor actions should be tightly coupled with sensory signals, i.e., with the environment. You can read about Brooks' subsumption architecture if you are interested in a radically different take on AI. As an aside, you may notice that a branch in the TOK is loosely analogous to a layer in Brooks' subsumption system, with the main difference being that the subsumption architecture does not have a tree of knowledge.

The TOK is an event classification/recognition/attention/prediction mechanism. Its primary purpose is to organize knowledge in a temporal hierarchy of related nodes. Within the context of motor behavior, it serves as a selector or switched conduit for signals arriving from the sensory layers. Sensorimotor behavior thus involves no computation. Essentially, there is a direct link between sensed events and the actions that they generate. I realize that this is somewhat counterintuitive. I expand on this topic in the motor coordination paragraph below.

Action Selection

One of the more obvious observations we can make about behavior is that it is highly selective. That is to say, we do not react to everything we sense all at once. The main reason is that, given the limited number of available effectors, trying to perform more than one task at a time would quickly generate all sorts of motor conflicts. So there is a need for a mechanism that limits the number of tasks the brain can do at a time. One of the nice things about the tree of knowledge is that it organizes events into neat packages called branches and allows only one branch to be active at a time. Since only the active branch can emit motor command signals, this effectively eliminates a huge number of potential conflicts. Furthermore, it restricts the generation of motor commands to temporally related events. So the TOK is itself the primary action selection mechanism. But there is more to it than that.

We all know from introspection that we do not automatically react to events all the time. Most of the times, we refrain from reacting. For example, we do not close the window every time we notice that it's open. Sometimes, we refrain from doing anything other than just observing. So obviously, the function of the action selection mechanism is to decide on not just what action to take but also on whether or not to take any action at all. This is a very important aspect of intelligence, one that is related to other topics such as adaptation, survival and conditioning. I will get back to this subject in a future article.

Motor learning is amazingly simple. It consists of randomly connecting the low-level nodes from a branch of the tree of knowledge to various effectors and wait to see if they generate motor conflicts (see the previous post for more on motor conflicts). Connections that cause conflicts are strongly weakened and almost immediately severed. Eventually, only harmonious connections survive and the system automatically generates coordinated behavior such as walking, navigating and manipulating objects. I know, it all seems like magic. How does it work? I mean, how can there be intelligent behavior if there is no computation? The reason that this is possible is that the driving factor behind intelligence is not really in the brain but in the environment. In other words, pretty much all the computations that are necessary to generate intelligent behavior are performed by the environment, not the brain. By the time the sensors pick it all up, it has already been properly and thoroughly computed. As I have written previously in this series, intelligence is all in the timing of events. In this light, the brain is no more than a big organized switchboard, one which has faith that the environment will do the right thing and do it consistently even if the information captured by the senses is not always perfect.

Brave New World

I've decided to keep a couple of important aspects of my understanding of intelligence close to my chest for the time being. As I wrote elsewhere, I need to consider a way to use this knowledge to generate funds for my research. Regardless of what I do, there is no doubt in my mind that we live in interesting times and that the age of truly intelligent machines is just around the corner. It is much closer than even the most optimistic members of the artificial intelligence community (e.g., people like Ray Kurzweil and the folks at the Singularity Institute) suspect. Needless to say, it will profoundly transform the world in ways that we can't even begin to fathom. It has the potential for both good and bad. We can only hope that it will all turn out for the betterment of humanity. Stay tuned.

Thanks for the comment. Unfortunately, COSA is still a dream. It would take a lot of money to implement a COSA system that is viable and able to challenge the existing paradigm. I personally would prefer an open-source COSA OS and a set graphical dev tools, but I'm open to other possibilities.

If my AI venture is successful, I plan to use some of that profit to finance a COSA research and development team, for both hardware and software.