Charles Xu publishes agent skills focused on idiomatic Go, guiding an AI agent through concurrency with goroutines, channels and mutexes, slice and map handling, error wrapping and propagation, interface design, functional options for constructors, structured logging with slog, and golangci-lint setup in CI pipelines. The skills stand out for their clear scope boundaries, each naming the adjacent topics it leaves to other skills, which helps an agent apply the right guidance to the task at hand.
Golang Skills
20 skills · 191 stars · Apache-2.0
Go Code Review Use when reviewing Go code or checking code against community style standards.
Go Concurrency Use when writing concurrent Go code — goroutines, channels, mutexes, or thread-safety guarantees.
Go Context Use when working with context.Context in Go — placement in signatures, propagating cancellation a…
Go Control Flow Use when writing conditionals, loops, or switch statements in Go — including if with initializati…
Go Data Structures Use when working with Go slices, maps, or arrays — choosing between new and make, using append, d…
Go Declarations Use when declaring or initializing Go variables, constants, structs, or maps — including var vs :…
Go Defensive Use when hardening Go code at API boundaries — copying slices/maps, verifying interface complianc…
Go Documentation Use when writing or reviewing documentation for Go packages, types, functions, or methods.
Go Error Handling Use when writing Go code that returns, wraps, or handles errors — choosing between sentinel error…
Go Functional Options Use when designing a Go constructor or factory function with optional configuration — especially…
Go Functions Use when organizing functions within a Go file, formatting function signatures, designing return…
Go Generics Use when deciding whether to use Go generics, writing generic functions or types, choosing constr…
Go Interfaces Use when defining or implementing Go interfaces, designing abstractions, creating mockable bounda…
Go Linting Use when setting up linting for a Go project, configuring golangci-lint, or adding Go checks to a…
Go Logging Use when choosing a logging approach, configuring slog, writing structured log statements, or dec…
Go Naming Use when naming any Go identifier — packages, types, functions, methods, variables, constants, or…
Go Packages Use when creating Go packages, organizing imports, managing dependencies, or deciding how to stru…
Go Performance Use when optimizing Go code, investigating slow performance, or writing performance-critical sect…
Go Style Core Use when working with Go formatting, line length, nesting, naked returns, semicolons, or core sty…
Go Testing Use when writing, reviewing, or improving Go test code — including table-driven tests, subtests,…