What problem does it solve? Building AI features that respect user privacy and work offline is hard when relying on cloud LLM APIs. This Skill provides proven Swift patterns for Apple's FoundationModels framework, letting you run language model inference entirely on-device in iOS 26+ apps. ## Core Features & Use Cases - Text Generation Sessions: Create single-turn or multi-turn LanguageModelSession instances with instructions, availability checks, and proper error handling. - Structured Output with @Generable: Generate strongly-typed Swift structs directly from prompts using the @Generable macro and @Guide constraints instead of parsing raw strings. - Tool Calling & Streaming: Define custom Tool implementations the model can invoke, and stream partial structured results via PartiallyGenerated types for real-time SwiftUI updates. - Use Case: Build a recipe assistant that extracts structured ingredients from natural language, searches a local database via a custom tool, and streams results into a SwiftUI list — all without any network request. ## Quick Start Ask the AI to write a SwiftUI view that uses LanguageModelSession with @Generable structured output and handles all model availability states.