AI Glossary / Governance, ethics and safety / Advanced

Adversarial search

Definition

Adversarial search is decision-making by exploring possible actions and the responses of other agents whose interests conflict with yours. Game playing provides a standard setting: a move must be judged partly by what an opponent can do next. Minimax is a classic method for two-player, deterministic, zero-sum games with perfect information, but adversarial search is broader than that particular algorithm.

What it means

Ordinary path search can ask which sequence of actions reaches a destination. A competitive game adds a complication: you do not control every action along the sequence. A promising outcome may depend on an opponent choosing a move they have no reason to choose.
Adversarial search makes those response choices explicit. Its conclusions remain conditional on the rules, available information and objectives represented in the model. Describing a commercial competitor as an opponent does not automatically make a real market a two-player zero-sum game. Cooperation, hidden information and uncertain events may require a different formulation.

How it works

A game tree represents positions and legal moves. In minimax, terminal outcomes receive utilities from one player's perspective. That player selects the largest available value at its turns; the opponent selects the smallest at its turns. Values propagate back to the current position, identifying a move under the assumed opposing behavior.
Full trees often become too large. Depth-limited search uses an evaluation function for positions where exploration stops, making the result dependent on estimated rather than complete outcomes. Alpha-beta pruning can skip branches that cannot alter the minimax decision for the searched tree. It preserves the minimax value under the same evaluation setup, though tied move selection can vary.
The search still needs an accurate model of legal actions. Faster calculation cannot repair an omitted response or a wrongly scored outcome.

Three practical examples

  • A board-game program explores its moves and its opponent's replies. It avoids an attractive capture if the reply would lead to a worse final position under its evaluation.
  • A training simulator lets a defensive player allocate resources while a simulated opposing player chooses a permitted response. The result is useful only within those specified capabilities and scoring rules.
  • A business workshop builds a simplified competitor-response tree. Participants use it to expose assumptions about likely reactions, rather than presenting a toy game's recommendation as a market forecast.

Think of it this way

Think of planning a move while giving the other player a chance to choose their reply. You cannot select the best reply on their behalf just because it makes your plan look good. The tree forces you to distinguish decisions you control from decisions controlled by someone else.

Worked example

Suppose you choose between moves A and B. Your opponent then chooses one of three replies, and the game ends. All scores are your payoff; the opponent prefers a lower score.
For A, the three possible scores are 7, 4 and 6. Its minimax value is the minimum, 4. For B, the scores are 9, 2 and 8, so its value is 2. At your starting position, choose the maximum of those two values: max(4, 2) = 4. Minimax therefore selects A.
Selecting B merely because its best outcome is 9 assumes a cooperative reply. Averaging the replies also changes the assumptions: A's average is 17 / 3, approximately 5.67, while B's is 19 / 3, approximately 6.33. Those averages would favor B if each reply were equally probable, but minimax does not assume that distribution.
For a pruning illustration, evaluate A fully first, establishing an available value of 4. While exploring B, suppose the reply scoring 2 is examined first. B's minimum can now be no greater than 2, whatever its other scores. Its remaining replies can be skipped when selecting the root move. This establishes that B cannot beat A; it need not establish B's exact value in a larger or partially unexplored tree.

Illustrative case study

Fictional Willow Games builds a small competitive puzzle. Its first agent consistently chooses moves that offer a large immediate reward, but human testers discover a reply that traps it one turn later.
The team adds a game-tree search with alternating player choices. Initial results improve, yet a deeper trap remains outside the search limit. Rather than claiming the agent plays optimally, the team documents its depth limit and evaluates the position-scoring function on those difficult cases.
It also checks the move generator against the puzzle's rules: one legal defensive move was missing, causing some searched positions to look worse than they really were. The correction changes decisions without changing the search algorithm. The case illustrates three distinct sources of error: ignoring an opponent, stopping too early and searching an inaccurate model.

Common misconceptions and mistakes

Taking the best outcome anywhere in a tree as attainable: an opponent controls some branches.
Assuming minimax predicts actual human behavior: it uses a specified worst-case response model.
Calling depth-limited evaluation a proof of optimal play: a favorable estimate can overlook later consequences.
Treating pruning as arbitrary deletion of inconvenient moves: valid alpha-beta pruning follows decision bounds.
Using zero-sum reasoning where both parties can gain: the payoff structure must fit the problem.

Business use

Adversarial search is useful when decisions genuinely depend on strategic responses and those responses can be modeled meaningfully. Start by identifying who controls each action, what information they possess and how outcomes are valued. Use sensitivity checks when payoffs or opponent behavior are uncertain. A transparent small model can help challenge a plan, but its apparent precision should not hide unsupported assumptions.

People also ask

Is minimax the whole of adversarial search?

No; it is one important algorithm within the broader area.

Does alpha-beta pruning change the minimax value?

Correct pruning preserves it for the same searched tree and evaluation.

Can the method handle chance or hidden information directly?

The basic formulation here requires extensions or different methods for those settings.

Check your understanding

Why does the worked example select A?

Answer: Its worst reply gives 4, compared with B's 2.

Why is B's average irrelevant to that minimax choice?

Answer: No equal-probability reply assumption was made.

What does a search-depth limit introduce?

Answer: Dependence on estimates of outcomes beyond the explored tree.

Related terms

  • Minimax
  • Game tree
  • Alpha-beta pruning
  • Utility
  • Evaluation function
  • Zero-sum games
  • Monte Carlo tree search
  • zero-sum game
  • expectimax

Learn next

Draw a two-move game tree and label who controls each node. Calculate its minimax value, then change the opponent to a stated random policy and compare the resulting choice.

  • Game tree
  • Minimax value
  • Random policy

More in Governance, ethics and safety

  • Adversarial Domain Adaptation - Adversarial domain adaptation is a family of methods that trains a useful predictive representation while making it harder to identify which domain supplied...
  • Adversarial example - An adversarial example is an input deliberately modified to cause a machine-learning model to produce an incorrect prediction or other unintended behavior.
  • Adversarial loss - Adversarial loss is a training objective derived from a competition between models or model components.
  • Adversarial Training - Adversarial training is a model-training approach that uses deliberately challenging, permitted modifications of training inputs to improve resistance to...
  • Adverse impact ratio - An adverse impact ratio compares the selection rate for one group with the selection rate for a reference group.
  • AI governance - AI governance is the system of decision rights, responsibilities, policies and oversight through which an organization directs its development, acquisition...

Sources

Russell and Norvig, AIMA algorithms, minimax search and alpha-beta search. https://aima.cs.berkeley.edu/algorithms.pdf University of California, Berkeley, CS 188, Minimax, pruning and evaluation functions. https://inst.eecs.berkeley.edu/~cs188/textbook/games/minimax.html The payoff tree, workshop suggestions and Willow Games case are original teaching illustrations.

Previous: Adversarial machine learning Next: Adversarial stylometry

  • Home
  • Daily AI Updates
  • Blog
  • AIFBL Academy
  • AI Glossary
  • Products and Tools
  • Store
  • Free CFO AI Prompt Pack
  • About Shihan Sheriff
  • Privacy Policy
  • Terms of Use
  • Refund Policy
  • Cookie Policy
  • Earnings Disclaimer