evolve-agent-cli
Use this skill when refactoring, adding a feature, adding a provider/adapter/backend, or hardening an EXISTING command-line tool that AI agents drive. Triggers on "refactor this CLI", "add a provider to", "add a feature to the CLI", "harden the mapper", "evolve this tool", "extend the agent CLI", "the CLI keeps breaking on". Diagnose with repo-health, write a "Read when:" effort doc, pin behavior with tests, then execute in the matching mode and update the contract docs. TS/Node-first.
What this skill does
# Evolve an agent CLI
Change an existing agent CLI the way the OpenClaw repos do — entered through
diagnosis, not a blank page. Same mental models as bootstrap; different entry point.
The work here is *mostly hardening*: across clawpatch/crabbox/clawsweeper, `fix` is
the #1 commit type (43–49%) and mappers run ~1 feat : 4 fix. Budget for it; a stream
of small `fix` commits is the system working, not thrashing.
## B0 — Diagnose (run the bundled tool)
```sh
python3 <plugin>/scripts/repo-health.py <repo> # swarm/single-author repo
python3 <plugin>/scripts/repo-health.py <repo> --bots-separate # autonomous-loop repo
```
Read the signals (full guide: [`references/diagnose-and-pin.md`](references/diagnose-and-pin.md)):
- **feat:fix per scope** → worst ratio = your fragile subsystem (test-sweep or redesign it).
- **Churn concentration** → the top file is *where the real spec lives*; over-invest in
pinning it before touching it.
- **Deletion bursts** → flat-zero means debt is accruing; schedule a refactor burst.
Then audit against the contract — if invariants are missing (no `--json`, no exit-code
classes, model holds write creds, state mixed into the code repo), hand off to
**audit-agent-cli** first.
## B1 — Write a "Read when:" effort doc 🔶 DECISION GATE (mode)
Before coding, **ask the human which mode** (one `AskUserQuestion`), because each runs
differently:
- **Add a feature (breadth)** — new language/provider/route/target.
- **Add a provider/adapter** — a new implementation behind the existing interface.
- **Harden** — grind edge cases on an existing subsystem.
- **Refactor** — restructure without behavior change.
Then create the matching doc using the templates (convention from crabbox, which uses
a `Read when:` trigger header on 70+ docs — see
[`references/read-when-docs.md`](references/read-when-docs.md)):
- refactor → [`templates/refactor-doc.template.md`](templates/refactor-doc.template.md)
(design context + migration phases with `Status:` lines + acceptance criteria + gate commands)
- feature → [`templates/plan-doc.template.md`](templates/plan-doc.template.md)
(goal + ownership split + CLI surface + implementation file checklist + gates)
The effort doc links to the *authoring handrail* (the durable how-to-add-one guide,
e.g. `docs/provider-backends.md`). Keep the two separate: the effort doc is
design-context-and-migration; the handrail is the reusable template.
## B2 — Pin behavior FIRST
Add characterization tests to the churn-hot file so behavior is locked before you
change it. You cannot safely refactor what isn't pinned. (This is why the OpenClaw
repos move fast — the test file IS the contract; clawpatch's `mapper.test.ts` is
touched in 144/372 commits.) See [`references/diagnose-and-pin.md`](references/diagnose-and-pin.md).
## B3 — Execute in the matching mode
- **Feature / adapter:** implement through the interface, never as a special case in
the core (`{ name, ...methods }` + one array entry). One focused test + one
CHANGELOG credit line. For adapter specifics, see **audit-agent-cli**'s contract and
the bootstrap `scaffold.md` interface pattern.
- **Harden:** one edge case per commit, each with a test. Expect many small `fix`es.
- **Refactor:** do it as a **burst** (extract helpers, derive schemas from a single
source, decompose a monolith) with behavior tests unchanged. Don't dribble refactors
across weeks — clawpatch did all 8 refactor commits in one day (66% of all deletions).
- **Change agent behavior:** that's data, not code → hand off to **agent-spec-kit**
(edit `prompts/`/`instructions/`/`schema/`, snapshot the output contract).
## B4 — Update the contract docs 🔶 DECISION GATE (schema bump)
- `source-map.md` must still map behavior→files correctly (regenerate the touched
sections — [`templates/source-map.template.md`](templates/source-map.template.md)).
- CHANGELOG entry with contributor credit.
- **If the persisted/output schema changed, ask the human before bumping
`schemaVersion`** and confirm the read-migration (zod `.transform()` defaults) keeps
old state loadable.
## B5 — Gate
CI green · the contract checklist still holds · `source-map.md` matches the tree ·
re-run `repo-health.py` and confirm feat:fix and churn didn't regress.
## Definition of done
- [ ] repo-health run; fragile scope identified
- [ ] effort doc written with `Read when:` header + gates
- [ ] behavior pinned with characterization tests before the change
- [ ] change made in the matching mode (interface for breadth; burst for refactor)
- [ ] source-map + CHANGELOG updated; schema bump confirmed if needed
- [ ] CI green; health signals stable
Related in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.