Upgrade to Pro — share decks privately, control downloads, hide ads and more …

AIHeroes 2026: Apple Foundation Models Workshop

Avatar for Tomas Parizek Tomas Parizek
May 03, 2026
9

AIHeroes 2026: Apple Foundation Models Workshop

Hands-on workshop building a single-screen iOS 26 chat app powered entirely by Apple's on-device Foundation Models framework — no network, no API keys, no per-token cost. Six checkpoints: availability, sessions, structured output, streaming, tool calling, and a typed transcript inspector. Presented at AI Heroes 2026, Turin. Repo: github.com/TParizek/AIHeroes-Apple-Foundation-Models-workshop

Avatar for Tomas Parizek

Tomas Parizek

May 03, 2026

Transcript

  1. Right on the phone • No network • No API

    key • No per-token cost • No data leaving the phone
  2. LLM is a function • Text in • Text out

    • Surprisingly good at structure
  3. Apple's on-device LLM • On device LLM with simple API

    • Free, offline, private • Minimum os: iOS 26, iPadOS 26, macOS 26 • Minimum processor: A17 Pro or any M series chip
  4. Step 1 • ChatViewModel.swift ◦ Check Foundation Models availability &

    start session in init ◦ Update send function with session conversation • Test the app: expected result is a functional LLM
  5. Step 2 • AssistantReply.swift ◦ Add @Generable and @Guide annotations

    ◦ Add “var sessions: [SessionCard]” to AssistantReply • ChatViewModel.swift ◦ Update session.respond to typed response • ChatView.swift ◦ Update func bubble -> case .assistant to render cards using SessionCardBubble • Test the app: expected result are visible session cards in responses
  6. Step 3 • ChatViewModel.swift ◦ Add var isStreaming: Bool to

    AssistantMessage ◦ Update session.respond to session.streamResponse ◦ Handle partial updates of response • ChatView.swift ◦ Show TypingIndicator when isStreaming is true, but response is empty • Test the app: expected result is seeing response stream as it is generated
  7. Step 4 • SearchSessionTool.swift ◦ Uncomment tool implementation ◦ Create

    SearchSpeakerTool.swift inspired by SearchSessionTool.swift • ChatViewModel.swift ◦ Update session creation with tools • Test the app: expected result is seeing response enriched with tool provided data
  8. What to remember • It's just a Swift API •

    Private by default • Free at runtime • Streaming, tools, multi-turn — all included