Skill

From MeroZemory/oh-my-droid · View interactive version

Skill is an AI agent skill from the GitHub repository MeroZemory/oh-my-droid. Manage local skills - list, add, remove, search, edit

How to use this skill

Skill file

Skill Management CLI

Meta-skill for managing oh-my-droid skills via CLI-like commands.

Subcommands

/skill list

Show all local skills organized by scope.

Behavior:

  1. Scan user skills in canonical-first order:
  1. Scan project skills in canonical-first order:
  1. Deduplicate within each scope by normalized relative path, preserving the canonical copy
  2. Parse YAML frontmatter for metadata
  3. Display in organized table format:
USER SKILLS (~/.agents/skills/droid-learned/):
| Name              | Triggers           | Quality | Usage | Scope |
|-------------------|--------------------|---------|-------|-------|
| error-handler     | fix, error         | 95%     | 42    | user  |
| api-builder       | api, endpoint      | 88%     | 23    | user  |

PROJECT SKILLS (.agents/skills/droid-learned/):
| Name              | Triggers           | Quality | Usage | Scope   |
|-------------------|--------------------|---------|-------|---------|
| test-runner       | test, run          | 92%     | 15    | project |

Fallback: If quality/usage stats not available, show "N/A"


/skill add [name]

Interactive wizard for creating a new skill.

Behavior:

  1. Ask for skill name (if not provided in command)
  1. Ask for description
  1. Ask for triggers (comma-separated keywords)
  1. Ask for argument hint (optional)
  1. Ask for scope:
  1. Create skill file with template:
---
name: <name>
description: <description>
triggers:
  - <trigger1>
  - <trigger2>
argument-hint: "<args>"
---

# <Name> Skill

## Purpose

[Describe what this skill does]

## When to Activate

[Describe triggers and conditions]

## Workflow

1. [Step 1]
2. [Step 2]
3. [Step 3]

## Examples

/<name> example-arg


## Notes

[Additional context, edge cases, gotchas]
  1. Report success with file path
  2. Suggest: "Edit /skill edit <name> to customize content"

Example:

User: /skill add custom-logger
Assistant: Creating new skill 'custom-logger'...

Description: Enhanced logging with structured output
Triggers (comma-separated): log, logger, logging
Argument hint (optional): <level> [message]
Scope (user/project): user

✓ Created skill at ~/.agents/skills/droid-learned/custom-logger/SKILL.md
→ Edit with: /skill edit custom-logger

/skill remove <name>

Remove a skill by name.

Behavior:

  1. Search for skill in both scopes:
  1. If found:
  1. If confirmed:
  1. If not found:

Safety: Never delete without explicit user confirmation.

Example:

User: /skill remove old-logger
Assistant: Found skill 'old-logger' in user scope:
  Description: Legacy logging utility
  Scope: user (~/.agents/skills/droid-learned/)

Delete 'old-logger' skill? (yes/no)

User: yes
Assistant: ✓ Removed skill 'old-logger' from user scope

/skill edit <name>

Edit an existing skill interactively.

Behavior:

  1. Find skill by name (search canonical then legacy directories in both scopes)
  2. Read current content via Read tool
  3. Display current values:

```

Current skill 'custom-logger':

```

  1. Ask what to change:
  1. For selected field:
  1. Report success with summary of changes

Example:

User: /skill edit custom-logger
Assistant: Current skill 'custom-logger':
  - Description: Enhanced logging with structured output
  - Triggers: log, logger, logging
  - Argument hint: <level> [message]

What would you like to edit? (description/triggers/argument-hint/content/rename/cancel)

User: triggers
Assistant: Current triggers: log, logger, logging
New triggers (comma-separated): log, logger, logging, trace

✓ Updated triggers for 'custom-logger'

/skill search <query>

Search skills by content, triggers, name, or description.

Behavior:

  1. Scan all skills in canonical and legacy directories for both scopes
  2. Match query (case-insensitive) against:
  1. Display matches with context:
Found 3 skills matching "typescript error":

1. typescript-fixer (user)
   Description: Fix common TypeScript errors
   Match: "typescript error handling patterns"

2. error-handler (user)
   Description: Generic error handling utilities
   Match: "Supports TypeScript and JavaScript errors"

3. lint-fix (project)
   Description: Auto-fix linting errors
   Match: "TypeScript ESLint error resolution"

Ranking: Prioritize matches in name/triggers over content matches

Example:

User: /skill search api endpoint
Assistant: Found 2 skills matching "api endpoint":

1. api-builder (user)
   Description: Generate REST API endpoints
   Triggers: api, endpoint, rest

2. backend-scaffold (project)
   Description: Scaffold backend services
   Match: "Creates API endpoint boilerplate"

/skill info <name>

Show detailed information about a skill.

Behavior:

  1. Find skill by name (search canonical then legacy directories in both scopes)
  2. Parse YAML frontmatter and content
  3. Display complete details:
Skill: custom-logger
Scope: user (~/.agents/skills/droid-learned/custom-logger/)
Description: Enhanced logging with structured output
Triggers: log, logger, logging
Argument Hint: <level> [message]
Quality: 95% (if available)
Usage Count: 42 times (if available)
File Path: /home/user/.agents/skills/droid-learned/custom-logger/SKILL.md

--- FULL CONTENT ---
[entire markdown content]

If not found: Report error with suggestion to use /skill search

Example:

User: /skill info custom-logger
Assistant: Skill: custom-logger
Scope: user
Description: Enhanced logging with structured output
Triggers: log, logger, logging
File: ~/.agents/skills/droid-learned/custom-logger/SKILL.md

--- CONTENT ---
# Custom Logger Skill

## Purpose
Enhanced logging with structured JSON output...
[rest of content]

/skill sync

Sync skills between user and project scopes.

Behavior:

  1. Scan both scopes:
  1. Compare and categorize:
  1. Display sync opportunities:
SYNC REPORT:

User-only skills (5):
  - error-handler
  - api-builder
  - custom-logger
  - test-generator
  - deploy-helper

Project-only skills (2):
  - test-runner
  - backend-scaffold

Common skills (3):
  - frontend-ui-ux
  - git-master
  - planner

Options:
  [1] Copy user skill to project
  [2] Copy project skill to user
  [3] View differences
  [4] Cancel
  1. Handle user choice:

Safety: Never overwrite without confirmation

Example:

User: /skill sync
Assistant: Found 5 user-only skills and 2 project-only skills.

Copy 'error-handler' from user to project? (yes/no/skip)
User: yes
Assistant: ✓ Copied 'error-handler' to .agents/skills/droid-learned/

Copy 'api-builder' from user to project? (yes/no/skip)
User: skip
...

Error Handling

All commands must handle:

Error format:

✗ Error: <clear message>
→ Suggestion: <helpful next step>

Usage Examples

# List all skills
/skill list

# Create a new skill
/skill add my-custom-skill

# Remove a skill
/skill remove old-skill

# Edit existing skill
/skill edit error-handler

# Search for skills
/skill search typescript error

# Get detailed info
/skill info my-custom-skill

# Sync between scopes
/skill sync

Implementation Notes

  1. YAML Parsing: Use frontmatter extraction for metadata
  2. File Operations: Use Read/Write tools, never Edit for new files
  3. User Confirmation: Always confirm destructive operations
  4. Clear Feedback: Use checkmarks (✓), crosses (✗), arrows (→) for clarity
  5. Scope Resolution: Always check both user and project scopes
  6. Validation: Enforce naming conventions (lowercase, hyphens only)

Future Enhancements

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.