NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Recovering Knowledge by Hardening Language Models

Haiming Wang, Yimeng Chen, Han Shi, Zhengying Liu, Zhenguo LiOpenReview 2025 · Submission to ICLR 2025 · Withdrawn

Its authors withdrew this paper, so there is no full text to read or summarize.

Abstract

Recent neural language models show impressive capabilities on a wide range of tasks. However, it is not fully understood how the knowledge of the language is encoded in these models. In this work, we focus on the simplest case of languages, regular languages, and study language models trained on strings matching certain regular expressions. We propose a method, dubbed LaMFA, to recover the full knowledge of the regular language model by hardening it into a finite automaton. Such hardening is conducted by empirically partition the latent space of language models into finite states, and then recover a deterministic finite automaton by the estimated transition probabilities between these states. Through experiments on regular languages of varying complexity, we demonstrate that LaMFA can effectively extract DFA that consistently replicate the performance of the original language model. Notably, the extracted DFAs exhibit enhanced generalization capabilities, achieving 100\% accuracy even in out-of-distribution scenarios
BibTeX
@misc{wang2025recovering,
  author = {Haiming Wang and Yimeng Chen and Han Shi and Zhengying Liu and Zhenguo Li},
  title = {{Recovering Knowledge by Hardening Language Models}},
  year = {2025},
  url = {https://openreview.net/forum?id=uOnElfFuey},
  howpublished = {OpenReview},
  note = {Submitted to ICLR 2025},
}

Loading related content...

Figure