mlsanityData to 14 Oct 2026

TDHook: A Lightweight Framework for Interpretability

arXiv 2509.25475 ↗First posted 29 Sep 2025cs.AI cs.LGcited by 0

On the map: Deep reinforcement learning methods → Interpretable and logic-guided RL

Abstract (arXiv)

Interpretability of Deep Neural Networks (DNNs) is a growing field driven by the study of vision and language models. Yet, some use cases, like image captioning, or domains like Deep Reinforcement Learning (DRL), require complex modelling, with multiple inputs and outputs or use composable and separated networks. As a consequence, they rarely fit natively into the API of popular interpretability frameworks. We thus present TDHook, an open-source, lightweight, generic interpretability framework based on texttttensordict and applicable to any texttttorch model. It focuses on handling complex composed models which can be trained for Computer Vision, Natural Language Processing, Reinforcement Learning or any other domain. This library features ready-to-use methods for attribution, probing and a flexible get-set API for interventions, and is aiming to bridge the gap between these method classes to make modern interpretability pipelines more accessible. TDHook is designed with minimal dependencies, requiring roughly half as much disk space as texttttransformerlens, and, in our controlled benchmark, achieves up to a ×2 speed-up over textttcaptum when running integrated gradients for multi-target pipelines on both CPU and GPU. In addition, to value our work, we showcase concrete use cases of our library with composed interpretability pipelines in Computer Vision (CV) and Natural Language Processing (NLP), as well as with complex models in DRL.

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Placed in Interpretable and logic-guided RL, one of 15 directions in Deep reinforcement learning methods. Builds on 50 of its 74 references that are in the map. First posted on arXiv 29 Sep 2025.

Builds on

50 of 74 references.

References · 50

  1. 2017Attention Is All You Needcited by 60,361
  2. 2015Deep Residual Learning for Image Recognitioncited by 52,096
  3. 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,744
  4. 2014Very Deep Convolutional Networks for Large-Scale Image Recognitioncited by 15,364
  5. 2017Proximal Policy Optimization Algorithmscited by 15,215
  6. 2016Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localizationcited by 6,733
  7. 2017Squeeze-and-Excitation Networkscited by 4,789
  8. 2022Flamingo: a Visual Language Model for Few-Shot Learningcited by 4,386
  9. 2017Axiomatic Attribution for Deep Networkscited by 3,384
  10. 2022Locating and Editing Factual Associations in GPTcited by 2,691
  11. 2013Deep Inside Convolutional Networks: Visualising Image Classification Models and Saliency Mapscited by 2,371
  12. 2013Visualizing and Understanding Convolutional Networkscited by 2,290
38 more
  1. 2013Describing Textures in the Wildcited by 2,125
  2. 2023Sparse Autoencoders Find Highly Interpretable Features in Language Modelscited by 1,420
  3. 2016Understanding intermediate layers using linear classifier probescited by 1,353
  4. 2023Representation Engineering: A Top-Down Approach to AI Transparencycited by 1,336
  5. 2017Interpretability Beyond Feature Attribution: Quantitative Testing with Concept Activation Vectors (TCAV)cited by 1,319
  6. 2022Editing Models with Task Arithmeticcited by 1,120
  7. 2023Steering Llama 2 via Contrastive Activation Additioncited by 1,085
  8. 2014Striving for Simplicity: The All Convolutional Netcited by 990
  9. 2020Quantifying Attention Flow in Transformerscited by 775
  10. 2019Attention is not not Explanationcited by 636
  11. 2020Captum: A unified and generic model interpretability library for PyTorchcited by 547
  12. 2019Unmasking Clever Hans Predictors and Assessing What Machines Really Learncited by 365
  13. 2023In-Context Learning Creates Task Vectorscited by 312
  14. 2016Not Just a Black Box: Learning Important Features Through Propagating Activation Differencescited by 297
  15. 2015Explaining NonLinear Classification Decisions with Deep Taylor Decompositioncited by 250
  16. 2024Patchscopes: A Unifying Framework for Inspecting Hidden Representations of Language Modelscited by 235
  17. 2020Concept Whitening for Interpretable Image Recognitioncited by 225
  18. 2020Explaining by Removing: A Unified Framework for Model Explanationcited by 218
  19. 2024Transcoders Find Interpretable LLM Feature Circuitscited by 200
  20. 2022Quantus: An Explainable AI Toolkit for Responsible Evaluation of Neural Network Explanations and Beyondcited by 171
  21. 2022From Attribution Maps to Human-Understandable Explanations through Concept Relevance Propagationcited by 141
  22. 2024AttnLRP: Attention-Aware Layer-Wise Relevance Propagation for Transformerscited by 120
  23. 2024AtP*: An efficient and scalable method for localizing LLM behaviour to componentscited by 111
  24. 2015Visualizing Deep Convolutional Neural Networks Using Natural Pre-Imagescited by 93
  25. 2019Pruning by Explaining: A Novel Criterion for Deep Neural Network Pruningcited by 89
  26. 2020Aligning Superhuman AI with Human Behavior: Chess as a Model Systemcited by 79
  27. 2023Inseq: An Interpretability Toolkit for Sequence Generation Modelscited by 78
  28. 2023TorchRL: A data-driven decision-making library for PyTorchcited by 60
  29. 2021Software for Dataset-wide XAI: From Local Explanations to Global Insights with Zennit, CoRelAy, and ViRelAycited by 55
  30. 2024pyvene: A Library for Understanding and Improving PyTorch Models via Interventionscited by 54
  31. 2024NNsight and NDIF: Democratizing Access to Open-Weight Foundation Model Internalscited by 45
  32. 2024Dissecting Language Models: Machine Unlearning via Selective Pruningcited by 42
  33. 2022Navigating Neural Space: Revisiting Concept Activation Vectors to Overcome Directional Divergencecited by 25
  34. 2023Understanding the (Extra-)Ordinary: Validating Deep Model Decisions with Prototypical Concept-based Explanationscited by 22
  35. 2023From Hope to Safety: Unlearning Biases of Deep Models via Gradient Penalization in Latent Spacecited by 20
  36. 2025RelP: Faithful and Efficient Circuit Discovery in Language Models via Relevance Patchingcited by 13
  37. 2025Fin-PRM: A Domain-Specialized Process Reward Model for Financial Reasoning in Large Language Modelscited by 7
  38. 2021Learning Domain Invariant Representations by Joint Wasserstein Distance Minimizationcited by 6

Built on by

Not cited yet.

Similar, not cited

Close in wording, no citation either way

  1. 2024A Multimodal Automated Interpretability Agent
  2. 2026From Weights to Concepts: Data-Free Interpretability of CLIP via Singular Vector Decomposition
  3. 2026Sparse but not Simpler: A Multi-Level Interpretability Analysis of Vision Transformers
  4. 2024LVLM-Interpret: An Interpretability Tool for Large Vision-Language Models
  5. 2025Towards Automated Semantic Interpretability in Reinforcement Learning via Vision-Language Models
  6. 2026The Standard Interpretable Model: A general theory of interpretable machine learning to deductively design interpretable methods using Lagrangian mechanics
  7. 2024Decompose the model: Mechanistic interpretability in image models with Generalized Integrated Gradients (GIG)
  8. 2025A Comprehensive Survey on Self-Interpretable Neural Networks