go-library

Apply Go library design patterns for extensible APIs and modular packages.

1|Updated Jan 9, 2026
One-click install
npx skills add https://github.com/JaimeStill/claude-context --skill go-library
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: go-library
Source: https://github.com/JaimeStill/claude-context/tree/main/plugins/go-development/skills/go-library
Command: npx skills add https://github.com/JaimeStill/claude-context --skill go-library

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Go library design often suffers from scattered patterns and unclear boundaries, making it hard to create reusable, extensible packages. This Skill provides structured guidelines to help teams craft maintainable APIs and predictable library boundaries.

Core Features & Use Cases

  • Format Extensibility Pattern: Extend library capabilities by adding new formats without modifying core internals.
  • Provider-Format Separation: Keep provider integration concerns isolated from format logic to improve modularity and testability.
  • Library Scope Definition: Clearly define what the library provides and what is intentionally out of scope to prevent drift.
  • Supplemental Package Pattern: Guide safe growth through higher-level extensions that depend on the core library.

Quick Start

Create a new library following the patterns above: initialize a module, implement a basic API, register an extensible format, and separate provider concerns into dedicated packages.

Frequently Asked Questions about go-library

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

FAQPage Schema
How do I design extensible Go libraries without modifying core internals?

To design extensible Go libraries, apply the Format Extensibility Pattern to add new formats without modifying core internals. This approach keeps packages modular and allows capabilities to grow safely.

What is the best way to separate providers from format logic in Go packages?

The best way to separate providers from format logic is Provider-Format Separation. This pattern isolates provider integration concerns into dedicated packages to improve modularity and testability.

How do I define boundaries for a Go package to prevent scope drift?

Define boundaries for a Go package using Library Scope Definition. This pattern specifies what the library provides and what is intentionally out of scope to prevent feature drift and maintain predictable APIs.

Can I add higher-level extensions that depend on a core Go library?

Yes, you can add higher-level extensions using the Supplemental Package Pattern. This pattern guides safe growth by allowing extensions to depend on the core library without coupling directly to its internals.

When should I structure my reusable APIs in the pkg directory in Go?

Structure reusable APIs in the pkg directory when building modular packages intended for external consumption. This location clearly signals public availability and helps enforce predictable library boundaries.