|
| 1 | +# agent-native-cli — Agent-Native CLI Design & Review Skill |
| 2 | + |
| 3 | +[中文文档](README_CN.md) |
| 4 | + |
| 5 | +## What it does |
| 6 | + |
| 7 | +- Evaluates whether an existing CLI is reliably usable by AI agents |
| 8 | +- Designs CLI interfaces that serve humans, agents, and orchestration systems simultaneously |
| 9 | +- Converts REST APIs and SDKs into agent-native CLI command trees |
| 10 | +- Reviews stdout contracts, exit code semantics, and error envelope design |
| 11 | +- Designs schema-driven self-description, dry-run previews, and schema introspection |
| 12 | +- Defines safety tiers (open / warned / hidden) for graduated command visibility |
| 13 | +- Designs delegated authentication so agents never own the auth lifecycle |
| 14 | +- Produces prioritized refactor plans with concrete interface examples |
| 15 | + |
| 16 | +## Multi-Platform Support |
| 17 | + |
| 18 | +Works with all major AI agents that support the [Agent Skills](https://agentskills.io) format: |
| 19 | + |
| 20 | +| Platform | Status | Details | |
| 21 | +|----------|--------|---------| |
| 22 | +| **Claude Code** | ✅ Full support | Native SKILL.md format | |
| 23 | +| **OpenClaw / ClawHub** | ✅ Full support | `metadata.openclaw` namespace | |
| 24 | +| **Hermes Agent** | ✅ Full support | `metadata.hermes` namespace, category: engineering | |
| 25 | +| **Pi-Mo** | ✅ Full support | `metadata.pimo` namespace | |
| 26 | +| **OpenAI Codex** | ✅ Full support | `agents/openai.yaml` sidecar | |
| 27 | +| **SkillsMP** | ✅ Indexed | GitHub topics configured | |
| 28 | + |
| 29 | +## Comparison: with vs. without this skill |
| 30 | + |
| 31 | +| Capability | Native agent | This skill | |
| 32 | +|------------|-------------|------------| |
| 33 | +| Evaluate whether a CLI is agent-native | No | Yes — structured diagnosis across 7 principles | |
| 34 | +| Design stdout JSON contract | Inconsistent | Always — stable envelope with `ok`, `data`, `error` | |
| 35 | +| Define exit code semantics | Ad hoc | Yes — documented, deterministic per failure class | |
| 36 | +| Design layered `--help` and schema introspection | No | Yes — full self-description pattern | |
| 37 | +| Design dry-run previews | Rarely | Always — request shape preview without execution | |
| 38 | +| Define safety tiers for commands | No | Yes — open / warned / hidden tiers | |
| 39 | +| Design delegated authentication | No | Yes — human manages auth lifecycle; agent uses token | |
| 40 | +| Separate trust levels for env vs. CLI args | No | Yes — directional trust model | |
| 41 | +| Produce prioritized refactor plan | Rarely | Always — P0 / P1 / P2 with examples | |
| 42 | +| Score CLI across 10-criterion rubric | No | Yes — 0–2 per criterion with verdict | |
| 43 | + |
| 44 | +## When to use |
| 45 | + |
| 46 | +- Evaluating whether an existing CLI is usable by an AI agent |
| 47 | +- Designing a new CLI interface for an API or SDK |
| 48 | +- Refactoring a human-first CLI to be machine-readable |
| 49 | +- Reviewing stdout, stderr, and exit code contract design |
| 50 | +- Defining dry-run, schema introspection, and self-description layers |
| 51 | +- Designing auth delegation and trust boundaries for agent safety |
| 52 | +- Producing a SKILL.md or skill docs from a CLI schema |
| 53 | + |
| 54 | +## Skill Installation |
| 55 | + |
| 56 | +### Claude Code |
| 57 | + |
| 58 | +```bash |
| 59 | +# Global install (available in all projects) |
| 60 | +git clone https://github.com/Agents365-ai/agent-native-cli.git ~/.claude/skills/agent-native-cli |
| 61 | + |
| 62 | +# Project-level install |
| 63 | +git clone https://github.com/Agents365-ai/agent-native-cli.git .claude/skills/agent-native-cli |
| 64 | +``` |
| 65 | + |
| 66 | +### OpenClaw / ClawHub |
| 67 | + |
| 68 | +```bash |
| 69 | +# Via ClawHub |
| 70 | +clawhub install agent-native-cli |
| 71 | + |
| 72 | +# Manual install |
| 73 | +git clone https://github.com/Agents365-ai/agent-native-cli.git ~/.openclaw/skills/agent-native-cli |
| 74 | + |
| 75 | +# Project-level install |
| 76 | +git clone https://github.com/Agents365-ai/agent-native-cli.git skills/agent-native-cli |
| 77 | +``` |
| 78 | + |
| 79 | +### Hermes Agent |
| 80 | + |
| 81 | +```bash |
| 82 | +git clone https://github.com/Agents365-ai/agent-native-cli.git ~/.hermes/skills/engineering/agent-native-cli |
| 83 | +``` |
| 84 | + |
| 85 | +Or add to `~/.hermes/config.yaml`: |
| 86 | + |
| 87 | +```yaml |
| 88 | +skills: |
| 89 | + external_dirs: |
| 90 | + - ~/myskills/agent-native-cli |
| 91 | +``` |
| 92 | +
|
| 93 | +### Pi-Mo |
| 94 | +
|
| 95 | +```bash |
| 96 | +git clone https://github.com/Agents365-ai/agent-native-cli.git ~/.pimo/skills/agent-native-cli |
| 97 | +``` |
| 98 | + |
| 99 | +### OpenAI Codex |
| 100 | + |
| 101 | +```bash |
| 102 | +# User-level install |
| 103 | +git clone https://github.com/Agents365-ai/agent-native-cli.git ~/.agents/skills/agent-native-cli |
| 104 | + |
| 105 | +# Project-level install |
| 106 | +git clone https://github.com/Agents365-ai/agent-native-cli.git .agents/skills/agent-native-cli |
| 107 | +``` |
| 108 | + |
| 109 | +### SkillsMP |
| 110 | + |
| 111 | +```bash |
| 112 | +skills install agent-native-cli |
| 113 | +``` |
| 114 | + |
| 115 | +### Installation paths summary |
| 116 | + |
| 117 | +| Platform | Global path | Project path | |
| 118 | +|----------|-------------|--------------| |
| 119 | +| Claude Code | `~/.claude/skills/agent-native-cli/` | `.claude/skills/agent-native-cli/` | |
| 120 | +| OpenClaw | `~/.openclaw/skills/agent-native-cli/` | `skills/agent-native-cli/` | |
| 121 | +| Hermes Agent | `~/.hermes/skills/engineering/agent-native-cli/` | Via `external_dirs` config | |
| 122 | +| Pi-Mo | `~/.pimo/skills/agent-native-cli/` | — | |
| 123 | +| OpenAI Codex | `~/.agents/skills/agent-native-cli/` | `.agents/skills/agent-native-cli/` | |
| 124 | + |
| 125 | +## Files |
| 126 | + |
| 127 | +- `SKILL.md` — **the only required file**. Loaded by all platforms as the skill instructions. |
| 128 | +- `agents/openai.yaml` — OpenAI Codex-specific configuration (display, policy, capabilities) |
| 129 | +- `README.md` — this file (English) |
| 130 | +- `README_CN.md` — Chinese documentation |
| 131 | + |
| 132 | +> **Note:** Only `SKILL.md` is needed for the skill to work. All other files are supplementary. |
| 133 | +
|
| 134 | +## GitHub Topics |
| 135 | + |
| 136 | +For SkillsMP indexing, this repository uses the following topics: |
| 137 | + |
| 138 | +`claude-code` `claude-code-skill` `claude-skills` `agent-skills` `skillsmp` `skill-md` `agent-native-cli` `cli-design` `interface-design` `structured-output` `schema-driven` `dry-run` `exit-codes` `tool-design` |
| 139 | + |
| 140 | +## License |
| 141 | + |
| 142 | +MIT |
| 143 | + |
| 144 | +## Support |
| 145 | + |
| 146 | +If this skill helps your work, consider supporting the author: |
| 147 | + |
| 148 | +<table> |
| 149 | + <tr> |
| 150 | + <td align="center"> |
| 151 | + <img src="https://raw.githubusercontent.com/Agents365-ai/images_payment/main/qrcode/wechat-pay.png" width="180" alt="WeChat Pay"> |
| 152 | + <br> |
| 153 | + <b>WeChat Pay</b> |
| 154 | + </td> |
| 155 | + <td align="center"> |
| 156 | + <img src="https://raw.githubusercontent.com/Agents365-ai/images_payment/main/qrcode/alipay.png" width="180" alt="Alipay"> |
| 157 | + <br> |
| 158 | + <b>Alipay</b> |
| 159 | + </td> |
| 160 | + <td align="center"> |
| 161 | + <img src="https://raw.githubusercontent.com/Agents365-ai/images_payment/main/qrcode/buymeacoffee.png" width="180" alt="Buy Me a Coffee"> |
| 162 | + <br> |
| 163 | + <b>Buy Me a Coffee</b> |
| 164 | + </td> |
| 165 | + </tr> |
| 166 | +</table> |
| 167 | + |
| 168 | +## Author |
| 169 | + |
| 170 | +**Agents365-ai** |
| 171 | + |
| 172 | +- Bilibili: https://space.bilibili.com/441831884 |
| 173 | +- GitHub: https://github.com/Agents365-ai |
0 commit comments