Research Models
Collection
Experimental and research model variants. โข 2 items โข Updated
How to use Ex0bit/lfm-Nanotron with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="Ex0bit/lfm-Nanotron") # Load model directly
from transformers import AutoModel
model = AutoModel.from_pretrained("Ex0bit/lfm-Nanotron", dtype="auto")How to use Ex0bit/lfm-Nanotron with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "Ex0bit/lfm-Nanotron"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "Ex0bit/lfm-Nanotron",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/Ex0bit/lfm-Nanotron
How to use Ex0bit/lfm-Nanotron with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "Ex0bit/lfm-Nanotron" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "Ex0bit/lfm-Nanotron",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "Ex0bit/lfm-Nanotron" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "Ex0bit/lfm-Nanotron",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use Ex0bit/lfm-Nanotron with Docker Model Runner:
docker model run hf.co/Ex0bit/lfm-Nanotron
lfm-Nanotron: Limited Edition 2.6B PRISM Model Access. Unlock a cutting-edge Nano sized AI model!
This is lfm-Nanotron โ A Nano Sized 2.6B parameter hybrid architecture language model fine-tuned with advanced techniques you won't find in mainstream releases:
| Parameter | Value |
|---|---|
| Parameters | ~2.6B |
| Hidden Size | 2048 |
| Layers | 30 (22 Conv + 8 Full Attention) |
| Attention Heads | 32 |
| KV Heads | 8 (GQA) |
| Vocabulary | 65,536 |
| Max Context | 128,000 tokens |
| Architecture | Hybrid Conv + Attention (LFM2) |
| File | Quantization | Size | Use Case |
|---|---|---|---|
lfm2-nanotron-ttft-gspo-prism-bf16.gguf |
BF16 | ~4.8GB | Full precision, best quality |
lfm2-nanotron-ttft-gspo-prism-Q4_K_M.gguf (+W4A16) |
Q4_K_M | ~1.5GB | Balanced quality/size |
lfm2-nanotron-ttft-gspo-prism-Q2_K.gguf |
Q2_K (+W2A16) | ~0.9GB | Maximum compression |
./llama-cli -m lfm2-nanotron-ttft-gspo-prism-Q4_K_M.gguf -p "Your prompt here" --temp 0.3 --min-p 0.15 --repeat-penalty 1.05
{
"temperature": 0.3,
"min_p": 0.15,
"repeat_penalty": 1.05
}
If you use this model in your research, please cite:
@misc{lfm2-nanotron-2026,
title={lfm2-Nanotron: Test-Time Fine-Tuned LFM2 with GSPO+PRISM},
author={Exobit (Eric Elbaz)},
year={2026},
publisher={Hugging Face},
url={https://huggingface.co/Ex0bit/lfm2-Nanotron}
}
This model is released under a custom research license. See LICENSE.md for details.