Litert Lm

Builds an Android app that runs an open text LLM on the device, on the CPU or the GPU, with the LiteRT-LM Kotlin API (com.google.ai.edge.litertlm:litertlm-android). Use this skill when creating a chat, summarization, or extraction feature with a .litertlm model from Hugging Face litert-community (Gemma, Qwen, Llama, Phi), including the Gradle dependency, the GPU manifest entries, getting the model file onto the device, Engine initialization off the main thread, a streamed multi-turn Conversation with sendMessageAsync, and the AndroidViewModel and Compose screen. Don't use for running .tflite v

499 stars 134 forksMobile Development

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add google-ai-edge/litert-samples --skill litert-lm
Manual install
git clone --depth 1 https://github.com/google-ai-edge/litert-samples.git /tmp/litert-samples
mkdir -p ~/.claude/skills
cp -r /tmp/litert-samples/skills/android/litert-lm ~/.claude/skills/litert-lm

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

This skill provides step-by-step guidance for building an Android app that runs
an open text LLM through the LiteRT-LM Kotlin API
(`com.google.ai.edge.litertlm`) on the CPU or the GPU. The model is one
`.litertlm` file. Images, audio, tool calling, and NPU backends aren't covered.
For vision and audio models with `.tflite` files, suggest the `litert-runtime`
skill.

When a LiteRT-LM class or method that this skill uses doesn't compile, you must
read the [LiteRT-LM Android guide](https://ai.google.dev/edge/litert-lm/android) and the [LiteRT-LM README](https://github.com/google-ai-edge/LiteRT-LM/blob/main/README.md) before
changing the code.

## Prerequisites

- A Kotlin Android project (the Android Studio Empty Activity template is enough). The `litertlm-android` 0.18.0 AAR declares `minSdk` 24.
- The dependency in the app-level `build.gradle.kts` file from Google Maven: `implementation("com.google.ai.edge.litertlm:litertlm-android:0.18.0")`. Google Maven lists the later releases.
- For the GPU backend, two `uses-native-library` entries inside `<application>` in `AndroidManifest.xml`. Add the `INTERNET` permission if the app downloads the model.
- The model file lives on the device's file system (hundreds of MB to a few GB), never in `assets/` or in the APK.

## Critical mandates
Read the full skill on GitHub

Details

Skill name
litert-lm
Path
skills/android/litert-lm/SKILL.md
License
Apache-2.0
Repo updated
17 November 2026
Copies
Found in 2 GitHub repos

FAQ

What does the Litert Lm skill do?

Builds an Android app that runs an open text LLM on the device, on the CPU or the GPU, with the LiteRT-LM Kotlin API (com.google.ai.edge.litertlm:litertlm-android). Use this skill when creating a chat, summarization, or extraction feature with a .litertlm model from Hugging Face litert-community (Gemma, Qwen, Llama, Phi), including the Gradle dependency, the GPU manifest entries, getting the model file onto the device, Engine initialization off the main thread, a streamed multi-turn Conversation with sendMessageAsync, and the AndroidViewModel and Compose screen. Don't use for running .tflite v

How do I install the Litert Lm skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add google-ai-edge/litert-samples --skill litert-lm. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Litert Lm popular?

It lives in google-ai-edge/litert-samples, which has 499 GitHub stars and 134 forks.

Related skills

Litert Runtime

499

google-ai-edge/litert-samples

Configures and implements LiteRT (.tflite) on-device inference on Android in Kotlin using the CompiledModel API on CPU and GPU. Use this skill for any Android LiteRT or .tflite task, including Gradle setup, image classification or vision/audio/embedding helpers, TensorBuffer reuse, CPU memory optimization, Bitmap preprocessing, AndroidViewModel GPU-to-CPU fallback with warm-up on a single-thread dispatcher, LiteRT in Google Play services (play-services-litert), migrating from legacy org.tensorflow.lite.Interpreter, GpuDelegate, or play-services-tflite, and latency benchmarking. Don't use for r

Mobile Development134

Accuracy Safe Quantization

499

google-ai-edge/litert-samples

Shrink a converted LiteRT model with ai-edge-quantizer (fp16 / int8 / int4) without losing accuracy, verifying parity against the float source after every step. Use when choosing a quantization recipe for a new model, when a quantized model fails to load, degrades on a task benchmark, or degenerates over long generations, or when deciding between dynamic-range, weight-only, and blockwise variants.

AI, LLMs & Agents134

Benchmark on Ddp

499

google-ai-edge/litert-samples

Measure a LiteRT .tflite model with `benchmark_model` on Developer Device Platform (DDP) lab phones through `litert benchmark --ddp`, or on the Mac you run it from, and turn the session into rows of the performance leaderboard under benchmark/leaderboard - one matrix entry per model, one session per accelerator, collect results.pb and runtime_info.pb, rebuild board.json, check the page, commit the data. Use when a model needs latency and memory numbers per platform, device and accelerator, or when a new benchmark_model release means re-measuring the board.

AI, LLMs & Agents134

Senior Mobile

1.2k

borghei/Claude-Skills

Mobile development across SwiftUI, Jetpack Compose, React Native (Expo) and Flutter: scaffolding, feature architecture, static performance checks and store listings. Use when building, optimizing or shipping a mobile app.

Mobile DevelopmentIn 1 list217

Swiftui Iphone Duo

470

FloWritesCode/fwc-swiftui-skills

Adapts and reviews SwiftUI apps for iPhone Duo (Xcode 27.1 / iOS 27.1 SDK) and continuously changing window sizes. Use when supporting the foldable iPhone Duo, outer or inner display, vertical bars (toolbarVerticalBehavior, axisBehavior, visibilityPriority, ToolbarOverflowMenu), sheet placement, reserved regions and the fold, ArrangementView, onHingeChange, CameraCaptureAccessory, NavigationSplitView, adaptive TabView sidebar, ViewThatFits, AnyLayout, or when replacing UIDevice / UIScreen.main / idiom / orientation layout branches.

Mobile Development23

Xcode Project Setup

519

firebase/agent-skills

Safely modifies Xcode projects (.pbxproj) to add Swift Packages and link files. Use this skill whenever an iOS project needs dependencies installed (e.g. Firebase, Alamofire).

Mobile Development116

Browse the most popular Claude skills, all mobile development skills, or write your own with the skills generator.