megastep/codex-skills

axiom-ios-ml

Use when deploying ANY machine learning model on-device, converting models to CoreML, compressing models, or implementing speech-to-text.

First seen Mar 5, 2026

Installation

$ npx skills add megastep/codex-skills --skill axiom-ios-ml

Summary

  • Use when deploying ANY machine learning model on-device, converting models to CoreML, compressing models, or implementing speech-to-text.
  • Covers CoreML conversion, MLTensor, model compression (quantization/palettization/pruning), stateful models, KV-cache, multi-function models, async prediction, SpeechAnalyzer, SpeechTranscriber.

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from megastep/codex-skills · top by installs.

npx skills add megastep/codex-skills

Browse all from megastep/codex-skills

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 5
License MIT
Default branch main
Open issues 0
Status Active

Skill metadata

Parsed from SKILL.md frontmatter.

LicenseMIT

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 4,591 B
  • docs SUMMARY.md 352 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 12 installs

SKILL.md

iOS Machine Learning Router

You MUST use this skill for ANY on-device machine learning or speech-to-text work.

When to Use

Use this router when:

  • Converting PyTorch/TensorFlow models to CoreML
  • Deploying ML models on-device
  • Compressing models (quantization, palettization, pruning)
  • Working with large language models (LLMs)
  • Implementing KV-cache for transformers
  • Using MLTensor for model stitching
  • Building speech-to-text features
  • Transcribing audio (live or recorded)

Boundary with ios-ai

ios-ml vs ios-ai — know the difference:

Developer Intent Router
"Use Apple Intelligence / Foundation Models" ios-ai — Apple's on-device LLM
"Run my own ML model on device" ios-ml — CoreML conversion + deployment
"Add text generation with @Generable" ios-ai — Foundation Models structured output
"Deploy a custom LLM with KV-cache" ios-ml — Custom model optimization
"Use Vision framework for image analysis" ios-vision — Not ML deployment
"Use pre-trained Apple NLP models" ios-ai — Apple's models, not custom

Rule of thumb: If the developer is converting/compressing/deploying their own model → ios-ml. If they're using Apple's built-in AI → ios-ai. If they're doing computer vision → ios-vision.

Routing Logic

CoreML Work

Implementation patterns$axiom-ios-ml-coreml

  • Model conversion workflow
  • MLTensor for model stitching
  • Stateful models with KV-cache
  • Multi-function models (adapters/LoRA)
  • Async prediction patterns
  • Compute unit selection

API reference$axiom-ios-ml-coreml-ref

  • CoreML Tools Python API
  • MLModel lifecycle
  • MLTensor operations
  • MLComputeDevice availability
  • State management APIs
  • Performance reports

Diagnostics$axiom-ios-ml-coreml-diag

  • Model won't load
  • Slow inference
  • Memory issues
  • Compression accuracy loss
  • Compute unit problems

Speech Work

Implementation patterns$axiom-ios-ml-speech

  • SpeechAnalyzer setup (iOS 26+)
  • SpeechTranscriber configuration
  • Live transcription
  • File transcription
  • Volatile vs finalized results
  • Model asset management

Decision Tree

  1. Implementing / converting ML models? → coreml
  2. CoreML API reference? → coreml-ref
  3. Debugging ML issues (load, inference, compression)? → coreml-diag
  4. Speech-to-text / transcription? → speech

Anti-Rationalization

Thought Reality
"CoreML is just load and predict" CoreML has compression, stateful models, compute unit selection, and async prediction. coreml covers all.
"My model is small, no optimization needed" Even small models benefit from compute unit selection and async prediction. coreml has the patterns.
"I'll just use SFSpeechRecognizer" iOS 26 has SpeechAnalyzer with better accuracy and offline support. speech skill covers the modern API.

Critical Patterns

coreml:

  • Model conversion (PyTorch → CoreML)
  • Compression (palettization, quantization, pruning)
  • Stateful KV-cache for LLMs
  • Multi-function models for adapters
  • MLTensor for pipeline stitching
  • Async concurrent prediction

coreml-diag:

  • Load failures and caching
  • Inference performance issues
  • Memory pressure from models
  • Accuracy degradation from compression

speech:

  • SpeechAnalyzer + SpeechTranscriber setup
  • AssetInventory model management
  • Live transcription with volatile results
  • Audio format conversion

Example Invocations

User: "How do I convert a PyTorch model to CoreML?" → Invoke: $axiom-ios-ml-coreml

User: "Compress my model to fit on iPhone" → Invoke: $axiom-ios-ml-coreml

User: "Implement KV-cache for my language model" → Invoke: $axiom-ios-ml-coreml

User: "Model loads slowly on first launch" → Invoke: $axiom-ios-ml-coreml-diag

User: "My compressed model has bad accuracy" → Invoke: $axiom-ios-ml-coreml-diag

User: "Add live transcription to my app" → Invoke: $axiom-ios-ml-speech

User: "Transcribe audio files with SpeechAnalyzer" → Invoke: $axiom-ios-ml-speech

User: "What's MLTensor and how do I use it?" → Invoke: $axiom-ios-ml-coreml-ref