axiom-foundation-models

axiom-foundation-models is a skill for Claude Code, Codex from ComeOnOliver/skillshub. It costs 67 tokens per session (7,666 once invoked), scanned A, original, MIT.

A guide to building on-device AI features with Apple’s Foundation Models framework. It focuses on summarising, extracting, classifying, generating structured output, streaming responses, and connecting tools.

In plain words
What is it for?
Use it when adding private, on-device language features to iPhone, iPad, Mac, or visionOS apps.
Why use it?
It helps prevent context overflow, blocked interfaces, unsuitable model choices, and fragile manual parsing of generated data.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when adding private, on-device language features to iPhone, iPad, Mac, or visionOS apps.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/comeonoliver/skillshub/axiom-foundation-models
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 ComeOnOliver/skillshub --skill axiom-foundation-models
Clone the repo
git clone --depth 1 https://github.com/ComeOnOliver/skillshub

Made for: Claude Code, Codex.

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 axiom-foundation-models

README.md
[![agentmods](https://agentmods.dev/badge/skills/comeonoliver/skillshub/axiom-foundation-models/github.svg)](https://agentmods.dev/skills/comeonoliver/skillshub/axiom-foundation-models)
Your own site
<a href="https://agentmods.dev/skills/comeonoliver/skillshub/axiom-foundation-models"><img src="https://agentmods.dev/badge/skills/comeonoliver/skillshub/axiom-foundation-models/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 axiom-foundation-models

Your own site · 80×15
<a href="https://agentmods.dev/skills/comeonoliver/skillshub/axiom-foundation-models"><img src="https://agentmods.dev/badge/skills/comeonoliver/skillshub/axiom-foundation-models.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 7,666 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.
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.00067 $0.07666
Opus 5 $0.00034 $0.03833
Sonnet 5 $0.00013 $0.01533
Haiku 4.5 $0.00007 $0.00767

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

Security

Grade A, and why

axiom-foundation-models 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 8d 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.

skills/CharlesWiltgen/Axiom/axiom-foundation-models/SKILL.md · 1,127 lines

How it starts

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

Foundation Models — On-Device AI for Apple Platforms

When to Use This Skill

Use when:

  • Implementing on-device AI features with Foundation Models
  • Adding text summarization, classification, or extraction capabilities
  • Creating structured output from LLM responses
  • Building tool-calling patterns for external data integration
  • Streaming generated content for better UX
  • Debugging Foundation Models issues (context overflow, slow generation, wrong output)
  • Deciding between Foundation Models vs server LLMs (ChatGPT, Claude, etc.)
Related Skills
  • Use axiom-foundation-models-diag for systematic troubleshooting (context exceeded, guardrail violations, availability problems)
  • Use axiom-foundation-models-ref for complete API reference with all WWDC code examples

Red Flags — Anti-Patterns That Will Fail

❌ Using for World Knowledge

Why it fails: The on-device model is 3 billion parameters, optimized for summarization, extraction, classification — NOT world knowledge or complex reasoning.

Example of wrong use:

// ❌ BAD - Asking for world knowledge
let session = LanguageModelSession()
let response = try await session.respond(to: "What's the capital of France?")

Why: Model will hallucinate or give low-quality answers. It's trained for content generation, not encyclopedic knowledge.

Correct approach: Use server LLMs (ChatGPT, Claude) for world knowledge, or provide factual data through Tool calling.


❌ Blocking Main Thread

Why it fails: session.respond() is async but if called synchronously on main thread, freezes UI for seconds.

Example of wrong use:

// ❌ BAD - Blocking main thread
Button("Generate") {
    let response = try await session.respond(to: prompt) // UI frozen!
}

Why: Generation takes 1-5 seconds. User sees frozen app, bad reviews follow.

Correct approach:

// ✅ GOOD - Async on background
Button("Generate") {
    Task {
        let response = try await session.respond(to: prompt)
        // Update UI with response
    }
}

Read the full file on GitHub · 1,127 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. 8d ago First seen · 1,127 lines · 67 tokens per session scan A 6991eb73dc50

Subscribe to this mod's changes

axiom-foundation-models is a skill published in the GitHub repository ComeOnOliver/skillshub (63 stars, last pushed 2mo ago), licensed MIT. It adds 67 tokens to every session and 7,666 once invoked, about $0.0003 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.