{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,2,5]],"date-time":"2026-02-05T13:12:35Z","timestamp":1770297155212,"version":"3.49.0"},"reference-count":44,"publisher":"Association for Computing Machinery (ACM)","issue":"FSE","license":[{"start":{"date-parts":[[2024,7,12]],"date-time":"2024-07-12T00:00:00Z","timestamp":1720742400000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by\/4.0\/"}],"content-domain":{"domain":[],"crossmark-restriction":false},"short-container-title":["Proc. ACM Softw. Eng."],"published-print":{"date-parts":[[2024,7,12]]},"abstract":"<jats:p>Deep reinforcement learning (DRL) has proven extremely useful in a large variety of application domains. However, even successful DRL-based software can exhibit highly undesirable behavior. This is due to DRL training being based on maximizing a reward function, which typically captures general trends but cannot precisely capture, or rule out, certain behaviors of the model. In this paper, we propose a novel framework aimed at drastically reducing the undesirable behavior of DRL-based software, while maintaining its excellent performance. In addition, our framework can assist in providing engineers with a comprehensible characterization of such undesirable behavior. Under the hood, our approach is based on extracting decision tree classifiers from erroneous state-action pairs, and then integrating these trees into the DRL training loop, penalizing the model whenever it performs an error. We provide a proof-of-concept implementation of our approach, and use it to evaluate the technique on three significant case studies. We find that our approach can extend existing frameworks in a straightforward manner, and incurs only a slight overhead in training time. Further, it incurs only a very slight hit to performance, or even in some cases \u2014 improves it, while significantly reducing the frequency of undesirable behavior.<\/jats:p>","DOI":"10.1145\/3660775","type":"journal-article","created":{"date-parts":[[2024,7,12]],"date-time":"2024-07-12T10:22:09Z","timestamp":1720779729000},"page":"1518-1539","source":"Crossref","is-referenced-by-count":1,"title":["On Reducing Undesirable Behavior in Deep-Reinforcement-Learning-Based Software"],"prefix":"10.1145","volume":"1","author":[{"ORCID":"https:\/\/orcid.org\/0009-0002-5147-0806","authenticated-orcid":false,"given":"Ophir M.","family":"Carmel","sequence":"first","affiliation":[{"name":"Hebrew University of Jerusalem, Jerusalem, Israel"}],"role":[{"role":"author","vocabulary":"crossref"}]},{"ORCID":"https:\/\/orcid.org\/0000-0001-5292-801X","authenticated-orcid":false,"given":"Guy","family":"Katz","sequence":"additional","affiliation":[{"name":"Hebrew University of Jerusalem, Jerusalem, Israel"}],"role":[{"role":"author","vocabulary":"crossref"}]}],"member":"320","published-online":{"date-parts":[[2024,7,12]]},"reference":[{"key":"e_1_3_1_2_1","unstructured":"D. Amodei C. Olah J. Steinhardt P. Christiano J. Schulman and D. Man\u00e9. 2016. Concrete Problems in AI Safety. Technical Report. https:\/\/arxiv.org\/abs\/1606.06565."},{"key":"e_1_3_1_3_1","doi-asserted-by":"publisher","DOI":"10.1109\/MSP.2017.2743240"},{"key":"e_1_3_1_4_1","unstructured":"O. Bastani Y. Pu and A. Solar-Lezama. 2018. Verifiable Reinforcement Learning via Policy Extraction. In Proc. 32nd Conf. on Neural Information Processing Systems (NeurIPS)."},{"key":"e_1_3_1_5_1","unstructured":"S. Bhatt. 2019. Reinforcement Learning 101. https:\/\/towardsdatascience.com\/reinforcement-learning-101-e24b50e1d292"},{"key":"e_1_3_1_6_1","doi-asserted-by":"crossref","unstructured":"M. Cai M. Mann Z. Serlin K. Leahy and C.-I. Vasile. 2023. Learning Minimally-Violating Continuous Control for Infeasible Linear Temporal Logic Specifications. Technical Report. https:\/\/arxiv.org\/abs\/2210.01162.","DOI":"10.23919\/ACC55779.2023.10156544"},{"key":"e_1_3_1_7_1","doi-asserted-by":"crossref","unstructured":"O. M. Carmel and G. Katz. 2024. On Reducing Undesirable Behavior in Deep-Reinforcement-Learning-Based Software: Code and Benchmarks. https:\/\/github.com\/ophircarmel\/Reducing-Undesirable-Behaviour","DOI":"10.1145\/3660775"},{"key":"e_1_3_1_8_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-319-10575-8"},{"key":"e_1_3_1_9_1","unstructured":"G. Dalal K. Dvijotham M. Vecerik T. Hester C. Paduraru and Y. Tassa. 2018. Safe Exploration in Continuous Action Spaces. Technical Report. https:\/\/arxiv.org\/abs\/1801.08757."},{"key":"e_1_3_1_10_1","doi-asserted-by":"crossref","unstructured":"T. Eliyahu Y. Kazak G. Katz and M. Schapira. 2021. Verifying Learning-Augmented Systems. In Proc. Conf. of the ACM Special Interest Group on Data Communication on the Applications Technologies Architectures and Protocols for Computer Communication (SIGCOMM). 305\u2013318.","DOI":"10.1145\/3452296.3472936"},{"key":"e_1_3_1_11_1","unstructured":"G. Gu L. Yang Y. Du G. Chen F. Walter J. Wang Y. Yang and A. Knoll. 2023. A Review of Safe Reinforcement Learning: Methods Theory and Applications. Technical Report. https:\/\/arxiv.org\/abs\/2205.10330."},{"key":"e_1_3_1_12_1","unstructured":"H. Harder. 2022. Snake Played by a Deep Reinforcement Learning Agent. https:\/\/towardsdatascience.com\/snake-played-by-a-deep-reinforcement-learning-agent-53f2c4331d36"},{"key":"e_1_3_1_13_1","unstructured":"Y. Hu W. Wang H. Jia Y. Wang Y. Chen J. Hao F. Wu and C. Fan. 2020. Learning to Utilize Shaping Rewards: A New Approach of Reward Shaping. Technical Report. https:\/\/arxiv.org\/abs\/2011.02669."},{"key":"e_1_3_1_14_1","unstructured":"N. Jay N. Rotman B. Godfrey M. Schapira and A. Tamar. 2019. A Deep Reinforcement Learning Perspective on Internet Congestion Control. In Proc. Int. Conf. on Machine Learning (ICML). 3050\u20133059."},{"key":"e_1_3_1_15_1","doi-asserted-by":"crossref","unstructured":"B. Johnson Y. Brun and A. Meliou. 2020. Causal Testing: Understanding Defects\u2019 Root Causes. In Proc. 42nd Int. Conf. on Software Engineering (ICSE). 87\u201399.","DOI":"10.1145\/3377811.3380377"},{"key":"e_1_3_1_16_1","doi-asserted-by":"crossref","unstructured":"D. Karger S. Oh and D. Shah. 2013. Efficient Crowdsourcing for Multi-Class Labeling. In Proc. ACM Int. Conf. on Measurement and Modeling of Computer Systems (SIGMETRICS). 81\u201392.","DOI":"10.1145\/2465529.2465761"},{"key":"e_1_3_1_17_1","doi-asserted-by":"crossref","unstructured":"G. Katz C. Barrett D. Dill K. Julian and M. Kochenderfer. 2017. Reluplex: An Efficient SMT Solver for Verifying Deep Neural Networks. In Proc. 29th Int. Conf. on Computer Aided Verification (CAV). 97\u2013117.","DOI":"10.1007\/978-3-319-63387-9_5"},{"key":"e_1_3_1_18_1","doi-asserted-by":"crossref","unstructured":"Y. Kazak C. Barrett G. Katz and M. Schapira. 2019. Verifying Deep-RL-Driven Systems. In Proc. 1st ACM SIGCOMM Workshop on Network Meets AI & ML (NetAI). 83\u201389.","DOI":"10.1145\/3341216.3342218"},{"issue":"9","key":"e_1_3_1_19_1","doi-asserted-by":"crossref","first-page":"1011","DOI":"10.1038\/nbt0908-1011","article-title":"What are Decision Trees?","volume":"26","author":"Kingsford C.","year":"2008","unstructured":"C. Kingsford and S. Salzberg. 2008. What are Decision Trees? Nature Biotechnology 26, 9 (2008), 1011\u20131013.","journal-title":"Nature Biotechnology"},{"key":"e_1_3_1_20_1","doi-asserted-by":"crossref","unstructured":"G. Lample and D. Chaplot. 2017. Playing FPS Games with Deep Reinforcement Learning. In Proc. 31st AAAI Conf. on Artificial Intelligence (AAAI).","DOI":"10.1609\/aaai.v31i1.10827"},{"key":"e_1_3_1_21_1","doi-asserted-by":"publisher","DOI":"10.1038\/nature14539"},{"key":"e_1_3_1_22_1","doi-asserted-by":"crossref","unstructured":"M. Leszak D. Perry and D. Stoll. 2000. A Case Study in Root Cause Defect Analysis. In Proc. 22nd Int. Conf. on Software Engineering (ICSE). 428\u2013437.","DOI":"10.1145\/337180.337232"},{"key":"e_1_3_1_23_1","unstructured":"Y. Li. 2017. Deep Reinforcement Learning: An Overview. (2017). Technical Report. https:\/\/arxiv.org\/abs\/1701.07274."},{"key":"e_1_3_1_24_1","volume-title":"Supervised Learning","author":"Liu Q.","year":"2012","unstructured":"Q. Liu and Y. Wu. 2012. Supervised Learning. Springer."},{"key":"e_1_3_1_25_1","doi-asserted-by":"crossref","unstructured":"E. Marchesini and A. Farinelli. 2020. Discrete Deep Reinforcement Learning for Mapless Navigation. In Proc. IEEE Int. Conf. on Robotics and Automation (ICRA). 10688\u201310694.","DOI":"10.1109\/ICRA40945.2020.9196739"},{"key":"e_1_3_1_26_1","doi-asserted-by":"crossref","unstructured":"V. Mnih K. Kavukcuoglu D. Silver A. Rusu J. Veness M. Bellemare A. Graves M. Riedmiller A. Fidjeland G. Ostrovski and et al. 2015. Human-Level Control through Deep Reinforcement Learning. 529\u2013533 pages.","DOI":"10.1038\/nature14236"},{"key":"e_1_3_1_27_1","doi-asserted-by":"crossref","unstructured":"S. Mousavi M. Schukat and E. Howley. 2018. Deep Reinforcement Learning: An Overview. In Proc. SAI Intelligent Systems Conf. (IntelliSys). 426\u2013440.","DOI":"10.1007\/978-3-319-56991-8_32"},{"key":"e_1_3_1_28_1","unstructured":"A. Ng D. Harada and S. Russell. 1999. Policy Invariance under Reward Transformations: Theory and Application to Reward Shaping. In Proc. Int. Conf. on Machine Learning (ICML). 278\u2013287."},{"key":"e_1_3_1_29_1","doi-asserted-by":"crossref","unstructured":"P. Palanisamy. 2020. Multi-Agent Connected Autonomous Driving using Deep Reinforcement Learning. In Proc. Int. Joint Conf. on Neural Networks (IJCNN). 1\u20137.","DOI":"10.1109\/IJCNN48605.2020.9207663"},{"key":"e_1_3_1_30_1","doi-asserted-by":"publisher","DOI":"10.5555\/1953048.2078195"},{"key":"e_1_3_1_31_1","doi-asserted-by":"publisher","DOI":"10.1109\/21.97458"},{"key":"e_1_3_1_32_1","unstructured":"J. Schulman F. Wolski P. Dhariwal A. Radford and O. Klimov. 2017. Proximal Policy Optimization Algorithms. Technical Report. http:\/\/arxiv.org\/abs\/1707.06347."},{"key":"e_1_3_1_33_1","doi-asserted-by":"crossref","unstructured":"V. Sheng and J. Zhang. 2019. Machine Learning with Crowdsourcing: A Brief Summary of the Past Research and Future Directions. In Proc. 33rd AAAI Conf. on Artificial Intelligence (AAAI).","DOI":"10.1609\/aaai.v33i01.33019837"},{"key":"e_1_3_1_34_1","doi-asserted-by":"crossref","unstructured":"D. Silver A. Huang C. Maddison A. Guez L. Sifre G. Van Den Driessche J. Schrittwieser I. Antonoglou V. Panneershelvam M. Lanctot and S. Dieleman. 2016. Mastering the Game of Go with Deep Neural Networks and Tree Search. Nature 529 7587 (2016) 484\u2013489.","DOI":"10.1038\/nature16961"},{"key":"e_1_3_1_35_1","doi-asserted-by":"publisher","DOI":"10.1109\/TNN.1998.712192"},{"key":"e_1_3_1_36_1","volume-title":"Reinforcement Learning: An Introduction","author":"Sutton R.","year":"2018","unstructured":"R. Sutton and A. Barto. 2018. Reinforcement Learning: An Introduction. MIT press."},{"key":"e_1_3_1_37_1","unstructured":"C. Tessler D. Mankowitz and S. Mannor. 2018. Reward Constrained Policy Optimization. Technical Report. https:\/\/arxiv.org\/abs\/1805.11074."},{"key":"e_1_3_1_38_1","doi-asserted-by":"crossref","unstructured":"P. Thomas B. Castro da Silva A. Barto S. Giguere Y. Brun and E. Brunskill. 2019. Preventing Undesirable Behavior of Intelligent Machines. Science 366 6468 (2019) 999\u20131004.","DOI":"10.1126\/science.aag3311"},{"key":"e_1_3_1_39_1","doi-asserted-by":"crossref","unstructured":"H. Van Hasselt A. Guez and D. Silver. 2016. Deep Reinforcement Learning with Double Q-Learning. In Proc. 30th AAAI Conf. on Artificial Intelligence (AAAI).","DOI":"10.1609\/aaai.v30i1.10295"},{"key":"e_1_3_1_40_1","unstructured":"A. Vidali. 2019. Deep Q-Learning Agent for Traffic Signal Control. https:\/\/github.com\/AndreaVidali\/Deep-QLearning-Agent-for-Traffic-Signal-Control"},{"key":"e_1_3_1_41_1","doi-asserted-by":"crossref","unstructured":"H.-N. Wang N. Liu Y.-Y. Zhang D.-W. Feng F. Huang D.-S. Li and Y.-M. Zhang. 2020. Deep Reinforcement Learning: A Survey journal=Frontiers of Information Technology & Electronic Engineering. 1726\u20131744 pages.","DOI":"10.1631\/FITEE.1900533"},{"key":"e_1_3_1_42_1","first-page":"863","volume-title":"Reward Shaping","author":"Wiewiora E.","year":"2010","unstructured":"E. Wiewiora. 2010. Reward Shaping. Springer, 863\u2013865."},{"key":"e_1_3_1_43_1","unstructured":"E. Wiewiora G. Cottrell and C. Elkan. 2003. Principled Methods for Advising Reinforcement Learning Agents. In Proc. 20th Int. Conf. on Machine Learning (ICML). 792\u2013799."},{"key":"e_1_3_1_44_1","unstructured":"D. Ye G. Chen W. Zhang S. Chen B. Yuan B. Liu J. Chen and et al. 2020. Towards Playing Full MOBA Games with Deep Reinforcement Learning. Technical Report. https:\/\/arxiv.org\/abs\/2011.12692."},{"key":"e_1_3_1_45_1","unstructured":"H. Zhang and Y. Guo. 2022. Safe Reinforcement Learning with Contrastive Risk Prediction. Technical Report. https:\/\/arxiv.org\/abs\/2209.09648."}],"container-title":["Proceedings of the ACM on Software Engineering"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3660775","content-type":"unspecified","content-version":"vor","intended-application":"text-mining"},{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3660775","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,2,4]],"date-time":"2026-02-04T08:03:58Z","timestamp":1770192238000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3660775"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2024,7,12]]},"references-count":44,"journal-issue":{"issue":"FSE","published-print":{"date-parts":[[2024,7,12]]}},"alternative-id":["10.1145\/3660775"],"URL":"https:\/\/doi.org\/10.1145\/3660775","relation":{},"ISSN":["2994-970X"],"issn-type":[{"value":"2994-970X","type":"electronic"}],"subject":[],"published":{"date-parts":[[2024,7,12]]}}}