---
title: "Learning to Win by Reading Manuals in a Monte-Carlo Framework"
description: "A Civilization II player learns which advice to use from the game manual, using Monte Carlo simulations to test moves and improve its…"
canonical: "https://research.elamur.ai/free/en/papers/branavan-2011-learning-win-reading-manuals-monte/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/branavan-2011-learning-win-reading-manuals-monte/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2011](https://md.research.elamur.ai/free/en/papers/2011/) / Learning to Win by Reading Manuals in a Monte-Carlo Framework

# Learning to Win by Reading Manuals in a Monte-Carlo Framework

Paper · 2011 · S.R.K. Branavan, David Silver and Regina Barzilay

**Authors:** [S.R.K. Branavan](https://md.research.elamur.ai/free/en/authors/s-r-k-branavan/), [David Silver](https://md.research.elamur.ai/free/en/authors/david-silver/) and [Regina Barzilay](https://md.research.elamur.ai/free/en/authors/regina-barzilay/) · **Year:** 2011 · **Venue:** Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies · **Licence:** [CC BY-NC-SA 3.0 (ACL Anthology, before 2016)](https://creativecommons.org/licenses/by-nc-sa/3.0/)

[**120** citations OpenAlex, 2026-10-14](https://openalex.org/works?filter=cites:W1580222235|W3121854931) · [Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies](https://aclanthology.org/volumes/P11-1/) · [licence](https://creativecommons.org/licenses/by-nc-sa/3.0/)

- [Publisher's page](https://aclanthology.org/P11-1028/)
- [PDF](https://aclanthology.org/P11-1028.pdf)
- [DOI 10.1613/jair.3484](https://doi.org/10.1613/jair.3484)
- [OpenAlex](https://openalex.org/W1580222235)

Citations: OpenAlex, 2026-10-14.

## Summary

A game manual can tell a player what makes a good place to settle without specifying where to build the next city. The player still has to recognize when the advice applies and choose among the actions the game allows. The authors ask whether a computer player can learn to make those connections from the consequences of its moves. They test the idea in Civilization II, using the official manual as a source of strategy advice and the game itself to judge the results of simulated play.

The player looks ahead by running Monte Carlo rollouts, meaning repeated simulations of possible continuations from the current position. An action-value estimate guides the moves inside each simulation. For each position and candidate move, the language component selects a sentence from the manual and assigns its words roles associated with actions, conditions in the game, or background language. The selected words and the game’s own descriptions of the position and move then contribute to the estimate. The score at the end of a rollout supplies feedback for learning which textual cues help. The player receives no human labels telling it which passage applies to a position or which words express its conditions.

Against the built-in opponent in Freeciv, the full system won 53.7% of games within the first 100 steps, compared with 17.3% for the Monte Carlo player that used game information alone. In separate runs played to completion, the corresponding win rates were 78.8% and 45.7%. Within the first 100 steps, controls that shuffled the manual’s words or added hidden choices driven solely by game information both finished below the full system. Selecting sentences without labeling word roles also improved on the game-only player. The full system’s higher win rate over that sentence-selection variant did not reach statistical significance in that comparison.

The language analyses help explain where the manual mattered. Early in play, the system more often chose a manual sentence over an unrelated newspaper sentence and was more accurate at distinguishing words about actions from words about game conditions. A player that used the full system for the first 50 steps and then stopped consulting the manual achieved a win rate close to that of the full system over the first 100 steps. The experiments show how advice aimed at beginners can shape the opening of a game, with simulation feedback helping the player decide which parts of that advice to use.

## Deep dive: Learning to Win by Reading Manuals in a Monte-Carlo Framework

A Civilization II player learns which advice to use from the game manual, using Monte Carlo simulations to test moves and improve its chances of winning. · about 37 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### What the manual leaves for the player to decide

In Civilization II, a settler’s ability to found a city leaves open where it should do so. Terrain, nearby resources and the presence of a river can make a location more attractive. The manual gives advice in those terms. Applying it requires connecting words about terrain and water with properties of actual map squares, then recognizing that those properties matter to a particular candidate move. A sentence about a favorable location can inform the decision while leaving plenty of room for judgment about the rest of the position.

Consider what the player has available before it makes that connection. The game describes a position in terms of tiles, terrain, resources, cities and units. It also supplies legal moves. The manual describes situations in prose, sometimes naming an action and its conditions in the same sentence, sometimes discussing a more general objective. These sources describe aspects of the same game at different levels. A game feature can identify a river on the map, while a sentence can suggest that the river matters when choosing a site for a city. The computational problem is to connect the two at the point when doing so can affect a decision.

A player can try to learn those relationships through play alone. It would need experience with settlement moves across many combinations of terrain and resources, and the value of a move might become apparent only after later decisions. Each position also offers many other choices. The authors point to the size of the space of possible positions, the distance between early decisions and their eventual consequences, and the number of continuations the player can consider. The manual could give the search a reason to try promising actions sooner, provided the player can tell when a passage is relevant.

The need for contextual judgment makes it difficult to train a text extractor by labeling the manual in advance. An annotator might easily identify a passage as advice about settlement. Deciding whether that passage is useful for a particular unit, action and position would require much more information. As the game changes, so does the set of passages worth considering. The authors therefore use game feedback to learn how to find useful material. This makes relevance part of the control problem: a learning signal is available when a simulated continuation ends, even though the game never identifies the sentence that helped.

The objective also sets a practical level of detail for the language analysis. The player needs to recover distinctions that can improve its estimates of moves. Identifying which words refer to a game condition and which describe an action can preserve a relationship that word counts would blur. A full account of the meaning of every manual sentence would serve a broader purpose than the experiment requires. The paper treats text analysis as a way to improve decisions with an explicit utility, the quantity the player tries to make larger.

#### From following directions to using advice

The authors place the work in grounded language acquisition. In that area, a system learns to interpret words by connecting them to situations, events or behavior outside the text. The paper is particularly close to reinforcement-learning work in which a system acts in an environment and receives feedback about what happens. That approach provides supervision through the consequences of a choice. Earlier work discussed in the paper uses this setup to connect written instructions to actions. [Reinforcement Learning for Mapping Instructions to Actions](https://md.research.elamur.ai/free/en/papers/branavan-2009-reinforcement-learning-mapping-instructions-actions/)

The authors also cite work on interpreting high-level instructions as commands. Even when the instructions leave some steps implicit, they describe a task to carry out. A strategy manual plays a looser role. It can suggest a good settlement site, describe a useful unit, or compare ways of developing a city. The reader has to decide whether the passage is pertinent now, as well as what observable conditions and available actions it concerns. The difference is visible in the output each task calls for. Following a document of instructions produces an execution of the specified task. Here, the output is a move selected with the help of advice, after comparing simulated continuations. [Reading between the Lines: Learning to Map High-Level Instructions to Commands](https://md.research.elamur.ai/free/en/papers/branavan-2010-reading-between-lines-learning-map/)

The paper distinguishes its task from another line of work on understanding written rules for games. A rule may determine which move is valid. Strategic advice helps choose among moves already known to be valid. The earlier game-language approach the authors discuss used previously collected records of play as supervision for learning rules. In their own setup, the game supplies legal actions directly, and the player generates its experience through simulations. This choice reflects both the goal of learning to play well and the cost the authors anticipate for collecting traces in a game of this size.

Monte Carlo search supplies the other half of the method. The authors describe its use in settings including Go, poker and real-time strategy games. The common idea is to examine possible moves by sampling what could happen after them. Where each position has many possible actions, storing a separate estimate for every position and move would give sparse experience for many of those choices. The paper instead approximates action values using features shared across positions and moves. A feature learned from one simulated settlement decision can then be active in another position with similar characteristics. Adding manual-derived features to that representation gives language a way to affect search while leaving its advice open to revision through play.

### The method, step by step

#### From a candidate move to an actual move

At a position in the game, the player needs to choose a legal action. It runs a set of simulated continuations from that position, with the built-in opponent playing the other side. The player makes choices for its own side inside those continuations using its current estimates of action values. Each continuation supplies an observed score at its endpoint. The search groups those scores by the first move of the simulation and uses their averages to choose which move to execute in the actual game.

The manual enters at the point where the player estimates a candidate action’s value. The player represents the position and the move with features, which are numerical indicators of properties or combinations of properties. It also evaluates sentences in the manual for their relevance to that position and move. After choosing a sentence, it assigns a role to each word. The selected words can then contribute features in combination with the game information. For a settlement move, words about grassland can interact with features describing the destination or the action of founding a city.

There are consequently different choices at different times. Inside a simulation, the action-value estimate is used to choose a move quickly, with occasional random exploration. Inside the estimate, the language component makes its own sampled choices about the sentence and its word roles. The actual game move is chosen after gathering utility observations from multiple simulations. This arrangement lets a manual sentence affect which continuations get explored. The continuation results, in turn, shape how strongly similar language affects later estimates.

How manual advice enters Monte Carlo search The steps in order.

#### The game interface and the search target

The authors describe the game as a Markov decision process. In this representation, the current state contains the game information on which the transition to the next state depends. The action is a choice available to the player, and the transition describes the distribution of states that can follow. The game engine lets the algorithm sample the transition by executing an action in a simulated position. The value function can therefore learn from observed continuations without requiring the search to enumerate the possible outcomes and their probabilities.

```
⟨S, A, T, R⟩
```

`S` is the set of possible game states. `A` denotes the space of legal actions, with the available choices determined by the state. `T` is the transition function. `R` is the utility function that assigns a real-valued measure of how favorable a state is. The angle brackets collect these parts into the description of the decision process.

```
T(s′ | s, a)
```

`T` gives the probability of the next state `s′` conditional on taking action `a` in current state `s`. Both `s` and `s′` are in the state set, and `a` belongs to the game’s action space. The vertical bar indicates the condition under which the transition probability is evaluated.

The state in the application includes the world map, tile attributes, and properties of the players’ cities and units. Tiles can differ in terrain and resources. Units have their own choices, and cities have actions as well. The authors study a game between two players on a map of 1000 squares. They report approximately 18 units under a player’s control on average and 15 choices for a unit. The paper gives 10²¹ as an indication of the size of the combined action space. To make the choice manageable, the authors assume that, given the state, a unit’s action can be treated independently of the choices of the player’s other units. This is a simplifying assumption for action selection. The game engine still produces the consequences of actions when it advances the simulated position.

A rollout can, in principle, continue until the game has a winner. The paper uses shorter simulations because completing a Civilization II game each time it needs to evaluate a move would be too expensive. At a rollout endpoint, it uses the ratio of the player’s game score to the opponent’s. The scores are available during play and provide a noisy indication of progress. Game wins are measured separately in evaluation. This separation matters because the search needs feedback at positions that can still be far from an actual win.

```
R(s_τ) = score_player(s_τ) / score_opponent(s_τ)
```

`R` is the utility in this application, evaluated at state `s_τ`. The subscript `τ` denotes the endpoint of the rollout. `score_player` and `score_opponent` denote the game scores of the search player and the built-in opponent at that state. The slash denotes their ratio. The score names write out the utility that the authors describe in prose.

#### Choosing moves during a simulation

The paper starts from a feature-based action value without text. Properties of a state and action are encoded in a vector, and learned weights give a value to their combination. If a feature is present in many positions, the corresponding weight can be informed by simulated experience across those positions. This is how the estimate can give a candidate move a value even when the exact combination of position and move has seldom occurred.

```
Q(s, a) = w · f(s, a)
```

`Q` is the estimated value of action `a` in state `s`. `f(s, a)` is the real-valued feature vector for the state and action. `w` is the vector of learned weights for those features. The centered dot is the dot product, which multiplies corresponding entries and sums their contributions.

Inside each rollout, the player uses an ε-greedy rule. On the exploratory branch, it draws a move uniformly from those available, giving each legal action the same chance. Otherwise, it takes a move whose current estimate is highest. Exploration gives some moves a chance to produce evidence even when the current estimates would rarely lead to them. This is particularly pertinent early in learning, when the usefulness of both game and text features has yet to be established.

```
aᵤ ∼ { Uniform(legal actions in sᵤ)     with probability ε
       arg maxₐ Q(sᵤ, a)                otherwise
```

`u` is the step within the rollout, `sᵤ` is the simulated state at that step, and `aᵤ` is the move chosen there. The symbol `∼` indicates the sampling rule. `Uniform` means an equal chance for each legal move. `ε` is the probability of using that exploratory branch. `arg maxₐ` selects an action `a` that gives the greatest value of `Q` among the actions available in `sᵤ`. For the language-aware player, that estimate also uses the manual.

A completed rollout returns its opening action and endpoint utility. Simulations started with the same move can follow different paths because of exploratory choices and the sampled game transitions. The pseudocode compares moves using the mean endpoint utility of the simulations that opened with each one. This makes the estimate at the root an empirical comparison across the continuations the player sampled.

```
aₜ = arg maxₐ [(1 / Nₐ) ∑ᵢ:ₐᵢ₌ₐ rᵢ]
```

`t` indexes the step in the actual game, and `aₜ` is the move selected there. `a` is a candidate opening move that was sampled, and `Nₐ` counts the rollouts beginning with it. `i` indexes a rollout, `aᵢ` is its first move, and `rᵢ` is its endpoint utility. The sum includes only indices for which `aᵢ` equals `a`. Dividing by `Nₐ` yields the mean for that move, and `arg maxₐ` selects a move with the highest mean. Once the selected move advances the actual game, rollouts start from the resulting position.

#### Finding a sentence for a move

The authors’ network takes the state, candidate action and manual as input. Its first hidden layer represents choices that depend on the input but have no training labels of their own. One choice is which manual sentence to use. The other concerns the roles of words in the selected sentence. The following layer turns those choices and the game information into a feature vector. The output combines those features in an action-value estimate.

A relevance feature can compare words in a sentence with labels in the game representation. For instance, the presence of the word for a terrain type in a sentence can supply evidence when a candidate action involves a tile with that terrain. Other features can combine the words with attributes of the action. The fitted relevance weights determine which comparisons help the player identify advice. The same sentence can receive different scores when the state or candidate action changes.

The choice is stochastic. Scores are transformed by a softmax, which exponentiates them and assigns each candidate a share of their total. Larger scores yield higher probabilities, and the player samples a choice from those probabilities. For a single use of the layer, only the sampled choice is active. Thus a particular estimate can use features from a single passage even when several passages have substantial probability.

```
p(yᵢ = 1 | x⃗) = exp(u⃗ᵢ · x⃗) / ∑ₖ exp(u⃗ₖ · x⃗)
```

`p` is the probability of the event before the vertical bar, conditional on input feature vector `x⃗`. `yᵢ` denotes hidden unit `i`, with `1` indicating that it is active. `u⃗ᵢ` is the weight vector for that unit. The centered dot combines its weights with the input features, and `exp` is the exponential function. `k` indexes all competing units, whose exponentiated scores are added in the denominator. The arrows over letters indicate vectors.

For the sentence choice, the authors express the score using a feature function that takes the candidate sentence as an argument. This form makes explicit that a sentence’s relevance depends on the position and proposed move. The features can also refer to the document from which the sentence comes.

```
p(yᵢ | sₜ, aₜ, d) ∝ exp(u⃗ · φ(yᵢ, sₜ, aₜ, d))
```

`yᵢ` is the candidate sentence indexed by `i`, `sₜ` is the game state at step `t`, and `aₜ` is the action under consideration there. `d` denotes the strategy document. `φ` returns a vector of relevance features for that combination, and `u⃗` holds the learned weights for those features. The dot gives their weighted score. `exp` transforms that score into a positive quantity. The sign `∝` indicates proportionality: the exponentiated scores are normalized over the candidate sentences to obtain the conditional probability `p`.

The sentence choice makes relevance local to a move. A passage about building a city can have high value when evaluating a settler’s options. A passage about naming the city can share words with it while offering little information about where to settle. The next stage tries to keep the useful structure within the selected sentence. That stage gives the final action-value estimate a way to treat a word describing the move differently from one describing its circumstances.

#### Deciding what the words describe

The paper calls the word-role assignment predicate labeling. Each word can describe an action, describe a state or condition, or belong to the background. These roles are defined by the control task. An action word helps describe what a player can do. A state word helps describe the circumstances or properties the action refers to. Background words fall outside those roles. Assigning the roles gives the player a way to preserve a distinction such as the difference between founding a city and the terrain on which the city would be built.

The procedure uses a dependency tree, a syntactic representation in which links connect words to the words they depend on. It starts at the root and proceeds towards the leaves. This order makes the parent’s assigned role available when a child is labeled. The authors motivate that choice with constructions in which words describing circumstances occur below words describing an action in the tree. In ordinary reading order, some of the words useful for judging a phrase’s role could occur later. The tree supplies an order based on the grammatical relations the parser identified. [Dependency parsing](https://md.research.elamur.ai/free/en/concepts/dependency-parsing/)

The word-role predictor also uses attributes such as the word itself, its grammatical category, and dependency information. A feature can pair a candidate role with one of these attributes. For instance, evidence for a role can depend on both the grammatical category of the current word and where it sits in the tree. The authors obtain the dependency information for the manual with the Stanford parser. The grammatical categories and tree come from the linguistic preprocessing, while the action, state and background assignments used in play are learned from the game. [Part-of-speech tagging](https://md.research.elamur.ai/free/en/concepts/part-of-speech-tagging/)

```
p(e⃗ᵢ | yᵢ, qᵢ) = ∏ⱼ p(eⱼ | j, e⃗₁:ⱼ₋₁, yᵢ, qᵢ)
```

`p` denotes probability. `e⃗ᵢ` is the whole sequence of role assignments for sentence `yᵢ`, and `qᵢ` is that sentence’s dependency parse. `j` indexes the words in the order used for labeling. `eⱼ` is the role assigned to the word at position `j` in that order. `e⃗₁:ⱼ₋₁` contains the roles decided before the current word. The product symbol `∏` combines the successive conditional probabilities, and the vertical bar introduces the information each conditional probability uses.

```
p(eⱼ | j, e⃗₁:ⱼ₋₁, yᵢ, qᵢ) ∝ exp(v⃗ · ψ(eⱼ, j, e⃗₁:ⱼ₋₁, yᵢ, qᵢ))
```

`eⱼ` is a candidate role at labeling position `j`, and `e⃗₁:ⱼ₋₁` is the partial assignment already made for that sentence. `yᵢ` and `qᵢ` are the sentence and its dependency parse. `ψ` produces features for the role choice in that context, and `v⃗` holds their learned weights. The dot gives the weighted score, and `exp` exponentiates it. The proportionality sign indicates that the scores must be normalized over the possible roles before `p` can be used as a conditional probability.

The network description represents a full predicate assignment as a hidden choice. The implementation computes an assignment only for the sentence chosen by the relevance component. That matters for a manual containing many sentences. Given a selected passage, the labeler can work through its words without labeling every other passage for the current estimate. The decision about which sentence matters is conditioned on game information. The word roles, once a sentence is chosen, are predicted from its linguistic features. The game supplies the training signal for those predictions through their effect on the estimated value.

#### Turning the language choices into a value

Once the sentence and its roles are chosen, the feature stage creates a numerical representation of the game and the relevant text. Some features use properties of the position and action, some use the words, and some represent combinations. For example, a word about grassland can be associated with the action of building a city through the features and their weights. The assignment of words to roles affects which such indicators are active. With the hidden choices fixed, feature computation is deterministic. A different sampled sentence or labeling can activate a different set of features for the same position and move.

```
Q(sₜ, aₜ, d) = w · f(sₜ, aₜ, d, yᵢ, zⱼ)
```

`Q` estimates the value of candidate action `aₜ` in state `sₜ` using document `d`. `t` identifies the step. `yᵢ` denotes the selected sentence, and `zⱼ` denotes the active predicate assignment, with `i` and `j` indexing those hidden choices here. `f` is the feature vector computed after the choices, and `w` holds its learned output weights. The dot sums the weighted feature entries. The output is linear in this vector for a given sentence and assignment. The full computation also includes the nonlinear operations that select them.

The paper reports roughly 306,800 features for this action-value representation, 158,500 for sentence relevance, and 7,900 for predicate labeling. These counts belong to different parts of the computation. The relevance features help decide which sentence to consider, the predicate features score word roles, and the action-value features help predict how well a rollout will end. In particular, the predicate features are defined in terms of the sentence and its parse. Associations between the selected words and the position or action enter the final estimate through the feature layer.

#### Learning from the end of a rollout

Learning happens within search. At an actual position, a rollout produces moves, states and an endpoint utility. The player compares the current estimates for the observed state-action pairs with that utility and updates the weights. Later rollouts from the actual position then use the revised estimates. The authors describe relearning the action-value approximation for each actual position, so the estimates can specialize to the part of the game reachable from there.

The target is the measured utility at the end of the rollout. When the same endpoint utility is used to train estimates for earlier decisions in the simulation, those estimates learn about consequences beyond each immediate move. The target also reflects the other decisions made in the rollout and any changes caused by the opponent. The method obtains its feedback by fitting across simulated experience, because an individual rollout cannot say which particular move, sentence or word role caused the final score.

The general update in the paper is a stochastic gradient step for squared error. It adjusts the parameters in the direction that reduces the discrepancy between the observed utility and the estimate. The paper then gives separate expressions for updating the output features and the hidden choices.

```
Δθ = −(α / 2) ∇θ [R(s_τ) − Q(s, a; θ)]²
    = α [R(s_τ) − Q(s, a; θ)] ∇θ Q(s, a; θ)
```

`Δθ` denotes a change in the parameters `θ`, which include the action-value, relevance and predicate weights. `α` is the learning rate, and `∇θ` denotes differentiation with respect to those parameters. `R(s_τ)` is the observed utility at rollout endpoint `s_τ`, with `τ` the endpoint step. `Q(s, a; θ)` is the predicted value of action `a` in state `s` under the current parameters. The document input is implicit for the text-aware system. The squared bracket is a squared prediction error. The factor `2` in the denominator cancels the factor from differentiating that square, and the leading minus sign gives the descent direction.

```
w ← w + α_w [Q − R(s_τ)] f(s, a, d, yᵢ, zⱼ)
```

`w` is the output weight vector, and the arrow means replacement by the value on its right. `α_w` is the output layer’s learning rate. `Q` stands for the current action-value estimate for state `s`, action `a` and document `d`. `R(s_τ)` is the observed utility at rollout endpoint `s_τ`. The vector `f` uses the state, action, document, selected sentence `yᵢ` and active predicate assignment `zⱼ`.

```
u⃗ᵢ ← u⃗ᵢ + α_u [Q − R(s_τ)] Q x⃗ [1 − p(yᵢ | ·)]
```

`u⃗ᵢ` is the weight vector associated with the active sentence choice `yᵢ`. `α_u` is the corresponding learning rate, `Q` is the action-value prediction, and `R(s_τ)` is the utility observed at the rollout endpoint. `x⃗` represents the input features for the update. `p(yᵢ | ·)` is the probability of the chosen sentence under the current conditional distribution, with the centered dot inside the probability standing for the conditioning input. The bracket subtracts that probability from `1`. The arrow assigns the updated vector.

```
v⃗ᵢ ← v⃗ᵢ + α_v [Q − R(s_τ)] Q x⃗ [1 − p(zᵢ | ·)]
```

`v⃗ᵢ` is the weight vector associated with the active predicate choice, written `zᵢ` in this update. `α_v` is its learning rate. `Q` and `R(s_τ)` are the predicted value and observed rollout utility, respectively. `x⃗` denotes the input features for the update. `p(zᵢ | ·)` is the probability of the chosen predicate assignment conditional on the relevant input, abbreviated by the dot. The bracket measures how far that probability is below `1`, and the arrow denotes assignment.

The signs in the layer-specific equations as printed are inconsistent with the general descent equation. The general expression multiplies the value gradient by observed utility minus predicted value. The subsequent expressions add a term using predicted value minus observed utility. For the linear output, the gradient of the estimate is the feature vector, so the discrepancy already appears in the output update. The article’s equations establish the squared-error objective and identify the inputs to the updates, while leaving the sign used in the implementation unresolved.

No relevance annotation or predicate gold standard is involved in these game-time updates. The same observed rollout outcome affects the estimated value and the choices about text that helped produce it. Over many simulations, a language feature can earn influence by recurring in decisions associated with favorable outcomes. The paper makes its code, data and complete experimental setup available alongside the work.

### Experiments and results

#### The manual, the opponent and the time budget

The source of advice is the official Civilization II manual. The authors count 2083 sentences and a vocabulary of 3638 words, with 16.9 words per sentence on average. The complete document serves as the strategy guide. This is a game-playing evaluation with a fixed manual, instead of a split in which different subsets of its sentences are used to measure gameplay training and test performance. The linguistic diagnostics use separate procedures for choosing distractor sentences and checking word labels.

The experiments use Freeciv version 2.2. The authors instrument the game so that the player can read states and execute actions programmatically. The opposing side is the built-in AI, a fixed game-playing program designed using knowledge of the game. The comparisons share a starting position and experimental settings, and the learned weights are initialized to zero. Independent runs allow the effects of the stochastic search to vary while holding the opening position fixed.

For the primary experiment, each game is observed through 100 actual steps. At each step, the player performs 500 rollouts, each ending after 20 simulated steps. The authors average the primary results across 200 independent runs for each method. They report running 8 rollouts in parallel on typical Intel Core i7 PCs with 4 hyper-threaded cores. A game through 100 steps takes roughly 1.5 hours in that setup. These constraints explain why the authors distinguish a rollout that ends at an intermediate score, an evaluation that ends at a common game step, and a separate evaluation that follows games through completion.

#### Wins by the end of the primary evaluation

The primary comparison records the percentage of games won by step 100. A game still in progress at that point contributes no win to that percentage. The loss column reported by the authors separately records games that had already ended in defeat. This distinction is visible in the self-play reference: when the built-in program plays itself, its win and loss percentages are both 0 within the window. The random player also has a win rate of 0 but a loss rate of 100. The two references therefore reach the same early win percentage with very different outcomes.

The game-only player uses the same search framework and a value estimate based on game features. The latent-variable control gives a game-only player additional hidden choices. The sentence-relevance variant can select manual passages without assigning word roles, and the random-text control receives a word-shuffled copy of the manual. These comparisons vary what the player can get from text while retaining a common opponent and evaluation window.

Civilization II win rate through 100 steps against the built-in Freeciv AI The player using the original manual with sentence selection and word roles has the highest observed win rate.

**The numbers**

| System or setting | Win rate % |
| --- | --- |
| Random player | 0 |
| Built-in AI self-play | 0 |
| Game only | 17.3 |
| Game only with latent variables | 26.1 |
| Shuffled manual | 40.3 |
| Sentence relevance only | 46.7 |
| Full system (this paper) | 53.7 |

The standard error of the full system’s early win percentage is ± 3.5. The game-only estimate has a standard error of ± 2.7. The values are ± 3.1 for the game-only latent-variable control, ± 3.4 for shuffled text, and ± 3.5 for sentence relevance alone. These errors describe uncertainty in the estimated win percentages across the independent games. The authors report that the full system’s early win rate is significantly higher than each comparison except sentence relevance alone.

The observed loss percentages add context to the victory measure. Through the same 100 steps, the full system lost 5.9% of its games. The observed loss percentages were 5.3% for game only, 3.7% for the game-only latent-variable control, 4.3% for shuffled text, and 2.8% for sentence relevance alone. The full system’s main advantage at the cutoff is in games already won. The early results leave the final status of ongoing games open, which is why the authors also follow games to their conclusion.

#### Games played to completion

The full-length evaluation uses 50 independent runs and reports the percentage of games each tested player eventually won. It includes the full language-aware player, the game-only player, and the game-only player with latent variables. Every player in this comparison faces the built-in opponent. The separation from the primary experiment is important when interpreting the percentages, since a win in a longer game is counted even when it would have arrived after the primary evaluation stopped.

Civilization II full-game win rate against the built-in Freeciv AI The system using the manual wins most often when the games are played to completion.

**The numbers**

| System or setting | Win rate % |
| --- | --- |
| Game only | 45.7 |
| Game only with latent variables | 62.2 |
| Full system (this paper) | 78.8 |

For these full-game win percentages, the standard errors are ± 7.0 for game only, ± 6.9 for the latent-variable alternative, and ± 5.8 for the full system. The ranking of these players matches their ranking under the early cutoff. The full-length test gives direct evidence that the system can translate its search guidance into completed victories. The cutoff experiment remains the broader comparison across baselines, since the sentence-only and shuffled-text variants are absent from the full-length results.

The two evaluations also put the built-in opponent in context. It is the fixed adversary against which the learned players are tested. Its early self-play result describes how quickly that reference matchup ends under the cutoff. The learned players’ full-game win rates measure a different question: how frequently each wins when given enough time to finish against that opponent.

### What the ablations show

#### Separating useful text from additional flexibility

Comparing the full system with game only establishes the size of the performance change in this setup when the player gains both access to the manual and the machinery for interpreting it. That comparison changes several things at once. The original game-only estimator combines its features linearly, whereas the full player also samples hidden choices that determine which features enter the output. The authors use two controls to ask whether this extra flexibility could account for the result on its own.

The game-only latent-variable control retains hidden choices while basing their activation on game information. Its win rate is higher than the linear game-only player’s in both evaluations in which they appear together. That pattern makes additional flexibility a plausible contributor to performance. The control nevertheless finishes below the full player both by the early cutoff and in games followed to completion. Under the tested design, a nonlinear estimator that sees only game information falls short of the player that can also draw features from the manual.

The other control keeps the full architecture and shuffles the original manual’s word positions. This preserves the pool and frequencies of the words while disrupting how they occur together. The shuffled text can still contain familiar labels from the game. It loses much of the organization that tells a reader which attributes qualify a move or what action a sentence is about. Its early win percentage is below that of the player using the original manual, and the reported comparison is statistically significant. Since the shuffle changes several properties of the text at once, the result supports the value of the organized manual across those properties. It provides no separate estimate for the effects of word order, grammatical relations or topical coherence.

The sentence-relevance comparison isolates a narrower change. Both players can select a sentence for a position and move. The full system additionally labels words by role and builds features using those labels. The early win percentages favor the full system, but the authors report that this pairwise comparison did not reach statistical significance. The increase over game only is already substantial for sentence selection. The role randomization and labeling evaluations give complementary evidence about the contribution of learned word roles.

#### What the relevance diagnostic measures

Relevance would ideally be evaluated by asking which advice applies to the precise position and candidate action under consideration. The authors judge that annotation impractical across the many decisions generated during play. They instead add randomly chosen Wall Street Journal sentences to the manual and check whether the selected sentence comes from the original game document. They draw the newspaper material from a corpus discussed in the work on the Penn Treebank. [The Penn Treebank](https://md.research.elamur.ai/free/en/papers/marcus-1993-building-large-annotated-corpus-english/)

In this diagnostic, a success means that the player picked a manual sentence in the presence of unrelated newspaper material. It could pick a manual sentence about the wrong move and still receive credit. The diagnostic is sensitive to whether the player can use the context to favor game text, but it cannot distinguish a general game-related passage from advice suited to that particular position. The distinction matters because vocabulary about cities or units can identify the source of a passage more easily than its relevance to a particular action.

The authors report average accuracy of 71.8% on this test, with the time course averaged over 100 independent runs. During the first 25 game steps, the average is 94.2%. The paper gives examples in which the selector favors advice about siting a city or comparing units used to defend cities, while passing over material about renaming a city or generic comments about research order. These examples illustrate how the preference can sometimes go beyond recognizing that the text is about Civilization II. The numerical diagnostic remains a test of which source the selected sentence came from.

The authors connect the time pattern to the manual’s intended audience. They describe it as a guide for new players, with much of its useful strategy concentrated in the opening. They also compare the norms of the text and game feature groups at the output layer. A norm summarizes the magnitude of a group of numerical values. The paper interprets the shift toward the game group after the first 25 steps as evidence that the player increasingly relies on game information. Together, the selection diagnostic and the output-layer analysis show a change over the course of play. A further intervention tests what happens when text is turned off.

#### Turning off text after the opening

In the hybrid experiment, the player uses the full system through the first 50 steps. For the subsequent 50, it plays without textual information. The hybrid wins 53.3% of games in the early evaluation, close to the 53.7% achieved by the full system over the same 100-step window. This comparison tests whether continued access to the manual improves the observed early win percentage after a substantial opening phase with text.

By the time text is removed, the player is already acting from the position reached with textual guidance. A city site, unit placement or other opening decision may continue to influence later play after the sentence that helped guide it is no longer consulted. The experiment therefore supports the value of using the manual early in games that then continue without it. It leaves open how useful the manual would be if first introduced later, or in games that reached different positions through an opening played without it.

The phases used by the authors also serve different purposes. The first 25 steps mark the early period in the selection and feature analyses. The hybrid intervention keeps text active for the first 50 steps. The near match between the hybrid and the full system shows that removing text at the tested switch point had little observed effect on the early win percentage. It gives no exact boundary for when individual passages or categories of advice stop helping.

#### Checking the word roles

The authors compare the inferred roles against a gold-standard annotation, meaning human reference labels for the words in the manual. They report accuracy for the full distinction among state, action and background, and a separate accuracy for discriminating state words from action words. The former tests whether the system can make all the distinctions it uses to create features. The latter focuses on words in the action and state categories.

Civilization II manual accuracy on state versus action word labels The learned labels distinguish state words from action words most accurately during opening play.

**The numbers**

| System or setting | Accuracy % |
| --- | --- |
| Random labeling | 50.0 |
| Learned labels, first 100 steps | 78.9 |
| Learned labels, first 25 steps (this paper) | 92.7 |

For the evaluation that includes the background class, the random word labeler has accuracy of 33.3%. The learned system reaches 45.1% over the first 100 steps and 48.0% over the first 25 steps. The early period is stronger by both metrics. The comparatively low accuracies for the task including background show that the word labels remain noisy. The stronger state-versus-action results establish that the labeler is better at distinguishing those roles in the separate evaluation. They leave the exact distribution of mistakes among all the roles unspecified.

The paper’s examples show the kind of structure these labels are intended to recover. A sentence about using settlers to improve land contains words for the action and words for units or conditions surrounding it. The labeling procedure can separate some of those roles and still make errors within the same sentence. The output weights also provide examples of associations between manual words and game attributes. Those weights show how the feature representation links the text to the game. The accuracy diagnostic assesses the word labels themselves, and a gameplay intervention tests what happens when those labels carry no learned information.

For that intervention, the authors keep the full system and choose predicate labels uniformly at random. It wins 44% of games in the early evaluation, near the 46.7% obtained by selecting sentences without assigning word roles. The intervention preserves the ability to select sentences and activate role-dependent features, while breaking the association between a word and its learned role. Its lower observed win percentage than that of the full system supports the usefulness of learned assignments in play. Read together with the sentence-only comparison, it suggests that assigning roles is useful insofar as the assignments retain some of the distinctions relevant to the move. The stronger claim that learned roles reliably outperform sentence selection alone remains limited by the reported significance comparison.

### Limitations

#### Limits the authors identify

The authors frame the language task around usefulness to a control application. The system can select a passage and label the words in it, giving the value estimator features that may change the search. This is a deliberately partial understanding of the manual. The procedure deals with a selected sentence and task-specific roles. A document can also develop advice across several sentences or introduce conditions that only become clear in a larger passage. The published architecture gives no direct account of how to combine such advice into an extended strategy.

The authors also identify the difficulty of assessing contextual relevance directly. Labeling advice as relevant would require considering the position and action, which vary across game instances and timesteps. They consequently use the manual-versus-newspaper diagnostic. Its reported accuracy tells a reader how frequently the manual supplies the chosen sentence when newspaper distractors are present. An evaluation of actual strategic relevance would have to ask whether the chosen manual passage helps with the specific decision. The linguistic examples provide some evidence at that level, while the aggregate estimate uses the broader source distinction.

Another limit follows from the cost of simulation. The paper truncates rollouts and evaluates endpoint score ratios because full games are too expensive to simulate at every decision. The authors describe game scores as noisy indicators of progress. A move that pays off late may look less attractive at that endpoint, and a move that improves the immediate score can appear favorable despite longer-term costs. The full-game results demonstrate that the chosen surrogate works well enough to support many victories in the tested setup. The paper leaves the effect of other rollout lengths and alternative utilities unexplored.

The time available for evaluation introduces a related constraint. The primary win metric tells how frequently the player has already won by a specified step. The authors recognize that games still under way may later become wins, and they run a separate full-game evaluation to check that the observed advantage persists. The full-game runs include fewer variants. Their results carry the comparison with the game-only baselines through to completed games, while leaving the full-length contribution of individual linguistic components open.

The authors give the manual’s concentration on opening play as an explanation for the time trends in relevance and output features. That explanation is consistent with the hybrid experiment and with the stated audience of the manual. It also identifies a condition on the result. Text can influence the search when it supplies information suited to the decisions being made. The study uses a guide particularly rich in early tactics and provides no equivalent test with a guide specifically designed around later stages.

#### Limits of the experimental design

The reported wins concern a single game setting, a fixed initial position, one manual and the built-in opponent. Independent games show variation across runs within those conditions. Starting from other maps or positions could change which parts of the manual matter, and another opponent could alter which continuations appear promising. The experiment establishes that the method improves gameplay in its tested setting. Its portability to different manuals, adversaries or environments remains an open empirical question.

The assumption about units also affects what the experiment can show. It makes the large action space tractable by allowing the algorithm to treat one unit’s choice independently of the choices of other units given the current state. Some plans depend on what multiple units will do in concert. The approximation can make those joint choices difficult to express within the immediate action evaluation. A rollout can still record the observable consequences of actions as the game develops. The setup gives limited evidence about how well the language mechanism would work if choosing coordinated joint actions were central to the task.

The sources of supervision should be distinguished from the inputs supplied by the experimental design. The player learns its text choices and action-value weights from game feedback, with no human relevance or predicate labels for those updates. It still receives a structured game interface, hand-defined feature functions, and dependency information generated by a parser. The environment is already able to identify terrain, resources, cities, units and available actions. The reported results concern learning associations across those existing representations. They provide limited evidence about grounding language when a player must infer the game attributes and action interface as well.

The architecture’s successful associations can also be narrower than the advice a human reader would extract. A feature can learn that a word about terrain is a good cue in a class of settlement decisions. This may suffice for better search even where the system has little evidence about a rarer construction that mentions the same terrain under a qualification. The study evaluates role accuracy and illustrates word-to-attribute associations, but it does not test systematic interpretation of different phrasings or verify that each learned association preserves the full meaning of a sentence. The difference is important when moving from the observed game results to claims about broad reading ability.

Finally, the strongest results concern the full method against players that lack intact textual advice. The reported advantage over sentence relevance alone is smaller and comes with a significance qualification. The role randomization gives a reason to regard the learned assignments as useful, while the limited set of completed-game comparisons makes their full-length effect unresolved. Likewise, the conflicting signs in the printed update formulas leave an implementation detail to verify for a precise reproduction. These limits qualify distinct claims about the method. The gameplay comparisons measure whether the full system wins more often, the linguistic tests characterize choices it makes on the way, and the training equations describe how those choices are updated.

### What came after

The subsequent papers that cite this work address several different relationships between language and decisions. Their topics make the connections clear at varying levels of specificity. A later study can share the problem of grounding text in an environment while using a different source of language or a different task. The citation relationships establish that the work appears in those discussions. The titles establish what those papers study, with the details of individual adaptations left open.

The most direct thematic connection is a later study of understanding language in text-based games through deep reinforcement learning. The Civilization II player has a structured game state and receives language from a document about how to play. A text-based game puts language in the setting where play itself takes place. This changes the role language has in the research question. A passage in the Civilization II manual can guide the choice of a move from a state already represented in game terms. Language understanding in a text-based game is also concerned with the descriptions through which the player encounters its situation. [Language Understanding for Text-based Games Using Deep Reinforcement Learning](https://md.research.elamur.ai/free/en/papers/narasimhan-2015-language-understanding-text-based-games/)

A later survey takes up the broader subject of reinforcement learning informed by natural language. The Civilization II work fits that subject because the manual influences which actions the player explores and evaluates, and play supplies feedback about how to use it. Its particular example is an external document offering high-level advice before the player encounters its specific decisions. A survey of the wider area puts that setup in a common discussion with other ways language can inform learning from interaction. [A Survey of Reinforcement Learning Informed by Natural Language](https://md.research.elamur.ai/free/en/papers/luketina-2019-survey-reinforcement-learning-informed-natural/)

Work on compositional semantics for instruction following addresses a neighboring problem the paper uses to define its own task. Instructions call for an interpreter to connect parts of an utterance to the behavior the instruction specifies. In the manual-reading study, those connections help a player evaluate a candidate move, and relevance changes with the position. The later work’s stated focus on alignment and composition brings the structure of the instruction into view. The point of contact is the relationship between meaningful parts of a sentence and actions or conditions in a task. The tasks ask different questions about how far that relationship determines the next action. [Alignment-Based Compositional Semantics for Instruction Following](https://md.research.elamur.ai/free/en/papers/andreas-2015-alignment-based-compositional-semantics-instruction/)

Other later work addresses learning a semantic parser from question-answer pairs. A question and its answer provide evidence about an interpretation through its consequence. The game paper likewise uses an observable consequence because the intermediate language choices are unannotated during training. The consequences differ in what they refer to. An answer concerns the result of interpreting a particular question, whereas the endpoint score reflects a path through the game that includes multiple actions and other influences. The connection is in the use of task outcomes to supervise an intermediate interpretation. [Semantic Parsing on Freebase from Question-Answer Pairs](https://md.research.elamur.ai/free/en/papers/berant-2013-semantic-parsing-freebase-question-answer/) [Semantic parsing](https://md.research.elamur.ai/free/en/concepts/semantic-parsing/)

Interactive text-to-SQL work also concerns learning or improving an interpretation in light of feedback. In its stated task, the feedback is itself natural language and arrives in an interactive parsing setting. In Civilization II, the advice arrives in a static document, and feedback comes from scores observed during simulation. This difference clarifies two roles language can play. It can be available in advance as a source of guidance, or it can be part of the response to an interpretation once the system has made one. [Speak to your Parser: Interactive Text-to-SQL with Natural Language Feedback](https://md.research.elamur.ai/free/en/papers/elgohary-2020-speak-your-parser-interactive-text/)

Grounded spatial reasoning provides another connection. The manual-reading player needs to relate words about rivers, grassland and city placement to an environment with spatial attributes. It uses those relationships to distinguish potentially good moves. Later work on representations for grounded spatial reasoning takes the representation of spatial relationships as its subject. The connection is visible in the settlement example: useful language grounding requires tracking where a condition holds and how that condition relates to an action, even when the main evaluation is about a different outcome. [Representation Learning for Grounded Spatial Reasoning](https://md.research.elamur.ai/free/en/papers/janner-2018-representation-learning-grounded-spatial-reasoning/)

A later study of embodied agents considers a source of prior knowledge on a different scale. Its subject is transferring knowledge from internet-scale vision and language systems into agents that act in an environment. Civilization II supplies a compact, game-specific manual that a search procedure consults for candidate actions. Both settings raise the question of how knowledge represented outside the acting system affects behavior inside its environment. The distinctive evidence in the Civilization II experiments is the combination of a shared search setup, a usable manual, and controls that remove or disrupt the advice. Those comparisons show how to ask whether the language input contributes to decisions in the environment. [Distilling Internet-Scale Vision-Language Models into Embodied Agents](https://md.research.elamur.ai/free/en/papers/sumers-2023-distilling-internet-scale-vision-language/)

## Cite

Cite as S.R.K. Branavan, David Silver and Regina Barzilay. 2011. Learning to Win by Reading Manuals in a Monte-Carlo Framework. Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies.

The paper itself, not this page. BibTeX from the library's record of the work.

```bibtex
@inproceedings{branavan2011learning,
  title = {{Learning to Win by Reading Manuals in a Monte-Carlo Framework}},
  author = {S.R.K. Branavan, David Silver and Regina Barzilay},
  booktitle = {Proceedings of the 49th Annual Meeting of the Association for Computational Linguistics: Human Language Technologies},
  year = {2011},
  doi = {10.1613/jair.3484},
  url = {https://doi.org/10.1613/jair.3484}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
