[KongchangAI]
· 2 min read· 1,081 words

Decoupling Robust Reinforcement Learning: How PB-GT Q-Learning Handles Adversarial State Perturbations

Decoupling Robust Reinforcement Learning: How PB-GT Q-Learning Handles Adversarial State Perturbations

PB-GT decouples pessimistic behavior and greedy targets, finding that the test-time worst-case rule dominates robustness.

Based on the PB-GT Q-learning study, this article explores the sources of robustness for RL agents under adversarial state perturbations. Traditional pessimistic Q-learning uses worst-case rules in both the Bellman target and test-time action selection, obscuring the source of robustness and adding test-time computation. PB-GT separates the two: it collects data with a pessimistic rule, learns and acts greedily, and evaluates learned Q-functions under both greedy and pessimistic test rules. Experiments on tabular GridWorld, continuous GridWorld, and CartPole show that most robustness comes from the test-time worst-case rule, with the pessimistic Bellman target providing only a small gain; training on adversarial data with a greedy target performs comparably to standard Q-learning. However, the worst-case rule may be overly cautious without an attacker and adds computational overhead, requiring trade-offs based on risk scenarios.

Introduction: How Can RL Agents Protect Themselves When Observations Are Corrupted?

Reinforcement learning (RL) agents rely on accurate observations during both training and deployment, but attackers can tamper with state inputs through adversarial perturbations. Even if the environment itself remains unchanged, the agent may make incorrect decisions. Such adversarial state perturbations pose a serious threat to real-world applications (e.g., autonomous driving, robotic control).

Previously, researchers proposed "Belief-enriched Pessimistic Q-Learning" to defend against such attacks: the agent maintains a set of states consistent with historical observations and selects the action with the highest worst-case value over that set. This worst-case reasoning was applied simultaneously to two components—the Bellman target for learning the Q-function and the action selection rule at test time. However, because both were changed at once, it was unclear which part provided robustness, and the test-time search added computational overhead to every decision.

A recent study [1] separated these two components and proposed PB-GT (Pessimistic-Behavior, Greedy-Target) Q-Learning. This method collects data using a pessimistic rule but learns and acts greedily, and evaluates each learned Q-function under two test rules separately. Based on this study, this article discusses its core findings and implications.

PB-GT Q-learning schematic

Bellman target is a key concept in Q-learning updates: Q(s,a) ← Q(s,a) + α[r + γ·max_a' Q(s',a') - Q(s,a)], where r + γ·max_a' Q(s',a') is the Bellman target, representing the current reward plus a discounted estimate of the optimal action value at the next state. In adversarial perturbation scenarios, the next state s' may be tampered with, so pessimistic Q-learning replaces max_a' in the target with min_{s'∈B} max_a' Q(s',a'), i.e., taking the worst case within the belief set B. Understanding the introduction of worst-case reasoning into the Bellman target is fundamental to distinguishing "training-time robustness" from "test-time robustness."

Method: Separating Behavior and Target

The core idea of PB-GT is to decouple the sources of robustness. Traditional pessimistic Q-learning uses the worst-case rule in both the Bellman update and action selection, whereas PB-GT uses the pessimistic rule only during data collection (i.e., the behavior policy) and adopts the greedy rule during learning and testing. This allows researchers to independently evaluate the contributions of pessimism in the Bellman target and the test-time worst-case rule.

Experiments were conducted in three environments: tabular GridWorld, continuous GridWorld, and CartPole. Each learned Q-function was evaluated under two test rules: the greedy rule and the pessimistic rule (i.e., the worst-case rule). This design clearly distinguishes the roles of training-time and test-time robustness.

Behavior policy is the policy used in reinforcement learning to interact with the environment and generate training data, as distinct from the target policy being evaluated or deployed. In PB-GT, the behavior policy uses the pessimistic rule (worst-case action selection) to collect data, while the learned Q-function (target policy) uses the greedy rule. This decoupling allows researchers to keep the data distribution adversarially robust while avoiding introducing pessimism into value estimation and final decisions. The separation of behavior policy and target policy is a common design in offline reinforcement learning and robust RL, and PB-GT uses it to isolate the sources of robustness.

Experimental Findings: Test-Time Worst-Case Rule Contributes Most of the Robustness

Tabular GridWorld: Pessimistic Bellman Target Provides Additional Gain

In tabular GridWorld, most of the robustness comes from the test-time worst-case rule. The pessimistic Bellman target (i.e., incorporating worst-case reasoning into the learning target) brings a small additional gain. This means that even if a greedy target is used during training, the agent can still achieve considerable robustness as long as the pessimistic rule is adopted at test time.

Training on Adversarial Data: Greedy Target Comparable to Standard Q-Learning

The study also found that training with a greedy target on adversarial data performs roughly the same as standard Q-learning. This indicates that merely adding adversarial examples to training data is insufficient to improve robustness; the key lies in the worst-case decision rule at test time.

Continuous GridWorld and CartPole: Verifying the Generality of the Conclusion

In continuous GridWorld and CartPole environments, the advantage of the test-time worst-case rule remains significant, further supporting the generality of the conclusion.

Worst-case rule at test time means: given the current observation, the agent does not directly select the action with the highest Q-value, but instead considers all possible states consistent with historical observations (the belief set) and selects the action that maximizes the minimum Q-value over that set, i.e., argmax_a min_{s∈B} Q(s,a). This is equivalent to performing a robust optimization with an inner minimization and outer maximization at decision time. This rule does not change the learned Q-function, only the action selection method, so it can be combined with any Q-function for evaluation. PB-GT's experiments directly compare the contributions of the greedy rule and the worst-case rule to robustness by fixing the Q-function and switching the test rule.

Costs and Trade-offs: The Over-Caution of the Worst-Case Rule

Although the test-time worst-case rule can effectively improve robustness, it also has obvious drawbacks: when there is no attacker in the environment, the rule may be overly cautious, leading to performance degradation. In addition, test-time search adds computational overhead to every decision. Therefore, the researchers discuss when it is worth paying the extra computational cost—in scenarios where adversarial risk exists and safety is critical, this cost is justified; when risk is low, the greedy rule may be more efficient.

Implications and Outlook

The PB-GT study provides important insights for robust reinforcement learning:

  1. Robustness mainly comes from test-time decisions: Rather than introducing complex worst-case targets during training, adopting a pessimistic rule at test time may be simpler and more effective.
  2. Data collection strategy and learning target can be decoupled: PB-GT demonstrates that separating behavior and target is feasible, offering new ideas for future research.
  3. Computational overhead requires trade-offs: The computational cost of the worst-case rule cannot be ignored, and practical deployment should flexibly choose based on risk scenarios.

Future work could explore how to adaptively adjust test-time rules to strike a balance between robustness and efficiency.

Conclusion

Adversarial state perturbations are a major obstacle to the deployment of reinforcement learning. By decoupling pessimistic behavior and greedy targets, PB-GT Q-learning reveals the dominant role of the test-time worst-case rule in robustness, providing an empirical basis for designing efficient defense strategies. This study reminds us that robustness comes not only from training but also from the degree of caution at decision time.

References [1] Original paper: Pessimistic-Behavior / Greedy-Target Q-Learning against Adversarial State Perturbations. (Source: rss)

#robust reinforcement learning#adversarial state perturbation#PB-GT Q-learning#worst-case rule#Bellman target#pessimistic Q-learning
Share:

Related articles