agentleFS
vahidkaargarvahidkaargar/it-department-skills/skills/skills-discovery/SKILL.md

skills-discovery

Skill2 starsChanged 4 months agoMITView on GitHub

MANDATORY SOURCE OF TRUTH for finding skills and rules on this machine — not optional. Use when you need a capability, skill, playbook, or rule and don't know which exists. ALWAYS search with skillfind/rulesfind/the localhost API instead of listing skill directories; a PreToolUse hook (skills-discovery-guard) blocks raw `ls`/`find` enumeration of skill dirs and will deny the tool call. Covers Claude Code, Cursor, Codex, Copilot, and any shell-capable agent.

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Search first, read ONE SKILL.md.

    line 20
  2. Very specific:

    If skillserve.py is running (see repo docs for setup), on http://127.0.0.1:3401 (bind localhost only): /search?q=<intent>&n=5 · …

    line 40
  3. Very specific:

    Read ~/.agents/skills-catalog/CATALOG.md (hot set), or grep ~/.agents/skills-catalog/index.json for keywords.

    line 47

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skills discovery — source of truth

Enforced when the opt-in guard hook is installed (see repo docs/hooks.md; treat search-first as mandatory even without it). The hook ~/.claude/hooks/skills-discovery-guard.py runs on every Bash call (PreToolUse) and denies (exit 2) raw enumeration of skill directories — ls/find/tree against ~/.claude/skills, ~/.agents, ~/.cursor/skills, ~/.skills-archive, plugin caches, or bulk find -name SKILL.md / glob-cat of many SKILL.md files. skillfind/rulesfind/build-index.py/skillserve.py are allow-listed by name so the catalog's own tooling still works. This is the STRICT §3 rule (~/.ai/rules.md, propagates into AGENT_RULES.md + CLAUDE.md) — every agent on this machine must comply, not just Claude Code.

Skills may live across many roots on this machine. NEVER enumerate them into context. Search first, read ONE SKILL.md.

Find a skill (any agent with shell access)

skillfind "<intent>"              # ranked top-5, e.g. skillfind "nginx reload"
skillfind "<intent>" --json       # machine-readable (name, path, score, category)
skillfind --get <name>            # one skill: path + triggers
skillfind --category <slug>       # browse one category
rulesfind "<topic>"               # rules (.md/.mdc); --always = per-session token cost

Then: Read the single SKILL.md path returned. Follow it. Done.

  • Hot set pre-listed (~1k tokens): ~/.agents/skills-catalog/CATALOG.md
  • Machine index: ~/.agents/skills-catalog/index.json (query via --json, don't load whole)
  • Archived skills searchable too; restore: mv ~/.skills-archive/<name> ~/.claude/skills/<name>

HTTP API (optional, agents with no shell)

If skillserve.py is running (see repo docs for setup), on http://127.0.0.1:3401 (bind localhost only): /search?q=<intent>&n=5 · /get?name=<skill> (returns full SKILL.md body) · /catalog · /rules?q= · /rules?always=1 · /health.

No shell, no HTTP? (last fallback)

Read ~/.agents/skills-catalog/CATALOG.md (hot set), or grep ~/.agents/skills-catalog/index.json for keywords. Never walk skill dirs.

Per-tool wiring map

ToolEntry point
Claude Code (global)copy installed to ~/.claude/skills/skills-discovery by install.py + ~/.claude/CLAUDE.md pointer
Cursor (global)not auto-installed — copy this skill dir to ~/.cursor/skills/ (or point Cursor at the ~/.agents copy)
Cursor (per-repo)copy ~/.agents/skills-catalog/templates/skills-discovery.mdc → <repo>/.cursor/rules/
Codex / Copilot / otherpaste ~/.agents/skills-catalog/templates/AGENTS-snippet.md into repo AGENTS.md; cross-tool map in ~/.ai/rules.md §8

Maintenance

  • Index auto-rebuilds when skill dirs change. After editing frontmatter/rules only: skillfind --rebuild.
  • CATALOG.md is generated — never hand-edit. Generator: ~/.agents/skills-catalog/scripts/build-index.py.
  • Installed as copies — edit in the cloned repo and re-run python3 install.py to propagate.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.