Xiaomi-Lens-0
A 4B open multimodal language model that predicts pixel-level masks and bounding boxes for grounding and visual reasoning.
At a Glance
Xiaomi-Lens-0 code is licensed under Apache-2.0; self-hosted use with publicly released model weights, code, and training/fine-tuning scripts at no charge.
Engagement
Available On
Listed Dec 2026
About Xiaomi-Lens-0
Xiaomi-Lens-0 is a 4B multimodal large language model from Xiaomi's SeerRay Lab, built on Qwen3.5-4B. It decodes each generated mask token into a pixel mask, so the model can point at the regions it describes in its answer or mid-reasoning. Weights, a demo, training and inference code, and the LensBench benchmark are publicly released under Apache-2.0.
What It Is
Xiaomi-Lens-0 is a vision-language model for grounding and segmentation. Given an image and a text instruction, it returns text containing bounding boxes and mask tokens, and a lightweight decoder turns each mask token into a pixel mask. The documented capabilities are referring expression comprehension, referring expression segmentation, multi-instance grounding, reasoning segmentation, embodied referring, and fine-grained perception such as counting and high-resolution question answering.
How the Method Works
Each generated mask token carries a contextual state that represents a target region given the image, instruction, and preceding response. The decoder combines this state with a single pre-merge feature grid from the vision encoder, with no separate segmentation encoder or multi-scale fusion. Mask tokens inside the reasoning trace also decode to masks, which the project calls thinking with visual latents. Training has two stages: mask decoder pretraining with the backbone frozen, then full-parameter supervised fine-tuning.
LensBench and Reported Results
The team also released LensBench, a segmentation benchmark with 4,800 instruction-level samples from 1,200 human-reviewed paired units across general, aerial, driving, and panoramic imagery. Each unit pairs single or multiple targets with explicit or implicit wording. The project reports that Xiaomi-Lens-0 leads compared models on all eight referring segmentation splits and improves over its Qwen3.5-4B backbone on all eight fine-grained perception benchmarks. The authors note that implicit instructions remain challenging on LensBench.
Setup Path
The repository provides a Transformers inference script that overlays masks and boxes on an image, and a two-process vLLM serving setup for text generation and mask decoding. Inference requires a CUDA GPU with bf16 and FlashAttention-2. An evaluation script runs LensBench, and training scripts support full fine-tuning or LoRA on the released checkpoint as well as reproducing the two-stage training.
Collections
Popular collections
- Run YOLO Mode Without Risking Your Laptop
Collection by @reproalex
- Let Your Agents Talk to Each Other
Collection by @leftchannel
- See What Your Agent Is Doing remix
Collection by @joemseifi
- Let Your AI Read the Document, Not Just the Words
Collection by @priyashah
Add Xiaomi-Lens-0 to one of your collections.
Community Discussions
Be the first to start a conversation about Xiaomi-Lens-0
Share your experience with Xiaomi-Lens-0, ask questions, or help others learn from your insights.
Pricing
Open Source (Apache-2.0)
Xiaomi-Lens-0 code is licensed under Apache-2.0; self-hosted use with publicly released model weights, code, and training/fine-tuning scripts at no charge.
- Code licensed under Apache-2.0
- Model weights published on Hugging Face and ModelScope
- Training and fine-tuning code (full-parameter and LoRA)
- LensBench benchmark dataset
- Weights license not separately evidenced; Apache-2.0 statement covers code
Capabilities
Key Features
- Referring expression comprehension with bounding boxes
- Referring expression segmentation with pixel masks
- Multi-instance grounding with per-instance boxes and masks
- Reasoning segmentation for implicit and functional requests
- Embodied referring in cluttered scenes
- Fine-grained perception with counting and high-resolution QA
- Thinking with visual latents via mask tokens in reasoning traces
- LensBench segmentation benchmark
- Full fine-tuning and LoRA on the released checkpoint
- Transformers inference and vLLM serving
