gof-design-patterns — Claude Code skill: GoF patterns in 8 languages
gof-design-patterns finds the right Gang of Four pattern for the problem you describe and writes a working implementation in one of eight languages.
no license 145 installs ★ 25 updated 2026-02-19
npx skills add markpitt/claude-skills --skill gof-design-patterns -a claude-codeWhat gof-design-patterns does
Describe a design problem and the skill picks a pattern from the creational, structural or behavioral group, says why it fits, then writes the code. You get a usage example, the trade-offs, notes on the idioms of your chosen language and a hint on how to test the result. Reference files ship with it: a selection guide and per-category pattern write-ups.
Eight languages are covered: C#, Rust, Python, Dart, Go, GenAIScript, TypeScript and C. Ask for Java or Kotlin and the code half of the answer disappears, leaving only the pattern choice and the reasoning.
You can also name a pattern outright, ask for two that work together (a Factory that produces Strategy objects), or compare lookalikes such as Strategy and State. Everything comes from your description, so a vague request tends to return a generic pattern. Say what varies in your code and what stays fixed.
What it helps with
- pick a pattern for payments that run through several providers
- write a Builder in TypeScript for a config object
- compare Strategy and State on real examples
- combine Factory and Strategy in Rust
- get a working Observer example in Go
Example prompts for the agent
- Payments go through several providers with different interfaces, which pattern fits and show me the Python code
- Write a Builder in TypeScript for my config object with a fluent interface
- Show Factory and Strategy together in Rust and explain why you would pair them
How to install gof-design-patterns
1Skills CLI (Vercel)
npx skills add markpitt/claude-skills --skill gof-design-patterns -a claude-code2Manually: put the files in place
~/.claude/skills/gof-design-patterns/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/gof-design-patterns/
1Skills CLI (Vercel)
npx skills add markpitt/claude-skills --skill gof-design-patterns -a codex2Manually: put the files in place
.agents/skills/gof-design-patterns/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add markpitt/claude-skills --skill gof-design-patterns -a cursor2Manually: put the files in place
.cursor/skills/gof-design-patterns/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install markpitt/claude-skills skills/gof-design-patterns2Manually: put the files in place
.github/skills/gof-design-patterns/SKILL.md1Skills CLI (Vercel)
npx skills add markpitt/claude-skills --skill gof-design-patterns -a gemini-cli2Platform CLI
gemini skills install https://github.com/markpitt/claude-skills --path skills/gof-design-patternsManually: put the files in place
.devin/skills/gof-design-patterns/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add markpitt/claude-skills --skill gof-design-patterns -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about gof-design-patterns
How do I install gof-design-patterns in Claude Code?
Run npx skills add markpitt/claude-skills --skill gof-design-patterns -a claude-code. The skill lands at ~/.claude/skills/gof-design-patterns/SKILL.md.
What does gof-design-patterns do?
It reads the problem you describe, recommends a GoF pattern and writes an implementation in the language you name, with a usage example and the trade-offs.
Which languages does it cover?
C#, Rust, Python, Dart, Go, GenAIScript, TypeScript and C. For anything else you still get the pattern recommendation and the reasoning behind it.