PromptHub
Back to Blog
Developer Tools Artificial Intelligence

nibzard/awesome-agentic-patterns: A Curated Catalogue for Production AI Agents

B

Bright Coding

Author

10 min read 36 views
nibzard/awesome-agentic-patterns: A Curated Catalogue for Production AI Agents

nibzard/awesome-agentic-patterns: A Curated Catalogue for Production AI Agents

Most tutorials for AI agents stop at toy demos—chatbots that book flights or summarize PDFs. But shipping autonomous or semi-autonomous systems in production means confronting messy, repeatable problems: context windows overflow, tool calls fail silently, multi-agent orchestration turns into a debugging nightmare, and feedback loops between agents and humans break down. The nibzard/awesome-agentic-patterns repository addresses this gap directly. It is a curated catalogue of agentic AI patterns—real-world workflows, architectural mini-patterns, and operational tricks that teams actually use to make agents useful at scale. With 4,791 GitHub stars, 427 forks, and active maintenance as of June 2026, this open-source resource has become a practical reference for developers building beyond the demo stage.

What is nibzard/awesome-agentic-patterns?

nibzard/awesome-agentic-patterns is an open-source catalogue maintained by Nibras Shahzad (nibzard), originating from hands-on experience building AI coding agents at Sourcegraph. The project emerged from the write-up "What Sourcegraph learned building AI coding agents" (May 2025) and the ongoing Raising an Agent video diary—material that grounds the patterns in production reality rather than theoretical idealization.

The repository is structured as a pattern library: each pattern lives as a Markdown↗ Smart Converter file in a patterns/ directory, auto-generated into categorized tables in the README. Patterns must meet three criteria to be included: they must be repeatable (used by more than one team), agent-centric (improving how an agent senses, reasons, or acts), and traceable (backed by a public reference such as a blog post, talk, repo, or paper). This editorial rigor distinguishes it from undifferentiated link lists.

Technically, the repository is primarily HTML (per GitHub's language detection), with the website built in Astro and deployed on Vercel. The source code for the web application resides in apps/web/. The project is licensed under Apache License 2.0, permitting commercial use with attribution. The last commit as of this writing was June 8, 2026, indicating active maintenance.

The catalogue spans eight core categories: Context & Memory, Feedback Loops, Learning & Adaptation, Orchestration & Control, Reliability & Eval, Security & Safety, Tool Use & Environment, and UX & Collaboration. This taxonomy reflects the full lifecycle of agent deployment—not just model selection, but the surrounding infrastructure that determines whether an agent succeeds or fails in production.

Key Features

Pattern-First Organization with Rigorous Inclusion Criteria. Every entry is vetted for repeatability, agent-centrality, and traceability. The repository explicitly rejects "proposals that are primarily product announcements or promotions," maintaining focus on architectural knowledge rather than marketing content.

Auto-Generated Documentation Pipeline. The README tables and website data are generated from the patterns/ folder via bun run build:data. This ensures consistency between the GitHub repository and the companion website at agentic-patterns.com, reducing documentation drift.

Rich Web Discovery Layer. Beyond the README, the website offers specialized tools: a Pattern Explorer with filtering by category, status, and complexity; a Compare Tool for side-by-side pattern analysis; a Decision Explorer for interactive use-case matching; Graph Visualization of pattern relationships; Pattern Packs for common architectures; and Developer Guides for selection and implementation. Dark mode support indicates attention to developer ergonomics.

Machine-Readable LLM Context. The project includes llms.txt—a structured documentation file optimized for AI assistants and RAG systems. This meta-layer enables LLM-powered tools to recommend appropriate patterns, creating a feedback loop where the catalogue itself improves agentic systems.

Production-Proven Provenance. Patterns derive from documented production experience, particularly Sourcegraph's agent development. The repository surfaces "the messy bits" that real products hide, including failure modes, iteration strategies, and organizational adaptations required for agent deployment.

Use Cases

Context Management for Long-Horizon Agents. Agents processing large codebases or extended conversations face context window limitations. Patterns like Context Window Auto-Compaction, Curated Code Context Window, and Episodic Memory Retrieval & Injection provide strategies for maintaining coherent agent state without exponential token costs. Teams building coding assistants or research agents can apply these directly.

Multi-Agent Orchestration at Scale. The Orchestration & Control category addresses coordination complexity with patterns like Declarative Multi-Agent Topology Definition, Planner-Worker Separation for Long-Running Agents, and Economic Value Signaling in Multi-Agent Networks. These suit organizations deploying agent swarms where task decomposition, sub-agent spawning, and resource allocation must be systematic rather than ad hoc.

Reliability Engineering for Agentic Systems. Patterns such as Agent Circuit Breaker, Canary Rollout and Automatic Rollback for Agent Policy Changes, and Schema Validation Retry with Cross-Step Learning translate traditional software reliability practices into agent-specific implementations. DevOps↗ Bright Coding Blog teams integrating agents into CI/CD pipelines will find actionable guidance here.

Security Hardening for Autonomous Code Agents. The Security & Safety category includes Isolated VM per RL Rollout, PII Tokenization, Policy-Gated Tool Proxy, and Zero-Trust Agent Mesh. These address the expanded attack surface when agents execute code, access credentials, or operate across organizational boundaries—critical for enterprises with compliance requirements.

Human-Agent Collaboration Workflows. Patterns like Human-in-the-Loop Approval Framework, Spectrum of Control / Blended Initiative, and Seamless Background-to-Foreground Handoff define interaction models where agents augment rather than replace human judgment. Product teams designing agent UX can reference these to set appropriate autonomy boundaries.

Installation & Setup

The repository itself is a documentation and pattern catalogue, not an installable package. However, contributing or building the website locally requires the following steps, derived from the README's contribution workflow:

# Clone the repository
git clone https://github.com/nibzard/awesome-agentic-patterns.git
cd awesome-agentic-patterns

# Install dependencies (the project uses bun)
bun install

# Build generated data and refresh README sections
bun run build:data

The bun run build:data command is critical: it regenerates the auto-generated TOC and pattern tables from the patterns/ folder, ensuring that any added patterns appear consistently across documentation and website data. Contributors adding patterns should follow this workflow:

# Create a feature branch for your pattern
git checkout -b add-my-pattern

# Add a new pattern file under patterns/ using the repository template
# See CONTRIBUTING.md for the required frontmatter and structure

# Regenerate documentation
bun run build:data

# Commit and push
git add .
git commit -m "Add: my-pattern-name"
git push origin add-my-pattern

The website in apps/web/ requires separate build steps. As an Astro project on Vercel, standard Astro commands apply after dependency installation. The llms.txt file is available at apps/web/public/llms.txt for local inspection or RAG system integration.

Real Code Examples

The repository is pattern-documentation-oriented rather than code-library-oriented. The following examples illustrate how patterns are documented and how the build system processes them, taken directly from the repository structure.

Pattern File Structure: Each pattern is a Markdown file with structured frontmatter. While the exact template isn't reproduced in the README excerpt, the auto-generation system implies standardized metadata. A representative pattern reference appears as:

# Context Window Auto-Compaction

## Problem
Agent context windows fill with irrelevant history, degrading 
reasoning quality and increasing token costs.

## Solution
Implement automatic compaction strategies that preserve 
semantic relevance while truncating or summarizing 
expendable content.

## Implementation
[Detailed guidance, references, and trade-offs]

## References
- [Public blog post, paper, or talk URL]

Build Data Regeneration: The core automation that maintains consistency:

# From package.json or contributing guidelines
bun run build:data
# Generates:
# - README TOC and pattern tables
# - Website data files in apps/web/
# - Cross-references between related patterns

Website Integration Pattern: The Astro-based site consumes pattern data:

// Conceptual structure based on Astro + auto-generated data
// apps/web/src/pages/patterns/[slug].astro
import { getCollection } from 'astro:content';

export async function getStaticPaths() {
  const patterns = await getCollection('patterns');
  return patterns.map(p => ({
    params: { slug: p.slug },
    props: { pattern: p },
  }));
}

Note that the repository does not currently expose extensive executable code examples within the README itself. The value lies in architectural pattern descriptions with reference implementations linked externally. Developers should expect to adapt patterns to their specific frameworks—LangChain, LlamaIndex, or custom orchestrators—rather than importing ready-made modules.

Advanced Usage & Best Practices

Integrate with RAG Systems for Pattern Retrieval. The llms.txt file is explicitly designed for this: provide it as context to LLM-powered coding assistants or indexing pipelines to improve pattern recommendations. The structured format enables semantic search over pattern descriptions and selection criteria.

Use Pattern Packs for Architectural Decisions. Rather than adopting patterns piecemeal, evaluate the curated Pattern Packs for common agent architectures (e.g., coding assistant, research agent, autonomous workflow engine). These pre-selected combinations account for interaction effects between patterns.

Contribute Production Failures as Patterns. The repository's strongest entries derive from post-mortem analysis. When submitting, emphasize the failure mode that motivated the pattern, not just the solution—this "messy bits" ethos is what distinguishes the catalogue from academic surveys.

Monitor Pattern Evolution. Categories are explicitly "fluid." Track issues and PRs for taxonomy changes that might affect how you discover relevant patterns. The maintainers encourage proposals for better categorization slices.

Leverage the Decision Explorer Before Implementation. The interactive guide at agentic-patterns.com can prevent premature optimization by matching use-case requirements to pattern complexity levels.

Comparison with Alternatives

Aspect nibzard/awesome-agentic-patterns General AI Pattern Collections Academic Survey Papers
Curation Criteria Repeatable, agent-centric, traceable; rejects promotions Variable; often undifferentiated link lists Comprehensive but not filtered for production applicability
Provenance Production experience (Sourcegraph agents, open community) Mixed; often theoretical or single-team Research contexts; may not reflect engineering constraints
Discoverability Website with filtering, comparison, graph visualization, decision explorer Typically README-only or basic tagging PDF/linear text; poor searchability
Machine Readability Native llms.txt for LLM/RAG consumption Rare None
Maintenance Model Open PRs, active commit history (June 2026) Often stagnant Static post-publication
Scope Agent-specific: sensing, reasoning, acting, collaboration, reliability Broader or narrower (e.g., only LLM prompts) Theoretical coverage of agent architectures

The primary trade-off: this catalogue sacrifices comprehensiveness for actionability. It will not cover every published agent technique, but included patterns are vetted for real-world applicability. For bleeding-edge research not yet production-tested, supplement with venues like arXiv or NeurIPS proceedings.

FAQ

What license covers the patterns? Apache License 2.0. Commercial use permitted with attribution.

How do I propose a new pattern? Fork, branch add-my-pattern, add a file under patterns/, run bun run build:data, and open a PR.

Is there an installable package? No—this is a documentation catalogue and website, not a library. Patterns are adapted to your framework.

What frameworks are patterns compatible with? Framework-agnostic. Descriptions reference concepts (tool use, context windows, circuit breakers) implementable in any stack.

How current is the content? Last commit June 8, 2026. The auto-generation pipeline ensures README and website stay synchronized.

Can I use llms.txt in my own RAG system? Yes—it's designed for this purpose, optimized for LLM consumption and pattern recommendation.

Why was my pattern PR rejected? The repository rejects "proposals that are primarily product announcements or promotions" even if technically valid.

Conclusion

nibzard/awesome-agentic-patterns fills a critical gap between agent tutorials and production reality. For developers and teams shipping autonomous or semi-autonomous AI systems—whether coding agents, research assistants, or workflow orchestrators—this catalogue offers vetted, repeatable architectural patterns with documented provenance. The 4,791-star community, active maintenance, and rich web discovery tools indicate sustained relevance as the agent ecosystem matures.

The resource is best suited for practitioners who have moved past initial prototyping and face the operational challenges of context management, multi-agent coordination, reliability engineering, and human-agent collaboration. It is not a quick-start guide for first-time agent builders, nor a comprehensive academic survey—rather, a pragmatic reference for the "messy bits" that determine production success.

Explore the patterns, contribute your own production learnings, and integrate llms.txt into your agent tooling: github.com/nibzard/awesome-agentic-patterns

Comments (0)

Comments are moderated before appearing.

No comments yet. Be the first to share your thoughts!

Recommended Prompts

View All
All tools