Generated banner for Litert Lm
Generated logo for Litert Lm

Litert Lm

Android (Google)OfficialCreated by Google LLCDistributed by Android (Google)

  • Skill
  • Tool integration
  • Data and AI
  • Apache-2.0
  • No issues found

From the author

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 vision, audio, or embedding models with the CompiledModel API, for image or audio input, tool calling, or NPU backends, or for converting models.
— the description by Google LLC

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

This skill provides a comprehensive guide for developers to implement on-device LLM capabilities in Android applications using the LiteRT-LM Kotlin API. It covers the end-to-end process from configuring Gradle dependencies and Android manifest requirements to managing the engine lifecycle, handling model file storage, and building a reactive UI with Jetpack Compose. The skill emphasizes best practices for performance, such as off-main-thread initialization, single-thread executor management, and proper resource cleanup to ensure stable and responsive AI features.

What it does

  • Configures Android projects for LiteRT-LM integration including Gradle and manifest settings.
  • Provides patterns for background engine initialization to prevent UI blocking.
  • Demonstrates how to implement a ViewModel for managing conversation state and streaming responses.
  • Offers guidance on handling model files on the device filesystem.
  • Includes boilerplate for a Jetpack Compose UI to interact with the LLM.
  • Outlines lifecycle management to safely handle engine and conversation resources.

When to use it

  • When you need to add chat, summarization, or text extraction features to an Android app.
  • When you want to run open LLMs like Gemma, Qwen, Llama, or Phi locally on the device.
  • When you require CPU or GPU-accelerated inference for text models.
  • When you are building an app that needs to handle large model files outside of the APK.

Advantages

  • Enables private, offline-capable AI features within Android applications.
  • Provides structured guidance on avoiding common pitfalls like main-thread blocking.
  • Includes specific instructions for GPU acceleration and dependency management.
  • Promotes robust lifecycle management for resource-intensive AI engines.

Usage examples

“How do I add the LiteRT-LM dependency to my Android project?”
The agent provides the specific implementation line for build.gradle.kts and explains the necessary minSdk requirements.
“Show me how to initialize the LiteRT-LM engine in a ViewModel.”
The agent provides a code snippet demonstrating the use of a single-thread executor and EngineConfig to initialize the model off the main thread.

Install

  1. Download the skill as a ZIP:

    https://mp-staging.autogineer.com/agent-skills/android/litert-lm/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip litert-lm.zip -d .agents/skills

Documentation by Google LLC

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 and the LiteRT-LM README 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

  • Dependency first : Before writing code that imports com.google.ai.edge.litertlm, add the litertlm-android dependency from Step 1 if the project lacks it. Verify with ./gradlew assembleDebug.

  • Background initialization : Engine(config).initialize() loads the weights and blocks for seconds. Call it on a background thread, never on the main thread.

  • Single owner : One single-thread executor owns the Engine and the Conversation. Creation, streaming, cancellation, and closing run on it.

  • Close once : Engine and Conversation are AutoCloseable. A second close on either throws IllegalStateException. So does close on an engine whose initialize threw. Store the engine only after initialize returns.

  • Model outside the APK : Pass an absolute path to EngineConfig. Never bundle a .litertlm file in assets/.

Detailed steps

Step 1: Configure Gradle and the manifest

Search the project for libs.versions.toml, app/build.gradle.kts, and AndroidManifest.xml before editing build files. Configure minSdk and add the LiteRT-LM dependency in app/build.gradle.kts:

<br />

android {
    defaultConfig {
        minSdk = 24
    }
}

dependencies {
    implementation("com.google.ai.edge.litertlm:litertlm-android:0.18.0")
}

If the project uses Hilt, check the Dagger version first. litertlm-android 0.18.0 carries Kotlin 2.4 metadata, which Hilt 2.59.2 can't read. The build then fails in hiltJavaCompileDebug with Provided Metadata instance has version 2.4.0, while maximum supported version is 2.3.0. Pick one fix:

  • Path A : Upgrade the Hilt version (com.google.dagger) to 2.60.1 or later. Ask the user before editing gradle/libs.versions.toml.

  • Path B : Keep the Hilt version and add a later version of the metadata reader to the annotation processor path in app/build.gradle.kts:

<br />

dependencies {
    ksp("org.jetbrains.kotlin:kotlin-metadata-jvm:2.4.21")
}

For the GPU backend, add both lines inside <application> in AndroidManifest.xml. Add the INTERNET permission outside <application> when the app downloads the model:

<br />

<uses-permission android:name="android.permission.INTERNET"/>

<application>
    <uses-native-library
        android:name="libvndksupport.so"
        android:required="false"/>
    <uses-native-library
        android:name="libOpenCL.so"
        android:required="false"/>
</application>
Step 2: Pick a model from litert-community

Choose a .litertlm file from litert-community on Hugging Face. Start with litert-community/gemma-4-E2B-it-litert-lm (the file gemma-4-E2B-it.litertlm, 2.6 GB). For a 0.6 GB model, start with litert-community/Qwen3-0.6B (the file Qwen3-0.6B.litertlm). Both files run on the CPU and the GPU. A SoC suffix such as _Google_Tensor_G5 or .mediatek.mt6993 marks an NPU build, which this skill doesn't cover. The model card names the tested backends and the size.

You must read get a model before you choose a model file other than these two, before you write the in-app download code, and when no .litertlm file exists for the model.

Step 3: Put the model file on the device

Pick one path:

  • Path A (local testing with adb) : Run the following commands only when all three are true: adb devices lists a device, the debug build of the app is installed on it, and the user supplied the local .litertlm path. If any of them is false, don't run the commands. Report them to the user as a post-implementation step instead. Replace <path> with the user's local path and <package> with the app's application ID:

    1. adb push <path> /data/local/tmp/model.litertlm

    2. adb shell run-as <package> cp /data/local/tmp/model.litertlm files/

  • Path B (in-app download) : Write the download code in the app. Use the app's HTTP client to write into filesDir, or DownloadManager to write into getExternalFilesDir(null). DownloadManager can't write to internal storage. Show the download progress and check the file size against the model card before loading. Never download a model file in the agent's own session.

  • Path C (Play for On-Device AI) : Write the code that resolves the path of a fast-follow or on-demand AI pack with the AI Delivery library (com.google.android.play:ai-delivery): AiPackManagerFactory.getInstance(context).getPackLocation(name)?.assetsPath(). The call returns null until the pack has finished downloading, so show a download state in that case. Creating the AI pack module and uploading the app to Play Console are post-implementation steps for the user.

On every path, pass the absolute path of the file to the engine.

Step 4: Initialize the engine off the main thread

Create the engine with EngineConfig(modelPath = ..., backend = ..., cacheDir = ...) and call initialize on a background thread:

  • Backend.CPU() is the default of EngineConfig and needs nothing from the device.

  • Backend.GPU() needs the two manifest lines from Step 1. Without them, the engine initializes, and the first reply ends in the error Can not find OpenCL library on this device.

  • cacheDir speeds up the second load.

Step 5: Implement the conversation ViewModel

Drive the engine and the conversation from a single-thread executor inside an AndroidViewModel, stream the reply, and expose immutable state to the UI:

<br />

import android.app.Application
import androidx.lifecycle.AndroidViewModel
import com.google.ai.edge.litertlm.Backend
import com.google.ai.edge.litertlm.Contents
import com.google.ai.edge.litertlm.Conversation
import com.google.ai.edge.litertlm.ConversationConfig
import com.google.ai.edge.litertlm.Engine
import com.google.ai.edge.litertlm.EngineConfig
import java.util.concurrent.Executors
import kotlin.coroutines.cancellation.CancellationException
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.SupervisorJob
import kotlinx.coroutines.asCoroutineDispatcher
import kotlinx.coroutines.cancel
import kotlinx.coroutines.delay
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.StateFlow
import kotlinx.coroutines.flow.asStateFlow
import kotlinx.coroutines.flow.update
import kotlinx.coroutines.launch
import kotlinx.coroutines.sync.Mutex
import kotlinx.coroutines.sync.withLock

data class ChatState(
    val ready: Boolean = false,
    val busy: Boolean = false,
    val reply: String = "",
    val error: String? = null
)

class ChatViewModel(app: Application) : AndroidViewModel(app) {
    private val executor = Executors.newSingleThreadExecutor()
    private val scope = CoroutineScope(
        SupervisorJob() + executor.asCoroutineDispatcher()
    )
    private val mutex = Mutex()
    private var engine: Engine? = null
    private var conversation: Conversation? = null
    private val _state = MutableStateFlow(ChatState())
    val state: StateFlow<ChatState> = _state.asStateFlow()

    fun load(modelPath: String, backend: Backend = Backend.CPU()) {
        scope.launch {
            mutex.withLock {
                if (engine?.engineConfig?.modelPath == modelPath) return@launch
                release()
                try {
                    val config = EngineConfig(
                        modelPath = modelPath,
                        backend = backend,
                        cacheDir = getApplication<Application>().cacheDir.path
                    )
                    engine = Engine(config).also { it.initialize() }
                    conversation = checkNotNull(engine).createConversation(
                        ConversationConfig(
                            systemInstruction =
                                Contents.of("You are a helpful assistant.")
                        )
                    )
                    _state.value = ChatState(ready = true)
                } catch (e: Exception) {
                    release()
                    _state.value = ChatState(error = e.message)
                }
            }
        }
    }

    fun send(text: String) {
        scope.launch {
            if (!_state.value.ready || _state.value.busy) return@launch
            _state.update { it.copy(busy = true, reply = "", error = null) }
            try {
                val replies = checkNotNull(conversation).sendMessageAsync(text)
                replies.collect { message ->
                    _state.update { it.copy(reply = it.reply + message) }
                }
            } catch (e: CancellationException) {
                throw e
            } catch (e: Exception) {
                _state.update { it.copy(error = e.message) }
            } finally {
                _state.update { it.copy(busy = false) }
            }
        }
    }

    private suspend fun release() {
        _state.update { it.copy(ready = false) }
        while (_state.value.busy) {
            conversation?.cancelProcess()
            delay(100)
        }
        conversation?.close()
        conversation = null
        engine?.close()
        engine = null
        _state.value = ChatState()
    }

    override fun onCleared() {
        scope.launch {
            mutex.withLock { release() }
            executor.shutdown()
        }.invokeOnCompletion { scope.cancel() }
    }
}

sendMessageAsync(text) returns a Flow<Message> of chunks, and toString gives a chunk's text. sendMessage(text) blocks and returns the whole reply. The conversation keeps its history, so the next send continues the chat. busy keeps the button disabled until the flow completes.

To set the sampling, pass SamplerConfig(topK = 10, topP = 0.95, temperature = 0.8) in ConversationConfig. All three parameters are required, and topP and temperature are Double.

load with the model path that is already loaded does nothing, whatever backend it asks for. A second call after a rotation keeps the loaded model, also after the app has fallen back to another backend. send runs only when the state is ready and not busy, the same test as the button. A tap that lands while release stops a reply does nothing. A tap queued behind a load reaches the model that load loaded when no reply was streaming.

Step 6: Wire the Compose screen

viewModel and collectAsStateWithLifecycle come from androidx.lifecycle:lifecycle-viewmodel-compose and androidx.lifecycle:lifecycle-runtime-compose (2.10.0):

<br />

import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.verticalScroll
import androidx.compose.material3.Button
import androidx.compose.material3.Text
import androidx.compose.material3.TextField
import androidx.compose.runtime.Composable
import androidx.compose.runtime.LaunchedEffect
import androidx.compose.runtime.getValue
import androidx.compose.runtime.mutableStateOf
import androidx.compose.runtime.remember
import androidx.compose.runtime.setValue
import androidx.compose.ui.Modifier
import androidx.lifecycle.compose.collectAsStateWithLifecycle
import androidx.lifecycle.viewmodel.compose.viewModel
import com.google.ai.edge.litertlm.Backend

@Composable
fun ChatScreen(modelPath: String, viewModel: ChatViewModel = viewModel()) {
    val state by viewModel.state.collectAsStateWithLifecycle()
    var input by remember { mutableStateOf("") }
    LaunchedEffect(modelPath) { viewModel.load(modelPath, Backend.GPU()) }
    Column {
        Text(
            state.reply,
            Modifier.weight(1f).verticalScroll(rememberScrollState())
        )
        state.error?.let { Text(it) }
        TextField(value = input, onValueChange = { input = it })
        Button(
            onClick = { viewModel.send(input); input = "" },
            enabled = state.ready && !state.busy
        ) {
            Text("Send")
        }
    }
}
Step 7: Manage the engine lifecycle
  • Keep the engine in the ViewModel for as long as its screen lives. When several screens share the engine, keep it in an application-scoped holder.

  • The ViewModel keeps its own thread and scope. viewModelScope is cancelled before onCleared runs, so a close launched there wouldn't run. onCleared cancels scope once the close is done.

  • release turns ready off and calls cancelProcess until the streaming reply's flow has ended. The flow ends at the latest when the reply ends on its own. release then closes the conversation and the engine, each once.

  • onCleared and a load that replaces the model both call release under the Mutex, one at a time, because release suspends while a reply stops.

  • To start a fresh chat, close the conversation and create a new one with createConversation. Keep the engine loaded.

Post-implementation steps for the user

Report the steps that apply to the user after the code compiles:

  • When Path A in Step 3 didn't run, copy the model to the device with the two adb commands from Path A.

  • When the app uses Path C in Step 3, create the AI pack module that holds the .litertlm file and upload the app to Play Console.

  • When no .litertlm file exists for the model, convert the model on a workstation. This skill doesn't convert models.

  • When the user asks for a complete reference app, point them to Google AI Edge Gallery.

Troubleshooting

SymptomCauseFix
First reply is slow.initialize ran on first use.Load at app start and set cacheDir.
First GPU reply ends in Can not find OpenCL library on this device.The manifest lacks the uses-native-library entries.Add both entries from Step 1 inside <application>.
close throws IllegalStateException.The engine or conversation was closed twice, or initialize threw.Store the engine only after initialize returns, and set each field to null after close.
Build fails with [Hilt] Provided Metadata instance has version 2.4.0.Hilt 2.59.2 can't read the Kotlin 2.4 metadata in litertlm-android 0.18.0.Follow Path A or Path B in Step 1.

Checklist

  • [ ] Is minSdk set to 24 or higher and is com.google.ai.edge.litertlm:litertlm-android:0.18.0 added in app/build.gradle.kts?

  • [ ] For the GPU backend, does AndroidManifest.xml declare libvndksupport.so and libOpenCL.so with android:required="false" inside <application>?

  • [ ] Is the .litertlm file loaded from an absolute path on the device's file system, never from assets/?

  • [ ] Do initialize, sendMessageAsync, cancelProcess, and close all run on the same single-thread background executor?

  • [ ] Is the conversation closed before the engine, each exactly once?

  • [ ] Does the project compile with ./gradlew assembleDebug?

Antipatterns

  • Never call Engine.initialize on the Android main thread.

  • Never place a .litertlm file in assets/ or ship it inside the APK.

  • Never call close on an engine whose initialize threw.

  • Never close the engine while a reply is streaming; call cancelProcess until the flow ends first.

  • Never close Engine or Conversation from viewModelScope in onCleared; that scope is already cancelled.

Files

LICENSE


                                 Apache License
                           Version 2.0, January 2004
                        http://www.apache.org/licenses/

   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION

   1. Definitions.

      "License" shall mean the terms and conditions for use, reproduction,
      and distribution as defined by Sections 1 through 9 of this document.

      "Licensor" shall mean the copyright owner or entity authorized by
      the copyright owner that is granting the License.

      "Legal Entity" shall mean the union of the acting entity and all
      other entities that control, are controlled by, or are under common
      control with that entity. For the purposes of this definition,
      "control" means (i) the power, direct or indirect, to cause the
      direction or management of such entity, whether by contract or
      otherwise, or (ii) ownership of fifty percent (50%) or more of the
      outstanding shares, or (iii) beneficial ownership of such entity.

      "You" (or "Your") shall mean an individual or Legal Entity
      exercising permissions granted by this License.

      "Source" form shall mean the preferred form for making modifications,
      including but not limited to software source code, documentation
      source, and configuration files.

      "Object" form shall mean any form resulting from mechanical
      transformation or translation of a Source form, including but
      not limited to compiled object code, generated documentation,
      and conversions to other media types.

      "Work" shall mean the work of authorship, whether in Source or
      Object form, made available under the License, as indicated by a
      copyright notice that is included in or attached to the work
      (an example is provided in the Appendix below).

      "Derivative Works" shall mean any work, whether in Source or Object
      form, that is based on (or derived from) the Work and for which the
      editorial revisions, annotations, elaborations, or other modifications
      represent, as a whole, an original work of authorship. For the purposes
      of this License, Derivative Works shall not include works that remain
      separable from, or merely link (or bind by name) to the interfaces of,
      the Work and Derivative Works thereof.

      "Contribution" shall mean any work of authorship, including
      the original version of the Work and any modifications or additions
      to that Work or Derivative Works thereof, that is intentionally
      submitted to Licensor for inclusion in the Work by the copyright owner
      or by an individual or Legal Entity authorized to submit on behalf of
      the copyright owner. For the purposes of this definition, "submitted"
      means any form of electronic, verbal, or written communication sent
      to the Licensor or its representatives, including but not limited to
      communication on electronic mailing lists, source code control systems,
      and issue tracking systems that are managed by, or on behalf of, the
      Licensor for the purpose of discussing and improving the Work, but
      excluding communication that is conspicuously marked or otherwise
      designated in writing by the copyright owner as "Not a Contribution."

      "Contributor" shall mean Licensor and any individual or Legal Entity
      on behalf of whom a Contribution has been received by Licensor and
      subsequently incorporated within the Work.

   2. Grant of Copyright License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      copyright license to reproduce, prepare Derivative Works of,
      publicly display, publicly perform, sublicense, and distribute the
      Work and such Derivative Works in Source or Object form.

   3. Grant of Patent License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      (except as stated in this section) patent license to make, have made,
      use, offer to sell, sell, import, and otherwise transfer the Work,
      where such license applies only to those patent claims licensable
      by such Contributor that are necessarily infringed by their
      Contribution(s) alone or by combination of their Contribution(s)
      with the Work to which such Contribution(s) was submitted. If You
      institute patent litigation against any entity (including a
      cross-claim or counterclaim in a lawsuit) alleging that the Work
      or a Contribution incorporated within the Work constitutes direct
      or contributory patent infringement, then any patent licenses
      granted to You under this License for that Work shall terminate
      as of the date such litigation is filed.

   4. Redistribution. You may reproduce and distribute copies of the
      Work or Derivative Works thereof in any medium, with or without
      modifications, and in Source or Object form, provided that You
      meet the following conditions:

      (a) You must give any other recipients of the Work or
          Derivative Works a copy of this License; and

      (b) You must cause any modified files to carry prominent notices
          stating that You changed the files; and

      (c) You must retain, in the Source form of any Derivative Works
          that You distribute, all copyright, patent, trademark, and
          attribution notices from the Source form of the Work,
          excluding those notices that do not pertain to any part of
          the Derivative Works; and

      (d) If the Work includes a "NOTICE" text file as part of its
          distribution, then any Derivative Works that You distribute must
          include a readable copy of the attribution notices contained
          within such NOTICE file, excluding those notices that do not
          pertain to any part of the Derivative Works, in at least one
          of the following places: within a NOTICE text file distributed
          as part of the Derivative Works; within the Source form or
          documentation, if provided along with the Derivative Works; or,
          within a display generated by the Derivative Works, if and
          wherever such third-party notices normally appear. The contents
          of the NOTICE file are for informational purposes only and
          do not modify the License. You may add Your own attribution
          notices within Derivative Works that You distribute, alongside
          or as an addendum to the NOTICE text from the Work, provided
          that such additional attribution notices cannot be construed
          as modifying the License.

      You may add Your own copyright statement to Your modifications and
      may provide additional or different license terms and conditions
      for use, reproduction, or distribution of Your modifications, or
      for any such Derivative Works as a whole, provided Your use,
      reproduction, and distribution of the Work otherwise complies with
      the conditions stated in this License.

   5. Submission of Contributions. Unless You explicitly state otherwise,
      any Contribution intentionally submitted for inclusion in the Work
      by You to the Licensor shall be under the terms and conditions of
      this License, without any additional terms or conditions.
      Notwithstanding the above, nothing herein shall supersede or modify
      the terms of any separate license agreement you may have executed
      with Licensor regarding such Contributions.

   6. Trademarks. This License does not grant permission to use the trade
      names, trademarks, service marks, or product names of the Licensor,
      except as required for reasonable and customary use in describing the
      origin of the Work and reproducing the content of the NOTICE file.

   7. Disclaimer of Warranty. Unless required by applicable law or
      agreed to in writing, Licensor provides the Work (and each
      Contributor provides its Contributions) on an "AS IS" BASIS,
      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
      implied, including, without limitation, any warranties or conditions
      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
      PARTICULAR PURPOSE. You are solely responsible for determining the
      appropriateness of using or redistributing the Work and assume any
      risks associated with Your exercise of permissions under this License.

   8. Limitation of Liability. In no event and under no legal theory,
      whether in tort (including negligence), contract, or otherwise,
      unless required by applicable law (such as deliberate and grossly
      negligent acts) or agreed to in writing, shall any Contributor be
      liable to You for damages, including any direct, indirect, special,
      incidental, or consequential damages of any character arising as a
      result of this License or out of the use or inability to use the
      Work (including but not limited to damages for loss of goodwill,
      work stoppage, computer failure or malfunction, or any and all
      other commercial damages or losses), even if such Contributor
      has been advised of the possibility of such damages.

   9. Accepting Warranty or Additional Liability. While redistributing
      the Work or Derivative Works thereof, You may choose to offer,
      and charge a fee for, acceptance of support, warranty, indemnity,
      or other liability obligations and/or rights consistent with this
      License. However, in accepting such obligations, You may act only
      on Your own behalf and on Your sole responsibility, not on behalf
      of any other Contributor, and only if You agree to indemnify,
      defend, and hold each Contributor harmless for any liability
      incurred by, or claims asserted against, such Contributor by reason
      of your accepting any such warranty or additional liability.

   END OF TERMS AND CONDITIONS

   APPENDIX: How to apply the Apache License to your work.

      To apply the Apache License to your work, attach the following
      boilerplate notice, with the fields enclosed by brackets "[]"
      replaced with your own identifying information. (Don't include
      the brackets!)  The text should be enclosed in the appropriate
      comment syntax for the file format. We also recommend that a
      file or class name and description of purpose be included on the
      same "printed page" as the copyright notice for easier
      identification within third-party archives.

   Copyright [yyyy] [name of copyright owner]

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Security

No issues found by our static scan· No issues found

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Created by
Google LLC
Publisher
Android (Google) (Official)
Distributed by
Android (Google)
Source
android/skills · device-ai/litert/litert-lm · commit bf68e2d
Licence
Apache License 2.0 (redistribution allowed)
  • LICENSE (added by AutoGineer from LICENSE.txt)
  • ATTRIBUTION.md (written by AutoGineer)
Synced

AutoGineer is not affiliated with or endorsed by Google LLC or Android (Google).

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download litert-lm.zip