add-pattern — Claude Code skill: what it does, how to install
Save Langroid design patterns for later use with a catalog entry and a separate implementation document containing code examples.
npx skills add pchalasani/claude-code-tools --skill add-pattern -a claude-codeWhat add-pattern does
When you encounter a Langroid design pattern, this skill records it in the project. It adds the pattern’s goal to the relevant section of patterns/SKILL.md and links to a dedicated document in patterns/.
That document explains the implementation idea and includes code examples. Its sections are Problem, Solution, Complete Code Example, Key Points, and When to Use. The catalog description is meant to help an agent match the pattern to future problems. The instructions are specific to Langroid patterns, so they don’t provide a workflow for documenting patterns from other frameworks.
What it helps with
- record a Langroid pattern in the catalog
- describe a pattern’s goal for later matching
- link a catalog entry to its implementation document
- organize a pattern write-up with code examples
Example prompts for the agent
- Save this Langroid pattern in the right catalog section and create its implementation document.
- Record the pattern for later use, with its goal and a link in
patterns/SKILL.md. - Document this Langroid pattern using Problem, Solution, and When to Use sections.
How to install add-pattern
1Skills CLI (Vercel)
npx skills add pchalasani/claude-code-tools --skill add-pattern -a claude-code2Manually: put the files in place
~/.claude/skills/add-pattern/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/add-pattern/
1Skills CLI (Vercel)
npx skills add pchalasani/claude-code-tools --skill add-pattern -a codex2Manually: put the files in place
.agents/skills/add-pattern/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add pchalasani/claude-code-tools --skill add-pattern -a cursor2Manually: put the files in place
.cursor/skills/add-pattern/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install pchalasani/claude-code-tools add-pattern2Manually: put the files in place
.github/skills/add-pattern/SKILL.md1Skills CLI (Vercel)
npx skills add pchalasani/claude-code-tools --skill add-pattern -a gemini-cli2Platform CLI
gemini skills install https://github.com/pchalasani/claude-code-tools --path plugins/langroid/skills/add-patternManually: put the files in place
.devin/skills/add-pattern/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add pchalasani/claude-code-tools --skill add-pattern -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 add-pattern
How do I install add-pattern in Claude Code?
Run npx skills add pchalasani/claude-code-tools --skill add-pattern -a claude-code. The skill file is at ~/.claude/skills/add-pattern/SKILL.md.
What does add-pattern do?
It records Langroid patterns by adding a goal and document link to patterns/SKILL.md, then describing the implementation and code examples in a separate file.
What sections does the pattern document use?
It follows the sections Problem, Solution, Complete Code Example, Key Points, and When to Use.
Source text
SKILL.md · MIT
--- name: add-pattern description: Use this skill when you learn one or more design pattern(s) in the Langroid (multi) agent framework, and want to make a note for future reference for yourself. Use this either autonomously, or when asked by the user to record a new pattern. --- # add-pattern ## Instructions When you learn a new Langroid design pattern, do the following: 1. Add an entry in the sibling `patterns/SKILL.md` file in the appropriate category section, containing a DESCRIPTION of the goal of the pattern (i.e. what it enables you to implement), accompanied by a `- Reference:` pointer to a markdown DOCUMENT in the `patterns/` directory. IMPORTANT - The DESCRIPTION should be clear enough that future YOU can effectively use it to MATCH design problems you may encounter in future. 2. In that DOCUMENT, describe the idea of the implementation along with code examples. Follow the format of existing pattern files (Problem, Solution, Complete Code Example, Key Points, When to Use).
© pchalasani · MIT · pchalasani/claude-code-tools