Liquid AI releases LFM2.5 encoders for CPUs
Liquid AI has released two compact bidirectional encoders that it says match larger models on classification benchmarks and stay fast at long input lengths, even on CPU-only hardware.
Liquid AI announced two encoder models, LFM2.5-Encoder-230M and LFM2.5-Encoder-350M, now available on Hugging Face. They are meant to be fine-tuned for classification, natural language understanding and token-level tasks, and they support a context length of 8,192 tokens.
The models start from Liquid's LFM2.5-230M and LFM2.5-350M decoders, which share the LFM2 hybrid backbone. To turn them into encoders, Liquid swapped the causal attention mask for a bidirectional one and made the short convolutions non-causal using symmetric center padding. It then trained them with masked language modeling at a 30% mask rate, twice BERT's 15%. Training ran in two phases: first at a 1,024-token context on a packed web corpus, then a long-context phase at 8,192 tokens.
Liquid fine-tuned 14 models on 17 GLUE, SuperGLUE and multilingual classification tasks and reports the mean over five seeds. On that suite, the 350M model ranked fourth. The three models ahead of it are all larger, including one with 3.5B parameters. The company says the 230M model beat ModernBERT-base and every EuroBERT model. Liquid has open-sourced the evaluation framework and raw results.
Speed is the main selling point. Liquid says the 230M model is the fastest it tested on CPU from 1K tokens upward. At 8,192 tokens, one forward pass took about 28 seconds, compared with over a minute and a half for ModernBERT-base, which works out to roughly 3.7x faster. On an Apple GPU, ModernBERT-base was faster below about 1K tokens, and the LFM2.5 models pulled ahead from around 2K. Liquid did not specify the CPU hardware in the material reviewed.
These encoders differ from last month's LFM2.5-Retrievers, which were trained only for retrieval. Liquid says the new models score well above the retrievers on these benchmarks.