Going Beyond Heuristics by Imposing Policy Improvement as a Constraint

In many reinforcement learning (RL) applications, augmenting the task rewards with heuristic rewards that encode human priors about how a task should be solved is crucial for achieving desirable performance. However, because such heuristics are usually not optimal, much human effort and computational resources are wasted in carefully balancing tasks and heuristic rewards. Theoretically rigorous ways of incorporating heuristics rely on the idea of \textit{policy invariance}, which guarantees that the performance of a policy obtained by maximizing heuristic rewards is the same as the optimal policy with respect to the task reward. However, in practice, policy invariance doesn't result in policy improvement, and such methods are known to empirically perform poorly. We propose a new paradigm to mitigate reward hacking and effectively use heuristics based on the practical goal of maximizing policy improvement instead of policy improvement. Our framework, Heuristic Enhanced Policy Optimization (HEPO), effectively leverages heuristics while avoiding the pitfall of prior methods for mitigating reward hacking. HEPO achieves superior performance on standard benchmarks with well-engineered reward functions. More surprisingly, HEPO allows policy optimization to achieve good performance even when heuristics are not well-engineered and designed by non-expert humans, showcasing HEPO's ability to reduce human effort in reward design. % HEPO is a plug-and-play optimization method for leveraging heuristics in reinforcement learning. Code is available at https://github.com/Improbable-AI/hepo.

Paper

Similar papers

Peer review

Reviewer P4zd7/10 · confidence 4/52024-07-05

Summary

In this paper, the authors address the problem of reward design in reinforcement learning. Specifically, it is common practice to add heuristics in the reward to help the training and a lot of manual engineering is needed to balance this heuristic and the main reward. They propose to modify the standard RL objective to a constrained optimization objective in order to incorporate heuristics in the reward function in a principled way. Their formulation consists in optimizing both the task reward and the heuristic reward while constraining the policy to have a better performance in the task reward compared to a policy that is solely maximizing the heuristic reward. This constraint ensures that the policy is not only exploiting the heuristic but also solves the task. The method is evaluated on a set of robotic control tasks where heuristics are already provided. I acknowledge reading the authors rebuttal and updated my score.

Strengths

They propose a simple formalization of the problem of reward design with adding heuristic to a main reward task. This does not address the general problem of reward alignment, but I think it is a very relevant problem in RL for domains with well defined but sparse rewards. The derivation of the algorithm is presented clearly. The experiments show that the proposed algorithm outperform the baseline in terms of average return. Except from the missing EIPO, the authors choose relevant baseline to compare against. The second experiment of reward designed in the wild is interesting. The author attempt to recreate the process of reward design with human participants. The statistical analysis of the experimental results is rigorous. The ablation study shows the importance of using the policy trained on the heuristic reward as a reference.

Weaknesses

The data collection part of the algorithm is not super clear. My understanding is that both policies are used and they collect the same amount of trajectories for each, why would the amount of data be the same and not more? The theoretical implications of this data sharing part should be clarified as well. It is not obvious to me that equation 7 and 8 actually lead to the correct policy improvement step. No theoretical analysis of the algorithm is provided. I am not sure that detailed theorem and proofs would be needed but at least some insights or discussion about the convergence. There is a brief mention that it would not converge to the optimal policy in the limitations but no proof is given. Why not include EIPO in the first experiment? Overall, there is no direct comparison with EIPO. The authors comment on certain aspects during the ablation study but it would have been even stronger to add a line for EIPO. In the second experiment some results appear to be missing which makes me question the validity of table 1 as well. I hope the author can clarify this in the rebuttal. One experiment that is missing and could have been interesting is to study the performance of the algorithm depending on the quality of the heuristic. I suggest merging the related work section and section 3.3.

Questions

- Why doesn’t the algorithm need more data since you need to collect data with both policies? - Equation (7) and (8) introduce an off-policy aspect to the algorithm, is convergence still guaranteed? - Why use J_random in the formula to measure performance? Why not use a percentage of improvement over $J_{H-only}$? - What happened with H4-9-10-12 in figure 2? - On the same problem with different heuristic, how would the performance of HEPO look like depending on the asymptotic performance of $\pi_H$

Rating

7

Confidence

4

Soundness

4

Presentation

4

Contribution

3

Limitations

The current algorithm seems limited to on policy methods. It also applies to problems where we can make a clear distinction between task reward and heuristic rewards.

Reviewer 15cn7/10 · confidence 3/52024-07-09

Summary

This paper introduces a constrained optimization approach for reinforcement learning, ensuring that the learned policy outperforms or matches the performance of policies trained solely with heuristic rewards. In simulations, the proposed HEPO method consistently delivers superior task performance across various tasks, demonstrating improved returns in robotic locomotion, helicopter, and manipulation tasks.

Strengths

This paper is straightforward and easy to follow, with a clearly stated motivation. It introduces an innovative constrained optimization approach that effectively leverages heuristic signals to enhance task performance in reinforcement learning. The effectiveness of the HEPO method is demonstrated through its consistent superiority across diverse tasks such as robotic locomotion, helicopter control, and manipulation, even with limited training data. Additionally, the proposed method simplifies the reward design process by dynamically balancing heuristic and task rewards without the need for manual tuning, showing significant improvements over traditional heuristic-only and mixed reward approaches.

Weaknesses

The paper would benefit from a more thorough theoretical analysis. Including a theoretical guarantee on the convergence rate, an examination of how the selection of heuristics impacts the HEPO method, and an analysis of the effect of the alpha parameter would enhance the robustness and depth of the study.

Questions

Could you please explain how the heuristic is obtained in the implementation? Additionally, it would be helpful to see the computational cost of solving the constrained optimization problem. Is it possible to include a comparison of your method with reward shaping and policy cloning methods? For equation 5, when rearranging equation 4, could you clarify where the term J(pi_H) goes?

Rating

7

Confidence

3

Soundness

3

Presentation

3

Contribution

3

Limitations

While the HEPO method shows empirical success, it lacks a thorough theoretical analysis, including a formal guarantee on the convergence rate and the effects of heuristic selection and the alpha parameter on performance. Additionally, the computational cost of solving the constrained optimization problem is not addressed, which could impact the feasibility of the approach in large-scale or real-time applications. Furthermore, the study does not compare HEPO with other reinforcement learning techniques such as reward shaping and policy cloning, which would provide a more comprehensive evaluation of its effectiveness.

Reviewer inih6/10 · confidence 3/52024-07-12

Summary

The paper presents a novel approach to improve reinforcement learning (RL) by incorporating heuristic signals. The authors propose a constrained optimization method that uses heuristic policies as references to ensure that the learned policies outperform heuristic policies on the exact task objective. The method, named Heuristic-Enhanced Policy Optimization (HEPO), was tested on various robotic tasks, demonstrating consistent performance improvements over standard heuristic methods.

Strengths

- The paper introduces a simple method to improve reinforcement learning (RL) algorithms using heuristic rewards, by shifting focus from ensuring optimal policy invariance to simply outperforming heuristic policies. - The method is validated on various environments, showing consistent performance improvements. - The paper is clearly written.

Weaknesses

- The claim that the contribution is an add-on to existing deep RL algorithms is not fully substantiated, as the authors only evaluate HEPO using Proximal Policy Optimization (PPO). Demonstrating HEPO's performance with other deep RL algorithms, such as Soft Actor-Critic (SAC), would help validate this claim. - The method is very similar to Extrinsic-Intrinsic Policy Optimization (EIPO), with the main difference being the reference policy used. The authors should provide more details on this difference, including the number of additional hyperparameters introduced in EIPO and a comparison of its complexity in terms of time with HEPO. - The benchmarks used in this paper differ from those in previous works like EIPO [6] and HuRL [7]. The authors should address how HEPO would perform on those benchmarks to ensure a fair comparison. - The paper does not include challenging tasks such as Montezuma's Revenge. - It is unclear whether the reward functions and heuristics used in the experiments are designed by the authors or sourced from ISAAC and BI-DEX benchmarks.

Questions

- Please check weaknesses. - How does HEPO perform with other deep RL algorithms, such as Soft Actor-Critic (SAC)? - What specific heuristics are used in the progressing tasks, and how are the rewards sparse/delayed? - In figure3: Is the T-only ablation equivalent to the EIPO algorithm or a modified version of HEPO? - Line 129 is missing a reference to the application of PPO in robotics with heuristic rewards.

Rating

6

Confidence

3

Soundness

3

Presentation

3

Contribution

2

Limitations

The authors address the limitations and potential negative impacts in their paper.

Authorsrebuttal2024-08-07

update the figure

We missed one curve in the rebuttal PDF and have updated Figure 7(a) in the following link: https://imgur.com/jzxWoq6. Note that we didn't train EIPO and HEPO for 2 billion frames since it will take around two weeks to finish.

Reviewer P4zd2024-08-08

Thank you for the detailed response and the additional experiments.

I think you answered all of my questions quite clearly. I would advise to modify the table 1 from the paper with the full results and add the plots from the rebuttal to the appendix as they are quite useful in understanding the performance of the method. I will update my score.

Reviewer 15cn2024-08-08

Thank you for the timely response

Your answers addressed my questions. I have no further comments.

Program Chairsdecision2024-09-25

Decision

Accept (poster)

© 2026 NYSGPT2525 LLC