Documentation

Skills

Skills are reusable agent workflow packages. Write once, use everywhere. Share with the community or keep private.

What is a Skill?

A skill is a Markdown file with YAML frontmatter that defines how an agent should approach a specific task. It is not code — it is structured guidance loaded into the agent's context at the right moment.

Skills tell the agent: what to do, how to verify it did it correctly, what tools to use, and when to ask for human input. They encode your team's best practices into a reproducible format.

Skill Format

---
name: tdd
description: Use when implementing any feature or bugfix — enforces test-first workflow
trigger: "implement|feature|bugfix|fix"
agent: claude-code
quality_threshold: 0.85
---

# Test-Driven Development

## When to use
Invoke this skill before writing any implementation code.

## Process
1. Write a failing test that describes the desired behavior
2. Run the test — confirm it fails for the right reason
3. Write the minimal implementation to make the test pass
4. Refactor without breaking the test
5. Commit with the test and implementation together

## Verification checklist
- [ ] Test written before implementation
- [ ] Test fails before implementation
- [ ] Test passes after implementation
- [ ] No implementation code without a corresponding test

Skill Lifecycle

  1. Trigger detection — The agent scans the task description for trigger keywords defined in the skill frontmatter.
  2. Skill loading — Matching skill content is injected into the agent's context.
  3. Execution — The agent follows the skill's process, using its checklist as a confidence guide.
  4. Confidence scoring — Checklist completion rate feeds directly into the task confidence score.
  5. Logging — Which skill was used, by which agent, is recorded in the audit trail.

Built-in Skills

ClawPilot ships with a core set of skills covering the most common development workflows:

tdd

Test-driven development. Enforces write-test-first for all feature and bugfix work.

brainstorming

Structured ideation before implementation. Explores user intent and design options.

systematic-debugging

Methodical bug investigation. Hypothesis → reproduce → isolate → fix → verify.

code-reviewer

Reviews completed work against original requirements and coding standards.

writing-plans

Produces structured implementation plans before touching any code.

verification-before-completion

Requires running verification commands before claiming any task is done.

Writing a Custom Skill

Place your skill file in ~/.openclaw/skills/ (or your configured skills directory). The filename is the skill name.

# ~/.openclaw/skills/my-skill.md
---
name: my-skill
description: What this skill does and when to use it
trigger: "keyword1|keyword2"
agent: openclaw          # preferred agent (optional)
quality_threshold: 0.80  # minimum confidence to auto-proceed
---

# My Skill

## Context
Explain what situation this skill is for.

## Process
Step-by-step instructions the agent will follow.

## Checklist
- [ ] Step 1 done
- [ ] Step 2 done
- [ ] Output verified

Frontmatter Reference

Field Required Description
name Yes Unique skill identifier (snake_case)
description Yes One-line description. Used for auto-matching and display.
trigger No Regex pattern on task text to auto-invoke. E.g. "implement|feature"
agent No Preferred agent. Falls back to router selection if not available.
quality_threshold No Minimum confidence (0–1) to auto-proceed without human review. Default: 0.75

Skills Marketplace

The marketplace (coming in Phase 4) lets you publish skills and install community-contributed ones with a single command:

# Install a community skill
labos skills install ldom1/legal-doc-review

# Publish your skill
labos skills publish my-skill --visibility public

Skills are versioned, rated, and reviewed by the community. Revenue share: 80% to creator, 20% to ClawPilot infrastructure.