Run this model with HF Jobs

Run LiquidAI/LFM3-VL-2B-MLX-4bit on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.

Paste one of these prompts into your coding agent:

Fine-tune on my dataset

Use HF Jobs to fine-tune https://huggingface.co/LiquidAI/LFM3-VL-2B-MLX-4bit. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.

Run batch inference

Use HF Jobs to run batch inference with https://huggingface.co/LiquidAI/LFM3-VL-2B-MLX-4bit on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.

Evaluate on a benchmark

Use HF Jobs to evaluate https://huggingface.co/LiquidAI/LFM3-VL-2B-MLX-4bit. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
How to use from the
Use from the
MLX library
# 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/LFM3-VL-2B-MLX-4bit")
config = load_config("LiquidAI/LFM3-VL-2B-MLX-4bit")

# 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)

LFM3-VL-2B-MLX-4bit

4-bit MLX version of LFM3-VL-2B for Apple Silicon. The weights take 1.59 GB.

Weights use 4-bit affine quantization with groups of 32. Token embeddings stay in 8-bit. The weights are trained with quantization-aware distillation (QAD), so they recover much of the 8-bit performance.

Find architecture and usage details in the original model card.

Use with MLX-VLM


Requires MLX-VLM 0.7.11 or later:

pip install -U "mlx-vlm>=0.7.11"
python -m mlx_vlm.generate --model LiquidAI/LFM3-VL-2B-MLX-4bit \
  --image <IMAGE PATH> --prompt "Describe this image." --enable-thinking \
  --temperature 0.1 --top-p 1.0 --top-k 50 --min-p 0.0 --repetition-penalty 1.1 \
  --max-tokens 16384

Reasoning stays off unless you pass --enable-thinking. More options in the MLX guide.

Downloads last month
10,325
Safetensors
Model size
2B params
Tensor type
U32
ยท
BF16
ยท
MLX
Hardware compatibility
Log In to add your hardware

4-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for LiquidAI/LFM3-VL-2B-MLX-4bit

Quantized
(64)
this model