Introduction
Measuring bias in Large Language Models (LLMs) has traditionally been a "black box" exercise. Researchers typically curate massive datasets like WinoBias or StereoSet, prompt the model, and analyze differences in the output. However, this behavioral approach is slow, expensive, and limited to the specific social groups defined in the pre-existing test sets.
A radical shift is proposed in the BIASLENS framework: instead of evaluating what the model says, we analyze how it represents concepts internally. By examining the geometric alignment of concepts within the model's internal vector space, bias can be detected without the need for manual test sets.
The Problem with Behavioral Metrics
Current bias evaluation relies on behavioral metrics, which measure probability gaps or classification errors in generated text. This approach suffers from three major flaws:
- Labor Intensive: It requires significant human effort to collect, annotate, and group data.
- Limited Scope: It is restricted to concepts with existing datasets (e.g., gender, race).
- Surface-Level: It only captures biases that manifest in the final output, potentially missing "latent" associations buried deep in the model's activations.
The authors argue that bias is fundamentally a representational problem: if the internal vector for "doctor" is geometrically closer to "male" than "female," the model is biased, regardless of whether that bias is explicitly triggered in a specific sentence.
The BIASLENS Framework
BIASLENS is a test-set-free framework that evaluates LLM bias by analyzing internal activations. The process operates in three main stages:
- CAV Derivation: Simple linear classifiers are trained to distinguish activations of a target concept (e.g., "doctor") from random data. The normal vector of this classifier is the Concept Activation Vector (CAV), representing the "direction" of that concept in the model's activation space.
- Concept Representation Extraction: Raw activations are often noisy. BIASLENS uses Sparse Autoencoders (SAEs) to "steer" the model's activations along the CAV direction and project them into a high-dimensional sparse space. This acts as a "lens," sharpening the signal of the concept and filtering out irrelevant features.
- Bias Score Calculation: The framework measures the cosine similarity between the target concept (e.g., "doctor") and two reference concepts (e.g., "male" vs. "female"). The absolute difference between these similarity scores constitutes the final Bias Score.
Experimental Setup and Results
The framework was validated using probing data (150 positive and 150 negative sentences per concept) generated by GPT-4o and sampled from OpenWebText. To ensure reliability, BIASLENS was compared against traditional metrics using Yelp, IMDB, and WinoBias datasets.
Key Results
- High Correlation: BIASLENS demonstrates a Spearman correlation of $r > 0.85$ with traditional behavioral metrics like F1-gap, indicating it is a highly reliable proxy for observable bias.
- Massive Efficiency: The framework achieves a 50x speedup. While manual baselines can take over 1,000 minutes to annotate and test, BIASLENS completes the entire pipeline in minutes.
- Uncovering Hidden Biases: Because it does not require pre-existing test sets, BIASLENS can explore high-stakes fields like medicine. For instance, it revealed a stronger internal association between "private insurance" and "surgery" compared to "public insurance"—a clinical bias that traditional tests might miss.
Conclusion
BIASLENS represents a significant advancement in AI safety and interpretability. By treating bias as a geometric alignment problem rather than a text-generation error, it provides a faster, more scalable, and more granular way to audit LLMs. Future work will focus on reducing prompt sensitivity during the steering phase and expanding the availability of Sparse Autoencoders for a wider range of open-source models.
Summary updated