litetune fine-tunes a small language model, converts it into a file that runs on a phone, and checks that the converted model still does the job.
Supported runtimes
LiteRT-LM
Google's on-device LLM runtime
$pip install litetune
$
brew install DenisovAV/tap/litetune
Why it exists
Converting a model so it fits on a device changes it. The file still loads, the tools still report success, and the model can still be worse at your task than it was before. litetune runs the converted model on data it was never trained on, compares it with the version it came from, and tells you the difference.
Supported formats
Output
.litertlm — the format LiteRT-LM loads
Platforms
Android, iOS, macOS, Linux and Windows natively
— web runs as a text-only preview with no function calling and no LoRA, so a tuned tool-calling model is native-only for now
Acceleration
CPU everywhere; GPU through OpenCL, Metal, Vulkan or DirectX 12; NPU on Snapdragon and Intel
— litetune measures on CPU, and every result records which backend produced it
Models
Gemma 3, Gemma 4, Qwen 3.5, FunctionGemma
— measured end to end on FunctionGemma so far
Where to run it
flutter_gemma
A Flutter plugin that runs .litertlm through the LiteRT-LM C API on five native platforms and a web preview. The same package also does embeddings and RAG.
Google AI Edge Gallery
Google's Android app for running local models on the device. Side-load the file to try it without writing an app first.
What it does
prepare
splits your data and drops the rows it cannot score
tune
fine-tunes it, with the settings the export step will need
convert
turns the result into the file the phone runtime loads
verify
compares that file with the model it came from
bundle
packages it together with what the comparison found