🔍 Read the full analysis: Stepwise Fine-tuning Of 350M AI Models To Enhance Output Clarity And Structure on ThorstenMeyerAI.com
TL;DR
Liquid AI has publicly shared a low-cost, reproducible fine-tuning recipe for its 350-million-parameter LFM2.5 model, using Group Relative Policy Optimization (GRPO). The method improves the model’s accuracy in producing structured outputs, raising scores from 22.6% to 29.7% on the IFStruct benchmark with just 500 samples and 100 steps, accessible on free-tier hardware.
Liquid AI has published a fully open-source, low-cost fine-tuning recipe that improves the output structure compliance of its 350M-parameter LFM2.5 model as detailed in the original analysis. The method, utilizing Group Relative Policy Optimization (GRPO), increases the model’s score on the IFStruct benchmark from 22.6% to 29.7% after approximately 500 training samples and 100 training steps. This development makes high-quality schema adherence achievable on modest hardware, such as free-tier GPUs, and aims to demonstrate that small models can be task-optimized with minimal resources. For more details, see the original analysis.
The fine-tuning process was carried out using a publicly available recipe on GitHub, which pairs the GRPO technique with the TRL library for training and llama.cpp for local evaluation. The entire pipeline was designed to run on inexpensive hardware, including free-tier Colab or Kaggle GPUs, making it accessible for individual developers and small teams. The base model was evaluated locally on a MacBook Pro with an Apple M5 Max processor, using a BF16 GGUF build of LFM2.5-350M, and achieved a baseline score of 22.6% on the IFStruct test set, close to the original report of 21.1%. After the fine-tuning, the model’s performance increased to 29.7%, with notable improvements in JSON and YAML output accuracy.
The training data originated from NVIDIA’s Nemotron-RL-instruction_following-structured_outputs dataset, which pairs prompts with JSON schemas. To improve format adherence, the authors augmented prompts with instructions to return outputs inside fenced code blocks in 40% of cases. Errors in output, such as missing required fields, wrong item counts, and type mismatches, were identified as the main failure points, with the most significant gains observed in passing JSON tests—from 18% to nearly 30%. The results varied widely across different output types and tasks, with the lowest success rate on recipes at 4.3% and higher on event ticket bookings at 45.8%.
Impact of Low-Cost Fine-tuning on Small Models
This development demonstrates that small, publicly available models can be significantly improved in their ability to produce structured, schema-compliant outputs with minimal fine-tuning. The approach lowers barriers for developers lacking large training budgets, enabling task-specific optimization on inexpensive hardware. The roughly seven-percentage-point increase on the IFStruct benchmark suggests that small models can be brought closer to larger models’ performance levels in structured output tasks, which are critical for real-world applications like data extraction, form filling, and automation.
While the improvement is modest, its cost-effectiveness and reproducibility make it a valuable contribution to the field. It challenges the assumption that only large, resource-intensive models can reliably generate structured data, opening avenues for democratized AI development and deployment in constrained environments.
GPU cloud computing for AI training
As an affiliate, we earn on qualifying purchases.
As an affiliate, we earn on qualifying purchases.
Background on Structured Output and Fine-tuning Efforts
Structured output tasks, such as JSON or YAML generation, are common in practical AI applications but remain challenging for smaller models. Historically, benchmarks have bundled these tasks with broader reasoning assessments, making isolated evaluation difficult. The IFStruct benchmark was introduced to address this gap, providing a standardized way to measure schema adherence in language model outputs. Prior efforts focused on large models or complex training pipelines, often inaccessible to individual developers due to high costs.
Liquid AI’s recent publication builds on this landscape by offering an accessible, minimal-resource method to enhance small model performance. The approach leverages a lightweight, open-source recipe that combines data augmentation, a specialized fine-tuning algorithm (GRPO), and local evaluation, making it feasible for hobbyists and small teams to implement and experiment with.
“This lightweight fine-tuning approach shows that small models can achieve meaningful improvements in schema compliance without extensive resources.”
— Thorsten Meyer, Liquid AI
As an affiliate, we earn on qualifying purchases.
Limitations and Generalization of Results
It is not yet clear how well these gains generalize to other datasets or structured-output tasks beyond IFStruct. The reported improvements are based on a specific benchmark and a particular setup, and the stability of results across different hardware, quantizations, or larger-scale fine-tuning remains untested. Additionally, the comparison between local baseline scores and published benchmark figures suggests some measurement variability, and the exact impact on real-world applications needs further validation.
Further research is required to determine whether similar methods can be effectively scaled or adapted to other small models and tasks, and whether the observed performance improvements hold under different deployment conditions.
As an affiliate, we earn on qualifying purchases.
Next Steps for Community Adoption and Testing
The authors have made the entire fine-tuning pipeline publicly available, encouraging others to reproduce and build upon their work. Future efforts are expected to explore scaling the sample size and step count, testing quantized models, and applying the GRPO recipe to other structured output tasks. Additional validation across different hardware setups and benchmarks will help establish the robustness and generalizability of these improvements. Community engagement and experimentation will be key to assessing the broader impact of this approach.
As an affiliate, we earn on qualifying purchases.
Key Questions
Can this fine-tuning method be applied to larger models?
While the current demonstration focuses on a 350M parameter model, the underlying principles of GRPO and data augmentation could be adapted for larger models, though additional resources and experimentation are needed to confirm effectiveness.
Is the fine-tuning process suitable for real-world applications?
Yes, especially for small models used in data extraction, form filling, or automation tasks, where schema compliance is critical. The low resource requirement makes it accessible for deployment in constrained environments.
How much improvement does the method achieve?
The reported increase on the IFStruct benchmark is approximately seven percentage points, from 22.6% to 29.7%, after a minimal fine-tuning run with around 500 samples and 100 steps.
What hardware is needed to reproduce these results?
The pipeline is designed to run on inexpensive hardware, including free-tier GPUs from Colab or Kaggle, and evaluation can be performed locally on a MacBook Pro with an Apple M5 Max processor.
Does this approach outperform larger models?
The publication does not claim that the fine-tuned small model surpasses larger models, only that it approaches their performance in specific structured output tasks with minimal resources.
Primary source: Hugging Face · via ThorstenMeyerAI.com