/ Модель

Характеристики

Контекст
262 144 токена
Параметры
1,6 млрд
Лицензия
Своя лицензия
Архитектура
lfm3 · dense
Базовая модель
LFM3-1.7B
Библиотека
transformers
Опубликована
12 ноя 2026

LFM3-1.7B-UtilityModel-edited-weights

Генерация текстаТекст → текст3 профессии

Экспериментально изменённая версия LFM3-1.7B для локальных агентов, ориентированная на JSON-вызовы инструментов и менее многословные ответы перед вызовом.

270скачиваний за 30 дней1лайквеса обновлены13 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Это экспериментальная версия весов LiquidAI/LFM3-1.7B, опубликованная пользователем cbert33 для локальных utility-агентов. Модель предназначена для генерации текста и вызовов инструментов в JSON-формате; автор изменил отдельные строки выходной матрицы lm_head, чтобы повысить вероятность JSON-вызовов и сократить повествование перед ними. Обучение, LoRA и квантизация не применялись; модель содержит 1,6 млрд параметров, использует архитектуру LFM3 и формат safetensors. Заявленная длина контекста базовой модели — 262 144 токена.

Автор сообщает, что в его проверке доля многословных ответов перед вызовом инструмента снизилась с 82,7% до 64,0%, а медианная длина такого повествования — с 769,5 до 508 слов. Эти результаты относятся к указанному автором набору промптов и не гарантируют такого же эффекта в других сценариях. Базовая модель рассчитана на локальных агентов и специализированные приложения; README не рекомендует её для агентного программирования и сложных многошаговых рассуждений. Лицензия указана как other, конкретные условия использования следует сверять с репозиторием и лицензией базовой модели.

Сценарии применения

  • генерация JSON-вызовов инструментов для локального агента
  • сокращение пояснений перед передачей управления инструменту
  • создание диалоговых агентов с длинным контекстом

Ограничения

Заявленное сокращение многословных ответов основано на ограниченной проверке автора и может не переноситься на другие промпты. Базовая модель не рекомендуется для агентного программирования и сложных многошаговых рассуждений.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

LFM3-1.7B-UtilityModel-edited-weights

This is a weight-edited version of LiquidAI/LFM3-1.7B, specialized for utility-agent use: JSON tool calls and less narration looping before the call. No training, no LoRA, no fine-tuning. Two static edits to the output head, derived from captured hidden states and applied to lm_head rows. No quantization was performed.

JSON tool call improvement

Stated goal: When JSON is requested, emit a JSON tool call ({"name": ..., "arguments": ...}) instead of the default XML <tool_call><function=...> format, at the model card's standard sampling settings (temperature 0.1, top_k 50, repetition_penalty 1.1).

How the weights were edited:

  • Untied the lm_head from the input embeddings (tie_word_embeddings: false); embed_tokens left byte-identical for the JSON-format edit.
  • JSON-format edit: measured 59 antml decision states (the states that emit <tool_call>), and computed the mean final hidden state there (L2 norm 73.21). Row 99 ({) shifted by +0.00453 times that vector; the 16 newline-family rows (207, 8, 469, 318, 604, 920, 833, 514, 703, 473, 64466, 64952, 96460, 95504, 3103, 13124) shifted by -0.00227 times that vector.
  • Looping edit: 33 JSON opener rows shifted by +0.0035 times the continue-boundary direction vector (L2 norm 40.86).
  • Embedding edit: rows 22 (.) and 39 (?) shifted by +0.10 times the boundary brace-logit direction.
  • All other tensors byte-identical; the readout is linear, so each push is exact.
  • Mechanism: at antml decision states the newline token (row 207) wins by ~29 logits over both { and <. Suppressing the newline family along the antml-state direction releases the brace gate.

Before / after:

MetricBaselineFinalDelta
pure JSON42.0%88.0%+46.0 pts
pure antml20.0%0.0%-20.0 pts
mixed26.7%0.0%-26.7 pts
neither11.3%12.0%+0.7 pts
parseable68.7%88.0%+19.3 pts
antml present46.7%0.0%-46.7 pts
prompts with >=1 parseable84%88%+4 pts

Looping behavior

Stated goal: reduce the narration ramble the model writes before the tool call.

How the weights were edited:

  • Captured the sentence/newline decision states where the model keeps narrating: 12,415 boundary states from 100 outputs from a held-out prompt slice (12,289 continue, 126 commit).
  • At continue boundaries the brace { sits at rank ~1,156 and ~18.9 logits below the actual next token; at commit boundaries it is rank ~4 and ~5.8 below. The structural decision is a ~14-logit swing.
  • Looping edit: 33 JSON opener rows shifted by +0.0035 times the mean continue-boundary direction vector (L2 norm 40.86).
  • Embedding edit: rows 22 (.) and 39 (?) shifted by +0.10 times the boundary brace-logit direction, where the direction is the boundary state minus the prose and post-brace states.
  • All other tensors byte-identical.

Before / after:

MetricBaselineFinalDelta
ramble rate82.7%64.0%-18.7 pts
median narration words769.5508-261.5
mean gen tokens20081951-2.8%

Files and reproducibility

  • model.safetensors - the edited weights (bf16, 3.98 GB).
  • config.json - tie_word_embeddings: false.
  • The included manifest lists the exact row ids, beta values, direction norms, and verification flags.
  • Base model: LiquidAI/LFM3-1.7B. The edits are static lm_head row shifts, not training.

Original model card: LFM3-1.7B

LFM3-1.7B

LFM3-1.7B is a text model for local agents and specialized applications, based on our new tri-hybrid architecture.

  • Agentic training: post-trained for agentic harnesses such as Hermes Agent, Pi, and OpenClaw, with a 256K-token context window.
  • Designed for the edge: at 4-bit precision, it takes about 1 GB of memory, so it fits on any phone or laptop.
  • Made to be specialized: adapt the model to your domains, formats, and tools via quick single-GPU fine-tuning.

Find more information about the LFM3 family in our release blog post.

Model details

The LFM3 family includes base, text, vision, audio, omni, and decision models.

LFM3-1.7B is designed for local agents, tool calling, structured outputs, and domain-specific fine-tuning. Use retrieval or search for knowledge-heavy tasks. It is not recommended for agentic coding or complex multi-step reasoning due to its small size.

Inference

Choose a checkpoint variant for your inference framework and hardware.

Sampling parameters:

  • General (chat, tool use, agents, coding): temperature=0.1,top_k=50, repetition_penalty=1.1
  • Math & STEM (math, science): temperature=1.0, top_p=0.95, top_k=20

Transformers quick start:

from transformers import pipeline

generator = pipeline(
    "text-generation",
    model="LiquidAI/LFM3-1.7B",
    trust_remote_code=True,
)

messages = [{"role": "user", "content": "What is C. elegans?"}]
output = generator(
    messages,
    do_sample=True,
    temperature=0.1,
    top_k=50,
    repetition_penalty=1.1,
    max_new_tokens=2048,
)
print(output[0]["generated_text"][-1]["content"])

For local agent setup, see the Agent Harnesses guide.

LFM3 uses this ChatML format, generated from the checkpoint's chat template:

<|startoftext|><|im_start|>system
You are a helpful assistant trained by Liquid AI.<|im_end|>
<|im_start|>user
Explain how a heat pump works.<|im_end|>
<|im_start|>assistant
<think>

Use tokenizer.apply_chat_template() with add_generation_prompt=True to format messages automatically.

Reasoning is enabled by default. You can set enable_thinking=False to disable thinking traces, but this behavior can be inconsistent, especially for reasoning-heavy tasks.

Reasoning from turns before the latest user message is removed unless preserve_thinking=True.

Pass function schemas through tools=... to apply_chat_template(). The template formats tool definitions and results automatically. Generated calls use XML:

<tool_call>
<function=get_weather>
<parameter=city>
Paris
</parameter>
</function>
</tool_call>

Execute the call in your application. Add the parsed assistant call to history as a tool_calls entry, then append the result as a tool message. Keep passing the tool schemas on subsequent requests and preserve the assistant's content and reasoning from the current tool-use turn.

function.arguments must be a Python mapping. Decode JSON strings with json.loads() before applying the template.

LFM3 supports deferred tools. Set defer_loading=True to keep tool definitions out of the prompt until your harness's search tool returns their names as tool_reference parts. The chat template then inserts their definitions into <additional_tools>.

tools = [
    search_tool,
    {"type": "function", "defer_loading": True, "function": get_weather_schema},
]
messages.append({
    "role": "tool",
    "tool_call_id": call_id,
    "content": [
        {"type": "text", "text": "Found 1 tool."},
        {"type": "tool_reference", "name": "get_weather"},
    ],
})

Your harness implements and runs the search. Keep the full tools list, including deferred tools, on every request. In the system prompt, tell the model when to search:

You only have one tool right now: search_tools, which searches a catalog of many more tools. If none of your current tools can handle a request, call search_tools to find one, then call the tool it returns.

Works with vLLM, SGLang, and LFM3-compatible llama.cpp builds. For llama.cpp, use a GGUF with the current chat template or load it with --chat-template-file.

See Deferred tools and tool search for the full guide.

Fine-tuning

LFM3-1.7B is designed for easy customization for a given domain, task, or application via TRL.

Performance

Benchmarks

LFM3-1.7B can power agentic applications that used to need 9B parameters.

Edge inference

At 32K context, LFM3-1.7B prefills at least 2.5x faster and decodes at least 1.8x faster than every compared model on all three devices, while using the least memory.

GPU inference

At 1,024 concurrent requests, LFM3-1.7B can produce 3.6 billion tokens/day on one NVIDIA B300.

Training

Pre-training: two stages build LFM3-1.7B-Base on 22T tokens in total.

  • Main pre-training: compared with LFM2, the mix adds more scientific papers, repository-level code, math, and a wider range of knowledge sources.
  • Mid-training: the last 3.5T tokens use curated, higher-quality data with a larger share of agentic traces and tool calls. This stage also extends the context window to 256K tokens.

Post-training: four stages develop conversation, reasoning, and tool-use capabilities.

  • Supervised fine-tuning (SFT): 1.75T tokens across various tasks, including chat, reasoning, tool calling, and agentic traces.
  • Mixed reinforcement learning: many domains trained at once, from math and code to SQL and structured outputs. A length penalty in the reward keeps answers concise.
  • Multi-domain on-policy distillation (MOPD): six specialist RL teachers (code, math, tool use, long context, agentic work, and enterprise workflows) are distilled back into a single model.
  • Agentic RL: tasks from web browsing to office work are run inside real agent harnesses, preparing the model for deployment.

Citation

@article{liquidAI2026LFM3,
  author  = {Liquid AI},
  title   = {Introducing LFM3: Every Modality for Specialized Intelligence},
  journal = {Liquid AI Blog},
  year    = {2026},
  note    = {www.liquid.ai/blog/lfm3},
}

For questions and feedback, join Discord. For custom deployment and fine-tuning support, contact Liquid AI.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Нельзя запустить

Модели нужен код из репозитория; запуск откроется после проверки совместимости.

Класс архитектуры
Lfm3ForCausalLM
Ревизия весов
a962bfd

0 моделей