What problem does it solve? Writing correct concurrent Go code is error-prone: goroutine leaks, race conditions, channel ownership violations, and deadlocks are common and hard to detect. This Skill provides structured guidance for writing, reviewing, and auditing concurrent Go code so every goroutine has a clear exit, channels have defined ownership, and shared state is properly synchronized. ## Core Features & Use Cases - Write mode: Implement goroutines, channels, select loops, worker pools, and fan-out/fan-in pipelines following structured concurrency rules (context cancellation, sender-closes-channel, unbuffered-by-default). - Review mode: Check PR diffs for goroutine leaks, missing ctx.Done() in select, WaitGroup Add/Done ordering bugs, and unprotected shared state. - Audit mode: Run up to 5 parallel sub-agents to audit an entire codebase for concurrency anti-patterns. - Decision tables: Choose between channels vs mutexes vs atomics, WaitGroup vs errgroup, sync.Map vs RWMutex+map, and iterators vs goroutine pipelines. - Use Case: You need to fetch 50 URLs concurrently with at most 10 in flight and cancel everything on the first error — the Skill guides you to errgroup.WithContext with SetLimit(10) instead of a hand-rolled worker pool. ## Quick Start Ask the agent to review your Go code for goroutine leaks and race conditions, or to write a bounded worker pool using errgroup.