Agent skill · software engineering · dpearson2699
apple-on-device-ai
Build private, on-device AI features on iPhone, iPad, and Mac with Foundation Models, Core ML, MLX Swift, or llama.cpp. Use when choosing an Apple-local model runtime, building an Apple Intelligence chatbot or tool-calling feature, running an LLM on Apple Silicon, converting or compressing a Python model for Core ML, or comparing on-device inference backends. For Swift Core ML loading and prediction code, use the coreml skill.
Why this skill is useful
Provides specific guidance on deploying and optimizing on-device ML models for Apple platforms, which the AI may not reliably generate on its own.
What it needs
Requires coremltools installed locally. About 7k tokens when loaded. Last updated 2026-07-31. 973 stars on the source repository.
What this skill does
On-Device AI for Apple Platforms Guide for selecting, deploying, and optimizing on-device ML models. Covers Apple Foundation Models, Core ML, MLX Swift, and llama.cpp. Contents Framework Selection Router Apple Foundation Models Overview Core ML Overview MLX Swift Overview Multi-Backend Architecture Performance Best Practices Common Mistakes Review Checklist References Framework Selection Router Use this decision tree to pick the right framework for your use case. Apple Foundation Models When to use: Text generation, summarization, entity extraction, structured output, and short dialog on iOS 26+ / macOS 26+ devices with Apple Intelligence enabled. No app-managed API key, network round trip, or model hosting; still handle system model asset readiness. Best for: Generating text or structured data with @Generable types Summarization, classification, content tagging Tool-augmented generation with the Tool protocol Apps that need guaranteed on-device privacy Not suited for: Complex math, code generation, factual accuracy tasks, or apps targeting pre-iOS 26 devices. Core ML When to use: Deploying custom trained models (vision, NLP, audio) across all Apple platforms. Converting models from PyTorch, TensorFlow, or scikit-learn with coremltools. Best for: Image classification, object detection, segmentation Custom NLP classifiers, sentiment analysis models Audio/speech models via SoundAnalysis integration Any scenario needing Neural Engine optimization Models requiring quantization, palettization, or pruning MLX Swift When to use: Running specific open-source LLMs (Llama, Mistral, Qwen, Gemma) on Apple Silicon with maximum throughput. Research and prototyping. Best for: Highest sustained token generation on Apple Silicon Running Hugging Face models from mlx-community Research requiring automatic differentiation Fine-tuning workflows on Mac llama.cpp When to use: Cross-platform LLM inference using GGUF model format. Production deployments needing broad device support. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills dpearson2699/apple-on-device-ai