paper-with-me

홈 › Papers

TokenSHAP: Interpreting Large Language Models with Monte Carlo Shapley Value Estimation

2024-07-14 · Roni Goldshmidt, Miriam Horovicz

As large language models (LLMs) become increasingly prevalent in critical applications, the need for interpretable AI has grown. We introduce TokenSHAP, a novel method for interpreting LLMs by attributing importance to individual tokens or substrings within input prompts. This approach adapts Shapley values from cooperative game theory to natural language processing, offering a rigorous framework for understanding how different parts of an input contribute to a model's response. TokenSHAP leverages Monte Carlo sampling for computational efficiency, providing interpretable, quantitative measures of token importance. We demonstrate its efficacy across diverse prompts and LLM architectures, showing consistent improvements over existing baselines in alignment with human judgments, faithfulness to model behavior, and consistency. Our method's ability to capture nuanced interactions between tokens provides valuable insights into LLM behavior, enhancing model transparency, improving prompt engineering, and aiding in the development of more reliable AI systems. TokenSHAP represents a significant step towards the necessary interpretability for responsible AI deployment, contributing to the broader goal of creating more transparent, accountable, and trustworthy AI systems.

📄 PDF Abstract BibTeX arXiv:2407.10114

Code (1)

ronigold/TokenSHAP 공식 구현 pytorch

Tasks

Computational EfficiencyPrompt Engineering

Similar Papers 제목 키워드 기반

AgentSHAP: Interpreting LLM Agent Tool Importance with Monte Carlo Shapley Value Estimation

2025-12-14 · Miriam Horovicz arxiv

LLM agents that use external tools can solve complex tasks, but understanding which tools actually contributed to a response remains a blind spot. No existing XAI methods address tool-level explanations. We introduce Age…

Toward Template-Free Explainability for Monte Carlo Tree Search

2026-05-15 · Siqi Lu, Mirsaleh Bahavarnia, Hiba Baroud, Yixuan Zhang 외 arxiv

Probabilistic search algorithms, such as Monte Carlo Tree Search (MCTS), have proven very effective in solving sequential decision-making tasks under uncertainty. However, interpreting asymmetric search trees that incorp…

Formal Logic

Monte Carlo Action Programming

2017-02-25 · Lenz Belzner

This paper proposes Monte Carlo Action Programming, a programming language framework for autonomous systems that act in large probabilistic state spaces with high branching factors. It comprises formal syntax and semanti…

Monte Carlo Tree Search for Interpreting Stress in Natural Language

2022-04-17 · LTEDI (ACL) 2022 5 · Kyle Swanson, Joy Hsu, Mirac Suzgun

Natural language processing can facilitate the analysis of a person's mental state from text they have written. Previous studies have developed models that can predict whether a person is experiencing a mental health con…

Is Monte Carlo Tree Search Just Every-Visit Monte Carlo Control?

2026-08-28 · Xianyi Wu arxiv

Monte Carlo Tree Search (MCTS) and every-visit Monte Carlo (MC) control are usually presented as different methods. MCTS is described in the language of search (selection, expansion, simulation, and backup), whereas MC c…

Reinforcement Learning