metadata
language:
- en
- de
- es
- fr
- it
- nl
- pl
- pt
- ar
- hi
- ja
- ru
- tr
- vi
- zh
tags:
- liquid
- lfm2
- lfm2.5
- bidirectional
- masked-lm
- encoder
library_name: transformers
license: other
license_name: lfm1.0
license_link: LICENSE
pipeline_tag: text-classification
base_model:
- LiquidAI/LFM2.5-Encoder-350M
LFM2.5-Encoder-350-Prompt-Router
A full fine-tune of LFM2.5-Encoder-350M with a zero-shot routing head that scores a prompt against user-defined routing lanes in a single encoder pass.
Find more details about our encoders in our blog post.
💻 Demos: Try this fine-tuned model running in a CPU-only Hugging Face space: Zero-shot prompt routing — define your own routing lanes as free text. The model scores the whole prompt against every lane in one pass.
Usage
⚠️ Loads custom code via
trust_remote_code=True(the model wraps atrust_remote_codeencoder).
Install the required packages:
pip install torch transformers
Run zero-shot prompt routing:
from transformers import AutoModel, AutoTokenizer
model_id = "LiquidAI/LFM2.5-Encoder-350-Prompt-Router"
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
model = AutoModel.from_pretrained(model_id, trust_remote_code=True).eval()
routes = ["Coding", "Sales", "Creative writing", "General knowledge"]
prompt = "Can you help me debug a failing Python unit test?"
print(model.route(prompt, routes, tokenizer=tokenizer))
📬 Contact
- Got questions or want to connect? Join our Discord community
- If you are interested in custom solutions with edge deployment, please contact our sales team.
Citation
@article{liquidAI2026Encoders,
author = {Liquid AI},
title = {LFM2.5-Encoders: Fast at Long Context, Even on CPU},
journal = {Liquid AI Blog},
year = {2026},
note = {www.liquid.ai/blog/lfm2-5-encoders},
}
Xet Storage Details
- Size:
- 2.87 kB
- Xet hash:
- 2057880d76e1ef595b662d317f2eae60124b9b077c6e33546db19ddc46a3a062
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.