All skills
agents365-ai avatar

/agent-native-design

@72ee04b

Use when designing, reviewing, or refactoring a CLI that must serve AI agents alongside humans, or when converting an API or SDK into an agent-usable CLI interface.

Use this Skill: https://skilld.dev/gh/agents365-ai/365-skills/agent-native-design

This session only. Nothing lands on disk.

referenceshybrid-mcp-cli.md

≈997 tokens on demand. Your agent reads this file only when SKILL.md points to it.

When CLI vs MCP vs Both

This skill teaches CLI design — but the largest production agents (Claude Code, Cursor, Gemini CLI, CircleCI) use both CLI and MCP, not one or the other. This file is the single home for the CLI-vs-MCP discussion and the benchmark data behind it; SKILL.md and the checklists point here.


The hybrid pattern

State changes happen through the CLI. System understanding happens through MCP.

  • Use CLI for: local/scriptable tasks, composable automation, state-changing operations, dev/infrastructure workflows
  • Use MCP for: multi-tenant SaaS, per-user authentication, stateful workflows, audit logs, fine-grained access control
  • Use both: most production agents that orchestrate infrastructure (Vercel CLI + MCP for SaaS integrations; GitHub CLI + MCP for enterprise GitHub instances)

Decision matrix

Scenario CLI MCP Notes
Single-user dev tool on same machine ✅ Process model is cheap; auth is local; composable with Unix pipes
Large multi-tenant SaaS with per-user OAuth ✅ Centralized auth; per-user scoping; network-attachable; no binary shipping required
Hundreds of tools where schema size matters ✅ ⚠️ CLI wins: eager MCP schema dumps consume 55K–80K tokens upfront. CLI lazy-loads via progressive help.
Orchestration + infrastructure changes ✅ State changes favor process-model CLIs
Complex permission models, audit requirements ✅ MCP's structured audit logs and per-user attribution
Hybrid: local infra + cloud SaaS ✅✅ ✅ CLI for infrastructure, MCP for SaaS. Both in same agent.

Benchmark data

These are the numbers behind the "CLI is more efficient than eager-loaded MCP" claim. Cite this section when SKILL.md or the checklists need backing.

  • Task completion: CLI-based agents achieve 28% higher task completion vs. MCP-only agents with the same token budget (Reinhard 2026).
  • Token efficiency: 33% advantage measured by Token Efficiency Score (CLI: 202, MCP: 152).
  • Per-task overhead: ~4,150 tokens (CLI) vs ~145,000 tokens (MCP) for an identical browser-automation task — a 35× reduction (Reinhard 2026).
  • Schema dump cost: MCP servers that load all tool schemas upfront consume 55K–80K tokens just for discovery. An agent running 10 sequential operations sees this overhead on every orchestration handoff.
  • Lazy-loading wins, in either world: Anthropic's Code execution with MCP (Nov 2025) reports that presenting MCP tools as code on a filesystem reduced one Google-Drive→Salesforce workflow from 150,000 tokens to 2,000 — a 98.7% saving. The same logic produces CLI's structural advantage: progressive --help is lazy-loading by default.

These numbers are why a CLI's progressive --help → resource help → schema <resource.action> pattern matters: the agent only pays for the parts it queries, not for everything the tool could do.


When to stick with CLI alone

Mario Zechner's empirical benchmark (Aug 2025) of MCP vs CLI for coding agents lands on a one-line conclusion that's worth taking seriously: "Just like a lot of meetings could have been emails, a lot of MCPs could have been CLI invocations." That doesn't make MCP wrong; it means the default has been wrong. For the workflows this skill targets — developer tools, infrastructure CLIs, single-user data and research workflows — CLI is the lighter, more inspectable, more composable choice.

When to switch to MCP or hybrid

If you reach a design where you'd be fighting the CLI process model (per-request user context, fine-grained per-call authorization, network-attached without local install, multi-tenant data isolation), that's the signal to add MCP to the mix, not to bend this skill out of shape. Consult the decision matrix above; if you need features from the MCP column, embrace the hybrid approach that production agents use.

Source: SKILL.md on GitHub

No alerts17d3 checks · Risk SAFE
  • Gen Agent Trust Hub17d

    This skill provides design principles, rubrics, and technical guidelines for creating 'agent-native' command-line interfaces. It includes comprehensive documentation on structured output, safety tiers, and delegated authentication, as well as template scripts for testing and metadata validation. No malicious patterns or security risks were identified.

  • Socket17d

    No alerts

  • Snyk17d

    Risk: LOW · No issues

Signed by skilld at 72ee04b. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 15 hours ago.

Activeupdated 3 weeks ago
homepage
https://github.com/Agents365-ai/365-skills
platforms
[
  "macos",
  "linux",
  "windows"
]
Other metadata
compatibility
Includes sidecar metadata for OpenClaw, Hermes, pi-mono, and OpenAI Codex; the core SKILL.md is portable to any agent runtime that supports Agent Skills-style instructions.
metadata
{
  "openclaw": {
    "requires": {},
    "emoji": "⌨️",
    "os": [
      "darwin",
      "linux",
      "win32"
    ]
  },
  "hermes": {
    "tags": [
      "cli",
      "agent-native",
      "interface-design",
      "structured-output",
      "schema-driven"
    ],
    "category": "engineering",
    "requires_tools": [],
    "related_skills": []
  },
  "pimo": {
    "category": "engineering",
    "tags": [
      "cli",
      "agent-native",
      "interface-design",
      "structured-output",
      "schema-driven"
    ]
  },
  "author": "Agents365-ai",
  "version": "1.4.0"
}

README badge

README badge for agents365-ai/365-skills/agent-native-design