Glad to see the scene is still alive and well. Back when it was picking up I made a Ruby client to one of the server based BWAPI clients, I built a really neat Ruby API to it too. Unfortunately I invested so much time at that point the actual 'AI' I made just 6-pooled the opponent, in just 44 lines though[1]!
Lately the release of mruby made me think maybe I should try again :) (mruby seriously reduces the amount of effort required in getting Ruby to talk to BWAPI.)
I used the python BWAPI client. I recently tried to get back into it but it seemed a lot more buggy and BWAPI wouldn't run on my newer Windows PC. :/
It was a lot of fun. Figuring out a base layout was the most difficult part for me. I ended up using the random function and placing buildings around my main base at random offsets. Didn't get too far with that, haha.
Yeah, silly problems like that really made being competitive with established AI's or even players hard. Just an AI that sets up a base properly and manages to build a proper army at the right timings but without any strategic insight into the opponent or even micro-decision making (which unit targets which opponent) will still do very decently, just because all the boiler plate is so much work not many AI's get to the actually being 'intelligent' part.
Seems the TvZ part of the bot could be improved by getting up turrets in time. Maybe they could get the bot to do a statistical analysis of builds they are likely to face in each match-up and use a build order that counters it.
Well, if you build enough to be safe against just about everything, your build will lose against any build which is properly executed. If you play the numbers and just have set builds which counter the most popular builds you might face, the human will pretty quickly figure out what the AI is doing and adapt their own build.
One of the most common and basic techniques in Starcraft is to bait another player into thinking you are doing a certain popular build, and then do something theoretically inferior but which requires a wildly different response.
Know your opponent is going to have turrets up at 5:30 on the clock? New build! Hits at 5:25! Have the AI use builds which have their turrets at (x-2) minutes just in case? Well, that's going to be an awful build against almost everything.
As shown in one example in the paper, even when the AI was extremely lucky and hard-countered the human's build, the human was able to adapt, respond, and win handily.
Since even the top humans are able to trick each other in these manners, you'd basically need general/strong AI to be able to compete.
> Well, if you build enough to be safe against just about everything, your build will lose against any build which is properly executed.
No one mentioned being safe against just about everything, just the important timing attacks (such as 3-hatch muta), which are known to be a big part about Starcraft. If you're going a build order that gets you straight-up killed by one of the most popular build orders, something is going wrong. Even if the enemy timing hits 5s before you get turrets up, your build should have a fallback e.g. marines in the base to hold off mutas until turrets complete, which is what a lot of progamers do off a 4-rax opening. Your (x-2) minutes statement seems to assume that AI builds can't cut corners and are forced to play the safest build possible every game.
> Since even the top humans are able to trick each other in these manners, you'd basically need general/strong AI to be able to compete.
This flies in the face of game theory, which is focused on solving exactly the problem you deem impossible to solve without strong AI. In 2008, poker bots (researched by the same university, the University of Alberta) have been able to defeat human experts in limit heads-up poker [1].
Perhaps the problem statement the researchers are working with is different from the one I'm envisioning. Maybe they are training their bots with only replays from other bots, rather than with replays from the top players in the world which constitute what we currently regard to be optimal play. I am thinking that the researchers may overlap with the poker research group, which suggests that the entire project is more focused on using superior game theory as the winning condition rather than exploiting areas where the computer is already known to be better than the human e.g. micro (giving hundreds of units unique instructions) and macro (sending build commands to buildings on the clock). The former is shown in the wraith vs. hydralisk video [2]. This may not work as well as in poker and may not yield as impressive games in the short-term as focusing on micro and macro, but the research is definitely fascinating!
They haven't even come close to a build which is safe against popular build orders or adapts. Judging by the difficulty they're having making the AI do what they want, this might be a bit harder than poker.
Top play uses huge tradeoffs depending on what the progamer thinks they are facing; that would require an AI which can dynamically scout and effectively adjust its build based on what it sees. That isn't even taking tricks into account.
Basically, everything that you are saying is so far beyond what they're doing to program the AI that it's completely irrelevant. Critical things are hard-coded instead of adaptive, so that would all have to be written from scratch.
(None of this proves that it's not possible to program an AI which can beat humans without general AI, of course. I suppose that if you had enough scenarios with adaptive logic built in, the AI's ability to perfectly split marines or zerglings could be used to design a timing attack impossible for humans to stop.)
edit: I did not see your edit of the two sentences of your post when I wrote mine, or I wouldn't have covered the same concept.
It's also good to note that in any tournament setup, the players would be in a best of 3 or best of 5. That means there's some meta-gaming going on as well. (Will the player go Muta 2 times in a row? or won't they? What did they do in the past?)
Building these AI's is actually a lot of work. They're usually built by a single or a few persons, in their spare time or perhaps as a college course. Most time is spent making sure your bot actually plays the game. Very little if any at all time is spent making the bot smart enough to deal with situations like this. In this case, obviously there's a bug where the bot is not dealing property with aerial attacks. A human player would have given up or made a suicide attack the second those mutas landed as he realized he missed a turret at his main.
Very well said. I've started a few month ago on an AI/Bot for 0AD an open source game. Scripting language is JavaScript running on SpiderMonkey. So far I've accumulated thousands of locs, learned a lot about writing fast code against a specific engine and have barely more than a framework. But I still remember the moment the bot did it's first baby steps and actually build a structure to train some scouts and started exploring the map.
Also it became a decent exercise in dealing with abstraction. The code base just explodes if you do not follow DRY - strictly.
Yes that was dumb. Should have basetraded (attacked with the tanks to force retreat (buy time and build towers) or destroy zerg base or 2 if the zerg keeps attacking).
Your research is out of date, then. :) Even the game of Go, thought to be the hardest for computers, now has bots at the 6-dan (stronger than >99% of humans will ever be) level.
Lately the release of mruby made me think maybe I should try again :) (mruby seriously reduces the amount of effort required in getting Ruby to talk to BWAPI.)
1] https://github.com/d-snp/RProxyBot/blob/master/basic_ai.rb