golang-expert

Provide expert guidance on Go concurrency patterns and idiomatic design.

4|1|Updated Mar 3, 2026
One-click install
npx skills add https://github.com/aegntic/clawreform --skill golang-expert-aegntic
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: golang-expert
Source: https://github.com/aegntic/clawreform/tree/main/crates/clawreform-skills/bundled/golang-expert
Command: npx skills add https://github.com/aegntic/clawreform --skill golang-expert-aegntic

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides expert guidance on writing idiomatic, efficient, and concurrent Go code, helping developers avoid common pitfalls and leverage the full power of the Go language.

Core Features & Use Cases

  • Concurrency Patterns: Expert advice on goroutines, channels, sync package, and errgroup.
  • Idiomatic Design: Guidance on interfaces, error handling, package design, and functional options.
  • Use Case: A developer is struggling to implement a performant, concurrent data processing pipeline in Go. They can consult this Skill for best practices on using channels, worker pools, and context propagation to achieve their goal.

Quick Start

Explain the fan-out/fan-in pattern in Go with a code example.

Frequently Asked Questions about golang-expert

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement a fan-out/fan-in concurrency pattern in Go?▼

The fan-out/fan-in concurrency pattern in Go is implemented by launching multiple goroutines to distribute work and using channels to collect the results. This pattern leverages goroutines and channels to parallelize data processing efficiently.

What is the best way to handle errors in concurrent Go goroutines?▼

Handling errors in concurrent Go goroutines is best achieved using the `errgroup` package and context propagation. This approach ensures that explicit error handling and cancellation are managed clearly across concurrent operations.

How do I use interfaces and functional options for idiomatic Go design?▼

Interfaces and functional options for idiomatic Go design are used to create flexible and explicit APIs. Defining small interfaces and passing configuration functions allows for clear package design and testable code structures.

When should I use channels versus the sync package in Go?▼

Channels in Go should be used for communicating data between goroutines, while the `sync` package is for protecting shared memory access. Choosing between them depends on whether you need data ownership transfer or mutex-protected state.

How does context propagation work in a Go data processing pipeline?▼

Context propagation in a Go data processing pipeline works by passing a `context.Context` through function calls. This ensures cancellation signals and deadlines are respected across goroutines and channels in the pipeline.

Why does my Go code lack explicit and performant design?▼

Your Go code may lack explicit and performant design if it avoids idiomatic patterns like proper error handling and package structuring. Writing clear Go code requires leveraging concurrency patterns and context propagation correctly.