11 Reinforcement Learning - Optimal Decision-Making Under Uncertainty

The Core Question: How Do Machines ‘Learn’ Optimal Decisions?

How can a machine, operating in a complex and uncertain world, automatically learn an optimal sequence of decisions through interaction and trial-and-error to achieve its long-term goals?

This is not just a technical question; it touches the core of economics, including rational decision-making, dynamic optimization, and game theory.

Core Concept of Reinforcement Learning An agent explores a suboptimal path (trial and error) before discovering the optimal path to its goal. Agent Long-term Goal Interaction & Trial-and-Error

The Concept of an ‘Agent’ in Economics

In economics, we constantly study ‘agents’—consumers, firms, governments—and how they make choices to maximize their utility or profit.

Reinforcement learning provides us with a novel, computational framework to simulate and optimize the decision-making processes of these agents, especially under conditions of incomplete information and dynamic environments.

A Business Case: Dynamic Pricing

Imagine you are a pricing algorithm (an agent) for an e-commerce platform.

  • State: Current inventory, competitor prices, user traffic, time of day…
  • Action: Increase price, decrease price, maintain price.
  • Reward: Total revenue for the day.
  • Goal: Find a pricing Policy that maximizes total revenue over the next 30 days.

You don’t have a dataset of ‘correct answers’. You can only learn by trying different prices and observing the outcomes. This is the home ground of reinforcement learning.

This Chapter’s Goal: Build Economic Intuition for RL

By the end of this lecture, you can:

  1. Express a sequential economic decision using states, actions, rewards, transitions, and discounting.
  2. Compute one Bellman-expectation, Q-learning, and terminal-state update by hand.
  3. Distinguish the on-policy Sarsa target from off-policy Q-learning.
  4. Compute standard DQN and Double DQN targets term by term and explain the target network.
  5. State the assumptions of the teaching environment and offline-evaluation risks when transferring RL to Chinese financial data.

Before You Begin

  1. If two rewards are 2 and 4 with γ=0.5, what is the return?
  2. Should a terminal transition bootstrap the next-state value?
  3. If behavior and target policies differ, is learning on-policy or off-policy?

Write all three answers before revealing.

Reveal and remediation

\(2+0.5\times4=4\); no, the terminal mask is zero; off-policy. If an item was wrong, return respectively to discounted return, terminal updates, or on/off-policy definitions.

90-Minute Main lesson and Optional Topics

  • 0–15 min: MDP tuple, return, and discount; complete the before-you-begin review.
  • 15–38 min: state value, action value, and a Bellman-expectation calculation.
  • 38–62 min: expectation to max, Sarsa versus Q-learning, and one hand update.
  • 62–80 min: DQN, target network, and the uses and limits of replay.
  • 80–90 min: local offline-RL support check and lesson review.

Study sequence

MDPBellman calculationQ-learningDQN/DDQN targetpracticelocal offline-RL review.

Optional topics: the cliff-walking visual, Dueling DQN, and application outlook.

The Three Families of Machine Learning

Machine learning is typically categorized into three main paradigms based on the learning style and data format.

The Three Families of Machine Learning A chart dividing machine learning into Supervised, Unsupervised, and Reinforcement Learning, with simple icons and descriptions for each. SupervisedLearning f(X) → y UnsupervisedLearning Find patterns ReinforcementLearning + Trial and error

Supervised Learning

Learns a mapping function from inputs to outputs, like a teacher providing correct answers.

  • Core Task: Prediction or Classification.
  • Data Format: Labeled data (X, y), where y is the correct answer.
  • Economics Analogy:
    • Regression: Predicting next year’s GDP based on historical data (GDP, interest rates, inflation).
    • Classification: Determining if a customer will default on a loan based on their information.
  • Limitation: Relies on large amounts of high-quality labeled data; cannot make sequential decisions.

Unsupervised Learning

Discovers hidden structures or patterns in data without any correct answers.

  • Core Task: Discovering data structure.
  • Data Format: Unlabeled data X.
  • Economics Analogy:
    • Clustering: Segmenting customers into different market segments.
    • Dimensionality Reduction: Extracting a few key factors from hundreds of macroeconomic indicators.
  • Limitation: Can only describe data, not guide decisions.

Reinforcement Learning

An agent learns how to make a sequence of decisions through ‘trial and error’ interaction with an environment to maximize cumulative reward.

  • Core Task: Learning an optimal sequence of decisions.
  • Data Format: Interaction data (state, action, reward).
  • Economics Analogy:
    • A firm continuously adjusts its advertising, R&D, and pricing strategies over multiple quarters to maximize its long-term market share and profit.

The Essence of RL: No ‘Correct Answer’

The most fundamental difference from supervised learning is that there is no predefined correct action in any given situation.

RL Essence 1: No Correct Answer An icon representing the lack of a 'correct answer' in RL, featuring a large question mark. ? No 'Correct Answer' Only a goal to maximize long-term reward

The Essence of RL: Delayed Feedback

Today’s action might have consequences that only become apparent far into the future. The feedback signal (reward) is often delayed.

RL Essence 2: Delayed Feedback An icon showing a clock and a winding path to a reward, symbolizing that the results of an action are not immediate. Delayed Feedback The value of today's decision is revealed in the future

The Essence of RL: The Explore vs. Exploit Trade-off

An agent must decide: should it exploit what it already knows to get a good reward, or should it explore new actions to potentially discover even better rewards?

RL Essence 3: Explore vs. Exploit An icon of a crossroads, symbolizing the agent's choice between a known path (exploitation) and an unknown one (exploration). Explore vs. Exploit Choose the known best, or try something new?

Core Framework: Markov Decision Process (MDP)

Reinforcement learning problems are typically modeled mathematically as a Markov Decision Process (MDP).

This is a mathematical framework for modeling sequential interactions between a decision-maker (the agent) and an environment. Understanding the MDP is the foundation for understanding all of RL.

It consists of five core components: (S, A, P, R, γ).

The Protagonists of an MDP: Agent and Environment

Agent and Environment The Agent and Environment are the two main entities in an MDP, interacting through actions and state/reward signals. Agent Learns and decides Environment External dynamics

MDP Component 1: State (S)

A State (\(s \in S\)) is a current description of the environment at a particular moment in time.

  • Definition: A set of information describing the current situation of the world, sufficient for making future decisions.

  • Key Property (Markov Property): The future depends only on the present state, not on the sequence of events that preceded it.

    \[ \large{ P(S_{t+1}|S_t, A_t) = P(S_{t+1}|S_1, A_1, ..., S_t, A_t) } \]

  • Economics Examples:

    • A company’s state could be (cash flow, inventory level, market share).
    • An economy’s state could be (GDP growth, inflation rate, unemployment rate).

MDP Component 2: Action (A)

An Action (\(a \in A\)) is an operation that the agent can perform.

  • Definition: The set of behaviors the agent can choose from in each state.
  • Types: Can be discrete (e.g., Buy, Sell, Hold) or continuous (e.g., set price to $10.53).
  • Economics Examples:
    • A company’s actions could be (set product price, determine advertising budget).
    • A central bank’s actions could be (raise rates by 25 bps, lower rates, maintain).

MDP Component 3: Reward (R)

A Reward (\(R_t\)) is the immediate feedback signal the environment gives to the agent after it takes action \(A_t\) in state \(S_t\).

  • Definition: A scalar value that measures the ‘goodness’ of an action. The Reward Hypothesis states that all goals can be described as the maximization of expected cumulative reward.
  • RL’s Goal: To maximize cumulative reward, not instantaneous reward.
  • Economics Examples:
    • For a trading algorithm, the reward is the daily portfolio return.
    • For a company, the reward is the quarterly profit.

MDP Component 4: Transition Probability (P)

State Transition Probability describes the dynamics of the environment.

  • Definition: The probability of transitioning to the next state \(s'\) after taking action \(a\) in state \(s\).

  • Mathematical Notation:

    \[ \large{ p(s' | s, a) = P(S_{t+1} = s' | S_t = s, A_t = a) } \]

  • Economics Example:

    • Given a current market share of 20% (s), if the company invests $1M in advertising (a), what is the probability that the market share will grow to 22% (s') next quarter? This is often stochastic.

MDP Component 5: Discount Factor (\(\gamma\))

The Discount Factor (\(\gamma\)) reflects the agent’s preference for present rewards over future rewards. We will discuss this in more detail shortly. It is a value between 0 and 1.

Summary: The MDP Quintuple

A complete Markov Decision Process is defined by a quintuple: \((\mathcal{S}, \mathcal{A}, P, R, \gamma)\)

The MDP Quintuple Shows the five core elements of an MDP: S (States), A (Actions), P (Transitions), R (Rewards), and gamma (Discount Factor), each with an icon. S States Worldconfiguration A Actions Availablechoices P Transitions Systemdynamics R Rewards Immediatefeedback γ Discountfactor Futurerewardweight

The Interaction Loop: The Agent-Environment ‘Dance’

The core process of reinforcement learning is a continuous loop of interaction.

The MDP Interaction Loop A loop diagram showing the Agent outputting an Action and the Environment returning a new State and Reward. Agent Environment Action A_t State S_{t+1}, Reward R_{t+1}

The Interaction Loop: A Step-by-Step Breakdown

  1. Observe: At time t, the agent observes the environment’s state \(S_t\).
    • (e.g., A trading algorithm observes the current stock price is $100 and volume is 500k shares.)
  2. Decide: The agent selects an action \(A_t\) based on its policy \(\pi\).
    • (e.g., The algorithm decides to ‘Buy 100 shares’.)
  3. Execute: The environment receives the action \(A_t\).
  4. Evolve: The environment transitions to a new state \(S_{t+1}\) and provides a reward \(R_{t+1}\) based on its internal dynamics.
    • (e.g., The market executes the trade, the price moves to $101, and the day’s unrealized profit is +$100.)
  5. This loop repeats.

The Agent’s Brain: The Policy Function (\(\pi\))

The Policy (\(\pi\)) is the agent’s code of conduct, its ‘brain’. It defines a mapping from states to actions.

  • Definition: A mapping from states to actions. It tells the agent what to do in each state.
  • Types:
    • Deterministic Policy: \(a = \pi(s)\), a unique action for each state.
    • Stochastic Policy: \(\pi(a|s) = P(A_t = a | S_t = s)\), the probability of taking action \(a\) in state \(s\).
  • RL’s Goal: To find an optimal policy \(\pi^*\) that maximizes long-term return.

The Economic Intuition of a Stochastic Policy

Why might we need a policy that is random?

To Explore the Unknown

  • A deterministic policy might get stuck in a rut, missing out on better options forever.

  • Randomness allows the agent to explore new, untried actions.

  • This is like a company occasionally trying a completely new marketing channel.

To Counter Adversaries

In some situations, the optimal behavior is inherently random. This is common in game theory; the optimal strategy for ‘Rock, Paper, Scissors’ is to choose randomly, making you unpredictable to your opponent.

The Objective Function: Maximize Cumulative Return

The agent’s goal is not to maximize the immediate reward \(R_{t+1}\), but to maximize the future cumulative return starting from the current moment.

The return \(G_t\) is defined as:

\[ \large{ G_t = R_{t+1} + \gamma R_{t+2} + \gamma^2 R_{t+3} + \dots = \sum_{k=0}^{\infty} \gamma^k R_{t+k+1} } \]

Core Concept: The Discount Factor (\(\gamma\))

The \(\gamma\) (gamma) in the formula is the discount factor, where \(0 \le \gamma \le 1\).

  • Economic Analogy:
    • If each step has a fixed duration and rewards are period cash flows, \(\gamma\) can resemble \(1/(1+r)\).

    • In general RL it defines the task’s weighting of distant rewards and is not identical to NPV.

  • Why do we need to discount?
    1. Time Value of Money: A dollar today is worth more than a dollar tomorrow.
    2. Task Time Preference: \(\gamma\) specifies the relative weight of near and distant rewards; represent model uncertainty separately through states, transitions, or robustness analysis.
    3. Mathematical Condition: With bounded rewards and \(0\le\gamma<1\), the infinite discounted return converges absolutely; \(\gamma=1\) needs additional conditions such as termination.

The Effect of the Discount Factor: An Example

Suppose the reward sequence is [+10, +2, +5, +8, ...]

\(\gamma = 0\) (Extremely Myopic)

\(G_t = 10 + 0 \cdot 2 + 0 \cdot 5 + \dots = 10\) Only cares about the immediate reward.

\(\gamma = 0.9\) (Farsighted)

\(G_t = 10 + 0.9 \cdot 2 + 0.9^2 \cdot 5 + \dots\) \(G_t = 10 + 1.8 + 4.05 + \dots\) Balances short-term and long-term gains.

The choice of \(\gamma\) is a key modeling decision that defines the agent’s degree of ‘foresight’.

The Yardstick for a Good Policy: The Value Function

How do we determine if a state is ‘good’ or ‘bad’? Or if an action is ‘good’ or ‘bad’?

This is the role of the Value Function. It is the Expectation of future returns.

There are two core types of value functions:

  1. State-Value Function (\(V_\pi(s)\))
  2. Action-Value Function (\(Q_\pi(s, a)\))

State-Value Function V(s): How Good is My Current Situation?

The State-Value Function \(V_\pi(s)\) answers the question: ‘If I start from state \(s\) and always follow policy \(\pi\), how much total future return can I expect to get?’

  • Definition:

    \[ \begin{aligned} V_\pi(s) &= E_\pi[G_t \mid S_t=s] \\ &= E_\pi\!\left[\sum_{k=0}^{\infty}\gamma^kR_{t+k+1}\,\middle|\,S_t=s\right]. \end{aligned} \]

  • Economics Example: Given the current macroeconomic conditions (state \(s\)), if the Federal Reserve follows its current interest rate policy (policy \(\pi\)), what is the expected value of future total economic output (return)?

Action-Value Function Q(s, a): How Good is This Choice?

  • Starting point: the agent is in state \(s\) and first chooses action \(a\).

  • Continuation rule: it follows policy \(\pi\) thereafter.

  • Quantity answered: \(Q_\pi(s,a)\) is the expected total future return under that choice and continuation.

  • Definition:

    \[ \large{ Q_\pi(s, a) = E_\pi[G_t | S_t = s, A_t = a] } \]

  • Intuition: \(Q_\pi(s, a)\) is an estimate of the Quality of taking a specific action in a specific state.

  • Economics Example: Given the current inventory level (state \(s\)), if the company chooses to cut prices by 10% (action \(a\)), what is the expected value of the company’s future total profit (return)?

The Relationship Between V and Q Functions

The value of a state is the expected value of all possible actions that could be taken from that state, weighted by the policy’s probability of choosing them.

\[ \large{ V_\pi(s) = \sum_{a \in A} \pi(a|s) Q_\pi(s, a) } \]

  • \(\pi(a|s)\) is the probability of choosing action \(a\) in state \(s\).
  • \(Q_\pi(s, a)\) is the value after choosing action \(a\).

This relationship is very intuitive and crucial for later algorithms.

The Core of Dynamic Programming: The Bellman Expectation Equation

The Bellman Equation is the most fundamental equation in reinforcement learning. It establishes a recursive relationship between the value of a state and the values of its successor states.

For the state-value function \(V_\pi(s)\):

\[ \large{ V_\pi(s) = \sum_{a \in A} \pi(a|s) \left( E[R_{t+1}|s,a] + \gamma \sum_{s' \in S} p(s'|s,a) V_\pi(s') \right) } \]

In words: The value of the current state = the expectation over all possible actions of the (immediate reward + the discounted expected value of the next state).

Decomposing the Bellman Expectation Equation (V-function)

Let’s break down the equation:

\[ \large{V_\pi(s) = \sum_{a \in A} \pi(a|s) \Big( \underbrace{R(s,a)}_{\text{What I get now}} + \gamma \underbrace{\sum_{s' \in S} p(s'|s,a) V_\pi(s')}_{\text{What I can expect later}} \Big)} \]

  1. Outer Expectation \(\sum_{a \in A} \pi(a|s) \dots\): Because our policy might be stochastic, we must average over all possible actions.
  2. Immediate Reward \(R(s,a)\): The reward received immediately after taking action \(a\).
  3. Inner Expectation \(\sum_{s' \in S} p(s'|s,a) \dots\): Because the environment’s response (state transition) might be stochastic, we must average over all possible next states.
  4. \(V_\pi(s')\): This is the magic of recursion. The value of the next state can be expanded in the same way.

Bellman Expectation Equation (Q-function)

For the action-value function \(Q_\pi(s, a)\), the Bellman equation has a slightly different form:

\[ \large{ Q_\pi(s, a) = R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) \sum_{a' \in A} \pi(a'|s') Q_\pi(s', a') } \]

Since \(\sum_{a' \in A} \pi(a'|s') Q_\pi(s', a') = V_\pi(s')\), we can simplify this to:

\[ \large{ Q_\pi(s, a) = R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) V_\pi(s') } \]

In words: The value of taking action a in state s = immediate reward + discounted expected value of the next state.

Bellman by Hand: Compute the Expectation First

  • At state \(s_0\), a policy chooses hold and sell with probability 0.5 each.

  • Let \(\gamma=0.9\).

  • Hold gives reward 1, moves deterministically to \(s_1\), and \(V_\pi(s_1)=4\).

  • Sell gives reward 3 and terminates, so its bootstrap mask is zero.

Predict: calculate both action values and \(V_\pi(s_0)\). Which operation changes for the optimal value?

Bellman by Hand: Reveal Expectation versus Max

\[ \begin{aligned} Q_\pi(s_0,\text{hold}) &= 1+0.9\times4=4.6, \\ Q_\pi(s_0,\text{sell}) &= 3+0.9\times0=3.0. \end{aligned} \]

\[ \begin{aligned} V_\pi(s_0) &= 0.5\times4.6+0.5\times3.0=3.8, \\ \max_a Q_\pi(s_0,a) &= 4.6. \end{aligned} \]

  • The first quantity evaluates the stated policy.

  • \(\max_aQ_\pi\) is only a one-step greedy value under continuation \(V_\pi\) and is not generally \(V^*\).

  • Only with the additional assumption \(V_\pi(s_1)=V^*(s_1)=4\)—for example, no later choice at \(s_1\)—may we write

\[ \begin{aligned} Q^*(s_0,\text{hold}) &= 4.6, \qquad Q^*(s_0,\text{sell})=3.0, \\ V^*(s_0) &= 4.6. \end{aligned} \]

Solving the RL Problem: Finding the Optimal Policy \(\pi^*\)

The ultimate goal of reinforcement learning is to find an optimal policy \(\pi^*\) that achieves a higher or equal expected return than any other policy from any initial state.

\[ \large{ \pi^* = \arg\max_{\pi} V_\pi(s) \quad \text{for all } s \in S } \]

The corresponding optimal value functions are denoted \(V^*(s)\) and \(Q^*(s, a)\).

The Bellman Optimality Equation

For an optimal policy, the Bellman equation takes a special form: the Bellman Optimality Equation. It no longer involves an expectation over actions but instead takes the maximum.

For \(V^*(s)\):

\[ \large{ V^*(s) = \max_{a \in A} \left( R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) V^*(s') \right) } \]

For \(Q^*(s, a)\):

\[ \large{ Q^*(s, a) = R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) \max_{a' \in A} Q^*(s', a') } \]

The max operator embodies optimality: the agent will always choose the action that leads to the best possible future.

How to Solve? Generalized Policy Iteration (GPI)

We know the target (the Bellman Optimality Equation), but how do we find the solution? Most RL algorithms follow a common pattern called Generalized Policy Iteration (GPI).

This is an iterative process involving two intertwined steps:

Generalized Policy Iteration (GPI) This diagram illustrates GPI, where Policy Evaluation and Policy Improvement work together to find the optimal policy and value function. Generalized Policy Iteration V π 2. Policy Improvement π' ← greedy(V) 1. Policy Evaluation V_π ← Bellman Expectation Eq. V*, π*

Policy Evaluation: How Good is My Current Policy?

Suppose we have a fixed policy \(\pi\) (e.g., an existing set of trading rules). We want to know its value.

  • Task: Compute \(V_\pi(s)\).

  • Method: Use the Bellman Expectation Equation and solve it iteratively.

    \[ \large{ V_{k+1}(s) = \sum_{a \in A} \pi(a|s) \left( R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) V_k(s') \right) } \]

    We start with a random \(V_0\) and repeatedly use the old value function to compute the new one until \(V_k\) converges. This process is called iterative policy evaluation.

Policy Improvement: Can I Do Better?

Once we know the value function \(V_\pi\) for our current policy \(\pi\), we can try to improve it.

  • Method: For each state \(s\), instead of following \(\pi\), we act ‘greedily’ by choosing the action that leads to the highest Q-value:

    \[ \large{ \pi'(s) = \arg\max_{a \in A} Q_\pi(s,a) } \]

    \[ \large{ = \arg\max_{a \in A} \left( R(s,a) + \gamma \sum_{s' \in S} p(s'|s,a) V_\pi(s') \right) } \]

  • For a finite MDP with exact policy evaluation and comparable action values, the new policy \(\pi'\) is no worse than \(\pi\).

  • This is the Policy Improvement Theorem; offline financial data without action support do not inherit that guarantee.

Algorithm Classification: Do We Need a Model of the Environment?

Algorithms that solve this GPI loop can be divided into two main categories:

Model-Based

The algorithm learns and/or uses an explicit transition-and-reward model for planning. The model may be given or learned, and it may be approximate.

  • Special Case: Dynamic programming with a known exact model.
  • Advantage: High data efficiency.
  • Limitation: learned models can be wrong and planning can amplify model bias; exact transition models are rarely available.

Model-Free

The algorithm does not need a model of the environment. It learns directly from samples (experience) generated by interacting with the environment.

  • Typical Algorithms: Q-Learning, Sarsa
  • Advantage: Much more applicable to complex, real-world problems.

Model-Free Methods: A Metaphor for Exploration

Model-Based vs. Model-Free RL A comparison: model-based is like having a map to plan a learning path, while model-free is like exploring without a map and learning from trial and error. Model-Based Learns/uses anexplicit model Plans before acting Model-Free No explicit model Learns from experience

Model-Free Algorithm Classification: How Do We Learn?

Within model-free algorithms, we can further classify them based on their learning style:

On-policy

The agent learns from and improves the same policy it uses to make decisions.

  • Analogy: A novice driver learns to improve their own driving skills while they are actively driving.
  • Typical Algorithm: Sarsa.

Off-policy

The agent can learn from a policy that is different from the one it is currently using to explore. It can learn a target (greedy) policy while behaving according to an exploratory policy.

  • Analogy: An expert learns how to be a perfect driver by watching videos of a novice driver’s mistakes.
  • Typical Algorithm: Q-Learning.

Model-Free Method 1: Monte Carlo (MC)

MC methods are the most intuitive model-free learning approach.

  • Core Idea: Estimate the value function by simulating a large number of complete episodes. An episode is a full trajectory from a starting state to a terminal state.
  • How to estimate \(Q_\pi(s,a)\)?
    1. Follow policy \(\pi\) and play many episodes.

    2. For every episode that visited the pair \((s,a)\), record the actual return \(G_t\) that followed.

    3. Average these returns to estimate \(Q_\pi(s,a)\).

      \[ \large{ Q(s,a) \leftarrow \text{Average}(G_t \text{ for all visits to } (s,a)) } \]

  • Limitation:
    • Full-return MC waits for the end of an episode, so updates are delayed and can have high variance.

    • Continuing tasks can still use truncation, regenerative states, or average-reward constructions; MC is not restricted to naturally episodic tasks.

Model-Free Method 2: Temporal-Difference (TD)

TD learning is one of the most central and innovative ideas in reinforcement learning. It combines the advantages of MC and dynamic programming.

  • Core Idea: Learn from every single step, without waiting for the episode to end. It updates the value of the current state using an estimate of the next state’s value.
  • Comparison with MC:
    • MC’s update target is the actual final return \(G_t\).
    • TD’s update target is an estimated future return \(R_{t+1} + \gamma V(S_{t+1})\).
  • This process of updating an estimate with another estimate is called bootstrapping.

The TD(0) Algorithm’s Update Rule

The simplest TD algorithm, TD(0), has the following update rule:

\[ \large{ V(S_t) \leftarrow V(S_t) + \alpha \underbrace{\left[ \overbrace{R_{t+1} + \gamma V(S_{t+1})}^{\text{TD Target}} - V(S_t) \right]}_{\text{TD Error}} } \]

  • \(\alpha\): The learning rate, which determines how much we update our estimate based on the new information.
  • TD Target (\(R_{t+1} + \gamma V(S_{t+1})\)): A bootstrapped target combining one observed reward with the current next-state estimate; it is not guaranteed to be more accurate than \(V(S_t)\).
  • TD Error (\(\delta_t\)): The difference between the current estimate and that bootstrapped target, used for an incremental update; finite-sample bias and noise can remain.

A Vivid Example: Walking from Dorm to Classroom

Imagine you want to predict how long it takes to walk from your dorm to the classroom. Your initial guess is 18 minutes.

MC vs. TD Learning Example A timeline showing that Monte Carlo updates only at the end of an episode, while Temporal-Difference updates at every step. Leave Dorm See Rain Bridge Jam Arrive at Class MC: Wait for the final return; then update. Update TD: Use each observation; update immediately. Update Update again
  • MC Method: Wait for the episode’s final return, then update the starting-state value.
  • TD Method: After each observation, update from the current reward and next-state estimate.

On-Policy TD Control Algorithm: Sarsa

Sarsa is an on-policy TD control algorithm that aims to learn the Q-function.

  • Name Origin: Its update rule requires a quintuple \((S_t, A_t, R_{t+1}, S_{t+1}, A_{t+1})\), which spells out S, A, R, S’, A’.

  • Update Rule:

    \[ \begin{aligned} Q(S_t,A_t) &\leftarrow Q(S_t,A_t) \\ &\quad + \alpha\!\left[R_{t+1}+\gamma(1-d_t)Q(S_{t+1},\mathbf{A_{t+1}})-Q(S_t,A_t)\right] \end{aligned} \]

  • Key point: the update uses the action \(A_{t+1}\) actually taken in \(S_{t+1}\). Here \(d_t=1\) marks a terminal transition, so \((1-d_t)\) sets the bootstrap term to zero.

The Exploration-Exploitation Dilemma: \(\epsilon\)-greedy Policy

To retain exploration while exploiting the current best action, we typically replace a purely greedy policy with an \(\epsilon\)-greedy policy.

  • With probability \(1-\epsilon\), choose the best-estimated action: \(a^* = \arg\max_a Q(s,a)\). (Exploit)
  • With probability \(\epsilon\), choose an action randomly from all possible actions. (Explore)

The value of \(\epsilon\) is often decayed over time. Claims of sufficient state-action exploration additionally require reachability, persistent visitation, and an appropriate decay schedule; \(\epsilon\)-greedy alone gives no unconditional guarantee.

Off-Policy TD Control Algorithm: Q-Learning

Q-Learning is one of the most famous and widely used algorithms in reinforcement learning. It is an off-policy algorithm.

  • Core Idea: It follows a behavior policy (e.g., \(\epsilon\)-greedy) to explore, while simultaneously learning the Q-values of a different target policy (the purely greedy policy).

  • Update Rule:

    \[ \begin{aligned} Q(S_t,A_t) &\leftarrow Q(S_t,A_t) \\ &\quad + \alpha\!\left[R_{t+1}+\gamma(1-d_t)\max_{a'}Q(S_{t+1},a')-Q(S_t,A_t)\right] \end{aligned} \]

  • Key difference: a nonterminal transition uses \(\max_{a'} Q(S_{t+1},a')\) regardless of the realized next action; when \(d_t=1\), Q-learning does not bootstrap from the terminal state.

Sarsa vs. Q-Learning: A Cliff Walking Analogy

Imagine an agent walking along the edge of a cliff, trying to get from the start (S) to the goal (G). Falling off the cliff results in a large negative reward.

Sarsa vs. Q-Learning: Cliff Walking Comparison This diagram shows the fundamental difference between Sarsa (cautious, safe path) and Q-Learning (aggressive, optimal path) in the cliff walking environment. Sarsa vs. Q-Learning: Cliff Walking Policies S G The Cliff Sarsa · on-policy actual next action learns a safer path Q-learning · off-policy max over next actions learns the cliff-edge path

Sarsa vs. Q-Learning: Interpretation

  • Sarsa (On-policy):
    • It’s a ‘cautious’ learner.

    • Because it knows its next action is also exploratory (and might accidentally step off the cliff), it factors this risk into its Q-value updates.

    • It learns a safer, albeit slower, path that stays far from the cliff.

  • Q-Learning (Off-policy):
    • It’s a ‘bold’ learner.

    • It always assumes the optimal action will be taken next, regardless of the fact that it might make mistakes while exploring.

    • It learns the fastest path right along the cliff edge, because it believes it will eventually execute that path perfectly.

Feature Sarsa (On-policy) Q-Learning (Off-policy)
Objective Learns the value of its current behavior policy Learns the value of the optimal policy
Update Uses the Q-value of the next actual action Uses the Q-value of the next possible best action
Behavior More conservative, avoids risky shortcuts More aggressive, favors optimal but risky paths

Python in Practice: Solving the ‘FrozenLake’ Problem with Q-Learning

To make these concepts concrete, let’s look at a classic RL problem: FrozenLake.

  • Environment: A 4x4 grid, with some tiles being safe frozen ice (F) and others being holes (H).
  • Goal: Navigate from the start (S) to the goal (G) without falling into a hole.
  • States: 16 grid positions.
  • Actions: Up, Down, Left, Right.
  • Reward: +1 for reaching the goal, 0 otherwise.
  • Challenge: The ice is slippery. An action to move ‘right’ might have some probability of sliding somewhere else.

This is a classic MDP.

Q-Learning Code Framework: Initialization

We need a Q-table to store the value of each (state, action) pair. Initially, we know nothing, so we set all values to zero.

Code
import numpy as np
import pandas as pd
n_states = 16  # 4x4 grid.
n_actions = 4  # left, down, up, right.
q_table = np.zeros((n_states, n_actions))
print('Initialized Q-Table (Shape: {}):'.format(q_table.shape))  # 展示当前步骤的结果。
q_df = pd.DataFrame(q_table, columns=['Left', 'Down', 'Up', 'Right'])
q_df.index.name = 'State'
print(q_df.head())  # 展示当前步骤的结果。
Initialized Q-Table (Shape: (16, 4)):
       Left  Down   Up  Right
State                        
0       0.0   0.0  0.0    0.0
1       0.0   0.0  0.0    0.0
2       0.0   0.0  0.0    0.0
3       0.0   0.0  0.0    0.0
4       0.0   0.0  0.0    0.0

Q-Learning Code Framework: The Main Loop

  • The core of the algorithm is a loop where the agent interacts with the environment and updates the Q-table.

  • To make this code self-contained, we will simulate a simple, non-slippery version of the FrozenLake environment.

Code
import numpy as np
import pandas as pd
MAP = ["SFFF", "FHFH", "FFFH", "HFFG"]
ACTION_EFFECTS = [-1, 4, -4, 1]
GOAL_STATE = 15
HOLES = [5,7,11,12]
def mock_step(state, action):  # 定义当前教学案例所需的函数。
    new_state = state + ACTION_EFFECTS[action]
    if (action == 0 and state % 4 == 0) or \
       (action == 3 and state % 4 == 3) or \
       (action == 2 and state < 4) or \
       (action == 1 and state > 11):
        new_state = state # Stay put if hitting a wall.
    if new_state in HOLES:  # Terminate rounds without reward when falling into an ice cave
        return new_state, 0, True # Fell in a hole, no reward, episode ends.
    elif new_state == GOAL_STATE:  # Terminating Rebates and Rewarding Success on Reaching Target
        return new_state, 1, True # Reached goal, reward 1, episode ends.
    else:  # 按当前教学条件控制计算分支。
        return new_state, 0, False # Normal move.

Separating the environment from the learner makes the transition logic easy to check and keeps each code chunk focused.

Code
# 固定局部随机数生成器,使探索轨迹与课堂输出可复现。
random_generator = np.random.default_rng(20250830)
q_table = np.zeros((16, 4))  # 从零初始化所有状态—动作价值
learning_rate = 0.2  # 用适中的步长传播稀疏终点奖励
gamma = 0.95  # 对更短的成功路径赋予更高价值
n_episodes = 12000  # 给稀疏奖励足够的可重复探索机会
successful_episodes = 0  # 记录训练期间实际到达终点的回合

# 前半程逐步退火探索率,后半程保留少量探索。
for episode_index in range(n_episodes):  # 遍历当前教学对象以完成重复计算。
    state = 0  # 每回合都从起点 S 开始
    epsilon = max(0.05, 1 - episode_index / 6000)  # 从充分探索平滑过渡到利用
    for step_index in range(64):  # 设置上限,避免撞墙策略形成无限回合
        if random_generator.random() < epsilon:  # 按退火后的概率探索
            action = int(random_generator.integers(4))  # 在四个动作中均匀探索
        else:  # 按当前教学条件控制计算分支。
            state_values = q_table[state]  # 读取当前状态的动作价值
            best_actions = np.flatnonzero(np.isclose(state_values, state_values.max()))  # 找出并列最优动作
            action = int(random_generator.choice(best_actions))  # 随机打破零值并列,避免固定偏向左移
        new_state, reward, done = mock_step(state, action)  # 执行一步环境转移
        bootstrap_value = 0 if done else q_table[new_state].max()  # 终止状态不再自举
        temporal_difference = reward + gamma * bootstrap_value - q_table[state, action]  # 计算 TD 误差
        q_table[state, action] += learning_rate * temporal_difference  # 把奖励向可达前序状态传播
        state = new_state  # 推进到下一状态
        if done:  # 按当前教学条件控制计算分支。
            successful_episodes += reward  # 只把到达目标计为成功
            break  # 洞或目标都会结束当前回合

Q-Learning Result: Greedy-Path Action Values

Show the reachable greedy-path states; the complete 16-state Q-table remains in q_df_final.

Code
print("Q-values on the greedy path:")  # 明确展示的是完整 Q 表的可达路径子集
q_df_final = pd.DataFrame(q_table, columns=['Left', 'Down', 'Up', 'Right'])
q_df_final.index.name = 'State'
print(q_df_final.loc[[0, 4, 8, 9, 13, 14, 15]].round(3))  # 展示与后续策略核验直接相关的状态
Q-values on the greedy path:
        Left   Down     Up  Right
State                            
0      0.735  0.774  0.735  0.774
4      0.774  0.815  0.735  0.000
8      0.815  0.000  0.774  0.857
9      0.815  0.902  0.000  0.902
13     0.000  0.902  0.857  0.950
14     0.902  0.950  0.902  1.000
15     0.000  0.000  0.000  0.000
Code
# 从起点执行确定性的贪心策略,验证学得策略确实到达目标。
greedy_state = 0  # 从 FrozenLake 起点开始验证
greedy_path = [greedy_state]  # 保存可解释的状态路径
for rollout_step in range(16):  # 最短成功路径远少于 16 步
    greedy_action = int(np.flatnonzero(np.isclose(q_table[greedy_state], q_table[greedy_state].max()))[0])  # 固定选择首个最优动作
    greedy_state, rollout_reward, rollout_done = mock_step(greedy_state, greedy_action)  # 执行贪心动作
    greedy_path.append(greedy_state)  # 记录到达的下一状态
    if rollout_done:  # 按当前教学条件控制计算分支。
        break  # 到达洞或目标后停止验证
assert greedy_state == GOAL_STATE and rollout_reward == 1  # 若策略未到目标则使渲染失败
assert np.count_nonzero(q_table[[0, 4, 8, 9, 13, 14]]) > 0  # 核验奖励已传播到可达前序状态
print(f'Successful training episodes: {successful_episodes}/{n_episodes}')  # 报告探索确实多次到达目标
print(f'Greedy path: {greedy_path}; reached goal: {greedy_state == GOAL_STATE}')  # 展示可重复策略
Successful training episodes: 8311/12000
Greedy path: [0, 4, 8, 9, 13, 14, 15]; reached goal: True

Interpretation

reward reaches the start and the verified path is 0 → 4 → 8 → 9 → 13 → 14 → 15. Terminal masking blocks cross-episode bootstrap; this deterministic execution check is not evidence for slippery, continuous, or market settings.

From Tables to Reality: The Curse of Dimensionality

The tabular method (Q-table) we just discussed works well for problems with small state and action spaces.

But what about real-world economic problems?

  • The state space of Chess is approximately \(10^{47}\).
  • The state space of Go is approximately \(10^{170}\).
  • The state of a self-driving car is continuous (position, velocity, orientation), making the state space infinite.

It is impossible to create a Q-table for these problems. This is where Deep Reinforcement Learning (DRL) comes in.

Deep Reinforcement Learning: Neural Networks for RL

The core idea of DRL is to use a deep neural network to approximate the value function or policy function, instead of a table.

  • Value Network: Takes a state \(s\) as input and outputs its value \(V(s)\), or the Q-value for each action \(Q(s,a)\).

    \[ \large{ Q(s, a; \mathbf{w}) \approx Q^*(s, a) } \]

    Here, \(\mathbf{w}\) represents the weights of the neural network.

  • Policy Network: Takes a state \(s\) as input and outputs the probability of taking each action, \(\pi(a|s)\).

major advance: The Deep Q-Network (DQN)

  • The 2013 DQN preprint evaluated seven Atari games from raw pixels and exceeded the compared human expert on three.

  • The 2015 Nature study expanded the evaluation to 49 games and reported aggregate performance comparable to a professional human games tester; these scopes and claims should not be conflated.

Sources: Mnih et al. (2013); Mnih et al. (2015).

The core of DQN is using a deep convolutional neural network (CNN) to approximate the optimal action-value function \(Q^*(s,a)\).

DQN Architecture A simplified diagram of the DQN architecture, showing input state, convolutional layers, fully connected layers, and the final Q-value outputs. State S screen pixels Conv layers Dense layers Q(s,a₁) Q(s,a₂)

DQN’s Loss Function: How to Train the Network?

How do we train this Q-network? We want the network’s prediction \(Q(s, a; \mathbf{w})\) to be as close as possible to the ‘target value’ given by the Bellman Optimality Equation.

Let \(\theta\) denote online-network parameters, \(\theta^-\) frozen target-network parameters, and \(d_t\in\{0,1\}\) the terminal indicator. Standard target-network DQN uses:

\[ \large{Y_t^{\mathrm{DQN}}=R_{t+1}+\gamma(1-d_t)\max_{a'}Q(S_{t+1},a';\theta^-)} \]

\[ \large{L(\theta)=\mathbb{E}\left[\left(Y_t^{\mathrm{DQN}}-Q(S_t,A_t;\theta)\right)^2\right]} \]

We can then use gradient descent to optimize the network weights \(\mathbf{w}\).

Experience Replay Reduces Correlation

DQN stabilizes training by storing transitions and sampling them later.

Experience Replay Mechanism An illustration of Experience Replay: the agent's experiences are stored in a replay buffer, and mini-batches are randomly sampled for training the Q-Network. Store, sample, then update Agent (s,a,r,s′) Replay buffer (s,a,r,s′) pasttransitions stored transitions Q-network update append sample
  • Effect: replay reduces adjacent-transition correlation and improves reuse; a changing-policy buffer still has stale distributions and incomplete state-action coverage.

A Frozen Target Network Stabilizes Bootstrap Targets

If the target changes with the online parameters on every update, learning chases a moving target. DQN uses θ for the current prediction and a temporarily frozen θ⁻ for the bootstrap target.

Target Network Mechanism in DQN An illustration showing two networks in DQN: a main network for predictions and a fixed target network for calculating the TD target, with weights copied periodically. Main Network (Q-Network, w) Predicts Q(s,a) Target Network (frozen θ⁻) Computes target max Q(s′,a′)using θ⁻ Copy weights every N steps
  • Effect: The target network w- is ‘frozen’ for a period, making the learning target much more stable.

The Overestimation Problem in DQN

Standard DQN uses max for action selection and evaluation; with noisy estimates, selecting the maximum creates upward selection bias.

\[ \large{Y_t^{\mathrm{DQN}}=R_{t+1}+\gamma(1-d_t)\max_{a'}Q(S_{t+1},a';\theta^-)} \]

If the Q-value estimates themselves have noise, taking the maximum will amplify positive noise, leading to an optimistic bias. This bias can propagate and accumulate through the bootstrapping process.

Solution: Double DQN (DDQN)

DDQN addresses the overestimation problem by decoupling ‘action selection’ from ‘value evaluation’.

  • Standard DQN Target:

    \[ \large{Y_t^{\mathrm{DQN}}=R_{t+1}+\gamma(1-d_t)\max_{a'}Q(S_{t+1},a';\theta^-)} \]

  • DDQN Target: It uses the main network to select the best action, but uses the target network to evaluate the value of that action.

    \[ \large{Y_t^{\mathrm{DDQN}}=R_{t+1}+\gamma(1-d_t)Q\!\left(S_{t+1},\arg\max_{a'}Q(S_{t+1},a';\theta);\theta^-\right)} \]

  • This decoupling is designed to reduce DQN’s maximization-induced overestimation bias. It does not guarantee conservative or more accurate estimates in every state or task; underestimation and accuracy must be evaluated empirically.

Numerical Check: Compute DQN and DDQN Targets First

  • Let \(R_{t+1}=1, \gamma=0.9, d_t=0\).

  • At the next state, the online network estimates actions A/B as \((5,4)\), while the target network estimates \((3,6)\).

  • Write both targets first, then decide whether a transition with \(d_t=1\) still bootstraps.

  • DQN takes the target-network maximum 6, so \(Y^{DQN}=1+0.9\times6=6.4\).
  • DDQN selects A with the online network and evaluates A as 3 with the target network, so \(Y^{DDQN}=1+0.9\times3=3.7\).
  • If \(d_t=1\), both equal immediate reward 1; the terminal mask prevents bootstrap.

Remediation

Further Decomposing the Value Function: Dueling DQN

Optional topic

Continue to the practice questions for the main lesson. Study Dueling DQN afterward if time permits.

Dueling DQN introduces a new network architecture that splits the Q-value estimate into two streams:

  1. State Value (\(V(s)\)): How good is it to be in this state, regardless of the action taken.
  2. Advantage Function (\(A(s,a)\)): How much better is it to take action \(a\) compared to the average action in this state.

\[ \large{ Q(s,a) = V(s) + \left( A(s,a) - \frac{1}{|\mathcal{A}|} \sum_{a' \in \mathcal{A}} A(s,a') \right) } \]

This architecture allows the network to learn the intrinsic value of states more efficiently, especially in situations where many actions have similar values.

Formative Check: Terminal State and Policy Semantics

  • Question 1: A transition yields −2 and terminates; γ=0.99 and the next-state network maximum is 100. What is the correct target?

  • Question 2: Sarsa uses the realized next action while Q-learning uses the maximizing action. Which is on-policy?

  • Reveal and remediation:
    • item 1 is −2 because the terminal mask removes bootstrap; item 2 is Sarsa on-policy and Q-learning off-policy.

    • If you wrote 97, revisit terminal transitions; if policies were reversed, revisit the two targets.

Step-by-Step Exercise: Compute One DDQN Target

  • Task: (R=0.5,γ=0.8,d=0); online A/B/C values are (2,5,4), target values are (6,1,3). Compute both targets.
  • Complete answer:
    • DQN takes the target-network maximum 6: \(0.5+0.8\times6=5.3\).

    • DDQN selects B online and evaluates B as 1 with the target network: \(0.5+0.8\times1=1.3\).

Apply It to a New Case: Offline RL with a Local Chinese Index

  • Task:
    • Using local hs300_index_only.h5 / hs300, design a monthly position teaching environment: month-end available states, actions {cash, hold}, and reward equal to next-month portfolio return minus transaction costs.

    • Submit state, action, transition, reward, behavior-policy coverage, and chronological offline evaluation.

  • Complete-answer reminder:
    • report the file, key and sample, construct states without looking ahead, include costs in the reward, explain behavior-policy coverage risk, and propose rolling out-of-sample evaluation with baselines.

    • Never present backtest returns as a live-performance guarantee.

  • Study note: This review completes the main lesson; study the Dueling DQN section afterward if time permits.

Apply It to a New Case: Executable Reference

Code
from pathlib import Path  # Locate Local CSI 300 Minimum Files
import numpy as np  # Calculate return and volatility states
import pandas as pd  # Read and Construct Offline Transfer Table
# Public download: https://assets.qiufei.site/data/index/hs300_index_only.h5
# After downloading, change the next line to the file's actual location on your device.
# Course-relative option: Path("data/index/hs300_index_only.h5")
# Windows: Path(r"C:\qiufei\data\index\hs300_index_only.h5")
# macOS: Path("/Users/your_name/data/index/hs300_index_only.h5")
# Linux: Path("/home/your_name/data/index/hs300_index_only.h5")
index_path = Path("/home/ubuntu/r2_data_mount/data/index/hs300_index_only.h5")
daily_index = pd.read_hdf(index_path, key='hs300')  # Reading real China index quotes
daily_index['date'] = pd.to_datetime(daily_index['datetime'].astype(str), format='%Y%m%d%H%M%S')
monthly_close = daily_index.query("'2005-01-01' <= date <= '2024-12-31'").set_index('date')['close'].resample('ME').last().to_frame()  # Fixed Sample Period and Aggregated Monthly
monthly_close['return_1m'] = monthly_close['close'].pct_change()  # Construct the monthly return
monthly_close['momentum_3m'] = monthly_close['close'].pct_change(3)  # Construct Monthly End Visible Momentum
monthly_close['volatility_3m'] = monthly_close['return_1m'].rolling(3).std()  # Compute rolling three-month volatility
monthly_close['high_vol'] = monthly_close['volatility_3m'].gt(monthly_close['volatility_3m'].expanding().median()).astype(int)  # Use only the historical extended median discretization
monthly_close['positive_momentum'] = monthly_close['momentum_3m'].gt(0).astype(int)  # Create a no-look-ahead momentum state
monthly_close['state'] = 2 * monthly_close['high_vol'] + monthly_close['positive_momentum']  # Encode four discrete states
monthly_close['behavior_action'] = monthly_close['positive_momentum']  # Clarify demonstration behavioral strategies rather than fictitious real transactions
monthly_close['next_return'] = monthly_close['return_1m'].shift(-1)  # Aligning Next Month Environmental Feedback
monthly_close['reward'] = monthly_close['behavior_action'] * monthly_close['next_return'] - .001 * monthly_close['behavior_action'].diff().abs().fillna(0)  # Deduct 10bp Swap Costs
monthly_close['next_state'] = monthly_close['state'].shift(-1)  # Aligning Next State
offline_batch = monthly_close.dropna().copy()  # Form a complete offline transfer sample
support_table = pd.crosstab(offline_batch['state'], offline_batch['behavior_action'])  # check Each State Action Coverage
display(support_table)  # Show whether counterfactual action values are identifiable
behavior_action 0 1
state
0 73 0
1 0 73
2 39 0
3 0 51

Apply It to a New Case: Evaluation and Support decision rule

  • Complete reference output:
    • 236 transitions span 2005-04 to 2024-11.

    • Action counts by state are (73,0), (0,73), (39,0), and (0,51).

    • Every state lacks one action, so the deterministic behavior policy provides no counterfactual support.

    • The correct conclusion is do not estimate a policy-improvement return from this batch; obtain broader behavior coverage and use conservative offline RL plus rolling baselines.

Apply It to a New Case: Chronological Evaluation

  • Chronological evaluation:
    • use rolling-origin splits.

    • In each fold, fit only on earlier months, choose hyperparameters and a support threshold on the immediately following validation window, then evaluate once on the later test window before rolling forward.

    • Report cash-only, always-hold, and the observed behavior policy as cost-matched baselines in every test window.

    • Because every state currently lacks one action, an alternative-policy value cannot be estimated from these data; the result here is “not identifiable,” not an invented backtest return.

Sources and Further Reading

  • Sutton, R. S. and Barto, A. G. (2018), Reinforcement Learning: An Introduction, 2nd ed.; adjacent support for Bellman equations, TD, and convergence conditions.
  • Mnih, V. et al. (2015), “Human-level control through deep reinforcement learning,” Nature.
  • van Hasselt, H., Guez, A., and Silver, D. (2016), “Deep Reinforcement Learning with Double Q-learning,” AAAI.
  • FrozenLake is explicitly a teaching simulation; the transfer uses local real HS300 prices without inventing backtest results.

Conclusion: RL Provides a New Paradigm for Economic Decision-Making

  • Core Framework: MDP provides a unified mathematical language for sequential decision problems.
  • Core Idea: convergence requires conditions such as a finite MDP, sufficient exploration, suitable learning rates, and adequate value representation; deep RL has no unconditional optimal-convergence guarantee.
  • Core Algorithms: From Q-Learning to DQN and its variants, algorithmic advancements are making it possible to solve increasingly complex problems.
  • Economic Significance: RL is more than just a tool for game AI; it offers a powerful, data-driven toolkit for dynamic pricing, resource management, portfolio optimization, auction design, and many other fields in economics.

Future Directions: RL’s Application in Economics

  • Market Modeling: Simulating markets with multiple RL agents to study the emergence of market equilibria and complex dynamics.
  • Algorithmic Game Theory: Designing agents that perform optimally in competitive or cooperative environments, such as auctions or supply chain negotiations.
  • Personalized Policies: Developing dynamic, individualized strategies for each user (e.g., in e-commerce recommendations) or each asset (e.g., in a portfolio).

Reinforcement learning is evolving from a subfield of computer science into a general framework for understanding and optimizing intelligent decision-making in complex systems.

Thank You!