A "Generic" I.A. improvement

All about getting the AI less baka...
Yorien
Posts: 33
Joined: Tue Feb 02, 2010 10:59 pm

Re: A "Generic" I.A. improvement

Post by Yorien »

Yorien says:
wololo wrote:I see your point but I don't think you see mine.
Next time you play against the AI, it has to know a bit about your deck. Last time you played a llanowar elve, you killed it with it, so it has to be careful of llanowar elves. That card happened to have enchantments on it, but that's already included in the stats.

The stats should take cards into account on an individual basis, but also on a "per id" basis, to use the information from previous battles.

Not sure I'm clear enough, but, if you played a "serra angel" and used it extensively, it doesn't matter if it was serra angel[4] or serra angel[2], what matters is that it was a Serra angel and it's somehow part of your combo, so next time you play it, the ai has to remember that serra angel is a danger. Not a particular instance of serra angel.

Because of that, I went with the simple way of treating only ids.
The real fix, as you mention, would be to work with both IDs of the card AND id of the instance.
if you attack with Serra Angel[1], the AI needs to increase the danger level of Serra Angel[1], but also (to a lesser extent) of all other Serra Angels.
If that particular Serra Angle has an enchantment on it, the enchantment also gets its danger level increased.

Cleaning the DB after each match loses LOTS of the efficiency of the system. one game is not enough for the AI to understand what is dangerous or not. That's my point.
Yep, I see your point, I was already talking about this with almosthumane some posts ago in this same topic:
...
Even better, Your idea could be placed by the IA onto another database (since most decks will remain static) so the IA "remembers" previous matches (something like Soccer League Stats: vsDeck 137, Wins=4, Loss=13, most threatening cards=#3654[112 threat], #97633[92 threat], #67541[79 threat], Less threatening cards= #1123[12 threat], #78656 [8 threat]), database fed by the "threat meter". This way the IA "learns" how to deal with returning opponents, both taking into account the "current match" threat and "lifetime matches". First time you play against an opponent you don't know his/her deck, but the more you play against, the more loy learn against that deck behaviour.

This way, IA adapts to the opponent's playstyle instead of taking a fixation with particular "coded" cards; two games against the same deck doesn't mean the other IA/playes will play exactly the same cards in the same order and make the same use of them than in the previous match.
...
Card #ID could be used in that "lifetime DB", and "unique #ID" in "current battle DB", so IA takes into account both what's happening now, and what happened before. Since "current battle DB is cleaned in a per-match basis, first it should fed the "lifetime DB" and then cleared (and another idea: "current battle DB" could give people a nice "post battle match stats" screen)

In this case, since feeding the "lifetime DB" should take many matches, "current battle DB" should have higher priority (you could get lucky once or twice with that Serra you speak off, but if after 20 battles Ia has a win/lose ratio of 5/15 and Serra is still in the "top five" - or "top three" - danger cards... then IA should start painting a bullseye on it).

An finally, this may be a more or less particular case and probably should have to be hardcoded, but in "token-based decks" like the elven one, probably IA should concentrate on beating out the crepes off the generators instead of the tokens.
Locked