A curated catalogue of agentic AI patterns — real‑world tricks, workflows, and mini‑architectures that help autonomous or semi‑autonomous AI agents get useful work done in production.
Why? Tutorials show toy demos. Real products hide the messy bits. This list surfaces the repeatable patterns that bridge the gap so we can all ship smarter, faster agents.
- Repeatable – more than one team is using it.
- Agent‑centric – improves how an AI agent senses, reasons, or acts.
- Traceable – backed by a public reference: blog post, talk, repo, or paper.
If your link ticks those boxes, it belongs here.
Visit: https://agentic-patterns.com
The website offers powerful discovery tools beyond this README:
- Pattern Explorer: Browse, filter, and search all patterns by category, status, complexity, and more
- Compare Tool: Side-by-side comparison of multiple patterns with shared attributes
- Decision Explorer: Interactive guide to find the right pattern for your use case
- Graph Visualization: Visual map of pattern relationships and connections
- Pattern Packs: Curated collections of patterns for common agent architectures
- Developer Guides: In-depth documentation on pattern selection and usage
- Dark Mode: Full theme support for comfortable reading in any environment
Built with Astro, deployed on Vercel, source code in apps/web/.
| Category | What you'll find |
|---|---|
| Context & Memory | Sliding-window curation, vector cache, episodic memory |
| Feedback Loops | Compilers, CI, human review, self-healing retries |
| Learning & Adaptation | Agent RFT, skill libraries, variance-based RL |
| Orchestration & Control | Task decomposition, sub-agent spawning, tool routing |
| Reliability & Eval | Guardrails, eval harnesses, logging, reproducibility |
| Security & Safety | Isolated VMs, PII tokenization, security scanning |
| Tool Use & Environment | Shell, browser, DB, Playwright, sandbox tricks |
| UX & Collaboration | Prompt hand-offs, staged commits, async background agents |
Categories are fluid — open a PR if you see a better slice!
The tables below are auto‑generated from the patterns/ folder.
- Agent-Powered Codebase Q&A / Onboarding
- Context Window Anxiety Management
- Context Window Auto-Compaction
- Context-Minimization Pattern
- Curated Code Context Window
- Curated File Context Window
- Dynamic Context Injection
- Episodic Memory Retrieval & Injection
- Filesystem-Based Agent State
- Layered Configuration Context
- Memory Synthesis from Execution Logs
- Proactive Agent State Externalization
- Progressive Disclosure for Large Files
- Prompt Caching via Exact Prefix Preservation
- Self-Identity Accumulation
- Semantic Context Filtering Pattern
- Tool Search Lazy Loading
- Working Memory via TodoWrite
- AI-Assisted Code Review / Verification
- Background Agent with CI Feedback
- Coding Agent CI Feedback Loop
- Dogfooding with Rapid Iteration for Agent Improvement
- Graph of Thoughts (GoT)
- Incident-to-Eval Synthesis
- Inference-Healed Code Review Reward
- Iterative Prompt & Skill Refinement
- Reflection Loop
- Rich Feedback Loops > Perfect Prompts
- Self-Critique Evaluator Loop
- Self-Discover: LLM Self-Composed Reasoning Structures
- Spec-As-Test Feedback Loop
- Tool Use Incentivization via Reward Shaping
- Agent Reinforcement Fine-Tuning (Agent RFT)
- Compounding Engineering Pattern
- Frontier-Focused Development
- Memory Reinforcement Learning (MemRL)
- Shipping as Research
- Skill Library Evolution
- Variance-Based RL Sample Selection
- Action-Selector Pattern
- Agent Modes by Model Personality
- Agent-Driven Research
- Artifact-Driven Analysis Pipeline Orchestration
- Autonomous Workflow Agent Architecture
- Budget-Aware Model Routing with Hard Cost Caps
- Burn the Boats
- Conditional Parallel Tool Execution
- Continuous Autonomous Task Loop Pattern
- Cross-Cycle Consensus Relay
- Custom Sandboxed Background Agent
- Discrete Phase Separation
- Disposable Scaffolding Over Durable Features
- Distributed Execution with Cloud Workers
- Dual LLM Pattern
- Economic Value Signaling in Multi-Agent Networks
- Explicit Posterior-Sampling Planner
- Factory over Assistant
- Feature List as Immutable Contract
- Hybrid LLM/Code Workflow Coordinator
- Inference-Time Scaling
- Initializer-Maintainer Dual Agent Architecture
- Inversion of Control
- Iterative Multi-Agent Brainstorming
- Lane-Based Execution Queueing
- Language Agent Tree Search (LATS)
- LLM Map-Reduce Pattern
- Multi-Model Orchestration for Complex Edits
- Opponent Processor / Multi-Agent Debate Pattern
- Oracle and Worker Multi-Model Approach
- Parallel Tool Call Learning
- Plan-Then-Execute Pattern
- Planner-Worker Separation for Long-Running Agents
- Progressive Autonomy with Model Evolution
- Progressive Complexity Escalation
- Recursive Best-of-N Delegation
- Self-Rewriting Meta-Prompt Loop
- Specification-Driven Agent Development
- Stop Hook Auto-Continue Pattern
- Sub-Agent Spawning
- Subject Hygiene for Task Delegation
- Swarm Migration Pattern
- Three-Stage Perception Architecture
- Tool Capability Compartmentalization
- Tool Selection Guide
- Tree-of-Thought Reasoning
- Workspace-Native Multi-Agent Orchestration
- Action Caching & Replay Pattern
- Adaptive Sandbox Fan-Out Controller
- Anti-Reward-Hacking Grader Design
- Asynchronous Coding Agent Pipeline
- Canary Rollout and Automatic Rollback for Agent Policy Changes
- CriticGPT-Style Code Review
- Extended Coherence Work Sessions
- Failover-Aware Model Fallback
- Lethal Trifecta Threat Model
- LLM Observability
- Merged Code + Language Skill Model
- No-Token-Limit Magic
- Reliability Problem Map Checklist for RAG and Agents
- RLAIF (Reinforcement Learning from AI Feedback)
- Schema Validation Retry with Cross-Step Learning
- Structured Output Specification
- Subagent Compilation Checker
- Versioned Constitution Governance
- Workflow Evals with Mocked Tools
- Deterministic Security Scanning Build Loop
- External Credential Sync
- Hook-Based Safety Guard Rails for Autonomous Code Agents
- Isolated VM per RL Rollout
- Non-Custodial Spending Controls
- PII Tokenization
- Sandboxed Tool Authorization
- Soulbound Identity Verification
- Transitive Vouch-Chain Trust
- Zero-Trust Agent Mesh
- Agent SDK for Programmatic Control
- Agent-First Tooling and Logging
- Agentic Search Over Vector Embeddings
- AI Web Search Agent Loop
- CLI-First Skill Design
- CLI-Native Agent Orchestration
- Code Mode MCP Tool Interface Improvement Pattern
- Code-Over-API Pattern
- Code-Then-Execute Pattern
- Dual-Use Tool Design
- Dynamic Code Injection (On-Demand File Fetch)
- Egress Lockdown (No-Exfiltration Channel)
- Intelligent Bash Tool Execution
- LLM-Friendly API Design
- Multi-Platform Communication Aggregation
- Multi-Platform Webhook Triggers
- Patch Steering via Prompted Tool Selection
- Progressive Tool Discovery
- Shell Command Contextualization
- Static Service Manifest for Agents
- Tool Use Steering via Prompting
- Virtual Machine Operator Agent
- Visual AI Multimodal Integration
- Abstracted Code Representation for Review
- Agent-Assisted Scaffolding
- Agent-Friendly Workflow Design
- AI-Accelerated Learning and Skill Development
- Chain-of-Thought Monitoring & Interruption
- Codebase Optimization for Agents
- Democratization of Tooling via Agents
- Dev Tooling Assumptions Reset
- Human-in-the-Loop Approval Framework
- Latent Demand Product Discovery
- Milestone Escrow for Agent Resource Funding
- Proactive Trigger Vocabulary
- Seamless Background-to-Foreground Handoff
- Spectrum of Control / Blended Initiative
- Team-Shared Agent Configuration as Code
- Verbose Reasoning Transparency
This project includes llms.txt, a machine-readable documentation file designed to help AI assistants and LLMs understand and recommend appropriate patterns.
What's included:
- Pattern categories and their purposes
- Key patterns with concise descriptions
- Usage guidelines for AI assistants
- Pattern selection strategies based on use case requirements
For developers building AI assistants:
The llms.txt file can be provided to LLMs as context to improve pattern recommendations. It's optimized for:
- RAG systems indexing this catalogue
- AI coding assistants suggesting patterns
- LLM-powered tools that recommend agentic patterns
Access: https://agentic-patterns.com/llms.txt (also available in apps/web/public/llms.txt)
- Fork & branch →
git checkout -b add-my-pattern - Add a pattern file under
patterns/using the template above. - Run
bun run build:datato refresh the generated README sections and site data. - Open a PR titled
Add: my-pattern-name. - This repository is pattern-first: proposals that are primarily product announcements or promotions will be rejected, even if technically valid.
See CONTRIBUTING.md for the fine print.
This project started after the write‑up "What Sourcegraph learned building AI coding agents" (28 May 2025) and the ongoing Raising an Agent video diary. Many first patterns come straight from those lessons — thanks to everyone sharing their journey in the open!
Apache‑2.0. See LICENSE.
