Swift concurrency

From ravnhq/ai-toolkit · View interactive version

Swift concurrency is an AI agent skill from the GitHub repository ravnhq/ai-toolkit. Swift Concurrency patterns — async/await, actors, tasks, Sendable conformance. Use when writing async/await code, implementing actors, working with structured concurrency, or ensuring data race safety.

How to use this skill

Skill file

Swift Concurrency Patterns

Expert guidance on Swift Concurrency best practices covering async/await, actors, tasks, Sendable, threading, memory management, testing, and migration strategies.

Rules

Core Swift Concurrency rules extracted as discrete, high-impact patterns. See rules index for the full list organized by:

References

See references/swift-concurrency.md for comprehensive guidance organized by:

Examples

Positive Trigger

User: "Refactor callback-based network code to async/await with actor isolation."

Expected behavior: Use swift-concurrency guidance, follow its workflow, and return actionable output.

Non-Trigger

User: "Refactor CSS grid layout for mobile breakpoints."

Expected behavior: Do not prioritize swift-concurrency; choose a more relevant skill or proceed without it.

Troubleshooting

Skill Does Not Trigger

Guidance Conflicts With Another Skill

Output Is Too Generic

Workflow

  1. Identify whether the request clearly matches swift-concurrency scope and triggers.
  2. Apply the skill rules and referenced guidance to produce a concrete result.
  3. Validate output quality against constraints; if gaps remain, refine once with explicit assumptions.
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.