Interfaze

logo

we're hiring

pricing

help

docs

blog

sign in

All models

LFM3 VL 2B

LFM3 VL 2B by LiquidAI, a image-text-to-text model with multimodal capabilities. Understand and compare multimodal features, benchmarks, and capabilities.

Comparison

FeatureLFM3 VL 2BInterfaze
Input Modalities

text, image, video

image, text, audio, video, document

Native OCRNoYes
Long Document ProcessingNoYes
Language Support

16 partial

162+

Native Speech-to-TextNoYes
Native Object DetectionNoYes
Guardrail ControlsYesYes
Context Input Size

128K

1M

Tool CallingYes

Tool calling supported + built in browser, code execution and web search

Scaling

FeatureLFM3 VL 2BInterfaze
Scaling

Self-hosted/Provider-hosted with quantization

Unlimited

Try InterfazeRead the Docs

View model card on Hugging Face

LFM3-VL-2B is a vision-language model for on-device visual understanding. It takes text, images, and video as input, and combines the LFM3 language model with a new in-house vision encoder.

New in LFM3-VL-2B:

  • Video understanding: the first LFM vision model that takes video as input. Ask questions about a recorded lecture, a walkthrough filmed on your phone, or a clip from a camera feed.
  • Thinking: the model reasons step by step before it answers. This helps most with harder visual questions, such as math, charts, and multi-step problems.
  • Spatial and embodied reasoning: the model finds objects and reasons about how they are placed relative to each other, a strong foundation for robotics applications.

Find more information about the LFM3 family in our release blog post.

Model details

The LFM3 family includes base, text, vision, audio, omni, and decision models.

LFM3-VL-2B is designed for on-device visual tasks: questions about video, reading documents, charts, and app screens, finding objects in an image, and spatial reasoning for robots. It is not recommended for coding, multi-turn conversations, or complex reasoning.

Inference

Choose a checkpoint variant for your inference framework and hardware.

Sampling parameters: temperature=0.1, top_p=1.0, top_k=50, min_p=0.0, repetition_penalty=1.1. For image and video preprocessing, use the values in processor_config.json.

Transformers quick start (transformers>=5.21.0):

pip install "transformers>=5.21.0" torch torchvision pillow
import torch
from transformers import AutoModelForImageTextToText, AutoProcessor

model_id = "LiquidAI/LFM3-VL-2B"

model = AutoModelForImageTextToText.from_pretrained(
    model_id, dtype=torch.bfloat16, device_map="auto", trust_remote_code=True
)
processor = AutoProcessor.from_pretrained(model_id, trust_remote_code=True)

messages = [
    {
        "role": "user",
        "content": [
            {"type": "image", "url": "https://placecats.com/300/200"},
            {"type": "text", "text": "Describe this image."},
        ],
    }
]

inputs = processor.apply_chat_template(
    messages,
    add_generation_prompt=True,
    tokenize=True,
    return_dict=True,
    return_tensors="pt",
).to(model.device)

with torch.inference_mode():
    output_ids = model.generate(
        **inputs,
        do_sample=True,
        temperature=0.1,
        top_k=50,
        repetition_penalty=1.1,
        max_new_tokens=16384,  # generate() needs an explicit limit; reasoning can be long
    )

generated_ids = output_ids[:, inputs["input_ids"].shape[1] :]
print(processor.batch_decode(generated_ids, skip_special_tokens=True)[0])

For most on-device use cases, we recommend llama.cpp b11960 or newer with the GGUF checkpoints. To run it in a desktop app such as Llama.app or LM Studio, click Use this model on the GGUF page and pick the app.

From a terminal, start a web chat UI and an OpenAI-compatible API at http://localhost:8080. With -hf, llama.cpp downloads the model and the matching vision projector (mmproj):

llama serve -hf LiquidAI/LFM3-VL-2B-GGUF:Q4_0 \
  --temp 0.1 --top-p 1.0 --top-k 50 --min-p 0.0 --repeat-penalty 1.1 \
  --no-reasoning-preserve --port 8080

To ask one question from the command line, use llama cli with the same flags, --image <IMAGE PATH> or --video <VIDEO PATH>, and -p "<PROMPT>". Video input needs ffmpeg in PATH.

For high-throughput serving on GPU, use vLLM or SGLang. Both serve an OpenAI-compatible API. Support for LFM3-VL in SGLang is in review in sgl-project/sglang#46858, and support in vLLM is in progress. We will update this card when their releases support it.

vLLM:

vllm serve LiquidAI/LFM3-VL-2B \
  --reasoning-parser qwen3 \
  --enable-auto-tool-choice --tool-call-parser qwen3_coder \
  --chat-template-content-format openai \
  --structured-outputs-config '{"backend": "xgrammar", "disable_any_whitespace": true}' \
  --media-io-kwargs '{"video": {"video_backend": "qwen3_vl"}}'

SGLang:

sglang serve --model-path LiquidAI/LFM3-VL-2B --trust-remote-code \
  --reasoning-parser auto \
  --tool-call-parser auto \
  --constrained-json-disable-any-whitespace

Send an image-and-text request with the OpenAI client. Change base_url to http://localhost:30000/v1 for SGLang, or http://localhost:8080/v1 for llama.cpp:

from openai import OpenAI

client = OpenAI(base_url="http://localhost:8000/v1", api_key="EMPTY")

response = client.chat.completions.create(
    model="LiquidAI/LFM3-VL-2B",
    messages=[
        {
            "role": "user",
            "content": [
                {"type": "image_url", "image_url": {"url": "https://placecats.com/300/200"}},
                {"type": "text", "text": "Describe this image."},
            ],
        }
    ],
    temperature=0.1,
    extra_body={"top_k": 50, "repetition_penalty": 1.1},
)
print(response.choices[0].message.content)

By default, LFM3-VL-2B samples video at 2 fps, with at least 4 and at most 768 frames per video. Each frame adds vision tokens, so for long videos a lower frame rate or frame limit uses less context and memory.

  • Transformers: set the frame rate per call with processor.apply_chat_template(..., processor_kwargs={"fps": 1}). Set the frame limit when you load the processor: AutoProcessor.from_pretrained(model_id, trust_remote_code=True, max_frames=128).
  • vLLM: set a server default in --media-io-kwargs, for example '{"video": {"video_backend": "qwen3_vl", "fps": 1, "max_frames": 128}}'. Override it per request with extra_body={"media_io_kwargs": {"video": {"fps": 1, "max_frames": 128}}}.
  • SGLang: change fps, min_frames, and max_frames under video_processor in processor_config.json in a local copy of the checkpoint.
  • llama.cpp: always uses 2 fps and 4 to 768 frames for this model. --video-fps has no effect.

LFM3-VL uses this ChatML format, generated from the checkpoint's chat template:

<|startoftext|><|im_start|>system
You are a helpful assistant trained by Liquid AI.<|im_end|>
<|im_start|>user
<|vision_start|><|image|><|vision_end|>What species is in this picture?<|im_end|>
<|im_start|>assistant
<think>

Use processor.apply_chat_template() with add_generation_prompt=True to format messages automatically. The model thinks in a <think>...</think> block before it answers.

The template inserts <|vision_start|><|image|><|vision_end|> for each image and <|vision_start|><|video|><|vision_end|> for each video. Do not put these tags in your message content.

Reasoning from turns before the latest user message is removed unless preserve_thinking=True.

Pass function schemas through tools=... to apply_chat_template(). The template formats tool definitions and results automatically. Generated calls use XML:

<tool_call>
<function=get_weather>
<parameter=city>
Paris
</parameter>
</function>
</tool_call>

[!WARNING] LFM3's tool call format has changed from the custom LFM2/LFM2.5 format to a superset of qwen3_coder.

Execute the call in your application. Add the parsed assistant call to history as a tool_calls entry, then append the result as a tool message. Keep passing the tool schemas on subsequent requests and preserve the assistant's content and reasoning from the current tool-use turn.

function.arguments must be a Python mapping. Decode JSON strings with json.loads() before applying the template.

See the Tool Use documentation for the full guide.

LFM3 supports deferred tools. Set defer_loading=True to keep tool definitions out of the prompt until your harness's search tool returns their names as tool_reference parts. The chat template then inserts their definitions into <additional_tools>.

tools = [
    search_tool,
    {"type": "function", "defer_loading": True, "function": get_weather_schema},
]
messages.append({
    "role": "tool",
    "tool_call_id": call_id,
    "content": [
        {"type": "text", "text": "Found 1 tool."},
        {"type": "tool_reference", "name": "get_weather"},
    ],
})

Your harness implements and runs the search. Keep the full tools list, including deferred tools, on every request.

See Deferred tools and tool search for the full guide.

Fine-tuning

LFM3-VL-2B is designed for easy customization for a given domain, task, or application via TRL.

Performance

Benchmarks

Across 62 vision benchmarks, LFM3-VL-2B scores at least 8 points ahead of all models of similar size. It matches Gemma 4 12B, is within 2 points of GPT-5.6 Luna, and scores higher than Gemini 3.5 Flash Lite.

Edge inference

LFM3-VL-2B has the highest prefill throughput and the lowest memory use of all compared models on all three devices.

GPU inference

On one NVIDIA B300, LFM3-VL-2B produces more than 12,000 tokens/s at 1,024 concurrent requests, more than any compared model.

Training

Pre-training: LFM3-VL-2B starts from LFM3-1.7B-Base, which is pre-trained in two stages on 22T tokens in total.

  • Main pre-training: compared with LFM2, the mix adds more scientific papers, repository-level code, math, and a wider range of knowledge sources.
  • Mid-training: the last 3.5T tokens use curated, higher-quality data with a larger share of agentic traces and tool calls. This stage also extends the context window to 256K tokens.

Post-training: four stages develop visual understanding, reasoning, and tool use.

  • Vision mid-training: LFM3-1.7B-Base is joined with our new in-house vision encoder, which combines convolution and attention, and trained on image and video data.
  • Supervised fine-tuning (SFT): a wide mix of instruction following, reasoning, tool calling, agentic traces, grounding, and multimodal perception and understanding.
  • Vision reinforcement learning: many domains trained at once, to improve reasoning and general intelligence.
  • Multi-domain on-policy distillation (MOPD): a vision teacher model and the Mixed RL model from LFM3-1.7B are distilled back into a single model.

Citation

@article{liquidAI2026LFM3,
  author  = {Liquid AI},
  title   = {Introducing LFM3: Every Modality for Specialized Intelligence},
  journal = {Liquid AI Blog},
  year    = {2026},
  note    = {www.liquid.ai/blog/lfm3},
}

For questions and feedback, join Discord. For custom deployment and fine-tuning support, contact Liquid AI.

Want more deterministic results?

Interfaze

logo

Product

Playground

OCR

Models

Leaderboards

Pricing

OpenWebSearch

DefaultModel