Skills
About 472 wordsAbout 2 min
Skills introduces the standardized capability set CNB provides for NPCs (AI assistants).
When to use: when an NPC should call platform capabilities — for example letting an AI assistant view repositories, create issues, or query build status, or attaching these capabilities to your own NPC. Skills builds on the OpenAPI(Open in new window), letting an NPC interact with the platform fully.
Capability List
The official Skills repository is cnb/skills, which includes the following core capabilities:
Code Hosting:
- Repository management (view, create, search)
- Issue operations (create, comment, close, label management)
- PR operations (create, review, merge, status check)
- Git operations (branch management, tags, releases)
- Code review (automated review, inline comments)
Build & Deployment:
- Pipeline configuration and triggering
- Build log querying
- Build status checking
Platform Interaction:
- Organization and member management
- User information querying
- Artifact registry operations
- Search and activities
For a more complete list of API capabilities, please refer to the OpenAPI documentation(Open in new window).
Usage Scenarios
Scenario 1: NPC Automatically Handles Issues
After a user @s an NPC in an Issue, the NPC automatically loads the corresponding Skill to complete the task:
@CodeBuddy Can you check if this Issue can be closed?Scenario 2: NPC Automatically Reviews Code
After a user @s an NPC in a PR requesting code review:
@CodeBuddy Can you review this PR?Installation & Configuration
Installing Skills
Install Skills in the NPC runtime image (requires the cnb command from CNB CLI). To call it manually from a terminal, log in first as described in Logging in to a specific host:
FROM node:22-bookworm-slim
RUN apt-get update \
&& apt-get install -y --no-install-recommends ca-certificates git git-lfs curl jq ripgrep \
&& rm -rf /var/lib/apt/lists/* \
&& git lfs install \
&& npm install -g @cnbcool/cnb-cli skills \
&& npx skills add https://cnb.cool/cnb/skills/cnb-skill.git -g -yCustom Skills
Create custom Skills in the project's .codebuddy/skills/ directory. Each Skill is a directory containing a SKILL.md file:
.codebuddy/skills/
my-skill/
SKILL.md # Skill definition file describing capabilities and usageThe NPC automatically recognizes and loads custom Skills in the project.
Priority for Skills with the same name
Global-level Skills take priority and override same-name project-level Skills: if a repo ships a stale copy of a Skill, the global version installed in the runtime image wins.
Related Documentation
- CNB CLI Plugin — the command-line tool behind Skills, exposing the full OpenAPI through the
cnbcommand - NPC — NPC concepts, event types, and configuration
- NPC Configuration — how to define NPC roles in a repository
- OpenAPI — complete CNB platform API documentation