What problem does it solve? Designing a SwiftData persistence layer involves many decisions—schema modeling, query construction, thread safety, and testability—where mistakes lead to duplicate records, slow fetches, memory bloat, and untestable code. This Skill provides structured guidance and reviewed patterns for building correct, performant SwiftData data layers. ## Core Features & Use Cases - Schema Design Review: Covers @Model classes, relationships, cascade delete rules, unique constraints, and schema migration with VersionedSchema. - Query Pattern Guidance: Explains when to use @Query versus FetchDescriptor, predicate construction, pagination, and fetch limits. - Repository Pattern & Testing: Shows protocol-based data abstraction with DTOs, @ModelActor implementations, and in-memory repositories for unit tests. - Performance Optimization: Details batch operations, background contexts, memory management, and predicate performance. - Use Case: When migrating an app from Core Data to SwiftData, use this Skill to review the new schema for missing unique constraints, move heavy imports into a @ModelActor, and wrap data access in a testable repository. ## Quick Start Ask the assistant to review your SwiftData data layer or design a schema for your app's models, mentioning your entities and query needs.