{"id":29104433,"url":"https://github.com/desp0o/swift-foundationmodels","last_synced_at":"2026-04-14T06:33:51.821Z","repository":{"id":301365483,"uuid":"1005177472","full_name":"Desp0o/swift-FoundationModels","owner":"Desp0o","description":"This is a personal playground experimenting with Apple's newly introduced FoundationModel framework. The goal is to explore the capabilities of LanguageModelSession.","archived":false,"fork":false,"pushed_at":"2025-06-26T13:02:48.000Z","size":129,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-26T14:19:17.129Z","etag":null,"topics":["ai","apple","artificial-intelligence","beta","ios","ios26","iosdevelopment","large-language-models","llm","macos","macos26","swiftui","xcode","xcode26"],"latest_commit_sha":null,"homepage":"https://youtube.com/shorts/6vQ-HgYl7XI?feature=share","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Desp0o.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-19T19:54:24.000Z","updated_at":"2025-06-26T13:02:51.000Z","dependencies_parsed_at":"2025-06-26T14:29:33.596Z","dependency_job_id":null,"html_url":"https://github.com/Desp0o/swift-FoundationModels","commit_stats":null,"previous_names":["desp0o/swift-foundationmodels"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Desp0o/swift-FoundationModels","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Desp0o%2Fswift-FoundationModels","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Desp0o%2Fswift-FoundationModels/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Desp0o%2Fswift-FoundationModels/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Desp0o%2Fswift-FoundationModels/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Desp0o","download_url":"https://codeload.github.com/Desp0o/swift-FoundationModels/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Desp0o%2Fswift-FoundationModels/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31785677,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T02:24:21.117Z","status":"ssl_error","status_checked_at":"2026-04-14T02:24:20.627Z","response_time":153,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","apple","artificial-intelligence","beta","ios","ios26","iosdevelopment","large-language-models","llm","macos","macos26","swiftui","xcode","xcode26"],"created_at":"2025-06-29T00:05:03.041Z","updated_at":"2026-04-14T06:33:51.803Z","avatar_url":"https://github.com/Desp0o.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🍏 Apple Foundation Model Playground\n\nThis 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.\n\n## Features 🚀\n- **Chat with AI** using `LanguageModelSession` — simple conversational interaction with Apple Intelligence.\n- **Generate Recipes** by passing selected ingredients to a custom `Recipe` structure using `@Generable`.\n- **Generate Person Structs** using `@Generable` and `@Guide` macros — define constraints like age range or hobbies count.\n\n## 🧠 Concepts\n- `@Generable`: Automatically generate struct values using Apple Intelligence.\n- `@Guide`: Provide field-level guidance for better, constraint-aware generation.\n- `LanguageModelSession`: A session-based interface to interact with Apple’s large language model.\n\n## 🔧 Tech Stack\n\n- 🧑‍💻 **SwiftUI**\n- 🛠️ **Xcode 26 Beta 2**\n- 📱 **iOS 26 Beta 2**\n- 💻 **macOS 26 Beta 2**\n\n## Screenshots 📸\n\u003cimg width=\"290\" alt=\"1\" src=\"https://github.com/user-attachments/assets/e7377dda-9978-48a9-aab5-028fc28ececd\" /\u003e\n\u003cimg width=\"290\" alt=\"2\" src=\"https://github.com/user-attachments/assets/eb85ac5c-990e-4590-aa97-dee6f9504553\" /\u003e\n\u003cimg width=\"290\" alt=\"3\" src=\"https://github.com/user-attachments/assets/0b30ed3a-d068-4477-8117-54711d3e7cb6\" /\u003e\n\u003cimg width=\"290\" alt=\"4\" src=\"https://github.com/user-attachments/assets/488121da-5609-43bb-b47b-70c4a1fbb57c\" /\u003e\n\u003cimg width=\"290\" alt=\"5\" src=\"https://github.com/user-attachments/assets/76d7fa43-ba67-4643-b29f-25a59cc88066\" /\u003e\n\n## Demo 🎥\n[Watch the video](https://youtube.com/shorts/Ho4EoBIbaoE?feature=share)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdesp0o%2Fswift-foundationmodels","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdesp0o%2Fswift-foundationmodels","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdesp0o%2Fswift-foundationmodels/lists"}