agentic_design_patterns: Instructions file for Codex

AGENTS.md

agentic_design_patterns AGENTS.md is an instructions file for Codex, OpenCode from gtesei/agentic_design_patterns. It costs 3,822 tokens per session, scanned A, original, MIT.

Repository instructions for an educational collection of runnable examples showing common ways to design AI agents. A monorepo is one repository containing multiple related projects; this one includes Python and TypeScript examples.

In plain words
What is it for?
Use them when running, modifying, or adding examples for prompt chains, routing, planning, tool use, retrieval, or collaboration between agents.
Why use it?
They explain the project layout and development conventions so changes fit the examples and their documentation.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions CLAUDE.md; mentions subagents; mentions Claude Code.

This is gtesei/agentic_design_patterns's own configuration. It tells Codex and OpenCode how to work on agentic_design_patterns itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything agentic_design_patterns configures →

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is cd ../foundational_design_patterns/<N>_<pattern>/typescript.

Reuse

Borrowing it

Nothing to install: this file belongs to gtesei/agentic_design_patterns. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/gtesei/agentic_design_patterns/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/gtesei/agentic_design_patterns

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for agentic_design_patterns AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/gtesei/agentic_design_patterns/agents-md/github.svg)](https://agentmods.dev/instructions/gtesei/agentic_design_patterns/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/gtesei/agentic_design_patterns/agents-md"><img src="https://agentmods.dev/badge/instructions/gtesei/agentic_design_patterns/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for agentic_design_patterns AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/gtesei/agentic_design_patterns/agents-md"><img src="https://agentmods.dev/badge/instructions/gtesei/agentic_design_patterns/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3,822 This file is loaded in full into every session.
When invoked 3,822 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.03822 $0.03822
Opus 5.5 $0.01529 $0.01529
Sonnet 5.5 $0.00764 $0.00764
Haiku 4.5 $0.00382 $0.00382

Measured 2mo ago against content hash 8d32ab0a59ac, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

agentic_design_patterns AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 266 lines

How it starts

The opening of the file, as written. The whole thing — 266 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AGENTS.md

Single source of truth for any AI agent working in this repository — Claude Code, OpenAI Codex, Aider, Cursor, Continue, etc. Repo guide + collaboration model + working conventions + project state. Read this first before making changes. Last updated 2026-05-17.

This file follows the AGENTS.md convention so any compliant agent picks it up automatically. There is no CLAUDE.md, CODEX.md, or other vendor-specific variant — AGENTS.md is the only file.


1. Repository purpose & layout

Educational, hands-on catalog of agentic-AI design patterns. Originally Python (LangChain / LangGraph); a curated TypeScript track now mirrors the entire foundational pattern set 1:1. Each pattern is self-contained, runnable, and accompanied by a long-form README.md. Reference material, not a deployable app.

Patterns live in 7 top-level category directories:

  • foundational_design_patterns/{1_prompt_chain, 2_routing, 3_parallelization, 4_reflection, 5_tool_use, 6_planning, 7_multi_agent_collaboration, 8_react, 9_rag, 10_hitl, 11_structured_outputs, 12_computer_use}
  • reasoning/{tree_of_thoughts, graph_of_thoughts, deep_research}
  • reliability/{error_recovery, guardrails}
  • orchestration/{goal_management, subagents, skills, agent_communication, mcp, prioritization}
  • observability/{evaluation_monitoring, resource_optimization}
  • memory/{memory_management, context_management}
  • learning/adaptive_learning

Each pattern dir has its own pyproject.toml, uv.lock, run.sh, README.md, QUICK_START.md, and src/ with example scripts (*_basic.py, *_advanced.py, or variants like _plan_and_act.py / _hiplan.py). Pattern packages all declare name = "agentic_design_patterns" but they are independent uv environments, not a single workspace — cd into the specific dir to install/run/lint.

TypeScript ports live under <pattern>/typescript/ for every pattern in foundational_design_patterns/. A single bun workspace with shared config lives in typescript_base/ (contains package.json, tsconfig.base.json, TYPESCRIPT.md) and covers all foundational TypeScript packages via the ../foundational_design_patterns/*/typescript glob.

Read the full file on GitHub · 266 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 266 lines · 3,822 tokens per session scan A 8d32ab0a59ac

Subscribe to this mod's changes

agentic_design_patterns AGENTS.md is an instructions file published in the GitHub repository gtesei/agentic_design_patterns (20 stars, last pushed 5mo ago), licensed MIT. It adds 3,822 tokens to every session, about $0.0153 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

agentic_design_patterns AGENTS.md compared with instructions from other repositories

agentic_design_patterns AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
agentic_design_patterns AGENTS.mdgtesei/agentic_design_patternsInstructions file205mo agoMITA3,822Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot
vscode model-prompts.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA2,022GitHub Copilot