Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add rshankras/claude-code-apple-skills --skill memorygit clone --depth 1 https://github.com/rshankras/claude-code-apple-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/rshankras/claude-code-apple-skills/memory)<a href="https://agentmods.dev/skills/rshankras/claude-code-apple-skills/memory"><img src="https://agentmods.dev/badge/skills/rshankras/claude-code-apple-skills/memory/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/rshankras/claude-code-apple-skills/memory"><img src="https://agentmods.dev/badge/skills/rshankras/claude-code-apple-skills/memory.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00036 | $0.03436 |
| Opus 5.5 | $0.00014 | $0.01374 |
| Sonnet 5.5 | $0.00007 | $0.00687 |
| Haiku 4.5 | $0.00004 | $0.00344 |
Grade A, and why
memory scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 359 lines — stays where its author put it; the contents beside it link to each section on GitHub.
InlineArray and Span
Guidance for Swift 6.2's low-level memory types: InlineArray for fixed-size inline storage without heap allocation, and Span for safe, zero-cost access to contiguous memory. These replace common uses of UnsafeBufferPointer and hand-tuned tuple storage with compiler-checked alternatives.
When This Skill Activates
Use this skill when the user:
- Asks about InlineArray, fixed-size arrays, or stack-allocated collections
- Mentions Span, MutableSpan, RawSpan, or UTF8Span
- Wants to eliminate heap allocations in hot paths
- Is replacing UnsafeBufferPointer or UnsafePointer with safe alternatives
- Asks about value generics or
let count: Intgeneric parameters - Needs zero-copy access to collection storage
- Mentions inline storage, contiguous memory, or memory layout
- Is doing binary parsing, signal processing, or embedded Swift work
- Wants to avoid copy-on-write overhead for small fixed collections
- Asks about non-escapable types or lifetime dependencies in Swift
Decision Tree
What memory optimization do you need?
│
├─ A fixed-size collection that never grows/shrinks
│ │
│ ├─ Size known at compile time, stored on stack
│ │ └─ InlineArray<N, Element>
│ │ ├─ No heap allocation
│ │ ├─ No reference counting
│ │ └─ No copy-on-write (eager copies)
│ │
│ └─ Size may vary at runtime
│ └─ Array<Element> (standard library)
│
├─ Safe read access to contiguous memory
│ │
│ ├─ Read-only access to typed elements
│ │ └─ Span<Element>
│ │
│ ├─ Mutable access to typed elements
│ │ └─ MutableSpan<Element>
│ │
│ ├─ Read-only access to raw bytes
│ │ └─ RawSpan
│ │
│ ├─ Mutable access to raw bytes
│ │ └─ MutableRawSpan
│ │
│ ├─ Unicode text processing
│ │ └─ UTF8Span
│ │
│ └─ Initializing a new collection's storage
│ └─ OutputSpan
│
├─ Unsafe pointer access (legacy or interop)
│ └─ UnsafeBufferPointer / UnsafeMutableBufferPointer
│ └─ Prefer Span instead for new code
│
└─ Standard dynamic collection
└─ Array<Element>
├─ Heap-allocated, copy-on-write
└─ Grows/shrinks dynamically
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 359 lines · 36 tokens per session scan A 71bf7bb3ecc9
memory is a skill published in the GitHub repository rshankras/claude-code-apple-skills (864 stars, last pushed 2d ago), licensed MIT. It adds 36 tokens to every session and 3,436 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-05.
memory compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| memoryrshankras/claude-code-apple-skills | Skill | 864 | 2d ago | MIT | A | 36 | Claude Code |
| swift-expertpersonamanagmentlayer/pcl | Skill | 44 | 11d ago | Apache-2.0 | A | 76 | Claude Code |
| ios-expertpersonamanagmentlayer/pcl | Skill | 44 | 11d ago | Apache-2.0 | A | 64 | Claude Code |
| swift6-concurrencymarkdavidgan/apple-dev-skills | Skill | 5 | 2mo ago | MIT | A | 74 | Claude Code |
| ios-swiftui-productJasonColapietro/ios-app-dev-skills | Skill | 9 | 2mo ago | MIT | A | 67 | Codex |
| swiftui-maxDev869/swift-tothemax | Skill | 7 | 4mo ago | MIT | A | 271 | Claude Code |
| swift-languageDev869/swift-tothemax | Skill | 7 | 4mo ago | MIT | A | 167 | Claude Code |