LiraNuna/LFM3-1.7B

A loop-fixed, reasoning-uplifted drop-in successor to LiquidAI/LFM3-1.7B, verified across ~43,000 benchmark items with zero benchmark contamination.


The Problem: Compulsive <think> Loops & Non-Thinking Leaks

LiquidAI/LFM3-1.7B is a remarkably strong 1.7B tri-hybrid reasoning model, but in real-world deployment and deterministic evaluation (do_sample=False), it suffers from three recurring failure modes:

  1. Compulsive <think> Re-Checking Loops: On multi-step logic, STEM, coding, and constrained-writing tasks, the model frequently enters endless self-doubt cycles inside <think> ("Wait, let me double-check... Alternatively, what if..."), burning through 2Kโ€“8K+ tokens without ever emitting </think> or producing a final answerโ€”looping on 97% of logic-grid puzzles, 29.5% of MMLU-Pro STEM (@ 4K), 15.2% of HumanEval (@ 4K), and 50.8% of IFEval (@ 2K).
  2. <think> Leakage When enable_thinking=False: On long-context retrieval tasks (RULER 4K/16K), the base model ignores enable_thinking=False and opens <think> anyway, exhausting short answer budgets (67.7% accuracy).
  3. Tool Over-Calling on Irrelevant Queries: On real-world irrelevant tool prompts (BFCL live_irrelevance), the base model invokes functions when no matching tool applies (68.6%).

How We Fixed It (Zero Eval-Set Overlap)

Rather than heavy SFTโ€”which typically degrades small models' knowledge and tool precisionโ€”we used a lightweight two-stage surgical pipeline:

  1. Weight-Space Programming (WSP): Inspired by Sparks of Weight-Space Programming (Takehi et al., MIT CSAIL), we probed feed_forward.w2 MLP activations at the exact token positions preceding compulsive re-check triggers (Wait, Let, Alternatively, Check, Hmm) versus clean </think> closures across layers 14, 20, 22, 23. Editing only the top k=64 loop-driving neurons per layer (0.0303% of parameters, zero gradient steps) while protecting tool-abstention and safety circuits immediately broke the vast majority of thinking loops.
  2. Multi-Teacher Top-64 KL Self-Distillation (r=8 LoRA, merged to bf16): Starting from the WSP model, we ran tight Top-64 KL self-distillation (lr โ‰ˆ 5e-5, 2 epochs) combining:
    • Strictly cleanly-closed (single </think>, 0 <tool_call>) reasoning/coding traces from official train splits (GSM8K train, MBPP train, ARC-Challenge train) and synthetic constrained-writing prompts.
    • Zero-overlap synthetic REST API abstention prompts (lifting BFCL live_irrelevance without hurting valid calls).
    • Zero-overlap synthetic long-context MK-NIAH/VT prompts (enable_thinking=False) with token-0 <think> hinge suppression (eliminating non-thinking <think> leaks on RULER).
    • Hard-mined synthetic 3-shot no-tool boundary suppression (eliminating hallucinated <tool_call> emissions when no <tools> schema is provided).
    • Zero-overlap synthetic factual passages anchored to Raw Base raw yes/no log-odds (preserving unprompted reading-comprehension calibration without touching BoolQ).

Zero Contamination: No validation or test items from any benchmark reported below were ever seen during training.


Before vs. After โ€” Scores & Loop Reduction (~43,000 Items)

All evaluations were run identically in bfloat16 (attn_implementation="sdpa", deterministic greedy decoding do_sample=False, </think>-stripped final-answer scoring). no_close counts responses that hit the token cap without ever emitting </think>.

1. High-Budget Reasoning, Coding, STEM & Instruction Following (4K / 8K Token Caps)

Benchmark n Max Tokens Base Score LiraNuna Score Score Delta Base Loops (no_close) LiraNuna Loops Loop Reduction
HumanEval FULL (unseen) 164 4,096 85.37% (140) 89.63% (147) +4.26% 25 (15.2%) 2 (1.2%) -92.0%
MMLU-Pro STEM CoT (unseen) 400 4,096 66.00% (264) 70.75% (283) +4.75% 118 (29.5%) 1 (0.25%) -99.2%
โ”œโ”€ Chemistry 80 4,096 67.5% 77.5% +10.0% 19 0 -100%
โ”œโ”€ Math 80 4,096 87.5% 93.8% +6.3% 11 0 -100%
โ”œโ”€ Computer Science 80 4,096 62.5% 67.5% +5.0% 22 1 -95.5%
โ”œโ”€ Engineering 80 4,096 36.2% 40.0% +3.8% 51 0 -100%
โ””โ”€ Physics 80 4,096 76.2% 75.0% -1.2% 15 0 -100%
IFEval FULL (p-strict / p-loose) 541 8,192 88.91% / 90.94% 88.72% / 91.68% -0.19% / +0.74% 37 (6.8%) 3 (0.55%) -91.9%
โ””โ”€ IFEval inst-strict / inst-loose 541 8,192 91.49% / 92.81% 92.57% / 94.48% +1.08% / +1.67% 12,249 chars 6,356 chars -48.1% length
MATH-500 FULL (unseen) 500 8,192 85.80% (429) 83.20% (416) -2.60% 31 (6.2%) 2 (0.4%) -93.5%
MBPP FULL 500 4,096 72.40% (362) 66.00% (330) -6.40% 76 (15.2%) 0 (0.0%) -100.0%
Combined 4K/8K Total 2,105 โ€” โ€” โ€” โ€” 287 (13.63%) 8 (0.38%) -97.2%

2. Strict-Budget Latency & Conciseness Stress Test (1K / 2K Token Caps)

Benchmark n Max Tokens Base Score LiraNuna Score Score Delta Base Loops (no_close) LiraNuna Loops Loop Reduction
GSM8K FULL (flex / strict) 1,319 2,048 90.67% / 27.29% 92.57% / 48.60% +1.90% / +21.31% 55 (4.2%) 6 (0.45%) -89.1%
IFEval FULL (p-strict / i-strict) 541 2,048 57.49% / 64.87% 75.42% / 80.94% +17.93% / +16.07% 275 (92 rep) 88 (19 rep) -68.0% (-79% rep)
MATH-500 FULL (unseen) 500 2,048 67.40% (337) 73.40% (367) +6.00% 124 (24.8%) 58 (11.6%) -53.2%
HumanEval FULL (unseen) 164 1,024 42.07% (69) 53.66% (88) +11.59% 115 (70.1%) 67 (40.9%) -41.7%
MBPP FULL 500 1,024 41.00% (205) 48.20% (241) +7.20% 287 (57.4%) 105 (21.0%) -63.4%
Logic-Grid Puzzles (2 splits) 106 4,096 20.8% parse (1.1% cell) 84.0% parse (7.9% cell) +63.2% parse 103 (97.2%) 7 (6.6%) -93.2%

3. Multi-Step Logic โ€” ALL 13 BBH Tasks (n = 3,146, 2K Cap)

BBH Suite / Task n Base Score LiraNuna Score Score Delta Base Loops LiraNuna Loops
7-Task Core BBH Combined 1,750 81.03% (1,418) 84.00% (1,470) +2.97% (+52) 284 (81 rep) 36 (7 rep, -91%!)
6 Unseen BBH Combined 1,396 74.93% (1,046) 82.59% (1,153) +7.66% (+107) 260 39 (-85.0%)
โ”œโ”€ web_of_lies (unseen) 250 98.40% 100.00% +1.60% 1 0
โ”œโ”€ navigate (unseen) 250 74.40% 94.80% +20.40% 50 4
โ”œโ”€ tracking_shuffled_objects_7 (unseen) 250 42.00% 62.00% +20.00% 78 12
โ”œโ”€ geometric_shapes (unseen) 250 60.00% 61.20% +1.20% 125 22 (0 <tool_call>)
โ”œโ”€ penguins_in_a_table (unseen) 146 78.77% 78.77% 0.00% 3 0
โ””โ”€ reasoning_about_colored_objects (unseen) 250 97.60% 97.20% -0.40% 3 1
ALL 13 BBH TASKS COMBINED 3,146 78.32% (2,464) 83.38% (2,623) +5.06% (+159) 544 75 (-86.2%)

4. Tool Calling โ€” ALL 12 BFCL v4 Splits (n = 3,625, enable_thinking=False)

BFCL v4 Split n Base Score LiraNuna Score Score Delta
Main 7 Splits (simple_python, multiple, parallel, irrelevance, live_multiple, live_parallel, live_irrelevance) 2,993 77.45% (2,318) 79.89% (2,391) +2.44% (+73)
โ””โ”€ Highlight: live_irrelevance 884 68.60% (606) 76.02% (672) +7.42% (+66)
Unseen 5 Splits (live_simple, simple_java, simple_javascript, parallel_multiple, live_parallel_multiple) 632 71.68% (453) 72.47% (458) +0.79% (+5)
ALL 12 BFCL v4 SPLITS 3,625 76.44% (2,771) 78.59% (2,849) +2.15% (+78)

5. Long-Context & Zero-Forgetting General Suite (~31,700 Items)

Benchmark n Base Score LiraNuna Score Delta
RULER 4K + 16K (S-NIAH, MK-NIAH, VT) 96 67.71% (65/96) 98.96% (95/96) +31.25% (+30)
AA-LCR 100K-tok (lexical proxy) 30 12/30 (1,529s) 13/30 (1,258s) +1 (18% faster)
TruthfulQA MC2 FULL 817 52.56% 64.58% +12.02%
ARC-Challenge FULL (acc / acc_norm) 1,172 24.06% / 26.28% 26.45% / 28.84% +2.39% / +2.56%
MMLU FULL (57 subjects) 14,042 49.59% 49.73% +0.14%
MMLU-Pro (5-shot direct LL, no CoT) 1,000 20.90% 21.10% +0.20%
HellaSwag FULL (acc / acc_norm) 10,042 41.09% / 53.68% 41.67% / 54.19% +0.58% / +0.51%
BoolQ FULL 3,270 75.57% 75.02% -0.55%
WinoGrande FULL 1,267 54.93% 54.46% -0.47%
WikiText-2 Word PPL (lower = better) 62 docs 16.78 (0.7609 bpb) 16.87 (0.7623 bpb) +0.09 (flat)

Recommended Decoding Settings

  • Deterministic Math / Code / Logic / Tool Calling: do_sample=False, max_new_tokens=4096 (or 8192 for competition math / complex multi-constraint writing).
  • General Chat: temperature=0.1, top_k=50, repetition_penalty=1.1 (default generation_config.json).

Limitations & Trade-Offs

  • Because LiraNuna/LFM3-1.7B terminates <think> much more decisively (cutting unclosed runs by -97.2% and halving IFEval output length), at very high token budgets (4Kโ€“8K) it trades a small margin on MATH-500 @ 8K (83.2% vs. 85.8%, -2.6%) and MBPP @ 4K (66.0% vs. 72.4%, -6.4%, 0/500 loops), while substantially outperforming the base model on HumanEval @ 4K (+4.26%), MMLU-Pro STEM @ 4K (+4.75%), IFEval @ 8K (loose/inst), GSM8K (+1.90%), 13-Task BBH (+5.06%), BFCL (+2.15%), RULER (+31.25%), and every 1Kโ€“2K latency-bounded benchmark.
  • Inherits the 1.7B parameter capacity of LiquidAI/LFM3-1.7B on long-tail factual trivia.

License, Attribution & Modification Notice

  • Base Model & Copyright: This model is a community derivative work of LiquidAI/LFM3-1.7B (Copyright ยฉ Liquid AI, Inc.), independently fine-tuned and not endorsed by Liquid AI.
  • License: Distributed under the LFM Open License v1.0 (lfm1.0). A verbatim copy is included in the repository root (LICENSE). Please review Section 5 (the $10M USD annual revenue threshold for free commercial use) before commercial deployment.
  • Modified Files Notice (Section 4):
    • Modified: model.safetensors (weights updated via Weight-Space Programming and merged r=8 LoRA Top-64 KL self-distillation) and README.md (this model card).
    • Unmodified from LiquidAI/LFM3-1.7B: config.json, configuration_lfm3.py, modeling_lfm3.py, lfm3_conv.py, generation_config.json, chat_template.jinja, tokenizer.json, tokenizer_config.json, special_tokens_map.json, and LICENSE.
Downloads last month
-
Safetensors
Model size
2B params
Tensor type
BF16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for LiraNuna/LFM3-1.7B

Finetuned
(100)
this model
Quantizations
1 model