feat(coding-agent): add configurable skills directories (#269)

This commit is contained in:
Nico Bailon 2025-12-21 11:48:40 -08:00 committed by GitHub
parent ace3563f0e
commit 70440f7591
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 186 additions and 39 deletions

View file

@ -145,6 +145,36 @@ Skills are discovered from these locations (later wins on name collision):
4. `~/.pi/agent/skills/**/SKILL.md` (Pi user, recursive)
5. `<cwd>/.pi/skills/**/SKILL.md` (Pi project, recursive)
## Configuration
Configure skill loading in `~/.pi/agent/settings.json`:
```json
{
"skills": {
"enabled": true,
"enableCodexUser": true,
"enableClaudeUser": true,
"enableClaudeProject": true,
"enablePiUser": true,
"enablePiProject": true,
"customDirectories": ["~/my-skills-repo"],
"ignoredSkills": ["deprecated-skill"]
}
}
```
| Setting | Default | Description |
|---------|---------|-------------|
| `enabled` | `true` | Master toggle for all skills |
| `enableCodexUser` | `true` | Load from `~/.codex/skills/` |
| `enableClaudeUser` | `true` | Load from `~/.claude/skills/` |
| `enableClaudeProject` | `true` | Load from `<cwd>/.claude/skills/` |
| `enablePiUser` | `true` | Load from `~/.pi/agent/skills/` |
| `enablePiProject` | `true` | Load from `<cwd>/.pi/skills/` |
| `customDirectories` | `[]` | Additional directories to scan (supports `~` expansion) |
| `ignoredSkills` | `[]` | Skill names to exclude |
## How Skills Work
1. At startup, pi scans skill locations and extracts names + descriptions
@ -233,3 +263,5 @@ Settings (`~/.pi/agent/settings.json`):
}
}
```
Use the granular `enable*` flags to disable individual sources (e.g., `enableClaudeUser: false` to skip `~/.claude/skills`).