agentleFS
Slava-codeSlava-code/slava-stack/.claude/skills/kb-add-folder/SKILL.md

kb-add-folder

Skill0 starsChanged 29 days agoMITView on GitHub

Add a new top-level KB folder, enforcing the growth rules in CONVENTIONS.md and updating the routing guide. Use when the user asks for a new folder or content category, or content fits no existing folder.

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 6 are distinctive, and 5 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 5

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Do they not fit existing folders?

    line 11
  2. Distinctive:

    If any fails, report to user with specifics and stop.

    line 14
  3. Very specific:

    Create the folder: mkdir -p <folder-name>.

    line 15
  4. Very specific:

    Write <folder-name>/README.md with frontmatter type: folder, description: (≤120 chars, rule-not-summary — describes the folder's purpose as …

    line 16
  5. Very specific:

    Add an entry under types: in schema/kb-schema.yaml with required fields, extra_fields, status_values, body_required_sections.

    line 18
  6. Very specific:

    Add new enums to enums: if needed.

    line 19
  7. Very specific:

    Create schema/templates/<type>.md with frontmatter (including description: placeholder with inline example) + required section skeleton.

    line 20
  8. Distinctive:

    Update CONVENTIONS.md §"Folder layout" table with the new folder row.

    line 21
  9. Distinctive:

    Add a row to the "Where does this piece of content go?" table.

    line 23
  10. Distinctive:

    Add to "Common queries" if applicable.

    line 24
  11. Distinctive:

    Commit(s) — prefer multiple atomic commits:

    line 26

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 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

/kb-add-folder

  1. Acquire runs/.lock.
  2. Confirm growth-rule compliance per CONVENTIONS § "Growth rules" (values are the named constants in that section):
    • Are there at least NEW_FOLDER_MIN_FILES existing files (committed or drafted) that fit this category?
    • Do they not fit existing folders? (Re-check AGENT-GUIDE.md routing table before saying "no.")
    • Is this a STRUCTURAL difference (new file type, new lifecycle, new required sections) OR just a topic tag?
    • Can the new <folder>/README.md (rules + purpose) be written within NEW_FOLDER_INDEX_MAX_LINES without hand-waving? If any fails, report to user with specifics and stop. Do not create the folder.
  3. Create the folder: mkdir -p <folder-name>.
  4. Write <folder-name>/README.md with frontmatter type: folder, description: (≤120 chars, rule-not-summary — describes the folder's purpose as a stable rule). Body: purpose, naming, structure, frontmatter requirements, when-written, pointer to CONVENTIONS for rules and INDEX.md for entries.
  5. If a new file type is introduced:
    • Add an entry under types: in schema/kb-schema.yaml with required fields, extra_fields, status_values, body_required_sections.
    • Add new enums to enums: if needed.
    • Create schema/templates/<type>.md with frontmatter (including description: placeholder with inline example) + required section skeleton.
    • Update CONVENTIONS.md §"Folder layout" table with the new folder row.
  6. Update AGENT-GUIDE.md:
    • Add a row to the "Where does this piece of content go?" table.
    • Add to "Common queries" if applicable.
  7. Regenerate INDEXes: python3 scripts/rebuild-indexes.py. Creates <folder-name>/INDEX.md (will show _(empty)_ until content lands) and refreshes root INDEX.md to include the new subfolder. Stage all modified INDEX.md files.
  8. Commit(s) — prefer multiple atomic commits:
    • kb: add <folder>/
    • schema: add <type> type (if applicable)
    • conventions: document <folder>/ (if applicable) Push after each.
  9. Release the lock.

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.