Discover and explore top open-source AI tools and projects—updated daily.
rachtibatExplainable AI for Transformers
Top 99.9% on SourcePulse
Summary
LXT (Layer-wise Relevance Propagation for Transformers) accelerates Explainable AI (XAI) research for Large Language Models (LLMs) and Vision Transformers (ViTs). It provides fast, faithful input attributions by revealing how each token and neuron contributes to model predictions, overcoming the noise and unreliability of traditional gradient-based methods. This enables deeper understanding and debugging of complex transformer architectures for researchers and power users.
How It Works
LXT employs AttnLRP, an attention-aware backpropagation technique that corrects gradient flow through non-linearities, ensuring accurate relevance scores. This method requires only a single backward pass, offering significant efficiency gains. It outperforms existing gradient, decomposition, and perturbation-based XAI methods, scaling computationally with $O(1)$ complexity and $O(\sqrt{N})$ memory relative to model depth. Beyond input attributions, LXT facilitates latent feature attribution and visualization by analyzing individual neuron importance, allowing for deeper model introspection.
Quick Start & Requirements
pip install lxttransformers==5.9.0, torch==2.12.0, python==3.11.examples/* directory.Highlighted Details
Maintenance & Community
Contributions are encouraged. The project is associated with ICML 2024. No specific community channels (e.g., Discord, Slack) or roadmap links are provided in the README.
Licensing & Compatibility
Limitations & Caveats
1 month ago
1 week
SakanaAI
zou-group
SafeAILab
karpathy