Thermodynamic Epistemic Routing: Zero-Parameter Detection of Factual vs. Speculative Generation in Large Language Models
Description
Large language models (LLMs) exhibit remarkable generative capabilities but suffer from a fundamental reliability issue: they cannot reliably distinguish between factual recall and speculative extrapolation. We present a novel approach that induces models to develop thermodynamically distinct computational pathways for these two epistemic modes. Unlike prior work that attempts to classify activation patterns spatially, we discover that the dynamics of layer-to-layer hidden state changes provide a more fundamental signal. Through adversarial co-training with LoRA adapters and a predictor network, we demonstrate that delta magnitude patterns—the L2 norms of consecutive hidden state differences—naturally separate factual and speculative content. This thermodynamic signal enables 98.39% classification accuracy on Qwen2.5-1.5B using only a scalar threshold with zero additional parameters (gap = 13.62 units), compared to 91.15% for the best spatial MLP probe. Direct replication on Qwen2.5-7B (4.67× parameters, identical hyperparameters) yields 98.13% accuracy with gap = 13.88—confirming the method transfers across model scale without modification. Our key finding is that spatial activation patterns read a downstream echo of the true signal, while thermodynamic features access the primary output of epistemic specialization. The approach preserves generation quality (eval loss improved from 1.914 to 1.835 at 1.5B; 2.323 to 1.076 at 7B) while creating interpretable epistemic structure, offering a path toward mechanistically grounded uncertainty quantification in production LLM systems.
Files
thermodynamic_epistemic_routing.pdf
Files
(453.4 kB)
| Name | Size | Download all |
|---|---|---|
|
md5:c2186953fa524708e61c456cca2542d4
|
453.4 kB | Preview Download |
Additional details
Dates
- Created
-
2026-03-02
Software
- Repository URL
- https://github.com/ameritusweb/thermodynamic-epistemic-routing
- Programming language
- Python
- Development Status
- Active