Image-Text-to-Text
MLX
Safetensors
lfm2_vl
liquid
lfm2
lfm2-vl
edge
lfm2.5
lfm2.5-vl
mlx_vlm
conversational
custom_code
Instructions to use LiquidAI/LFM2.5-VL-3B-MLX-bf16 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- MLX
How to use LiquidAI/LFM2.5-VL-3B-MLX-bf16 with MLX:
# Make sure mlx-vlm is installed # pip install --upgrade mlx-vlm from mlx_vlm import load, generate from mlx_vlm.prompt_utils import apply_chat_template from mlx_vlm.utils import load_config # Load the model model, processor = load("LiquidAI/LFM2.5-VL-3B-MLX-bf16") config = load_config("LiquidAI/LFM2.5-VL-3B-MLX-bf16") # Prepare input image = ["http://images.cocodataset.org/val2017/000000039769.jpg"] prompt = "Describe this image." # Apply chat template formatted_prompt = apply_chat_template( processor, config, prompt, num_images=1 ) # Generate output output = generate(model, processor, formatted_prompt, image) print(output) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- LM Studio
- Pi
How to use LiquidAI/LFM2.5-VL-3B-MLX-bf16 with Pi:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "LiquidAI/LFM2.5-VL-3B-MLX-bf16"
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "mlx-lm": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "LiquidAI/LFM2.5-VL-3B-MLX-bf16" } ] } } }Run Pi
# Start Pi in your project directory: pi
- OpenClaw new
How to use LiquidAI/LFM2.5-VL-3B-MLX-bf16 with OpenClaw:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "LiquidAI/LFM2.5-VL-3B-MLX-bf16"
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "LiquidAI/LFM2.5-VL-3B-MLX-bf16" \ --custom-provider-id mlx-lm \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
- Hermes Agent
How to use LiquidAI/LFM2.5-VL-3B-MLX-bf16 with Hermes Agent:
Start the MLX server
# Install MLX LM: uv tool install mlx-lm # Start a local OpenAI-compatible server: mlx_lm.server --model "LiquidAI/LFM2.5-VL-3B-MLX-bf16"
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default LiquidAI/LFM2.5-VL-3B-MLX-bf16
Run Hermes
hermes
- Atomic Chat
Try LFM • Documentation • LEAP • Blog
LFM2.5-VL-3B-MLX-bf16
MLX export of LFM2.5-VL-3B for Apple Silicon inference.
LFM2.5-VL-3B is a vision-language model built on the LFM2.5-2.6B backbone with a SigLIP2 NaFlex vision encoder (400M). It supports OCR, document comprehension, multilingual vision understanding, bounding box prediction, and function calling.
Quickstart
uv run --with mlx-vlm mlx_vlm.generate --model LiquidAI/LFM2.5-VL-3B-MLX-bf16 --max-tokens 100 --temperature 0.2 --image https://placecats.com/neo/300/200 --prompt "how many animals are in the picture?"
from mlx_vlm import apply_chat_template, generate, load
from mlx_vlm.utils import load_image
model, processor = load("LiquidAI/LFM2.5-VL-3B-MLX-bf16")
image = load_image("https://placecats.com/neo/300/200")
messages = [
{
"role": "user",
"content": [
{"type": "image"},
{"type": "text", "text": "What do you see in this image?"},
],
}
]
prompt = apply_chat_template(
processor,
model.config,
messages,
add_generation_prompt=True,
num_images=1,
)
result = generate(
model,
processor,
prompt,
[image],
temp=0.2,
top_k=50,
repetition_penalty=1.0,
verbose=True,
)
print(result.text)
- Downloads last month
- -
Model size
3B params
Tensor type
BF16
·
Hardware compatibility
Log In to add your hardware
Quantized
Model tree for LiquidAI/LFM2.5-VL-3B-MLX-bf16
Base model
LiquidAI/LFM2.5-VL-3B