AGENTS.md — the
porting contract in one file: why conversion isn’t conversion, the two gates, the traps agents
hit, and what isn’t an agent’s call. No install needed. One fetch for everything here:
llms.txt.apps/ — Xcode 27 + xcodegen, the coreai-models patch stack + tokenizer.jsonmodels/whisper-large-v3-turbo/README.md).
Engine-level deep-dive: knowledge/swift-runtime.mdPORTING.md — the complete walk from HF
checkpoint to a verified .aimodel on iPhone (oracle → export → gates → device → publish),
with a vision and an LLM worked example. Start here to contribute a port.models/<model>/recipe.toml via
python3 conversion/zoo_convert.py run <name> — see Rebuild a bundleknowledge/conversion-guide.mdknowledge/compression.mdknowledge/custom-metal-kernels.md · knowledge/performance-ceiling.mdknowledge/coreai-beta-mpsgraph-kvwrite-bug.md — FB23024751 / apple/coreai-models#5LLVM ERROR: …, failed assertion …, failedToSpecialize, NSPOSIXErrorDomain Code=2, …) → knowledge/coreai-error-index.md — every exact string this project has observed, verbatim as a heading, with the verified cause, the fix, and the log or Apple issue behind it| Dir | What |
|---|---|
| coreai-kit ↗ | (sibling repo) The Swift package that runs this zoo: 1-line catalog: APIs (ChatSession, KitTranscriber, …), model download + cache, and per-kind example apps in Examples/ — the cards’ ▶️ / 💻 doors point there. |
models/ |
One directory per model — the card, the recipe.toml that reproduces its published bundles, and the generated _INVENTORY.md / index.json. Laid out like apple/coreai-models. |
skills/ |
Agent skills — install them and your coding agent can pick a model, reproduce its bundle, and verify the result. |
knowledge/ |
Verified notes on the framework: conversion, compression, stateful KV, custom Metal kernels, AOT, compute-unit rules, the Swift runtime. |
conversion/ |
Re-authored models + convert / verify / compress scripts (PyTorch → .aimodel). |
cli/ |
coreai export / doctor / verify — find a model’s export route, lint an artifact against the failure patterns in knowledge/, gate it against an HF oracle. DOCTOR_RULES.md is the table those checks come from: 64 ways a conversion succeeds and the result is quietly wrong. |
swift/ |
CoreAIRunner — a Swift package that drives .aimodel LLM bundles, including architectures beyond the standard runtime. |
apps/ |
Engine showcases — apps for models that need a hand-tuned backend (custom Metal kernels, patch stack: BitCPM, RWKV-7, LLaDA, …) and the device-verification bench behind the published numbers. Want to just run a model? Use the kit examples ↗ instead. |
Every model in the table is a conversion recipe anyone could have written — and some are, by people who are not me. Nanbeige4.2-3B (PR #6, by @ukint-vs) is the reference for what a contributed port looks like, and pocket-tts (PR #12, by @RahulRachuri) is the reference for how far the gates can be taken — an ASR round trip and a 302-sentence sweep, because tensor cosine can pass while the audio is unintelligible. The shape of both: pinned checkpoint + immutable bundle revision, the overlay/recipe/gates in the PR, the bundle published under the contributor’s own HF namespace (you keep ownership and credit), and the maintainer runs the iPhone hardware gate for you if you don’t have the device.
PORTING.md walks the whole path (oracle → export → gates →
publish); PRs welcome.knowledge/coreai-error-index.md; if it is there, so is the fix.BENCHMARKS.md.Projects outside this repo that carry code ported from the zoo, read its model index, or follow one of its conversion recipes:
RFDETR.export(format="coreai") (since 1.11.0) was ported from the
zoo’s RF-DETR conversion
(pull request).CoreAIModelZooCatalog fetches the zoo’s
models/index.json and turns the recipes marked verified into entries
in its model catalog
(source).coremltools), not Core AI
(source).Built something? Open a showcase issue — a name, a link, and one line is all it takes.