Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add ancoleman/ai-design-components --skill building-clisgit clone --depth 1 https://github.com/ancoleman/ai-design-componentsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/ancoleman/ai-design-components/building-clis)<a href="https://agentmods.dev/skills/ancoleman/ai-design-components/building-clis"><img src="https://agentmods.dev/badge/skills/ancoleman/ai-design-components/building-clis/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/ancoleman/ai-design-components/building-clis"><img src="https://agentmods.dev/badge/skills/ancoleman/ai-design-components/building-clis.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00055 | $0.03120 |
| Opus 5 | $0.00028 | $0.01560 |
| Sonnet 5 | $0.00011 | $0.00624 |
| Haiku 4.5 | $0.00006 | $0.00312 |
Grade A, and why
building-clis scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 477 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Building CLIs
Build professional command-line interfaces across Python, Go, and Rust using modern frameworks with robust argument parsing, configuration management, and shell integration.
When to Use This Skill
Use this skill when:
- Building developer tooling or automation CLIs
- Creating infrastructure management tools (deployment, monitoring)
- Implementing API client command-line tools
- Adding CLI capabilities to existing projects
- Packaging utilities for distribution (PyPI, Homebrew, binary releases)
Common triggers: "create a CLI tool", "build a command-line interface", "add CLI arguments", "parse command-line options", "generate shell completions"
Framework Selection
Quick Decision Guide
Python Projects:
- Typer (recommended): Modern type-safe CLIs with minimal boilerplate
- Click: Mature, flexible CLIs for complex command hierarchies
Go Projects:
- Cobra (recommended): Industry standard for enterprise tools (Kubernetes, Docker, GitHub CLI)
- urfave/cli: Lightweight alternative for simple CLIs
Rust Projects:
- clap v4 (recommended): Type-safe with derive API or builder API for runtime flexibility
For detailed framework comparison and selection criteria, see references/framework-selection.md.
Core Patterns
Arguments vs. Options vs. Flags
Positional Arguments:
- Primary input, identified by position
- Use for required inputs (max 2-3 arguments)
- Example:
convert input.jpg output.png
Options:
- Named parameters with values
- Use for configuration and optional inputs
- Example:
--output file.txt,--config app.yaml
Flags:
- Boolean options (presence = true)
- Use for switches and toggles
- Example:
--verbose,--dry-run,--force
Decision Matrix:
| Use Case | Type | Example |
|---|---|---|
| Primary required input | Positional Argument | git commit -m "message" |
| Optional configuration | Option | --config app.yaml |
| Boolean setting | Flag | --verbose, --force |
| Multiple values | Variadic Argument | files... |
What ships with it
19 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- examples/go/cobra_basic.go 929 B
- examples/go/cobra_subcommands.go 2.3 KB
- examples/go/cobra_viper.go 2.0 KB
- examples/python/test_cli.py 1.9 KB runs code
- examples/python/typer_basic.py 911 B runs code
- examples/python/typer_config.py 2.2 KB runs code
- examples/python/typer_progress.py 1.1 KB runs code
- examples/python/typer_subcommands.py 2.7 KB runs code
- examples/rust/clap_builder.rs 1.3 KB
- examples/rust/clap_derive.rs 806 B
- examples/rust/clap_subcommands.rs 2.0 KB
- outputs.yaml 8.4 KB
- references/argument-patterns.md 13 KB
- references/configuration-management.md 14 KB
- references/distribution.md 7.2 KB
- references/framework-selection.md 12 KB
- references/output-formatting.md 6.2 KB
- references/shell-completion.md 5.6 KB
- references/subcommand-design.md 14 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 477 lines · 55 tokens per session scan A df202d2b8ea2
building-clis is a skill published in the GitHub repository ancoleman/ai-design-components (519 stars, last pushed 9mo ago), licensed MIT. It adds 55 tokens to every session and 3,120 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
polars
High-performance DataFrame library for Python ETL, analytics, and pandas migration. Use for expression-based data manipulation with lazy query optimization, parallel execution, streaming out-of-core processing, Arrow interoperability, and optional GPU execution.
port-from-python
Port Python into Rust — construct mapping, the semantic traps (integer width, floor division, str versus bytes, exceptions to Result), and the seam, which is a process boundary for a standalone replacement and PyO3 when Python keeps calling the code. Use when porting, rewriting, or migrating Python, CPython, Django…
python
Apply when writing Python code. Type hints, error handling, mutable defaults, async patterns, and packaging conventions.
pydub-automation
Automate repetitive audio tasks with Python using PyDub for batch processing, format conversion, normalization, and content assembly. Use when: Processing large numbers of audio files consistently; Converting between audio formats at scale; Normalizing loudness across a batch of files; Assembling intros/outros…
fastapi
Apply when building FastAPI endpoints, Pydantic models, or async APIs. Covers routing, dependency injection, error handling, testing, and OpenAPI hygiene.
rust-strict
Rust security, strictness, and vulnerability prevention rules. Use when writing, reviewing, or auditing Rust code. Complements rust-skills (179 general rules) with security-focused rules: unsafe audit, unwrap/expect bans, error handling hierarchy, secret handling, concurrency safety, input validation for Tauri…