CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

golang-design-patterns

Idiomatic Golang design patterns — functional options, constructor APIs, `init()` and global-state avoidance, enums, panic vs error decisions, resource management and lifecycle, graceful shutdown, timeouts and retries, streaming and iterators, and architecture styles (clean, hexagonal, DDD, flat). Apply when choosing between architectural patterns, implementing functional options, designing constructor APIs, setting up graceful shutdown, applying resilience patterns, or asking which idiomatic Go pattern fits a specific problem. Not for wiring a DI container or comparing DI libraries (→ See `samber/cc-skills-golang@golang-dependency-injection` skill), nor for error wrapping, `errors.Is`/`As`, or logging mechanics (→ See `samber/cc-skills-golang@golang-error-handling` skill).

68

Quality

85%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Quality

Content

72%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

A well-structured overview-first skill: lean idiomatic code inline, genuine one-level-deep reference files that all exist, and clear cross-referencing to sibling skills. Weaknesses are the duplicated best-practices summary that restates later sections, a couple of prose-only or pointer-only sections, and only implicit workflow sequencing for its design/review modes.

Suggestions

Trim duplication: the 21-item 'Best Practices Summary' repeats items (1, 2, 3, 7, 9, 10, 11) that later sections cover in detail — either cut the overlapping items or shorten the detailed sections to pointers where the summary line already suffices.

Add a short executable example to the 'Retry & Context Checks' section (a select on ctx.Done() with backoff), matching the code density of the other pattern sections.

Make the Design/Review mode workflows slightly more explicit — e.g., a 3-step sequence for review mode (scan → report findings → propose refactors) so mode behavior doesn't depend on inference.

DimensionReasoningScore

Conciseness

The body is dense and idiom-focused with tight code blocks and Go-specific rationale ('multiple init() functions run in declaration order... in filename alphabetical order — fragile'), but the 21-item 'Best Practices Summary' restates roughly ten items that the later sections then repeat in detail, which is trimming opportunity. Not 5 because of that deliberate duplication; not 3 because virtually every sentence carries non-generic guidance rather than padding.

4 / 5

Actionability

Mostly executable guidance: copy-paste-ready Go for functional options, init() avoidance, enums, package-level regexp, embed, defer Close, and context timeouts, with bad/good contrasts. Not 5 because a few sections give only prose or bare pointers — 'Retry logic MUST check ctx.Err() between attempts' has no code, and 'Database Patterns' and 'Compile-Time Interface Checks' are single-line redirects.

4 / 5

Workflow Clarity

The two 'Modes' provide brief sequencing ('ask the developer about their architecture preference before proposing patterns'; 'report findings before suggesting refactors'), but the skill is primarily a pattern reference: no explicit multi-step workflow, no validation checkpoints, and review-mode findings criteria are listed only as a one-line scan hint. Not 4 because checkpoints/sequences are implicit rather than 'mostly present'; not 2 because the mode structure does define a coherent order of operations. No destructive/batch cap applies.

3 / 5

Progressive Disclosure

The SKILL.md body stays an overview (core patterns with compact code) while detail is split across six real reference files — data-handling.md, resource-management.md, architecture.md, clean-architecture.md, hexagonal-architecture.md, ddd.md — all referenced one level deep with a 'Detailed Guides' table describing each file's scope, and cross-references to sibling skills for out-of-scope topics. All referenced paths exist on disk and none of the reference files nest further references.

5 / 5

Total

16

/

20

Passed

Description

92%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

An exemplary description: concrete capability enumeration, explicit 'Apply when' triggers, and a 'Not for' clause with redirects that sharply reduces conflict with sibling skills. The only weakness is mild — a few natural synonyms (plain 'Go', file extensions) are missing from the trigger terms.

DimensionReasoningScore

Specificity

The description enumerates multiple concrete capabilities — 'functional options, constructor APIs, init() and global-state avoidance, enums, panic vs error decisions, resource management and lifecycle, graceful shutdown, timeouts and retries, streaming and iterators, and architecture styles (clean, hexagonal, DDD, flat)' — comprehensive coverage with no vague filler. Not below 5 because no significant capability area of the skill is missing from the enumeration.

5 / 5

Completeness

Both questions are answered explicitly: the 'what' is the long capability enumeration, and the 'when' is the concrete 'Apply when choosing between architectural patterns, implementing functional options, designing constructor APIs, setting up graceful shutdown, applying resilience patterns, or asking which idiomatic Go pattern fits a specific problem' clause — plus a 'Not for...' exclusion list. It clearly exceeds the 4 anchor, whose 'when' is present but less explicit.

5 / 5

Trigger Term Quality

Trigger phrases like 'implementing functional options', 'designing constructor APIs', 'setting up graceful shutdown', 'applying resilience patterns', and 'choosing between architectural patterns' match natural user phrasing, and 'Golang' plus named styles (clean, hexagonal, DDD) aid discovery. Not 5: some natural synonyms are absent (e.g., plain 'Go', '.go' file extension, 'interfaces', 'project structure'), so coverage is good but not exhaustive.

4 / 5

Distinctiveness Conflict Risk

Clear Go design niche with explicit de-scoping of adjacent territory — 'Not for wiring a DI container or comparing DI libraries... nor for error wrapping, errors.Is/As, or logging mechanics' — each redirecting to a named sibling skill, so mis-trigger risk against overlapping skills is minimal. No broader anchor fits better.

5 / 5

Total

19

/

20

Passed

Validation

93%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 15 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

metadata_field

'metadata' should map string keys to string values

Warning

Total

15

/

16

Passed

Repository

samber/cc-skills-golang

Path

skills/golang-design-patterns/SKILL.md

Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.