LLMSeg: Training-Free Text-Prompted Image Segmentation with B-Splines
Organizations: King Abdullah University of Science and Technology (KAUST)
Abstract
Promptable segmentation models such as SAM 3 achieve remarkable open-vocabulary performance but require dedicated architectures, large-scale annotation engines, and task-specific training. We ask a different question: can a general-purpose multimodal large language model (MLLM) segment images directly, without an added segmentation head, mask decoder, or training? We present LLMSeg, a training-free pipeline that turns a vision-capable LLM into a text-prompted image segmenter. LLMSeg decomposes segmentation into three LLM-driven stages. First, detect localizes all instances matching a free-form text query and describes their coarse morphology. Next, segment traces each instance using closed periodic B-splines confined to its detected box. These splines define an outer boundary and optional hole loops. Finally, refine iteratively proposes focus boxes around residual errors and retraces confined splines. The process ends when the mask stabilizes or the pass budget is exhausted. The output is a binary mask with inspectable intermediate geometry. We evaluate LLMSeg across ten referring and reasoning segmentation splits (ReasonSeg and RefCOCO/+/g). We also evaluate open-vocabulary instance segmentation (LVIS, COCO, and SA-Co), semantic segmentation, and zero-shot detection (ODinW13 and RF-100VL). With an off-the-shelf Gemini-3.7-Flash backend, LLMSeg is competitive with and often surpasses the specialist SAM 3 model on identical items. It reaches 71.5 cIoU on ReasonSeg val without additional segmentation-specific training. Backend model updates can improve accuracy without retraining the pipeline. The code is available at https://abdullahamdi.com/llmseg .
Figures & tables
| ReasonSeg | RefCOCO | RefCOCO+ | RefCOCOg | ||||||||
| Method | MLLM/Backend | val | test | val | testA | testB | val | testA | testB | val (U) | test (U) |
| Seg-Zero | Qwen2.5-VL 7B | 62.0 | 52.0 | – | – | – | – | – | – | – | – |
| LISA | LLaVA 7B | – | – | 74.9 | 79.1 | 72.3 | 65.1 | 70.8 | 58.1 | 67.9 | 70.6 |
| LISA | LLaVA1.5 13B | 72.9 | 62.2 | – | – | – | – | – | – | – | – |
| GLaMM | Vicuna 7B | 47.2 | – | 79.5 | 83.2 | 76.9 | 72.6 | 78.7 | 64.6 | 74.2 | 74.9 |
| PSALM | Phi1.5 1.3B | – | – | 83.6 | 84.7 | 81.6 | 72.9 | 75.5 | 70.1 | 73.8 | 74.4 |
| Semantic segmentation | Zero-shot detection | ||||||||||
| ADE20K-150 | Cityscapes | ODinW13 | RF-100VL | ||||||||
| Method | gIoU | cIoU | mIoU | AP 0 | gIoU | cIoU | pmF1 | AP 0 | gIoU | cIoU | pmF1 |
| APE-D (LVIS-trained) | – | – | 44.2 | – | – | – | – | – | – | – | – |
| Gemini 2.5 Pro | – | – | – | 33.7 | – | – | – | 11.6 | – | – | – |
| gDino-T | – | – | – | 49.7 | – | – | – | 15.7 | – | – | – |
| gDino1.5-Pro | – | – | – | 58.7 | – | – | – | – | – | – | – |
| LVIS | COCO | |||||
| Method | cgF1 | box AP | mask AP | cgF1 | box AP | mask AP |
| OWLv2 | 20.1 | 35.2 | – | – | 38.2 | – |
| OWLv2 † | 29.3 | 45.5 | 43.4 | – | 46.1 | – |
| gDino-T | 14.7 | 20.5 | – | – | 45.7 | – |
| LLMDet-L | 35.1 | 42.0 | 36.3 | – | 55.6 | – |
| APE-D † | – | 59.6 | 53.0 | – | 58.3 | – |
Appendix figures & tables28 assets
Supplementary material from the paper’s appendix.
Appendix
| Benchmark (splits) | Query (words) | Split | Neg. | Scored | Ground truth | Metric |
| ReasonSeg val / test | reasoning sentence (18.3 / 20.7) | 200 / 779 | 2.0 / 0.3 | all | one mask per query | gIoU, cIoU |
| RefCOCO val / testA / testB | referring expression (3.6) | 10,834 / 5,657 / 5,095 | 0 | 500 each | one instance | gIoU, cIoU |
| RefCOCO+ val / testA / testB | no location words (3.6) | 10,758 / 5,726 / 4,889 | 0 | 500 each | one instance | gIoU, cIoU |
| RefCOCOg val / test | written description (8.5) | 4,896 / 9,602 | 0 | 500 each | one instance | gIoU, cIoU |
| LVIS val | category name (1.4) | 129,547 | 45.9 | 1,500 | every instance | cgF1, pmF1, AP |
| COCO val2017 | category name (1.2) | 29,631 | 50.6 | 1,500 | every instance | cgF1, pmF1, AP |
| Training | val | test | |||||
| Method | MLLM | RES | ReasonSeg | gIoU | cIoU | gIoU | cIoU |
| Published, full splits ( Carion et al., 2026 ) | |||||||
| SEEM ( Zou et al., 2023 ) | – | ✗ | ✗ | 25.5 | 21.2 | 24.3 | 18.7 |
| Grounded SAM ( Ren et al., 2024 ) | – | ✗ | ✗ | 26.0 | 14.5 | 21.3 | 16.4 |
| OVSeg ( Liang et al., 2023 ) | – | ✗ | ✗ | 28.5 | 18.6 | 26.1 | 20.8 |
| GLaMM ( Rasheed et al., 2024 ) | Vicuna 7B | ✓ | ✗ | 47.4 | 47.2 | – | – |
| RefCOCO | RefCOCO+ | RefCOCOg | ||||||||
| Method | MLLM / backbone | RES | val | testA | testB | val | testA | testB | val (U) | test (U) |
| Published, full splits, cIoU ( Carion et al., 2026 ) | ||||||||||
| LISA ( Lai et al., 2024 ) | LLaVA 7B | ✓ | 74.9 | 79.1 | 72.3 | 65.1 | 70.8 | 58.1 | 67.9 | 70.6 |
| GSVA ( Xia et al., 2024 ) | 13B | ✓ | 79.2 | 81.7 | 77.1 | 70.3 | 73.8 | 63.6 | 75.7 | 77.0 |
| GLaMM ( Rasheed et al., 2024 ) | Vicuna 7B | ✓ | 79.5 | 83.2 | 76.9 | 72.6 | 78.7 | 64.6 | 74.2 | 74.9 |
| SAM4MLLM ( Chen et al., 2024 ) | LLaVA1.6 7B | ✓ | 79.6 | 82.8 | 76.1 | 73.5 | 77.8 | 65.8 | 74.5 | 75.6 |
| LVIS | COCO | SA-Co/Gold | |||||||||
| Method | MLLM | cgF1 | pmF1 | box AP | mask AP | cgF1 | pmF1 | box AP | mask AP | cgF1 | pmF1 |
| Human | – | – | – | – | – | – | – | – | – | 72.8 | – |
| OWLv2 ( Minderer et al., 2023 ) | – | 20.1 | – | 35.2 | – | – | – | 38.2 | – | 17.3 | – |
| OWLv2 (LVIS-trained) | – | 29.3 | – | 45.5 | 43.4 | – | – | 46.1 | – | 24.6 | – |
| gDino-T ( Liu et al., 2024a ) | – | 14.7 | – | 20.5 | – | – | – | 45.7 | – | 3.3 | – |
| LLMDet-L ( Fu et al., 2025 ) | – | 35.1 | – | 42.0 | 36.3 | – | – | 55.6 | – | 6.5 | – |
| Backend | Developer | Release | Stage-2 gIoU | Final gIoU | |
| GPT-6 Astra † | OpenAI | 2026-09 | 74.2 [70.4, 77.9] | 72.9 [69.2, 76.6] | -1.2 |
| Gemini 3.7 Flash | 2026-08-13 | 65.7 [62.1, 69.5] | 69.4 [65.9, 72.8] | +3.7 | |
| Gemini 3.8 Flash † | 2026-09 | 63.4 [59.4, 67.3] | 66.7 [63.0, 70.4] | +3.3 | |
| Gemini 3.5 Flash | 2026-05 | 62.9 [59.1, 66.6] | 66.2 [62.4, 70.0] | +3.3 | |
| GPT-5.6 Sol † | OpenAI | 2026-07 | 61.2 [57.3, 64.9] | 61.6 [57.7, 65.5] | +0.3 |
| Gemini 3 Flash | 2025-12 | 58.9 [55.1, 62.7] | 58.6 [55.1, 61.9] | -0.3 |
| Variant | gIoU | cIoU | calls/image | s/image |
| LLMSeg (reported configuration) | 70.7 0.74 | 74.7 1.62 | 14.6 0.32 | 177 9 |
| w/o deterministic postprocessing | 70.2 0.27 | 74.1 2.20 | 14.8 0.37 | 162 12 |
| + box-adjust pre-pass | 70.0 0.27 | 70.2 0.38 | 15.7 0.34 | 188 17 |
| w/o postprocessing + box-adjust | 69.5 0.11 | 73.2 1.64 | 15.9 0.10 | 169 12 |
| + topology conditioning | 69.2 1.34 | 72.6 0.23 | 14.3 0.59 | 175 17 |
| w/o refinement ( ) | 63.8 0.68 | 67.2 2.72 | 2.0 0.00 | 24 2 |
| Variant | gIoU | cIoU | calls/image |
| LLMSeg (reported configuration) | 79.3 | 79.8 | 17.5 |
| w/o deterministic postprocessing | 76.6 | 77.9 | 17.1 |
| + box-adjust pre-pass | 79.2 | 79.7 | 18.4 |
| w/o postprocessing + box-adjust | 77.9 | 78.3 | 19.1 |
| + topology conditioning | 76.7 | 77.3 | 16.8 |
| w/o refinement ( ) | 66.9 | 64.6 | 2.0 |
| measured / estimated cost per image | ||||
| Method | calls | median | est. $ | final |
| MLLM / SAM 3 | s | / 1k img | gIoU | |
| LLMSeg (GPT-6 Astra) | 11.7 / 0 | 218 | 323.9 | 72.9 |
| LLMSeg (Gemini 3.7 Flash) | 15.0 / 0 | 153 | 15.6 | 69.4 |
| LLMSeg (Gemini 3.8 Flash) | 16.2 / 0 | 419 | 33.7 | 66.7 |
| LLMSeg (Gemini 3.5 Flash) | 17.6 / 0 | 246 | 77.9 | 66.2 |
Image Segmentation
Image segmentation assigns pixels or voxels to objects and regions, supporting measurement, scene understanding, and decisions across image domains.
See all 399 papers