Instructions to use litert-community/Qwen2.5-1.5B-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- LiteRT-LM
How to use litert-community/Qwen2.5-1.5B-Instruct with LiteRT-LM:
# LiteRT-LM runs on various platforms (Android, iOS, Windows, Linux, macOS, IoT, Web/WASM) # and supports many APIs (C++, Python, Kotlin, Swift, JavaScript, Flutter). # For platform-specific integration guides, please refer to the official developer website: # https://ai.google.dev/edge/litert-lm # To try LiteRT-LM, the easiest way is to use our CLI tool. # 1. Install the LiteRT-LM CLI tool: pip install -U litert-lm # 2. Download and run this model locally: # See: https://ai.google.dev/edge/litert-lm/cli litert-lm run \ --from-huggingface-repo=litert-community/Qwen2.5-1.5B-Instruct \ --prompt="Write me a poem"
- Notebooks
- Google Colab
- Kaggle
Add int4 (wi4b64) quantized variant
This PR adds an int4 (wi4b64) dynamic-range quantized .litertlm variant: Qwen2.5-1.5B-Instruct_wi4b64_ekv4096.litertlm (790 MB, external KV cache length 4096).
Toolchain / pipeline (unpack β quantize β repack):
litert-lm-peekdump of the official f32.litertlmrelease in this repository.ai-edge-quantizer0.8.0 post-training dynamic-rangedynamic_wi4b64_afp32(int4 weights, blockwise-64, fp16 scales, fp32 activations) applied full-scope to the TFLite section.- Rebuilt with
litert-lm-builder0.14.0; tokenizer and LlmMetadata mirrored from the official q8 release. Resulting.litertlmformat 1.5.0.
Source checkpoint: litert-community/Qwen2.5-1.5B-Instruct f32 release.
Validation: inference-validated on Windows x86_64 CPU β 59.7 tok/s prefill / 11.8 tok/s decode β with correct Korean QA output.
Runtime tested: LiteRT-LM v0.14.0, Windows x86_64 (CPU/GPU); the project's Android arm64 (Snapdragon 865) pipeline runs the same format (device throughput not benchmarked for this file).
Known caveat: the metadata carries lowercase model_type (tf_lite_prefill_decode) vs uppercase in the official files β loads fine on LiteRT-LM v0.14.0, noted for completeness.
Produced by the LiteRT-LM-Unity project (https://github.com/Leuconoe/LiteRT-LM-Unity, release v0.14.0-unity).