원클릭으로
local-skills-setup
Set up and manage local skills for automatic matching and invocation
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Set up and manage local skills for automatic matching and invocation
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
AI-native code annotation protocol that encodes intent, risk, dependencies, constraints, and test expectations in machine-parseable comments.
Professional Codex-native multi-agent code review with confidence scoring
架构规划专家 - 使用 Codex 本地上下文、仓库证据和只读 child agent 进行大型系统架构设计与规划。
Backend architecture patterns, API design, database optimization, and server-side best practices for Node.js, Express, and Next.js API routes.
Imported from everything-codex command checkpoint
Universal coding standards, best practices, and patterns for TypeScript, JavaScript, React, and Node.js development.
SOC 직업 분류 기준
| name | local-skills-setup |
| description | Set up and manage local skills for automatic matching and invocation |
| argument-hint | [list|add|scan] |
| version | 0.1.0 |
| source | fork |
| checksum | c2f00039734d6ce242eb934aedf12667b53ac3908b85ade875f0316c3e3d848d |
| updated_at | "2026-02-11T01:29:16.000Z" |
| layer | meta |
Codex supports native subagents. Delegate with spawn_agent, coordinate with send_input, collect via wait_agent, and clean up with close_agent.
Execution preference:
[ANALYST]/[ARCHITECT]/[EXECUTOR]/[REVIEWER] structure in a single response.Minimal orchestration pattern:
spawn_agent -> send_input (optional) -> wait_agent -> close_agent
Codex invocation: use
$local-skills-setup ...orlocal-skills-setup: ...
This skill provides a guided wizard for setting up and managing your local learned skills. Skills are reusable problem-solving patterns that Codex automatically applies when it detects matching triggers.
Local skills allow you to capture hard-won insights and solutions that are specific to your codebase or workflow:
When you solve a tricky bug or discover a non-obvious workaround, you can extract it as a skill. Codex will automatically detect and apply these skills in future conversations when it sees matching triggers.
First, check if skill directories exist and create them if needed:
# Check and create user-level skills directory
USER_SKILLS_DIR="$HOME/.codex/skills/omc-learned"
if [ -d "$USER_SKILLS_DIR" ]; then
echo "User skills directory exists: $USER_SKILLS_DIR"
else
mkdir -p "$USER_SKILLS_DIR"
echo "Created user skills directory: $USER_SKILLS_DIR"
fi
# Check and create project-level skills directory
PROJECT_SKILLS_DIR=".omc/skills"
if [ -d "$PROJECT_SKILLS_DIR" ]; then
echo "Project skills directory exists: $PROJECT_SKILLS_DIR"
else
mkdir -p "$PROJECT_SKILLS_DIR"
echo "Created project skills directory: $PROJECT_SKILLS_DIR"
fi
Scan both directories and show a comprehensive inventory:
# Scan user-level skills
echo "=== USER-LEVEL SKILLS (~/.codex/skills/omc-learned/) ==="
if [ -d "$HOME/.codex/skills/omc-learned" ]; then
USER_COUNT=$(find "$HOME/.codex/skills/omc-learned" -name "*.md" 2>/dev/null | wc -l)
echo "Total skills: $USER_COUNT"
if [ $USER_COUNT -gt 0 ]; then
echo ""
echo "Skills found:"
find "$HOME/.codex/skills/omc-learned" -name "*.md" -type f -exec sh -c '
FILE="$1"
NAME=$(grep -m1 "^name:" "$FILE" 2>/dev/null | sed "s/name: //")
DESC=$(grep -m1 "^description:" "$FILE" 2>/dev/null | sed "s/description: //")
MODIFIED=$(stat -c "%y" "$FILE" 2>/dev/null || stat -f "%Sm" "$FILE" 2>/dev/null)
echo " - $NAME"
[ -n "$DESC" ] && echo " Description: $DESC"
echo " Modified: $MODIFIED"
echo ""
' sh {} \;
fi
else
echo "Directory not found"
fi
echo ""
echo "=== PROJECT-LEVEL SKILLS (.omc/skills/) ==="
if [ -d ".omc/skills" ]; then
PROJECT_COUNT=$(find ".omc/skills" -name "*.md" 2>/dev/null | wc -l)
echo "Total skills: $PROJECT_COUNT"
if [ $PROJECT_COUNT -gt 0 ]; then
echo ""
echo "Skills found:"
find ".omc/skills" -name "*.md" -type f -exec sh -c '
FILE="$1"
NAME=$(grep -m1 "^name:" "$FILE" 2>/dev/null | sed "s/name: //")
DESC=$(grep -m1 "^description:" "$FILE" 2>/dev/null | sed "s/description: //")
MODIFIED=$(stat -c "%y" "$FILE" 2>/dev/null || stat -f "%Sm" "$FILE" 2>/dev/null)
echo " - $NAME"
[ -n "$DESC" ] && echo " Description: $DESC"
echo " Modified: $MODIFIED"
echo ""
' sh {} \;
fi
else
echo "Directory not found"
fi
# Summary
TOTAL=$((USER_COUNT + PROJECT_COUNT))
echo "=== SUMMARY ==="
echo "Total skills across all directories: $TOTAL"
After scanning, offer these options in plain text with numbered choices:
Question: "What would you like to do with your local skills?"
Options:
If user chooses "Add new skill", invoke the learner skill:
Use the Skill tool to invoke: learner
This will guide them through the extraction process with quality validation.
Show detailed information including trigger keywords:
echo "=== DETAILED SKILL INVENTORY ==="
echo ""
# Function to show skill details
show_skill_details() {
FILE="$1"
LOCATION="$2"
echo "---"
echo "Location: $LOCATION"
echo "File: $(basename "$FILE")"
# Extract frontmatter
NAME=$(grep -m1 "^name:" "$FILE" 2>/dev/null | sed "s/name: //")
DESC=$(grep -m1 "^description:" "$FILE" 2>/dev/null | sed "s/description: //")
TRIGGERS=$(grep -m1 "^triggers:" "$FILE" 2>/dev/null | sed "s/triggers: //")
QUALITY=$(grep -m1 "^quality:" "$FILE" 2>/dev/null | sed "s/quality: //")
[ -n "$NAME" ] && echo "Name: $NAME"
[ -n "$DESC" ] && echo "Description: $DESC"
[ -n "$TRIGGERS" ] && echo "Triggers: $TRIGGERS"
[ -n "$QUALITY" ] && echo "Quality: $QUALITY"
# Last modified
MODIFIED=$(stat -c "%y" "$FILE" 2>/dev/null | cut -d. -f1 || stat -f "%Sm" "$FILE" 2>/dev/null)
echo "Last modified: $MODIFIED"
echo ""
}
# Export function for subshell
export -f show_skill_details
# Show user-level skills
if [ -d "$HOME/.codex/skills/omc-learned" ]; then
echo "USER-LEVEL SKILLS:"
find "$HOME/.codex/skills/omc-learned" -name "*.md" -type f -exec bash -c 'show_skill_details "$0" "user-level"' {} \;
fi
# Show project-level skills
if [ -d ".omc/skills" ]; then
echo "PROJECT-LEVEL SKILLS:"
find ".omc/skills" -name "*.md" -type f -exec bash -c 'show_skill_details "$0" "project-level"' {} \;
fi
Analyze the current conversation context to identify potential skill-worthy patterns. Look for:
Report findings and ask if user wants to extract any as skills.
Ask user to provide either:
Then ask for scope:
Validate the skill format and save to the chosen location.
Provide quick templates for common skill types. When user wants to create a skill, offer these starting points:
---
id: error-[unique-id]
name: [Error Name]
description: Solution for [specific error in specific context]
source: conversation
triggers: ["error message fragment", "file path", "symptom"]
quality: high
---
# [Error Name]
## The Insight
What is the underlying cause of this error? What principle did you discover?
## Why This Matters
What goes wrong if you don't know this? What symptom led here?
## Recognition Pattern
How do you know when this applies? What are the signs?
- Error message: "[exact error]"
- File: [specific file path]
- Context: [when does this occur]
## The Approach
Step-by-step solution:
1. [Specific action with file/line reference]
2. [Specific action with file/line reference]
3. [Verification step]
## Example
\`\`\`typescript
// Before (broken)
[problematic code]
// After (fixed)
[corrected code]
\`\`\`
---
id: workflow-[unique-id]
name: [Workflow Name]
description: Process for [specific task in this codebase]
source: conversation
triggers: ["task description", "file pattern", "goal keyword"]
quality: high
---
# [Workflow Name]
## The Insight
What makes this workflow different from the obvious approach?
## Why This Matters
What fails if you don't follow this process?
## Recognition Pattern
When should you use this workflow?
- Task type: [specific task]
- Files involved: [specific patterns]
- Indicators: [how to recognize]
## The Approach
1. [Step with specific commands/files]
2. [Step with specific commands/files]
3. [Verification]
## Gotchas
- [Common mistake and how to avoid it]
- [Edge case and how to handle it]
---
id: pattern-[unique-id]
name: [Pattern Name]
description: Pattern for [specific use case in this codebase]
source: conversation
triggers: ["code pattern", "file type", "problem domain"]
quality: high
---
# [Pattern Name]
## The Insight
What's the key principle behind this pattern?
## Why This Matters
What problems does this pattern solve in THIS codebase?
## Recognition Pattern
When do you apply this pattern?
- File types: [specific files]
- Problem: [specific problem]
- Context: [codebase-specific context]
## The Approach
Decision-making heuristic, not just code:
1. [Principle-based step]
2. [Principle-based step]
## Example
\`\`\`typescript
[Illustrative example showing the principle]
\`\`\`
## Anti-Pattern
What NOT to do and why:
\`\`\`typescript
[Common mistake to avoid]
\`\`\`
---
id: integration-[unique-id]
name: [Integration Name]
description: How [system A] integrates with [system B] in this codebase
source: conversation
triggers: ["system name", "integration point", "config file"]
quality: high
---
# [Integration Name]
## The Insight
What's non-obvious about how these systems connect?
## Why This Matters
What breaks if you don't understand this integration?
## Recognition Pattern
When are you working with this integration?
- Files: [specific integration files]
- Config: [specific config locations]
- Symptoms: [what indicates integration issues]
## The Approach
How to work with this integration correctly:
1. [Configuration step with file paths]
2. [Setup step with specific details]
3. [Verification step]
## Gotchas
- [Integration-specific pitfall #1]
- [Integration-specific pitfall #2]
When invoked with an argument, skip the interactive wizard:
$local-skills-setup list - Show detailed skill inventory$local-skills-setup add - Start skill creation (invoke learner)$local-skills-setup scan - Scan both skill directoriesWhen invoked without arguments, run the full guided wizard (Steps 1-4).
Remind users that good skills are:
Non-Googleable - Can't easily find via search
Context-Specific - References actual files/errors from THIS codebase
Actionable with Precision - Tells exactly WHAT to do and WHERE
Hard-Won - Required significant debugging effort
When introducing the skill system, explain these benefits:
Automatic Application: Codex detects triggers and applies skills automatically - no need to remember or search for solutions.
Version Control: Project-level skills (.omc/skills/) are committed with your code, so the whole team benefits.
Evolving Knowledge: Skills improve over time as you discover better approaches and refine triggers.
Reduced Token Usage: Instead of re-solving the same problems, Codex applies known patterns efficiently.
Codebase Memory: Preserves institutional knowledge that would otherwise be lost in conversation history.
$learner - Extract a skill from current conversation$note - Save quick notes (less formal than skills)$deepinit - Generate AGENTS.md codebase hierarchyShow users what a typical session looks like:
> $local-skills-setup
Checking skill directories...
✓ User skills directory exists: ~/.codex/skills/omc-learned/
✓ Project skills directory exists: .omc/skills/
Scanning for skills...
=== USER-LEVEL SKILLS ===
Total skills: 3
- async-network-error-handling
Description: Pattern for handling independent I/O failures in async network code
Modified: 2026-01-20 14:32:15
- esm-path-resolution
Description: Custom path resolution in ESM requiring fileURLToPath
Modified: 2026-01-19 09:15:42
=== PROJECT-LEVEL SKILLS ===
Total skills: 5
- session-timeout-fix
Description: Fix for sessionId undefined after restart in session.ts
Modified: 2026-01-22 16:45:23
- build-cache-invalidation
Description: When to clear TypeScript build cache to fix phantom errors
Modified: 2026-01-21 11:28:37
=== SUMMARY ===
Total skills: 8
What would you like to do?
1. Add new skill
2. List all skills with details
3. Scan conversation for patterns
4. Import skill
5. Done
$local-skills-setup scan periodically to review your skill library