Skill authoring

From ai-ecoverse/slicc · View interactive version

Skill authoring is an AI agent skill from the GitHub repository ai-ecoverse/slicc. Use this when the user wants to write a new skill, edit an existing one, or understand SLICC's skill system. Covers SKILL.md frontmatter (name, description, allowed-tools), how to write a description that triggers reliably, native `/workspace/skills/` vs compatibility `.agents/` / `.claude/skills/`

How to use this skill

Skill file

Skill authoring

A skill is a folder with a SKILL.md (and optional companion files) that loads into the agent's system prompt when the description matches the user's intent. This skill is about authoring those folders well.

Discovery

SLICC discovers five kinds of skill roots:

| Root | Source | Mutability |

| ------------------------------------------------------------ | -------------------------------------------- | ----------------------------------- |

| /workspace/skills/<name>/SKILL.md | Bundled or installed via upskill | Install-managed; you can edit them |

| .agents/skills/<name>/SKILL.md (anywhere) | Compatibility (Cursor / SuperClaude) | Read-only (discovered, not managed) |

| .claude/skills/<name>/SKILL.md (anywhere) | Compatibility (Claude Code) | Read-only (discovered, not managed) |

| <mount>/.claude-plugin/marketplace.json → plugin skills/ | Claude Code marketplace (mounted repos) | Read-only (discovered, not managed) |

| <plugin-root>/skills/<name>/SKILL.md | Agent Plugins installed via plugin install | Read-only (discovered, not managed) |

Skills under /workspace/skills/ installed with upskill carry a .upskill provenance record (source, ref, commit, file list) that upskill list --outdated consults and upskill update [--dry-run] uses to refresh them. upskill never modifies or deletes a dotfile in a skill directory, so that is where a skill should keep its credentials and local state (scripts/.config) — everything else is replaced on update.

The marketplace root is auto-discovered: when a mounted directory contains .claude-plugin/marketplace.json, SLICC reads the manifest, resolves each plugin's source path, and discovers skills at <plugin-source>/skills/<name>/SKILL.md. No install step needed — mount the repo and the skills are live immediately. Agent Plugins (agent-plugins.org packages with a plugin.json manifest) require an explicit plugin install <path|repo> — <repo> may be a local directory or a GitHub reference (owner/repo, owner/repo@branch, or a https://github.com/owner/repo[/tree/branch[/dir]] URL, downloaded into /workspace/.plugins/sources/); their skills then surface automatically. Precedence: native > agents > claude > marketplace > plugin.

When you create a new skill for SLICC, put it in /workspace/skills/<name>/. The .agents/, .claude/, and marketplace paths exist so SLICC can pick up skills authored for other agents without modification — don't create new skills there.

SKILL.md structure

---
name: <slug>
description: |
  Use this when ...
  ... (1–3 sentences explaining trigger conditions, what's covered, and what's
  NOT covered if there's a sibling skill that handles related topics.)
allowed-tools: bash, read_file, write_file, edit
---

# Title (matches `name`)

... body ...

Frontmatter fields

Writing a good description

The description is a trigger, not a summary. It runs through the agent at every turn — too vague and the skill loads when irrelevant; too narrow and it doesn't load when needed.

Pattern that works: "Use this when \<user-facing trigger\>. Covers \<topics\>. \[For \<adjacent topic\> use \<sibling skill\>.\]"

Compare:

Keyword soup. The agent has to guess what "licks" or "screencapture" mean for this user.

Names the user intent ("setting up event-driven automation"), names the commands the agent will reach for, and tells the agent when to load it.

Rules of thumb:

Body conventions

Companion files

`.jsh` — JavaScript shell scripts

.jsh files on the shell's $PATH search roots are auto-discovered as shell commands. Full reference: ./jsh-runtime-extensions.md.

Runtime surface (use these — don't reinvent)

Node-standard bare globals:

| Global | Use for |

| -------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |

| process | argv, env, cwd(), exit(code), exitCode (deferred status; honoured after the event-loop drain), stdout.write, stderr.write; stdin is one-shot buffered (no streaming) — read(), events, or async iterator, drain once |

| console | log/info/debug/dirxml/table/dir → stdout; warn/error/assert/trace → stderr (assert does not throw); group* indent; time*/count* labeled; clear no-op |

| fetch | Standard fetch routed through SLICC's proxied transport (cookies + CORS handled). |

| require(p) | Synchronous CJS require. Use require('sliccy:<name>') for capability bridges and require('fs') for the VFS bridge (see below). |

| __dirname / __filename | CJS scope vars — the script's own directory and absolute path. |

Capability bridges via require('sliccy:<name>') (full reference: ./jsh-runtime-extensions.md):

| require('sliccy:<name>') | Use for |

| --------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |

| sliccy:exec | Callable exec(cmd) + .spawn(argv[]). Composes with any supplemental command or .jsh script. |

| sliccy:agent | Callable agent(prompt, opts?) → sub-scoop final text (parsed when schema set) + .spawn(...) → { finalText, exitCode, stderr, sessionId?, sessionStatus?, usage? }. opts: model, thinking, cwd, allowedCommands, readOnly, schema, images, escalate, minimal, systemPrompt, tools, session, resume, envelope. session / resume / envelope return { output, sessionId?, sessionStatus?, usage? }. |

| sliccy:skill | dir / root / refs / assets / config() / token(providerId) — skill-root references/ and assets/, script-dir .config, provider tokens. |

| sliccy:http | http.client({ baseUrl, token, headers, retry, timeoutMs }) — standard API-client builder. |

| sliccy:browser | findTab, ensureTab, openWindow, windowBounds, setWindowBounds, eval, evalAsync, cookie, localStorage, fetch, websocket.on(...). |

| sliccy:usb / sliccy:serial / sliccy:hid | list() / request() + device methods. Chromium-only. |

| sliccy:computer | register(handlers) — jsh-hosted computer backend (screenshot/input over computer-call; keep-alive). |

| sliccy:cli | die(msg, opts?), out(value), warn(msg, opts?), help(text). |

| sliccy:color | ANSI helpers (green, red, bold, dim, …) auto-disabled on non-TTY / NO_COLOR. |

| sliccy:time | parseDuration, ago, range, future, gmailDate. |

| sliccy:fmt | trunc, col, table, date. |

| sliccy:pool | pool(n, items, fn) — bounded concurrency runner. |

VFS bridge:

| require('fs') / require('node:fs') | readFile, writeFile, readFileBinary, writeFileBinary, appendFile, readDir, exists, stat, mkdir, rm, fetchToFile — all paths are VFS, async. There is no bare fs global. |

| -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |

Runtime extensions (live — prefer these over hand-rolled equivalents)

Reach these via require('sliccy:<name>'). Full reference: ./jsh-runtime-extensions.md. Use them instead of reimplementing the cross-skill patterns they replace.

Ship a .jsh when the skill needs deterministic, parameterizable behavior the agent shouldn't have to re-derive each time (e.g. a slicc-handoff helper, a custom diff formatter, a domain-specific lint).

`.bsh` — browser shell scripts

.bsh files auto-execute when the browser navigates to a matching URL:

Use .bsh for site-specific automations — auto-fillers, lick-emitters, or page transforms that should run whenever the user lands on a particular host.

Filesystem at a glance

The VFS is stored in IndexedDB; it survives tab closes and refreshes. The mount shell command bridges remote storage (local folders, S3-compatible, Adobe DA) into VFS paths — see /workspace/skills/mount/SKILL.md.

The VFS supports symbolic links transparently:

ln -s /workspace/skills /workspace/skill-link    # Create symlink
readlink /workspace/skill-link                    # Read link target
ls -la /workspace/                                # Shows symlinks with -> target

cat, read_file, write_file etc. follow symlinks automatically.

Mount points must be empty. Mounting over existing files is blocked so built-in skills and scripts stay discoverable. ln -s /mnt/… /shared/x works: the link lives on VFS, and everything through it reaches the mount. A link cannot live _on_ a mount, though (EINVAL): mount backends have no symlink inode.

Don't

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.