Awesome Agentic Patterns 
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.
What counts as a pattern?
- 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.
Quick Tour of Categories
Category | What you'll find |
---|---|
Orchestration & Control | Task decomposition, sub‑agent spawning, tool routing |
Context & Memory | Sliding‑window curation, vector cache, episodic memory |
Feedback Loops | Compilers, CI, human review, self‑healing retries |
Tool Use & Environment | Shell, browser, DB, Playwright, sandbox tricks |
UX & Collaboration | Prompt hand‑offs, staged commits, async background agents |
Reliability & Eval | Guardrails, eval harnesses, logging, reproducibility |
Categories are fluid — open a PR if you see a better slice!
The tables below are auto‑generated from the patterns/
folder.
Context & Memory
- Context-Minimization Pattern
- Curated Code Context Window
- Curated Context Window
- Curated File Context Window
- Dynamic Context Injection
- Episodic Memory Retrieval & Injection
- Layered Configuration Context
Feedback Loops
- Background Agent with CI Feedback
- Coding Agent CI Feedback Loop
- Dogfooding with Rapid Iteration for Agent Improvement
- Graph of Thoughts (GoT) NEW
- Inference-Healed Code Review Reward
- Reflection Loop
- Rich Feedback Loops > Perfect Prompts
- Self-Critique Evaluator Loop
- Self-Discover: LLM Self-Composed Reasoning Structures NEW
- Spec-As-Test Feedback Loop
- Tool Use Incentivization via Reward Shaping
Orchestration & Control
- Action-Selector Pattern
- Agent-Driven Research
- Conditional Parallel Tool Execution
- Dual LLM Pattern
- Explicit Posterior-Sampling Planner
- Inference-Time Scaling NEW
- Inversion of Control
- Iterative Multi-Agent Brainstorming
- Language Agent Tree Search (LATS) NEW
- LLM Map-Reduce Pattern
- Multi-Model Orchestration for Complex Edits
- Plan-Then-Execute Pattern
- Self-Rewriting Meta-Prompt Loop
- Specification-Driven Agent Development
- Sub-Agent Spawning
- Three-Stage Perception Architecture NEW
- Tool Capability Compartmentalization
- Tree-of-Thought Reasoning
Reliability & Eval
- Asynchronous Coding Agent Pipeline
- CriticGPT-Style Code Review NEW
- Extended Coherence Work Sessions
- Lethal Trifecta Threat Model
- Merged Code + Language Skill Model
- No-Token-Limit Magic
- RLAIF (Reinforcement Learning from AI Feedback) NEW
- Versioned Constitution Governance
Tool Use & Environment
- Agent SDK for Programmatic Control
- CLI-Native Agent Orchestration
- Code-Then-Execute Pattern
- Dynamic Code Injection (On-Demand File Fetch)
- Egress Lockdown (No-Exfiltration Channel)
- LLM-Friendly API Design
- Patch Steering via Prompted Tool Selection
- Shell Command Contextualization
- Subagent Compilation Checker
- Tool Use Steering via Prompting
- Virtual Machine Operator Agent
- Visual AI Multimodal Integration NEW
UX & Collaboration
- Abstracted Code Representation for Review
- Agent-Assisted Scaffolding
- Agent-Friendly Workflow Design
- Seamless Background-to-Foreground Handoff
- Spectrum of Control / Blended Initiative
- Verbose Reasoning Transparency
Contributing in 3 steps
- Fork & branch →
git checkout -b add-my-pattern
- Add a pattern file under
patterns/
using the template above. - Open a PR titled
Add: my-pattern-name
— the README & site will regenerate automatically.
See CONTRIBUTING.md
for the fine print.
Inspiration
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!
License
Apache‑2.0. See LICENSE
.