Skip to main content
Glama

Android On-Device AI / AICore Guide

android_ondevice_ai
Read-only

Discover how to implement on-device AI with Android AICore and ML Kit, enabling private, offline features like smart reply and object detection without network calls or API costs.

Instructions

On-device AI reference — Android 16 AICore and ML Kit Gen AI API. Used by Gmail (Smart Reply), Google Photos (object detection), Pixel Screenshots (semantic search). The official architecture: wrap ML models behind repository interfaces so on-device (AICore) and cloud (Vertex AI) are swappable without touching the UI layer. No network round-trip. No API costs. No privacy exposure. Works offline. AI tools default to cloud API calls when on-device is the 2026 answer for Pixel devices. Topics: 'overview' (architecture pattern, when to use), 'setup' (dependencies, availability check, fallback pattern), 'smart reply' (Gmail-style suggestion chips), 'ml kit' (non-generative ML — image labeling, barcode, face detection, translation).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topicNoTopic: 'overview', 'setup', 'smart reply', 'ml kit', 'architecture'
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations declare readOnlyHint=true, and the description reinforces no side effects by characterizing it as a reference that 'works offline' and involves no network round-trip or API costs. No contradiction.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description front-loads the purpose and includes structured topic list with bullet-like formatting. While verbose, every sentence adds context, and the length is justified given the breadth of content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a guide tool with one optional parameter and no output schema, the description covers what it does, its architecture, use cases, and topic details. It is complete enough to inform invocations, though return format is not specified (acceptable).

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100% with a parameter description listing valid topics. The description expands this by adding parenthetical explanations for each topic ('architecture pattern', 'dependencies, availability check' etc.), providing extra meaning.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it is an 'On-device AI reference' for Android 16 AICore and ML Kit, with concrete examples (Gmail Smart Reply, Google Photos object detection) distinguishing it from sibling tools covering compliance, debugging, or building.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains contexts like offline and privacy as reasons to use on-device AI, and contrasts with cloud API defaults. While it doesn't explicitly list exclusions, the topic list ('overview', 'setup', etc.) guides when to invoke.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/VIKAS9793/AndroJack-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server