swift-concurrency-safety

swift-concurrency-safety is a skill for Claude Code, Codex from memi-design/design-skills. It costs 34 tokens per session (313 once invoked), scanned A, original, MIT.

A guide to handling simultaneous work safely in Swift 6 apps. It explains tasks, actors, cancellation, and rules for safely sharing values between concurrent operations.

In plain words
What is it for?
Use it when adding asynchronous features, migrating to Swift 6, fixing actor or Sendable errors, or reviewing cancellation and failure behavior.
Why use it?
It helps avoid data races, UI updates from the wrong thread, stuck work, and warnings that are hidden instead of properly resolved.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it when adding asynchronous features, migrating to Swift 6, fixing actor or Sendable errors, or reviewing cancellation and failure behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/memi-design/design-skills/swift-concurrency-safety
Install

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.

Any agent
npx skills add memi-design/design-skills --skill swift-concurrency-safety
Clone the repo
git clone --depth 1 https://github.com/memi-design/design-skills

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for swift-concurrency-safety

README.md
[![agentmods](https://agentmods.dev/badge/skills/memi-design/design-skills/swift-concurrency-safety/github.svg)](https://agentmods.dev/skills/memi-design/design-skills/swift-concurrency-safety)
Your own site
<a href="https://agentmods.dev/skills/memi-design/design-skills/swift-concurrency-safety"><img src="https://agentmods.dev/badge/skills/memi-design/design-skills/swift-concurrency-safety/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.

agentmods 80×15 button for swift-concurrency-safety

Your own site · 80×15
<a href="https://agentmods.dev/skills/memi-design/design-skills/swift-concurrency-safety"><img src="https://agentmods.dev/badge/skills/memi-design/design-skills/swift-concurrency-safety.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 34 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 313 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00034 $0.00313
Opus 5 $0.00017 $0.00156
Sonnet 5 $0.00007 $0.00063
Haiku 4.5 $0.00003 $0.00031

Measured 9d ago against content hash c223be2d4604, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

swift-concurrency-safety 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 9d ago.

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.

skills/swift-concurrency-safety/SKILL.md · 30 lines

What it actually says

Swift Concurrency Safety

Use this skill for async features, Swift 6 migration, actor-isolation errors, Sendable warnings, task cancellation, or UI work that crosses concurrency domains.

Workflow

  1. Record the target's Swift language mode and concurrency-checking settings.
  2. Map mutable state and its owner before adding tasks or annotations.
  3. Keep UI state on the main actor. Move long-running work behind async service boundaries instead of blocking the actor.
  4. Prefer structured child tasks. Use detached or unstructured tasks only when lifetime and cancellation are explicitly owned.
  5. Pass immutable Sendable values across isolation boundaries. Do not hide warnings with unchecked conformance until invariants are documented and tested.
  6. Propagate cancellation and define what partial work is rolled back or retained.
  7. Compile with the project's strictest supported concurrency checks and test ordering, cancellation, failure, and reentrancy.

Review failures

  • Actor annotations added only to silence diagnostics.
  • Task {} used as an ownership escape hatch.
  • UI-observable models mutated off the main actor.
  • Mutable reference types crossing actors without an isolation plan.
  • Continuations that can resume twice or never resume.
  • Async APIs with no cancellation or timeout behavior.

Read references/migration.md before changing language mode or performing a broad migration.

Files

What ships with it

2 files 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.

Changes

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.

  1. 9d ago First seen · 30 lines · 34 tokens per session scan A c223be2d4604

Subscribe to this mod's changes

swift-concurrency-safety is a skill published in the GitHub repository memi-design/design-skills (7 stars, last pushed 1mo ago), licensed MIT. It adds 34 tokens to every session and 313 once invoked, about $0.0002 per session on Opus 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-09-03.

Related

Other skills, from other repositories

swiftui-performance

Profile, diagnose, and remediate SwiftUI runtime performance using code review, Instruments, and repeatable measurements. Use when a SwiftUI screen renders slowly, scrolling or animations hitch, view bodies update excessively, list identity churns, layout work spikes, or broad Observation dependencies raise CPU cost.…

dpearson2699/swift-ios-skills · 87 tokens

ios-ettrace-performance

Use when capturing or analyzing ETTrace profiles for a focused iOS launch or runtime flow, including exact-build dSYM UUID matching, Simulator or device capture, processed per-thread flamegraph JSON, sampled inclusive/exclusive time, unresolved symbols, and comparable verification. Use debugging-instruments or…

dpearson2699/swift-ios-skills · 69 tokens

debugging-instruments

Debug iOS apps and profile performance using LLDB, the interactive Memory Graph Debugger, and Instruments. Use for crashes, retain-cycle inspection, hangs, build failures, and generic CPU, memory, energy, or network profiling. Use ios-memgraph-analysis for .memgraph capture, leaks CLI ownership paths, or persistent…

dpearson2699/swift-ios-skills · 85 tokens

agent-dart-build-resolver

Dart/Flutter build, analysis, and dependency error resolution specialist. Fixes dart analyze errors, Flutter compilation failures, pub dependency conflicts, and buildrunner issues with minimal, surgical changes. Use when Dart/Flutter builds fail.

KunanonJ/ai-skills-hub · 55 tokens

rn-metro-console

Use when you need to read a running React Native app's console output — confirm a log fired, watch console.warn/error, or verify runtime behavior — without opening the DevTools GUI. Reads logs from Metro's CDP endpoint; bounded by default. Read-only with respect to project source. Runs the bundled rn-console.mjs…

AndrewDongminYoo/rn-agents-kit · 72 tokens

activitykit

Implement, review, or improve Live Activities and Dynamic Island experiences in iOS apps using ActivityKit. Use when building real-time updating widgets for the Lock Screen and Dynamic Island — delivery tracking, sports scores, ride-sharing status, workout timers, media playback, or any time-sensitive information that…

dpearson2699/swift-ios-skills · 105 tokens