Skip to main content

FADE: Why Bad Descriptions Happen to Good Features

Project description


FADE Logo


arXiv

Logo FADE: Why Bad Descriptions Happen to Good Features

Logo FADE helps you evaluate the alignment between LLM features and their natural language descriptions across four key metrics: Clarity, Responsiveness, Purity, and Faithfulness.

🔍 Features

  • Model-agnostic evaluation of feature-to-description alignment
  • Works with standard tramsformer neurons and SAE features
  • Support for OpenAI, Azure, Ollama, vLLM, and other evaluation models

Installation

pip install fade-language

Tutorial

Check out our Tutorial Notebook that walks you through:

  • A basic evaluation setup
  • Using cached activations for improved performance
  • Working with SAE features
  • Using different evaluation models
  • Advanced configuration options

Quickstart

from fade import EvaluationPipeline

# custom evaluation-model configuration with OpenAI LLM
config = {
    'evaluationLLM': {
        'type': 'openai', # type of evaluation model
        'name': 'gpt-4o-mini-2024-07-18', # the model variant
        'api_key': 'YOUR-KEY-HERE',
    }
}

# initialize evaluation pipeline
eval_pipeline = EvaluationPipeline(
    subject_model=model,  # e.g. huggingface model
    subject_tokenizer=tokenizer,  # e.g. huggingface tokenizer
    dataset=dataset,  # dict with int keys and str values
    config=config, # the custom config
    device=device,  # torch device
)

# example neuron specification
neuron_module = 'named.module.of.the.feature'  # str of the module name
neuron_index = 42  # int of the neuron index
concept = "The feature description you want to evaluate."  # str of the feature description

# run evaluation
(clarity, responsiveness, purity, faithfulness) = eval_pipeline.run(
    neuron_module=neuron_module,
    neuron_index=neuron_index,
    concept=concept
)

Citation

@misc{puri2025fadebaddescriptionshappen,
    title={FADE: Why Bad Descriptions Happen to Good Features}, 
    author={Bruno Puri and Aakriti Jain and Elena Golimblevskaia and Patrick Kahardipraja and Thomas Wiegand and Wojciech Samek and Sebastian Lapuschkin},
    year={2025},
    eprint={2502.16994},
    archivePrefix={arXiv},
    primaryClass={cs.LG},
    url={https://arxiv.org/abs/2502.16994}, 
}

🚧 This repository is still in active development! More examples and detailed documentation will follow soon! 🚧

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fade_language-0.1.2.tar.gz (23.3 kB view details)

Uploaded Source

File details

Details for the file fade_language-0.1.2.tar.gz.

File metadata

  • Download URL: fade_language-0.1.2.tar.gz
  • Upload date:
  • Size: 23.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for fade_language-0.1.2.tar.gz
Algorithm Hash digest
SHA256 4a8b8f7fdc8f80ae0fc721f42ccbab2f9386476330014a07b467d5a71093b261
MD5 48dee3e807ac401fb9243ccde25d5267
BLAKE2b-256 dc971b77506be5b4231e18c64e86970480e3d0eeabeb14d888ad337f8dabb100

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page