dattri-LLM: A Unified and Efficient Library for Training Data Attribution at LLM Scale
$\texttt{dattri-LLM}$ is a training data attribution library that targets LLM-scale per-example gradients through a unified gradient interface. For supported layers it offers exact factorized and materialized gradient representations, using a FLOP-aware cost model to choose between them per layer and operation; an open-loop interface captures gradients via autograd hooks during existing backward passes, integrates with unmodified DDP/FSDP pipelines, and caches them for reuse. An attributor interface over a uniform gradient stream supports new methods, and training-state callbacks enable in-training applications. Across evaluated methods and projection regimes it achieves $1.4$-$3.1\times$ speedups, with token-level attribution and online data selection shown as uses.