An Ever Changing/Learing AI

Started by
11 comments, last by wodinoneeye 10 years, 1 month ago

Wizards of AI Programming I need your help,

My good wizards of the programming world. my question to you is; Is there a way to make an AI system that learns from your actions. If it is the fact that there are predestined things that the AI will remember or if there is actually a way to make a program that writes it own code according to your actions as a player. I am not that tech savvy I usually focus on making things pretty, but I was curios and figured I would ask if anyone had any input on the matter at hand. Thanks Everyone

-Ethan Leslie

www.rev6studios.com

"And I looked, and behold a pale horse: and his name that sat on him was Death, and Hell followed with him"

Advertisement

Your question is very broad and very vague. Actually, you ask two questions.

1) Is there a way to make an AI system that learns from your actions?

To the first one, the answer is obviously "yes". Let's figure out a hangman game: the AI could figure out what letters you tend to pick frequently and choose words that have few of these letters, just to annoy you. In other words, it learns from you.

This is of course a pretty simple example but still a very valid one. It is actually the simplest model, making counts/statistics about the player's behavior and then applying a counter-action accordingly.

Then, there are all kind of more advanced models, machine learning techniques, neural networks, etc.

2) Is there a way to make a program that writes it own code according to your actions as a player?

Actually, there is no need to write code to adapt to a player's actions. Most of the time, everything in the game boils down to a set of choices and numbers. You can represent the player's location, it's direction, speed, playing cards, whatever, using numbers. So basically, it's just some data crunching which will throw out a number to tell what the AI opponent should do.

Rewriting code at runtime is rarely used, and surely unnecessary for most AI tasks. However, there are some programming languages which can rewrite their own code at run-time, most notably Scheme/Lisp. Others too, even javascript could do it to some extend with "eval", however, it is considered "very" bad practice to do that. Scheme/Lisp on the other hand have very powerful mechanisms to manipulate their own code. I believe in the seventies or eighties there was also research about AI manipulating their own code, but as far as I know, nothing very fancy came out of it.

This notion that in order to have learning AI you need programs that modify their own code is preposterous, but also very common. The divide between code and parameters is an arbitrary one, and it's much more productive to think of learning as changing parameters.

The other thing that should be mentioned is that adaptive AI is something you probably don't want in a video game. It's hard enough to debug a non-adaptive AI to make sure that the bad guys don't get stuck in corners or do other stupid things that break the illusion. If the AI can change once it's in the hands of the player, this can become a much harder problem, unless the adaptability is very limited and controlled.

This notion that in order to have learning AI you need programs that modify their own code is preposterous, but also very common. The divide between code and parameters is an arbitrary one, and it's much more productive to think of learning as changing parameters.

The other thing that should be mentioned is that adaptive AI is something you probably don't want in a video game. It's hard enough to debug a non-adaptive AI to make sure that the bad guys don't get stuck in corners or do other stupid things that break the illusion. If the AI can change once it's in the hands of the player, this can become a much harder problem, unless the adaptability is very limited and controlled.

Could you point me in the direction of a good starting place to learn the basics of AI. I don't intend to dive into it much as I stated I am mainly graphics oriented however I would like to have a better understanding of what I am talking about so that in the future I don't make myself look foolish like I did in this post.

"And I looked, and behold a pale horse: and his name that sat on him was Death, and Hell followed with him"

This notion that in order to have learning AI you need programs that modify their own code is preposterous, but also very common. The divide between code and parameters is an arbitrary one, and it's much more productive to think of learning as changing parameters.

The other thing that should be mentioned is that adaptive AI is something you probably don't want in a video game. It's hard enough to debug a non-adaptive AI to make sure that the bad guys don't get stuck in corners or do other stupid things that break the illusion. If the AI can change once it's in the hands of the player, this can become a much harder problem, unless the adaptability is very limited and controlled.

Could you point me in the direction of a good starting place to learn the basics of AI. I don't intend to dive into it much as I stated I am mainly graphics oriented however I would like to have a better understanding of what I am talking about so that in the future I don't make myself look foolish like I did in this post.

I'd check out the first post on the AI Forum...it'll point you to many great books and sites to get your AI blood flowing!

Could you point me in the direction of a good starting place to learn the basics of AI. I don't intend to dive into it much as I stated I am mainly graphics oriented however I would like to have a better understanding of what I am talking about so that in the future I don't make myself look foolish like I did in this post.


As already mentioned, the sticky at the top of this forum is a good starting place. If you want to get more serious about it, I particularly recommend the text book "Artificial Intelligence: A Modern Approach" (which is listed in the sticky).

EDIT: Oh, and I meant to say that you didn't look foolish at all. Although I do think you are wrong, the way you were thinking was the way everyone thought in the 70s, and is still very common.
Basically, intelligence is the ability to gather information.

However, to achieve human level intelligence, you would have to make a program that can debug itself (two different arguments and not so preposterous).

But it is true that it is possible to make AI that learns. Yet, you say ever learning.

Now, just because someone has information, doesn't mean they know how to use that information in useful and meaningful ways.

They call me the Tutorial Doctor.

Basically, intelligence is the ability to gather information.
However, to achieve human level intelligence, you would have to make a program that can debug itself (two different arguments and not so preposterous).
But it is true that it is possible to make AI that learns. Yet, you say ever learning.
Now, just because someone has information, doesn't mean they know how to use that information in useful and meaningful ways.

Its more than just "gather information" (including what the information means) it is then figuring out then WHAT to do about that information and then HOW to achieve doing it.

Further complications is when you have time involved (discerning the progression of information temporally), and when you have imperfect information (uncertainty) to deal with.

The learning aspect then has to cover that entire process

The 'What' part also requires having gathered HOW to tell what is 'good'/'bad' or 'right'/'wrong' to be able to make the decisions required (which can include knowing when enough information has been gathered to make a proper decision, or interim actions until enough is gathered, or deciding that there never will be enough information)

--------------------------------------------[size="1"]Ratings are Opinion, not Fact
I think you and I are saying the same thing, hence, my last statement. When an agency has gathered certain information, they call it gathered intel.

Whether by sensory mechanisms or not, we are constantly gathering information.

Example. Three men are looking towards a tree, but only two of them can see the tree, the other is blind.

One of the two that can see is mute and crippled. The other has all of his senses.

Without some way for the blind man to gather information about the tree, he has no way to describe it, even if he is a brilliant person.

Without some way for the mute man to relay his information, how can he describe it?

Which man is intelligent and which isn't?

They define intelligence as the ability to understand, but in the example above, isn't one man's ability to understand limited by his handicap?

They call me the Tutorial Doctor.

I think you and I are saying the same thing, hence, my last statement. When an agency has gathered certain information, they call it gathered intel.

Whether by sensory mechanisms or not, we are constantly gathering information.

Example. Three men are looking towards a tree, but only two of them can see the tree, the other is blind.

One of the two that can see is mute and crippled. The other has all of his senses.

Without some way for the blind man to gather information about the tree, he has no way to describe it, even if he is a brilliant person.

Without some way for the mute man to relay his information, how can he describe it?

Which man is intelligent and which isn't?

They define intelligence as the ability to understand, but in the example above, isn't one man's ability to understand limited by his handicap?

Ah but the Blind man can hear correct? Then wouldn't he have heightened hearing, thus making it possible to hear the differences in the environment and depict the tree in detail. Let alone the ability to touch the tree feel it and describe it in a way that someone with sight would never imagine. Hawking A clear example of someone who is cripple and Mute let alone brilliant has found a way to share mass amounts of information. We live in a day and age where a "handicap" is not means for a limit of what one can do. Personally, I feel that the person with all of their senses would be the one with the true handicap. They have a under appreciation for everything in life and will never experience what the other two could even begin to thus making him Less "brilliant:

"And I looked, and behold a pale horse: and his name that sat on him was Death, and Hell followed with him"

This topic is closed to new replies.

Advertisement