This is a personal playground experimenting with Apple's newly introduced FoundationModel framework. The goal is to explore the capabilities of LanguageModelSession and @Generable macros for generating structured and intelligent Swift data using Apple Intelligence.
- Chat with AI using
LanguageModelSessionβ simple conversational interaction with Apple Intelligence. - Generate Recipes by passing selected ingredients to a custom
Recipestructure using@Generable. - Generate Person Structs using
@Generableand@Guidemacros β define constraints like age range or hobbies count.
@Generable: Automatically generate struct values using Apple Intelligence.@Guide: Provide field-level guidance for better, constraint-aware generation.LanguageModelSession: A session-based interface to interact with Appleβs large language model.
- π§βπ» SwiftUI
- π οΈ Xcode 26 Beta 2
- π± iOS 26 Beta 2
- π» macOS 26 Beta 2