将强化学习黑箱策略转为可读可执行的逻辑程序,实现行为可解释与优化。
From Black Box to Executable Logic: Explainable Reinforcement Learning through Prolog Expert Systems
- 通过三阶段转换,将深度强化学习策略转为可运行的Prolog规则列表。
- 在16,944状态任务中复现最优回报,连续控制任务中达97%以上性能。
- 提供可验证的决策解释,适合需要透明决策的高风险场景。
训练好的深度强化学习策略是黑箱,我们探讨能否将其重写为可读、可执行、可编辑的逻辑程序以实现可解释性。本文提出三阶段后处理转换:提取冻结的近端策略优化教师模型,基于经典关系学习方法生成有序规则列表,并输出为由现成逻辑引擎执行的Prolog程序;后续扩展阶段迭代修改规则库,仅当策略评估显示回报提升时才接受更新。我们证明四项保证:回报损失有界,使提炼程序成为有限马尔可夫决策过程中的机器可验证证书;扩展循环单调递增并终止。对于连续观测情形,我们回答转换是否可能:命题阈值实例化可在分辨率B增大时达到任意精度,分歧为O(1/B),回报差距以相同速率收敛;匹配下界表明,对斜向决策边界,成本随观测维度指数增长。实验表明,在包含16,944可达状态的两室钥匙门任务中,扩展后的Prolog程序在所有种子下达到精确最优回报;在预算受限条件下,十次试验中有十次超越随机教师的精确回报。在三个连续控制任务中,生成程序可替代网络:在Acrobot上用11条规则匹配神经教师表现,于CartPole恢复约97%回报;而在更精细的LunarLander任务中仅部分恢复,恰好符合指数下界预测的上限。
原文摘要 · Abstract (English)
A trained deep reinforcement learning policy is a black box, and we ask whether it can be made explainable by rewriting it as an executable logic program that reproduces its behaviour and that a person can read, a logic engine can run, and an optimizer can edit. We present a three-stage post-hoc transformation that extracts a frozen proximal policy optimization teacher, induces an ordered rule list from its decisions in the manner of classical relational learning, and emits the result as a Prolog program whose every decision is executed by an off-the-shelf logic engine; a subsequent expansion stage edits the rule base and accepts an edit only when policy evaluation certifies a return increase. We prove four guarantees. A return-loss bound makes the distilled program a machine-checkable certificate in a finite Markov decision process, and the expansion loop improves monotonically and terminates. For the continuous-observation setting we answer whether the conversion is possible at all: the propositional threshold instantiation converts the network to arbitrary fidelity as the resolution B grows, with disagreement O(1/B) and a return gap that closes at the same rate, and a matching lower bound shows the cost is exponential in the observation dimension for an oblique decision boundary. Empirically, on a two-room key-and-door task with 16,944 reachable states the expanded Prolog program attains exact optimal return in every seed and, in a budget-capped regime, exceeds the stochastic teacher on exact return in ten of ten seeds. On three continuous-control tasks the emitted program substitutes the network, matching the neural teacher within noise on Acrobot with eleven clauses and recovering about 97% of its return on CartPole, while on the finer-control LunarLander it recovers only partially, exactly the ceiling the exponential lower bound predicts.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。