ferret documentation#

Latest PyPI version HuggingFace Spaces Demo YouTube Video arxiv preprint downloads badge

ferret is Python library for benchmarking interpretability techniques on Transformers.

Use any of the badges above to test our live demo, view a video demonstration, or explore our technical paper in detail.


We are in the process of restructuring and enriching the documentation. As such, you might find WIP pages or missing docstrings. We are sorry for the inconvenience.


To install our latest stable release, run this command in your terminal:

pip install -U ferret-xai

This is the preferred method to install ferret, as it will always install the most recent stable release.

If you don’t have pip installed, this Python installation guide can guide you through the process.


If you are using ferret for your work, please consider citing us!

    title = "ferret: a Framework for Benchmarking Explainers on Transformers",
    author = "Attanasio, Giuseppe and Pastor, Eliana and Di Bonaventura, Chiara and Nozza, Debora",
    booktitle = "Proceedings of the 17th Conference of the European Chapter of the Association for Computational Linguistics: System Demonstrations",
    month = may,
    year = "2023",
    publisher = "Association for Computational Linguistics",