0% found this document useful (0 votes)
35 views

Lecture 6 Adverserial Search

Artificial intelligence has made significant progress in game playing by developing algorithms to approximate optimal strategies. These algorithms include minimax for deterministic games to choose the move with the highest minimum outcome against the opponent's best response. Evaluation functions were also developed to assign values to board positions. While perfect play remains intractable for most games, pruning techniques and machine learning have allowed programs to achieve superhuman performance in chess and checkers by searching more deeply. Nondeterministic games introduce uncertainty that must be accounted for through algorithms like expected value calculations over multiple simulations.

Uploaded by

Usama Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views

Lecture 6 Adverserial Search

Artificial intelligence has made significant progress in game playing by developing algorithms to approximate optimal strategies. These algorithms include minimax for deterministic games to choose the move with the highest minimum outcome against the opponent's best response. Evaluation functions were also developed to assign values to board positions. While perfect play remains intractable for most games, pruning techniques and machine learning have allowed programs to achieve superhuman performance in chess and checkers by searching more deeply. Nondeterministic games introduce uncertainty that must be accounted for through algorithms like expected value calculations over multiple simulations.

Uploaded by

Usama Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 20

Artificial Intelligence

Game Playing
Games vs. search problems
• “Unpredictable" opponent  solution is a strategy
• specifying a move for every possible opponent reply
• Time limits  unlikely to find goal, must approximate
• Plan of attack:
• Computer considers possible lines of play (Babbage, 1846)
• Algorithm for perfect play (Zermelo, 1912; Von Neumann, 1944)
• Finite horizon, approximate evaluation (Zuse, 1945; Wiener, 1948; Shannon, 1950)
• First chess program (Turing, 1951)
• Machine learning to improve evaluation accuracy (Samuel, 1952-57)
• Pruning to allow deeper search (McCarthy, 1956)
Types of games
Game tree (2-player, deterministic, turns)
Minimax
Perfect play for deterministic, perfect-information games
Idea: choose move to position with highest minimax value
= best achievable payoff against best play
E.g., 2-ply game:
Minimax algorithm
Properties of minimax
• Pruning does not affect final result
• Good move ordering improves effectiveness of pruning
• With “perfect ordering," time complexity = O(bm/2)
doubles solvable depth
• A simple example of the value of reasoning about which
computations are relevant (a form of metareasoning)
• Unfortunately, 3550 is still impossible!
Resource limits
Evaluation functions
Deterministic games in practice
• Checkers: Chinook ended 40-year-reign of human world champion Marion
Tinsley in 1994. Used an endgame database defining perfect play for all
positions involving 8 or fewer pieces on the board, a total of 443,748,401,247
positions.
• Chess: Deep Blue defeated human world champion Gary Kasparov in a six-
game match in 1997. Deep Blue searches 200 million positions per second,
uses very sophisticated evaluation, and undisclosed methods for extending
some lines of search up to 40 ply.
• Othello: human champions refuse to compete against computers, who are too
good.
• Go: human champions refuse to compete against computers, who are too
bad. In go, b > 300, so most programs use pattern knowledge bases to
suggest plausible moves.
Nondeterministic games: backgammon
Nondeterministic games in general
In nondeterministic games, chance introduced by dice, card-shuffling
Simplified example with coin-flipping:
Algorithm for nondeterministic
games
Games of imperfect information
• E.g., card games, where opponent's initial cards are unknown
• Typically we can calculate a probability for each possible deal
• Seems just like having one big dice roll at the beginning of the
game
• Idea: compute the minimax value of each action in each deal,
then choose the action with highest expected value over all
deals
• Special case: if an action is optimal for all deals, it's optimal.
• GIB, current best bridge program, approximates this idea by
1) generating 100 deals consistent with bidding information
2) picking the action that wins most tricks on average
Summary

• Games are fun to work on! (and dangerous)


• They illustrate several important points about AI
• perfection is unattainable  must approximate
• good idea to think about what to think about
• uncertainty constrains the assignment of values to states
• optimal decisions depend on information state, not real state
• Games are to AI as grand prix racing is to automobile
design
Credits

• Stuart Russell's (Berkeley) course slides,


http://aima.cs.berkeley.edu/instructors.html

You might also like