Confirm successful installation by checking the skill directory location:
.cursor/skills/axiom-storage-diag
Restart Cursor to activate axiom-storage-diag. Access via /axiom-storage-diag in your agent's command palette.
β
Security Notice
We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.
Skills execute code in your environment. Always review source, verify the publisher, and test in isolation before production.
Core principle 90% of file storage problems stem from choosing the wrong storage location, misunderstanding file protection levels, or missing backup exclusionsβnot iOS file system bugs.
The iOS file system is battle-tested across millions of apps and devices. If your files are disappearing, becoming inaccessible, or causing backup issues, the problem is almost always in storage location choice or protection configuration.
Red Flags β Suspect File Storage Issue
If you see ANY of these:
Files mysteriously disappear after device restart
Files disappear randomly (weeks after creation)
App backup size unexpectedly large (>500 MB)
"File not found" after app background/foreground cycle
Files inaccessible when device is locked
Users report lost data after iOS update
Background tasks can't access files
β FORBIDDEN "iOS deleted my files, the file system is broken"
iOS file system handles billions of files daily across all apps
System behavior is documented and predictable
99% of issues are location/protection mismatches
Mandatory First Steps
ALWAYS check these FIRST (before changing code):
// 1. Check WHERE file is storedfuncdiagnoseFileLocation(_ url:URL){let path = url.path
if path.contains("/tmp/"){print("β οΈ File in tmp/ - system purges aggressively")}elseif path.contains("/Caches/"){print("β οΈ File in Caches/ - purged under storage pressure")}elseif path.contains("/Documents/"){print("β File in Documents/ - never purged, backed up")}elseif path.contains("/Library/Application Support/"){print("β File in Application Support/ - never purged, backed up")}}// 2. Check file protection levelfuncdiagnoseFileProtection(_ url:URL)throws{let attrs =tryFileManager.default.attributesOfItem(atPath: url.path)iflet protection = attrs[.protectionKey]as?FileProtectionType{print("Protection: \(protection)")if protection ==.complete {print("β οΈ File inaccessible when device locked")}}}// 3. Check backup statusfuncdiagnoseBackupStatus(_ url:URL)throws{let values =try url.resourceValues(forKeys:[.isExcludedFromBackupKey])iflet excluded = values.isExcludedFromBackup {print("Excluded from backup: \(excluded)")}}// 4. Check file existence and sizefuncdiagnoseFileState(_ url:URL){ifFileManager.default.fileExists(atPath: url.path){iflet size =try?FileManager.default.attributesOfItem(atPath: url.path)[.size]as?Int64{print("File exists, size: \(size) bytes")}}else{print("β File does not exist")}}
Decision Tree
Files Disappeared
Files missing? β Check where stored
ββ Disappeared after device restart
β ββ Was in tmp/? β EXPECTED (tmp/ purged on reboot)
β β β FIX: Move to Caches/ or Application Support/
β β
β ββ Was in Caches/? β System purged (storage pressure)
β β β FIX: Move to Application Support/ if can't be regenerated
β β
β ββ Protection level .complete? β Inaccessible until unlock
β β FIX: Wait for unlock or use .completeUntilFirstUserAuthentication
β
ββ Disappeared randomly (weeks later)
β ββ In Caches/? β System purged under storage pressure
β β β EXPECTED if re-downloadable
β β β FIX: Re-download when needed, or move to Application Support/
β β
β ββ In Documents or Application Support/?
β β Check if user deleted app (purges all data)
β β Check iOS update (rare, but check migration path)
β
ββ Only some files missing
β Check isExcludedFromBackup + iCloud sync
β Check if file names have special characters
β Check file permissions
Files Inaccessible
Can't access file?
ββ Error: "No permission" or NSFileReadNoPermissionError
β ββ Device locked? β Check file protection
β β ββ .complete protection? β Wait for unlock
β β β FIX: Use .completeUntilFirstUserAuthentication
β β
β ββ Background task accessing? β .complete blocks background
β β FIX: Change to .completeUntilFirstUserAuthentication
β
ββ File exists but read returns empty/nil
β ββ Check actual file size on disk
β β May be zero-byte file from failed write
β
ββ File exists in debugger but not at runtime
β Check if using wrong directory (Documents vs Caches)
β Check URL construction
Backup Too Large
App backup > 500 MB?
ββ Check Documents directory size
β ββ Large files (>10 MB each)?
β ββ Can they be re-downloaded? β Move to Caches + isExcludedFromBackup
β ββ User-created? β Keep in Documents (warn user if >1 GB)
β
ββ Check Application Support size
β ββ Downloaded media/podcasts?
β β Mark isExcludedFromBackup = true
β
ββ Audit backup with code:
```swift
func auditBackupSize() {
let docsURL = FileManager.default.urls(
for: .documentDirectory,
in: .userDomainMask
)[0]
let size = getDirectorySize(url: docsURL)
print("Documents (backed up): \(size / 1_000_000) MB")
}
```
Common Patterns by Symptom
Pattern 1: Files in tmp/ Disappear
Symptom: Temp files missing after restart or even during app lifecycle
Cause: tmp/ is purged aggressively by system
Fix:
// β WRONG: Using tmp/ for anything that should persistlet tmpURL =FileManager.default.temporaryDirectory
let fileURL = tmpURL.appendingPathComponent("data.json")try data.write(to: fileURL)// WILL BE DELETED// β CORRECT: Use Caches/ for re-generable datalet cacheURL =FileManager.default.urls(for:.cachesDirectory,in:.userDomainMask
)[0]let fileURL = cacheURL.appendingPathComponent("data.json")try data.write(to: fileURL)
Pattern 2: Caches Purged, Data Lost
Symptom: Downloaded content disappears weeks later
Cause: Caches/ is purged under storage pressure (expected behavior)
Fix: Either re-download on demand OR move to Application Support if can't be regenerated
βΊAccess to product documentation and roadmap tools (Jira, Notion, etc.)
βΊUnderstanding of product management frameworks (RICE, Jobs-to-be-Done, etc.)
βΊStakeholder contact information and communication channels
Time Estimate
30-60 minutes to see productivity improvements
Steps
1Install product management skill
2Start with user story generation for known feature
3Progress to competitive analysis: research 2-3 competitors
4Use for roadmap prioritization: apply RICE/ICE scoring
5Draft stakeholder communications and refine based on feedback
6Build template library for recurring PM tasks
7Share effective prompts with product team
Common Pitfalls
β Not validating competitive researchβverify facts before sharing
β Accepting user stories without involving engineering team
β Over-relying on frameworks without qualitative judgment
β Not customizing outputs to company culture and communication style
β Skipping stakeholder validation of generated requirements
Best Practices
β Do
+Validate research and competitive analysis with real data
+Collaborate with engineering when generating technical requirements
+Customize frameworks and templates to your company context
+Use skill for first drafts, refine with stakeholder input
+Document successful prompt patterns for PM tasks
+Combine AI efficiency with human judgment and intuition
β Don't
βDon't publish competitive analysis without fact-checking
βDon't finalize user stories without engineering review
βDon't make prioritization decisions solely on AI scoring
βDon't skip customer validation of generated requirements
βDon't ignore company-specific context and culture
π‘ Pro Tips
β Provide context: company goals, constraints, customer feedback
β Ask for alternatives: 'Show 3 ways to prioritize this roadmap'
β Request stakeholder-specific formatting: 'Executive summary vs. engineering spec'
β Use skill for 70% generation + 30% customization to company needs
When to Use This
β Use when
Use for user story writing, competitive research, roadmap prioritization, stakeholder communication, and PRD drafting. Best for reducing repetitive documentation and research work.
β Avoid when
Avoid for strategic product vision (requires deep customer empathy), pricing decisions (needs market and financial expertise), or when face-to-face customer discovery is more valuable than speed.
Learning Path
1Basic: user stories, feature specs, status updates