liveBook · Manning

Context

As explained in Optimization Algorithms: AI techniques for design, planning, and control problems

Context is observed information describing the current situation that conditions the expected reward of an action.

Context is observed information describing the current situation and conditioning an action’s expected reward. In a contextual multi-armed bandit, the best action can change with the context. section 12.1

Distinguish context from related decision settings:

  • Treat a noncontextual multi-armed bandit as having one repeated decision situation with no changing state or side information. section 12.1.6
  • Use context when action quality depends on current conditions, such as selecting a truck configuration for a city or interstate route. section 12.1 section 12.5
  • Keep the setting distinct from a Markov decision process, where actions affect the environment across multiple time steps through states and transitions. section 12.1

Truck selection

Represent city or interstate as shared context, then evaluate combinations of truck size, engine type, and tire type. A contextual bandit samples an action, observes a noisy reward, and updates its choices. A Vowpal Wabbit implementation uses action-dependent features, exploration, and 2,500 training iterations; one test selects a medium electric truck with snow tires for a city context. section 12.5

Figure 12.12 A CMAB-based recommender system to select delivery truck size, engine type, and tire type based on a specified context

Explore the contextual-bandit recommender diagram linking route context to truck size, engine, and tire decisions. section 12.5

How Optimization Algorithms: AI techniques for design, planning, and control problems covers it

How deep it goes
Defines context, contrasts it with noncontextual bandits and MDPs, and demonstrates implementation without deriving learning theory.
Examples
Uses casino slot machines as a noncontextual contrast and truck selection across route types as a contextual example.
What it assumes
Assumes basic reinforcement-learning distinctions while explaining states, actions, rewards, exploration, and exploitation through examples.
What you can do after
Apply it via Vowpal Wabbit to select actions whose rewards depend on shared and action-dependent features.
How it connects
Connects context to contextual multi-armed bandits, multi-armed bandits, reinforcement learning, and Markov decision processes.

Also explained in

Compare how 18 books explain context →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Optimization Algorithms: AI techniques for design, planning, and control problems. The section links point to the parts of the book it draws on.