AI Agents Guide (Prompting Guide)

The Prompt Engineering Guide’s Agents section covers 7 topics on building and designing AI agent systems.

Introduction to Agents (confidence: high)

Covers the core concept of LLM agents: autonomous systems that perceive, reason, and act. Distinguishes agents from simple chatbots.

Agent Components (confidence: high)

The building blocks of agent systems:

  • Planning — Task decomposition, reasoning loops, reflection
  • Memory — Short-term (context) and long-term (external storage)
  • Tool Use — Function calling, API integration, code execution

AI Workflows vs AI Agents (confidence: high)

Key distinction: workflows are deterministic, predefined pipelines (prompt chaining, routing), while agents are autonomous, self-directed systems that decide their own next steps.

Context Engineering for AI Agents (confidence: high)

Designing context windows for agent systems: system prompts, dynamic context injection, and context management strategies for multi-turn agent interactions.

Context Engineering Deep Dive (confidence: medium)

Advanced context engineering techniques: prioritization strategies, sliding windows, hierarchical context structures, and compression methods for long-running agent sessions.

Function Calling (confidence: high)

Enabling agents to invoke external tools via structured JSON outputs. Covers function definitions, parameter schemas, response parsing, and error handling. prompt-engineering-applications

Deep Agents (confidence: medium)

Architectures for complex, multi-step agent systems that go beyond simple ReAct loops: hierarchical planning, sub-agent delegation, and persistent state management.

Agent Team Token Costs (confidence: high)

Agent teams spawn multiple Claude Code instances, each with its own context window, so token usage scales with the number of active teammates and how long each runs. In plan mode a team uses roughly 7× the tokens of a standard session. Cost controls: use Sonnet for teammates, keep teams small, keep spawn prompts focused (teammates auto-load CLAUDE.md, MCP servers, and skills, but everything in the spawn prompt is in context from the start), and shut teammates down when their work is done.

Implications

Multi-agent systems inherit the context-engineering problem at team scale: each teammate’s context window is an independent token bill. Delegation that isolates verbose output — see token-usage-reduction — becomes more important as agent teams grow.

Implications

The Agents section reflects the industry’s shift from simple prompting to autonomous agent systems. Context engineering emerges as a critical skill — different from prompt engineering, focused on managing the information environment agents operate in. Terminal-native agentic coding CLIs like crush are a concrete instance of these principles at tool scale.

prompt-engineering-guide | prompt-engineering-techniques | prompt-engineering-applications | llm-research-findings

Sources

  • raw/prompts/articles/promptingguide-pt-agents.md
  • raw/prompts/articles/promptingguide-pt-agents-introduction.md
  • raw/prompts/articles/promptingguide-pt-agents-components.md
  • raw/prompts/articles/promptingguide-pt-agents-ai-workflows-vs-ai-agents.md
  • raw/prompts/articles/promptingguide-pt-agents-context-engineering.md
  • raw/prompts/articles/promptingguide-pt-agents-context-engineering-deep-dive.md
  • raw/prompts/articles/promptingguide-pt-agents-function-calling.md
  • raw/prompts/articles/promptingguide-pt-agents-deep-agents.md
  • raw/prompts/articles/claude-code-costs-reduce-token-usage.md