← All skills
swiftdata
95 / 100 · Low risk
Fine to try.
By dpearson2699/swift-ios-skills (GitHub) · coding · 1,282 stars · scanned at commit 8d90fd1
Implement, review, or improve data persistence using SwiftData. Use when defining @Model classes with @Attribute, @Relationship, @Transient, #Unique, or #Index; when querying with @Query, #Predicate, FetchDescriptor, or SortDescriptor; when configuring ModelContainer and ModelContext for SwiftUI or background work with @ModelActor; when planning schema migrations with VersionedSchema and SchemaMigrationPlan; when setting up CloudKit sync with ModelConfiguration; or when coexisting with or migra…
Works with any agent that supports SKILL.md skills.
What this skill can do
Connects to the internet
The author does not mention this.
Found in 22 places.
Show 17 more
- skills/swiftdata/references/core-data-coexistence.md, line 313
let articles = try context.fetch(FetchDescriptor<SchemaV2.Article>()) - skills/swiftdata/references/swiftdata-advanced.md, line 65
try fetch(request).fetchedSnapshots.count - skills/swiftdata/references/swiftdata-advanced.md, line 71
try fetch(request).fetchedSnapshots.map(\.persistentIdentifier) - skills/swiftdata/references/swiftdata-advanced.md, line 416
let trips = try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-advanced.md, line 426
let trips = try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-advanced.md, line 627
let allTrips = try modelContext.fetch(FetchDescriptor<Trip>()) - skills/swiftdata/references/swiftdata-advanced.md, line 630
let businessTrips = try modelContext.fetch(FetchDescriptor<BusinessTrip>()) - skills/swiftdata/references/swiftdata-advanced.md, line 902
let trips = try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-queries.md, line 153
return try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-queries.md, line 169
(`fetch(_:batchSize:)`). This will throw - skills/swiftdata/references/swiftdata-queries.md, line 179
let trips = try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-queries.md, line 193
let trips = try modelContext.fetch(descriptor) - skills/swiftdata/references/swiftdata-queries.md, line 201
| `fetch(_:)` | `[T]` | Standard fetch, all results in memory | - skills/swiftdata/references/swiftdata-queries.md, line 202
| `fetch(_:batchSize:)` | `FetchResultsCollection<T>` | Lazy batched loading | - skills/swiftdata/references/swiftdata-queries.md, line 211
let results: FetchResultsCollection<Trip> = try modelContext.fetch( - skills/swiftdata/references/swiftdata-queries.md, line 555
let all = try modelContext.fetch(FetchDescriptor<Trip>()) - skills/swiftdata/references/swiftdata-queries.md, line 607
let trips = try modelContext.fetch(FetchDescriptor<Trip>())
and 2 more places
Install
Paste this into your terminal. It downloads exactly the version we scanned, not whatever is newest.
if [ -e ~/.agents/skills/'swiftdata' ] || [ -L ~/.agents/skills/'swiftdata' ]; then echo 'A skill folder named swiftdata already exists — not replacing it' >&2; false; else d=$(mktemp -d) && git clone --quiet --filter=blob:none --no-checkout 'https://github.com/dpearson2699/swift-ios-skills' "$d" && git -C "$d" checkout --quiet '8d90fd121a263355a4fb44fd082af1416a5c1c2a' -- 'skills/swiftdata' && mkdir -p ~/.agents/skills && cp -R "$d"/'skills/swiftdata' ~/.agents/skills/'swiftdata' && rm -rf "$d"; fi
Codex reads ~/.agents/skills directly. For Claude Code, Cursor, Copilot, Gemini CLI, Antigravity or OpenCode, also link it. For Claude Code: ln -s ~/.agents/skills/'swiftdata' ~/.claude/skills/'swiftdata' (other agents: ~/.cursor/skills, ~/.copilot/skills, ~/.gemini/skills, ~/.gemini/config/skills, ~/.config/opencode/skills). Or install through the finder skill, which does both.
Badge for your README
The badge for dpearson2699/swift-ios-skills shows the score of its lowest-scoring skill.

[](https://zalavijaysinh.github.io/skilltrust/repos/dpearson2699/swift-ios-skills/)
Score history
| Date | Version | Score |
|---|
| 2026-11-08 | 8d90fd1 | 95 |
| 2026-11-07 | 8d90fd1 | 95 |