Reinforcement Learning

Compare immediate rewards and future states

Give the future more weight

Botie must compare an immediate reward with the value of where each action leads. The discount can change that choice.

BOTIE

The discount rises from 0.5 to 0.9 while rewards and transitions stay fixed. Which zero-based action index wins?
The inputs we are comparing

Next-state probabilities per action

Same in both cases

10
01

Next-state value estimates

Same in both cases

  1. 02
  2. 16

Immediate expected rewards

Same in both cases

  1. 03
  2. 10

Discount

Immediate reward wins

0.5

Future benefit wins

0.9
Result for immediate reward wins
0

For a list use brackets, such as [2, 4]. For a matrix put each row in brackets. Text answers can stay as text.

An immediate reward competes with the destination

This check uses the pieces from “Choose an action after valuing its continuation”.

BOTIE

Botie has three actions and two possible next states. Combine each action's immediate reward with its discounted expected destination value. Return the zero-based index of the highest-valued action; discount is 0.5.
Next-state probabilities per action
10
0.50.5
01
Next-state value estimates
  1. 02
  2. 110
Immediate expected rewards
  1. 05
  2. 10
  3. 21
Discount
0.5

Use a number, text, or an array matching the requested result. For a matrix, put each row in brackets. Saving your prediction runs your current construction on these inputs and checks the earlier examples too.

Build a construction in the workspace above first. This case will test those pieces.

Why is choosing once from supplied values less than a full value-iteration algorithm?

Planning requires consistent value updates across relevant states, including terminal states.

This is one state's greedy improvement step from supplied values. A full planner must update all relevant states and handle terminals.

Work through the Python challenges →
Continue the courseLearning Action Values From Experience →
← Valuing Rewards That Arrive Later