Null-Guard/LFM2.5-230M-distilled-Gemini-3.8-Flash
LFM2.5-230M-distilled-Gemini-3.8-Flash
A 230M-parameter edge model distilled from Gemini 3.8 Flash, built on Liquid AI's LFM2.5-230M architecture. This model targets the reasoning, tool-use, and instruction-following behavior of a frontier-scale teacher while keeping the memory and latency footprint of a sub-billion-parameter on-device model.
⚠️ Fill-in-required: Sections marked [FILL IN] below need your actual training details, data sources, and eval numbers before this card is publish-ready. Everything else reflects verified, public specs of the base model.Model Details
Model Description
This model is a knowledge-distilled variant of LFM2.5-230M, fine-tuned to imitate outputs generated by Gemini 3.8 Flash, Google's most recent Flash-tier release (GA as of September 2, 2026), which is optimized for long-horizon software engineering, agentic tool use, and multi-step reasoning.
The goal of this distillation is to compress a fraction of Gemini 3.8 Flash's behavior — [FILL IN target capability, e.g. "structured data extraction," "tool-calling reliability," "coding assistance"] — into a model small enough to run on CPUs, mobile NPUs, and low-power edge devices, while retaining the LFM2.5 architecture's native strengths in agentic tasks and data extraction.
Intended Uses
Recommended for:
[FILL IN, e.g. on-device agentic pipelines, structured data extraction, lightweight chat assistants]
Not recommended for:
- Reasoning-heavy workloads (advanced math, novel code generation, long creative writing) — this is a known limitation of the 230M base architecture and is unlikely to be fully resolved by distillation alone.
- Safety- or compliance-critical decisions without human review.
- Any use case prohibited under the Gemini API Terms of Service that produced the distillation data (see below).
How to Use
from transformers import AutoModelForCausalLM, AutoTokenizer, TextStreamer
model_id = "Null-Guard/LFM2.5-230M-distilled-Gemini-3.8-Flash"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
device_map="auto",
dtype="bfloat16",
)
messages = [
{"role": "user", "content": "Explain the difference between a list and a tuple in Python."}
]
inputs = tokenizer.apply_chat_template(
messages, add_generation_prompt=True, return_tensors="pt"
).to(model.device)
streamer = TextStreamer(tokenizer, skip_prompt=True)
_ = model.generate(inputs, max_new_tokens=256, streamer=streamer, temperature=0.3)Tool / Function Calling
If distilled with tool-use data, LFM2.5 models write Pythonic function calls by default (a Python list wrapped in <|tool_call_start|> / <|tool_call_end|> tokens). [FILL IN if you changed this behavior, or removed tool-calling support during distillation.]
Quantized / Edge Deployment
[FILL IN if you provide GGUF / ONNX / AWQ variants, and link them here, e.g. for llama.cpp or WebGPU deployment.]
Training Details
Training Data
[FILL IN: describe the prompt distribution used to query Gemini 3.8 Flash — e.g. size of dataset, domains covered (code, QA, tool-use), how prompts were sourced or generated, and any filtering/quality control applied to teacher outputs before training on them.]
Distillation Procedure
[FILL IN: e.g.]
- Sampled
Nprompts from[dataset/source]. - Generated teacher completions via the Gemini API (
gemini-3.8-flash), temperatureX. - Filtered/deduplicated/graded completions.
- Fine-tuned LFM2.5-230M (or LFM2.5-230M-Base) on teacher completions via
[SFT / DPO / sequence-level KD]. [Any additional RL, DPO, or preference-tuning stages.]
Hyperparameters
Evaluation
[FILL IN: benchmark table comparing this model to (a) the LFM2.5-230M base/instruct checkpoint and (b) Gemini 3.8 Flash itself, on whatever evals matter for your target task — e.g. tool-call accuracy, extraction F1, or a relevant academic benchmark. Report the teacher/student gap honestly; it's expected and useful signal for downstream users.]
Limitations
- Inherits the general limitations of the 230M-parameter base architecture: not suited for reasoning-heavy math, advanced code generation, or long-form creative writing.
- Distillation transfers style and surface behavior from the teacher, not the teacher's underlying capability — expect a meaningful capability gap versus Gemini 3.8 Flash itself, especially on out-of-distribution prompts not covered by the distillation data.
[FILL IN any biases or failure modes observed during your own evaluation.]
Compliance & Licensing
This model card and repository involve two separate licensing considerations:
- Base model weights (LFM2.5-230M): released by Liquid AI under the custom `lfm1.0` license, not a standard OSI license (e.g. Apache-2.0/MIT). Review its terms before redistributing derivative weights commercially.
- Teacher-generated training data (Gemini 3.8 Flash): synthetic data and model behavior distilled from a proprietary API is generally subject to the provider's terms of service. Google's Gemini API terms have historically restricted using API outputs to train or improve models that compete with Google's own models — this may affect how (or whether) you can license, redistribute, or commercialize this checkpoint. This is not legal advice; consult the current Gemini API Additional Terms of Service and/or counsel before publishing or commercial release.
[FILL IN your own chosen license for this repo's incremental contributions, consistent with the above.]
Citation
@misc{lfm2.5-230m-distilled-gemini,
title = {LFM2.5-230M-distilled-Gemini-3.8-Flash},
author = {Null-Guard},
year = {2026},
note = {Distilled from Gemini 3.8 Flash on the LFM2.5-230M architecture}
}Please also cite the base model:
@misc{lfm2.5,
title = {LFM2.5: On-device hybrid language models},
author = {Liquid AI},
year = {2026},
url = {https://huggingface.co/LiquidAI/LFM2.5-230M}
}Acknowledgements
Built on LiquidAI/LFM2.5-230M. Distilled using outputs from Google's Gemini 3.8 Flash.
