Skip to content

v0.5.0

Latest

Choose a tag to compare

@maschulz maschulz released this 29 Aug 19:15
· 4 commits to main since this release

This release corrects several bugs in the attribution estimators. Upgrading changes numerical results — refit-based loss magnitudes halve, and some negative-class and near-parity signs change. Re-run analyses that pinned scores from an earlier version.

Breaking

  • Requires Python 3.10 or newer (3.9 reached end of life in October 2025).

Fixed

  • Loss scores use half squared error throughout, so InfluenceFunctions and the refit-based attributors (LOOInfluence, BanzhafInfluence, BootstrapInfluence) share one scale. Refit-based loss magnitudes are now half their previous values; rankings are unchanged.
  • Prediction-mode influence for classifiers without predict_proba (e.g. RidgeClassifier) uses the margin toward the true class. Negative-class scores flip sign relative to earlier versions.
  • target="absolute" and worst_group_mean are attributed by exact perturbation evaluation, correcting scores that the previous linearization mispredicted near a zero crossing or a group tie.
  • The influence(method="auto") bootstrap fallback for unsupported models is seeded and uses 200 runs, so results are reproducible.
  • fit, explain, and functional_value raise on mismatched X/y (or X_ref/y_ref) row counts instead of silently broadcasting into a wrong result.
  • InfluenceFunctions rejects positive=True (NNLS) models; method="auto" falls back to a refit method that handles them.

Added

  • py.typed, so type checkers use the package's annotations.

Documentation

  • The AUROC attribution's agreement with exact refit (r > 0.99) is a property of the package benchmark, not a general guarantee; the perturbation approximation is dataset-dependent, so validate against RefitFunctionalInfluence on your data.
  • BootstrapInfluence documents its in-bag multiplicity bias (a point appears ~1.58 times on average when present, inflating magnitudes); the ranking is the reliable output.