EU-Halt β Production Heads
Collection
K=4 head sets for frozen LLM trunks. Attach with eu_halt.attach(model, heads_repo=...). One forward pass β disagreement score. β’ 11 items β’ Updated
microsoft/Phi-3.5-mini-instruct (default)
Lightweight epistemic-uncertainty detector: K=4 prediction heads sharing the frozen microsoft/Phi-3.5-mini-instruct trunk. Configuration: mid_dim=128, K=4 (default).
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
from eu_halt import attach
model = AutoModelForCausalLM.from_pretrained(
"microsoft/Phi-3.5-mini-instruct", torch_dtype=torch.bfloat16,
).to("cuda").eval()
tokenizer = AutoTokenizer.from_pretrained("microsoft/Phi-3.5-mini-instruct")
uncertainty = attach(
model,
heads_repo="debajyotidasgupta/eu-halt-phi-3.5-mini-instruct",
mid_dim=128,
)
print(uncertainty("Who founded Quora in 2008?", tokenizer))
# Higher = more uncertain.
heads_final.pt β final K=4 head state dict.heads_step{500,1000,1500,2000,2500}.pt β intermediate checkpoints.source_layers.json β the 4 trunk-layer indices the heads read from.history.json β per-step loss + disagreement + GPU stats.HuggingFaceFW/fineweb-edu (streaming).quiet variants).OOD AUROC (id vs ood), 2164 samples total:
| Signal | AUROC | 95% CI |
|---|---|---|
| disagreement | 0.7420 | [0.7193, 0.7614] |
| entropy | 0.5382 | [0.5150, 0.5612] |
| last_token_unc | 0.4002 | [0.3691, 0.4337] |
| mahalanobis | 1.0000 | [1.0000, 1.0000] |
| p_true | nan | [nan, nan] |
| semantic_entropy | nan | [nan, nan] |
Best signal: mahalanobis
uncertainty.per_token(text, tokenizer).Apache-2.0 for the heads.
The trunk model microsoft/Phi-3.5-mini-instruct retains its own license (Qwen3 / Llama-3 / Phi / Gemma).
@misc{ais_eu_halt_2026,
author = {Dasgupta, Debajyoti and Anthropic Claude},
title = {EU-Halt: Lightweight Multi-Head Epistemic Detectors for Frozen LLMs},
year = {2026},
url = {https://huggingface.co/debajyotidasgupta/eu-halt-phi-3.5-mini-instruct},
}
Base model
microsoft/Phi-3.5-mini-instruct