Skip to content

model : add LiquidAI/LFM3-1.7B and LiquidAI/LFM3-VL-2B - #31252

Merged
ngxson merged 8 commits into
ggml-org:masterfrom
tdakhran:tarek/lfm3/upstream/1-text-vl
Oct 27, 2026
Merged

ngxson merged 8 commits into
ggml-org:masterfrom
tdakhran:tarek/lfm3/upstream/1-text-vl

Conversation

@tdakhran

@tdakhran tdakhran commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Overview

Add support for the text and vision models from the LiquidAI LFM3 model family

Huge thanks to @CISC and @ngxson for contributions and review.

Additional information

Video input support will be added later.
Correctness and conformance verified against the reference HF implementation (text/chat logprobs, image sizing, tool calls, structured output, image input).
F32/Q8_0/Q4_0 quantization smoke-tested on Mac and CUDA.

Requirements

  • I have read and agree with the contributing guidelines
  • AI usage disclosure: YES, prototyping, correctness testing.

tdakhran and others added 6 commits October 26, 2026 23:25
Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Xuan-Son Nguyen <son@huggingface.co>
Assisted-by: Claude Opus 5.5
Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Tarek Dakhran <github@dakhran.com>
Assisted-by: Claude Opus 5.5
@tdakhran
tdakhran requested review from a team, CISC, ggerganov and pwilkin as code owners October 27, 2026 15:05
@github-actions github-actions Bot added model Model specific testing Everything test related mtmd Related to multimodal functionality (video/image/audio) conversion labels Oct 27, 2026
@CISC CISC added the highlight Changes that will be highlighted in the next release notes label Oct 27, 2026
@tdakhran
tdakhran marked this pull request as draft October 27, 2026 15:17
@tdakhran

Copy link
Copy Markdown
Contributor Author

A few final checks, uploading GGUFs, and regenerating the Metal Fusion CSV.

auRose94 pushed a commit to auRose94/llama.cpp that referenced this pull request Oct 28, 2026
* model : add LiquidAI/LFM3-1.7B and LiquidAI/LFM3-VL-2B

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Xuan-Son Nguyen <son@huggingface.co>
Assisted-by: Claude Opus 5.5

* tests : set the SWA rope base of the LFM3 test model

Assisted-by: Claude Opus 5.5

* llama : enable recurrent state rollback for LFM3

Assisted-by: Claude Opus 5.5

* Apply batched suggestions from code review

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Tarek Dakhran <github@dakhran.com>

* gguf-py : align the lfm3vl mapping comments

Assisted-by: Claude Opus 5.5

* llama : fix CRLF line endings from the review suggestions

Assisted-by: Claude Opus 5.5

* tests : add the LFM3 Metal fusion baseline

Assisted-by: Claude Opus 5.5

* llama : keep the LFM3-VL depthwise conv kernels in F32 when quantizing

Assisted-by: Claude Opus 5.5

---------

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Xuan-Son Nguyen <son@huggingface.co>
timmyy123 added a commit to timmyy123/LLM-Hub that referenced this pull request Oct 28, 2026
Adds LiquidAI's LFM3 1.7B (262K context, reasoning, tool calling) and LFM3 VL 2B (images; llama.cpp has
no LFM3-VL video yet) to the catalog.

LFM3 needs llama.cpp b11946 (ggml-org/llama.cpp#31252), but an installed build was never updated, so
existing installs would stay on one that can't load it. Windows, Linux and macOS now treat b11946 as
the minimum: an older install is replaced on the next model load and its folder removed, or kept and
used when the newer build can't be downloaded. Builds are ordered by number, not by name.

The Windows self-test takes --attach for vision runs.

Tested in the app with an older build installed: Mac (M1 Pro, Metal, b11853 -> b11946), Windows
(RTX 4090, CUDA, b11836 -> b11946) and Linux (WSL, CUDA, b11838 -> b11946). LFM3 1.7B answered on all
three (about 85, 290 and 246 tok/s); LFM3 VL 2B read a newspaper front page on Mac and Windows.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
baylitoo added a commit to baylitoo/slm_benchmark that referenced this pull request Oct 28, 2026
* feat(serving): LFM3 families (lfm3, lfm3_vl)

Every LFM3 GGUF reports arch "lfm3", so the projector and Hub tags pick
the family: no mmproj -> lfm3, mmproj -> lfm3_vl, an audio-only projector
(LFM3-Audio-2B) is refused instead of being promoted to vision.

Own KV-cache constant, 12,288 bytes/token (6 full-attention layers x 4 KV
heads x head_dim 128), runtime note for ggml-org/llama.cpp#31252, and
lfm3_1_7b / lfm3_vl_2b benchmark profiles.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* docs: LFM3 families in models/onboarding and models/reasoning

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
cubicalbatch added a commit to cubicalbatch/vesta that referenced this pull request Oct 28, 2026
b11938 is the first release with the `lfm3` architecture
(ggml-org/llama.cpp#31252, LFM3-1.7B / LFM3-VL-2B). b10373 aborts with
"unknown model architecture: 'lfm3'" on those GGUFs.

Verified: the llamacpp stage builds from the pinned asset; the binary
loads and answers with LFM3-1.7B-Q4_K_M.gguf inside the runtime base
image, and the app's router path (--models-dir + data/config/models.ini)
loads LFM3 and Qwen3.5-4B unchanged.
huaxel pushed a commit to huaxel/strix-llama.cpp that referenced this pull request Nov 1, 2026
* model : add LiquidAI/LFM3-1.7B and LiquidAI/LFM3-VL-2B

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Xuan-Son Nguyen <son@huggingface.co>
Assisted-by: Claude Opus 5.5

* tests : set the SWA rope base of the LFM3 test model

Assisted-by: Claude Opus 5.5

* llama : enable recurrent state rollback for LFM3

Assisted-by: Claude Opus 5.5

* Apply batched suggestions from code review

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Tarek Dakhran <github@dakhran.com>

* gguf-py : align the lfm3vl mapping comments

Assisted-by: Claude Opus 5.5

* llama : fix CRLF line endings from the review suggestions

Assisted-by: Claude Opus 5.5

* tests : add the LFM3 Metal fusion baseline

Assisted-by: Claude Opus 5.5

* llama : keep the LFM3-VL depthwise conv kernels in F32 when quantizing

Assisted-by: Claude Opus 5.5

---------

Co-authored-by: Sigbjørn Skjæret <sigbjorn.skjaeret@huggingface.co>
Co-authored-by: Xuan-Son Nguyen <son@huggingface.co>
edwardyoon added a commit to edwardyoon/focus-llama that referenced this pull request Nov 6, 2026
The fork synced ggml-org#31431 (tensor split for LFM3, which references LLM_ARCH_LFM3 in llama-model.cpp) but not ggml-org#31252 (which adds the enum value), leaving master in a non-building state. Add the enum value + name mapping (matching ggml-org#31252) to unblock the build. The full LFM3 model implementation is not included.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conversion highlight Changes that will be highlighted in the next release notes model Model specific mtmd Related to multimodal functionality (video/image/audio) testing Everything test related

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants