optimize-cli-for-agents
optimize-cli-for-agents
Make CLIs reliable for agent use. The priorities are stable machine output, semantic exit codes, non-interactive operation, explicit recovery paths, and help text that an agent can treat as an API contract. For workflows that improve outputs over multiple passes, design the CLI as an iterative feedback loop instead of a one-shot command.
When To Use
Use this skill when:
- an agent keeps failing to parse a CLI result
- stdout mixes JSON with progress text
- every failure exits
1with no structured error body - a command hangs waiting for interactive confirmation
- a workflow involves generated artifacts that must be validated, corrected, and resubmitted
- you are designing a fresh CLI and want agent-first constraints from day one
- you need to decide whether a workflow should stay CLI-first, move to MCP, or split into a hybrid
If the user is choosing between CLI, MCP, skills, or a hybrid, read references/mcp-vs-cli-decision.md before recommending an interface.
Core Audit
More from yigitkonur/skills-by-yigitkonur
run-research
Use skill if you are answering one technical research question with current web evidence, Reddit practitioner experience, and source-backed synthesis, optionally fanned out across parallel subagents.
42run-agent-browser
Use skill if you are driving the agent-browser CLI for ad hoc browser automation — @ref snapshots, sessions, forms, extraction, screenshots, headed/stealth, or provider runs.
38publish-npm-package
Use skill if you are publishing to npm via GitHub Actions release workflow with trusted publishing, NPM_TOKEN, provenance, semantic-release, changesets, release-please, or fixing npm publish CI.
35build-mcp-use-server
Use skill if you are building TypeScript MCP servers with mcp-use/server — server.tool, response helpers, ctx.auth, sessions, transports, widgets, Inspector, deploy.
34init-agent-config
Use skill if you are creating, auditing, or migrating CLAUDE.md, AGENTS.md, or REVIEW.md instruction files, folder-scoped agent guidance, or cross-agent companion entrypoints.
34build-skills
Use skill if you are creating or substantially revising a Claude skill and need workspace-first evidence, remote comparison, and repo-fit synthesis before writing SKILL.md.
32