deploy-edge-ai-model

deploy-edge-ai-model is a skill for Claude Code from pjt222/agent-almanac. It costs 108 tokens per session (4,234 once invoked), scanned A, original, MIT.

A deployment guide for running machine-learning models directly on phones, embedded devices, or browsers instead of sending data to a server.

In plain words
What is it for?
Use it to convert models to TensorFlow Lite or ONNX, apply INT8 or INT4 quantization, build Android or iOS features, and benchmark device performance.
Why use it?
It helps adapt models to limited device memory and computing power while choosing formats, compression, and hardware acceleration.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Part of the agent-almanac plugin — 122 skills, 76 agents shipped together

Good fit Use it to convert models to TensorFlow Lite or ONNX, apply INT8 or INT4 quantization, build Android or iOS features, and benchmark device performance.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/pjt222/agent-almanac/deploy-edge-ai-model
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add pjt222/agent-almanac --skill deploy-edge-ai-model
Clone the repo
git clone --depth 1 https://github.com/pjt222/agent-almanac

Made for: Claude Code.

Or install agent-almanac, the plugin that ships this one along with the rest of its 122 skills, 76 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for deploy-edge-ai-model

README.md
[![agentmods](https://agentmods.dev/badge/skills/pjt222/agent-almanac/deploy-edge-ai-model/github.svg)](https://agentmods.dev/skills/pjt222/agent-almanac/deploy-edge-ai-model)
Your own site
<a href="https://agentmods.dev/skills/pjt222/agent-almanac/deploy-edge-ai-model"><img src="https://agentmods.dev/badge/skills/pjt222/agent-almanac/deploy-edge-ai-model/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for deploy-edge-ai-model

Your own site · 80×15
<a href="https://agentmods.dev/skills/pjt222/agent-almanac/deploy-edge-ai-model"><img src="https://agentmods.dev/badge/skills/pjt222/agent-almanac/deploy-edge-ai-model.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 108 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,234 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00108 $0.04234
Opus 5 $0.00054 $0.02117
Sonnet 5 $0.00022 $0.00847
Haiku 4.5 $0.00011 $0.00423

Measured 6d ago against content hash b8aabed8b7f3, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

deploy-edge-ai-model scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

i18n/caveman-lite/skills/deploy-edge-ai-model/SKILL.md · 459 lines

How it starts

The opening of the file, as written. The whole thing — 459 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Deploy Edge AI Model

See Extended Examples for complete configuration files, quantization scripts, and benchmark templates.

Deploy ML models to edge devices with optimized inference, hardware acceleration, and on-device model management.

When to Use

  • Deploying LLMs (Gemma 4, Phi, Llama) to mobile devices via Google AI Edge Gallery
  • Converting models to TensorFlow Lite or ONNX for on-device inference
  • Quantizing models to INT8/INT4 for reduced memory and faster inference
  • Building Android/iOS apps with local AI capabilities
  • Selecting hardware delegates (GPU, NPU, DSP, Hexagon, CoreML)
  • Benchmarking inference latency and memory on target devices
  • Deploying MediaPipe tasks (vision, text, audio) to mobile or embedded platforms

Inputs

  • Required: Trained model (SavedModel, PyTorch, ONNX, or Hugging Face checkpoint)
  • Required: Target platform (Android, iOS, Linux embedded, browser)
  • Required: Target device constraints (RAM, storage, compute capability)
  • Optional: Calibration dataset for post-training quantization
  • Optional: Google AI Edge Gallery configuration for LLM deployment
  • Optional: Hardware delegate preferences (GPU, NPU, CPU-only)

Procedure

Step 1: Evaluate Model for Edge Deployment

Assess model size, latency requirements, and target device capabilities.

# assess_model.py
import os
import tensorflow as tf

def assess_model_for_edge(saved_model_path, target_ram_mb=4096):
    """Evaluate whether a model is suitable for edge deployment."""
    model = tf.saved_model.load(saved_model_path)

    # Check model size on disk
    model_size_mb = sum(
        os.path.getsize(os.path.join(dp, f))
        for dp, _, filenames in os.walk(saved_model_path)
        for f in filenames
    ) / (1024 * 1024)

    print(f"Model size: {model_size_mb:.1f} MB")
    print(f"Target RAM: {target_ram_mb} MB")
    print(f"Size/RAM ratio: {model_size_mb / target_ram_mb:.2%}")

    if model_size_mb > target_ram_mb * 0.25:
        print("WARNING: Model exceeds 25% of device RAM - quantization recommended")
        return False
    return True

Read the full file on GitHub · 459 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 459 lines · 108 tokens per session scan A b8aabed8b7f3

Subscribe to this mod's changes

deploy-edge-ai-model is a skill published in the GitHub repository pjt222/agent-almanac (32 stars, last pushed yesterday), licensed MIT. It adds 108 tokens to every session and 4,234 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

voice-extractor

Capture a user's real writing voice from 5-20 prior samples, store a local voice.yaml fingerprint, and enforce it on newsjack drafts so AI tells disappear. Measures voice with named stylometry lenses (Burrows's Delta function-word vector, MATTR lexical diversity, sentence-length burstiness, Biber Dimension-1 register…

elvisun/newsjack · 90 tokens

map

Build and commit a Cortex function knowledge graph — maps structural dependencies and domain intent relationships across all AI functions in the project. Supports --reduce (default on) for transitive reduction of the dependency graph.

Snowflake-Labs/cocoplus · 42 tokens

realistic-prompt-generation

Generate natural, controlled prompt variants from a target-blind design brief and prompt architecture while preserving approved jobs, acts, journeys, constraints, roles, locales, proximity bands, and evidence language. Use after architecture design and before contamination or semantic QA.

elvisun/newsjack · 55 tokens

test

Enter the Test phase of CocoBrew. Reads spec.md test requirements, generates test cases, executes SQL validation and quality checks, records results in test.md. Can be re-run without full rebuild. Requires Build phase completion.

Snowflake-Labs/cocoplus · 47 tokens

map-diff

Analyze the impact of staged git changes against the committed Cortex function knowledge graph — shows which downstream functions are affected before you commit.

Snowflake-Labs/cocoplus · 28 tokens

migrating-ai-sdk-to-common-ai

Migrates Airflow projects from airflow-ai-sdk to apache-airflow-providers-common-ai 0.4.0+. Use when replacing airflow-ai-sdk with the official Airflow AI provider - migrating LLM decorators (@task.llm, @task.agent, @task.llmbranch, @task.embed), switching from model strings/objects to connection-based LLM…

astronomer/agents · 151 tokens