---
published: true
id: cli
title: CLI
description: Knowledge captured in João Lopes' learning graph.
tags:
- ai-engineering
- cli
- agent-design
- determinism
locale: en
resource: https://joaolopes.dev.br/knowledge/concepts/en/cli/
created: '2026-03-19'
---

# CLI
A command-line interface is a text-based interface for interacting with software through typed commands.

## Definition
In the context of AI-assisted development, CLI (command-line interface) refers to the deterministic tool layer: shell commands and scripts that an AI agent invokes to produce predictable, reproducible outputs. The model decides when to call a command; the command does the same thing regardless. CLI is also more context-efficient than MCP — a CLI command returns exactly what it returns, with no JSON envelope or protocol overhead.

## Source
- [Command-line interface - Wikipedia](https://en.wikipedia.org/wiki/Command-line_interface)

## Related
- [AI Agent](/concepts/en/ai-agent.md)
- [MCP](/concepts/en/mcp.md)
- [Hooks](/concepts/en/hooks.md)
