From cowork-skills
Guides dynamic generation of project-specific skill routers from installed plugins via cowork config router. Explains routing system using Skills.toml, Skills.lock, and trigger keyword extraction.
How this skill is triggered — by the user, by Claude, or both
Slash command
/cowork-skills:cowork-routerThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
> Meta-router that guides dynamic generation of project-specific skill routers
Meta-router that guides dynamic generation of project-specific skill routers
This is a meta-skill that:
cowork config routerThis skill does NOT hardcode specific plugins - it describes the system for dynamically discovering and routing to installed plugins.
┌─────────────────────────────────────────────────────────────────────────┐
│ Skills.toml (User Config) │
│ [skills.install] │
│ rust-skills = "user/rust-skills" │
│ dora-skills = { path = "/local/dora-skills", plugin = true } │
└─────────────────────────────────────────────────────────────────────────┘
│
▼
┌───────────────────────┐
│ cowork config install │
└───────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────┐
│ Skills.lock (Generated) │
│ - Tracks installed plugins, versions, paths │
│ - Records extracted trigger keywords │
└─────────────────────────────────────────────────────────────────────────┘
│
▼
┌───────────────────────┐
│ cowork config router │
└───────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────────────┐
│ .claude/skills/cowork-router/SKILL.md (Dynamic) │
│ - Auto-generated from installed plugins │
│ - Merged trigger keywords from all plugins │
│ - Domain detection table based on actual installations │
└─────────────────────────────────────────────────────────────────────────┘
Each plugin contains skills with SKILL.md files. The frontmatter description field contains trigger keywords:
---
name: rust-router
description: "Triggers on: E0xxx, ownership, borrow, lifetime, async, trait"
---
cowork config router scans all installed plugins and extracts:
rust-router, dora-router)Generates a project-specific cowork-router that:
# Initialize project configuration
cowork config init
# Add plugin dependencies
cowork config add rust-skills ZhangHanDong/rust-skills --plugin
cowork config add dora-dev /path/to/dora-skills --dev --plugin
# Install all dependencies
cowork config install
# Generate dynamic router from installed plugins
cowork config router
# Generate router with auto-trigger hooks
cowork config router --hooks
The dynamically generated router will contain:
---
name: cowork-router
description: "Triggers on: [merged keywords from all plugins]"
---
## Domain Detection
| Domain | Keywords | Route To |
|--------|----------|----------|
| [plugin-1] | [extracted keywords] | [plugin-1-router] |
| [plugin-2] | [extracted keywords] | [plugin-2-router] |
| ... | ... | ... |
All plugin routers should follow this pattern:
┌─────────────────────────────────────┐
│ cowork-router (Meta) │
│ Unified entry - Domain detection │
└───────────────┬─────────────────────┘
│
┌────────────────────────┼────────────────────────┐
▼ ▼ ▼
┌───────────────┐ ┌───────────────┐ ┌───────────────┐
│ plugin-router │ │ plugin-router │ │ plugin-router │
│ (Domain A) │ │ (Domain B) │ │ (Domain C) │
└───────┬───────┘ └───────┬───────┘ └───────┬───────┘
│ │ │
▼ ▼ ▼
plugin-skills plugin-skills plugin-skills
When a question spans multiple domains:
Example: "Dora node 中 E0382 错误"
dora-router (dataflow context)rust-skills:m01-ownership (ownership mechanics)| File | Location | Purpose |
|---|---|---|
Skills.toml | .cowork/Skills.toml | User configuration |
Skills.lock | .cowork/Skills.lock | Installed state (auto-generated) |
cowork-router | .claude/skills/cowork-router/ | Dynamic router (auto-generated) |
hooks.json | .claude/skills/cowork-router/ | Auto-trigger hooks (optional) |
Run cowork config router after:
In Skills.toml:
[triggers]
priority = ["dora-router", "rust-router", "makepad-router"]
[triggers.overrides]
"async" = "rust-router"
"widget" = "makepad-router"
Higher priority routers win when keywords conflict.
npx claudepluginhub gqadonis/cowork-skillsGuides dynamic generation of project-specific skill routers from installed plugins via cowork config router. Explains routing system using Skills.toml, Skills.lock, and trigger keyword extraction.
Routes all agent actions through the correct skill before code or file operations, enforcing a check-before-act workflow with adaptive routing overrides and model hint escalation.
Generates router-based skills for AI tools: captures intent, decomposes actions, drafts SKILL.md, writes actions, and validates. Use when creating, scaffolding, or refactoring a skill.