Swift Concurrency Agent Skill
Expert guidance for any AI coding tool that supports the Agent Skills open format — safe concurrency, performance, and Swift 6+ migration.
Based on the comprehensive Swift Concurrency Course, distilled into actionable, concise references for agents.
This repository is packaged as a portable Agent Plugin (spec 1.0.0): compatible clients discover the skill automatically from the root plugin.json manifest and the skills/ directory. Client-specific manifests for Claude Code, Cursor, Codex, and pi are included as well, and the plugin is published in the OpenAI Plugins Directory for ChatGPT and Codex.
Who this is for
- Teams migrating to Swift 6 / strict concurrency who need safe defaults and quick triage.
- Developers debugging data races, isolation errors, or flaky async tests.
- Anyone wanting performance-minded concurrency patterns (actors, tasks, Sendable, async streams).
See also my other skills:
How to Use This Skill
Option A: Using skills.sh (recommended)
Install this skill with a single command:
npx skills@latest add https://github.com/avdlee/swift-concurrency-agent-skill --skill swift-concurrency
For more information, visit the skills.sh platform page.
Installed before the Agent Plugins migration? Run npx skills@latest update using skills CLI 1.5.24 or newer. It migrates the saved skill path without treating the skill as deleted.
Then use the skill in your AI agent, for example:
Use the swift concurrency skill and analyze the current project for Swift Concurrency improvements
Option B: ChatGPT & Codex (OpenAI Plugins Directory)
This plugin is published in the universal OpenAI Plugins Directory shared by ChatGPT and Codex:
- In the ChatGPT desktop app, select Codex (or ChatGPT with Work enabled), or use the plugin browser in Codex CLI.
- Open Plugins and search for "Swift Concurrency".
- Install the plugin. The skill becomes available in new chats and sessions.
Option C: Claude Code Plugin
Personal Usage
To install this Skill for your personal use in Claude Code:
-
Add the marketplace:
/plugin marketplace add AvdLee/Swift-Concurrency-Agent-Skill
-
Install the Skill:
/plugin install swift-concurrency@swift-concurrency-agent-skill
Project Configuration
To automatically provide this Skill to everyone working in a repository, configure the repository's .claude/settings.json:
{
"enabledPlugins": {
"swift-concurrency@swift-concurrency-agent-skill": true
},
"extraKnownMarketplaces": {
"swift-concurrency-agent-skill": {
"source": {
"source": "github",
"repo": "AvdLee/Swift-Concurrency-Agent-Skill"
}
}
}
}
When team members open the project, Claude Code will prompt them to install the Skill.
Option D: Cursor Plugin
Load the plugin from a local clone by placing it in ~/.cursor/plugins/local, or install it from the Cursor Marketplace once listed. Cursor supports both the portable Agent Plugins manifest (plugin.json) and the Cursor Plugin manifest (.cursor-plugin/plugin.json) included in this repository.
Using another tool?
See INSTALLATION.md for all other installation options: pi, Gemini CLI, Autohand Code, and manual installation.
How to verify:
Your agent should reference the triage/playbook in skills/swift-concurrency/SKILL.md and jump into the relevant reference file for your error or task.
What This Skill Offers
This skill gives your AI coding tool comprehensive Swift Concurrency guidance. It can:
Guide Your Concurrency Decisions
- Choose the right tool for the job (async/await, actors, tasks, task groups)
- Understand when to use
@MainActor, custom actors, or nonisolated
- Navigate isolation domains and prevent data races at compile time
- Apply
Sendable conformance correctly for value and reference types
Write Safe Concurrent Code
- Avoid common pitfalls like actor reentrancy and retain cycles
- Prevent data races with proper isolation
- Handle task cancellation and error propagation correctly
- Manage memory safely in concurrent contexts