arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2602.21845cs.LGcs.AIcs.CY
收藏

xai-cola: 一个用于稀疏化反事实解释的Python库

xai-cola: A Python library for sparsifying counterfactual explanations

Technical University of Denmark(丹麦技术大学)

Lin Zhu, Lei You

AI总结:

xai-cola是一个开源Python库,用于稀疏化反事实解释,通过端到端流程减少冗余特征变化,提升解释效率。

摘要:

反事实解释(CE)是事后可解释性中的一个重要领域。然而,大多数CE生成器生成的解释往往高度冗余。本文介绍了一个开源的Python库xai-cola,它提供了一个端到端的流程,用于稀疏化由任意生成器产生的CE,减少冗余的特征变化同时保持其有效性。该库提供了一个文档化的API,输入为pandas DataFrame形式的原始表格数据、预处理对象(用于标准化和编码)以及训练好的scikit-learn或PyTorch模型。在此基础上,用户可以使用内置或外部导入的CE生成器。该库还实现了几种稀疏化策略,并包含可视化程序用于分析和比较稀疏化的反事实。xai-cola以MIT许可证发布,并可通过PyPI安装。实证实验表明,xai-cola在多个CE生成器上产生更稀疏的反事实,我们的设置中修改的特征数量可减少高达50%。源代码可在https://github.com/understanding-ml/COLA获取。

英文摘要:

Counterfactual explanation (CE) is an important domain within post-hoc explainability. However, the explanations generated by most CE generators are often highly redundant. This work introduces an open-source Python library xai-cola, which provides an end-to-end pipeline for sparsifying CEs produced by arbitrary generators, reducing superfluous feature changes while preserving their validity. It offers a documented API that takes as input raw tabular data in pandas DataFrame form, a preprocessing object (for standardization and encoding), and a trained scikit-learn or PyTorch model. On this basis, users can either employ the built-in or externally imported CE generators. The library also implements several sparsification policies and includes visualization routines for analysing and comparing sparsified counterfactuals. xai-cola is released under the MIT license and can be installed from PyPI. Empirical experiments indicate that xai-cola produces sparser counterfactuals across several CE generators, reducing the number of modified features by up to 50% in our setting. The source code is available at https://github.com/understanding-ml/COLA.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑