@itamarzand88/awesome-agent-conventions-6
AAGENTS.md - Guide for AI Coding Assistants
Install
agr install @itamarzand88/awesome-agent-conventions-6 --target codexWrites 1 file into AGENTS.md, pinned to git-d29dbfaf.
- AGENTS.md
Document
AGENTS.md - Guide for AI Coding Assistants
This document is designed to help AI coding assistants (Kiro, Claude Code, Copilot, etc.) effectively work with the CBMC codebase. It provides a comprehensive overview of the project structure, key concepts, and development practices.
Table of Contents
- Project Overview
- Repository Structure
- Key Directories
- Architectural Concepts
- Central Data Structures
- Build System
- Testing Framework
- Coding Standards
- Documentation Practices
- Common Development Workflows
- Navigation Tips
- Important Links
Project Overview
CBMC (C Bounded Model Checker) is the main tool in the CProver suite for formal verification of C and C++ programs.
What CBMC Does
- Bounded model checking for C/C++ programs
- Supports C89, C99, most of C11, C17, C23
- Supports most compiler extensions from gcc and Visual Studio
- Verifies array bounds, pointer safety, exceptions, and user-specified assertions
- Performs verification by unwinding loops and passing equations to decision procedures
- Also includes JBMC for Java bytecode verification
Project Website
- Main site: cprover.org
- Documentation: diffblue.github.io/cbmc
Repository Structure
cbmc/
├── src/ # Main source code
├── jbmc/ # Java Bounded Model Checker
├── regression/ # Regression test suites
├── unit/ # Unit test suites
├── doc/ # Documentation
│ ├── architectural/ # Architecture documentation
│ ├── ADR/ # Architecture Decision Records
│ ├── cprover-manual/ # User manual
│ └── man/ # Man pages
├── scripts/ # Build and development scripts
├── cmake/ # CMake configuration
├── integration/ # Integration test examples
│ ├── linux/ # Linux integration examples
│ └── xen/ # Xen hypervisor examples
├── .github/ # GitHub configuration and workflows
│ ├── workflows/ # CI/CD workflow definitions
│ │ ├── build-and-test-Linux.yaml # Main Linux build and test
│ │ ├── pull-request-checks.yaml # PR validation checks
│ │ ├── coverage.yaml # Code coverage reporting
│ │ ├── syntax-checks.yaml # Code style and linting
│ │ ├── codeql-analysis.yml # Security analysis
│ │ ├── performance.yaml # Performance benchmarking
│ │ ├── profiling.yaml # Pre-solver profiling on PRs
│ │ └── release-packages.yaml # Release automation
│ └── dependabot.yml # Dependency update automation
├── CODING_STANDARD.md # Coding conventions
├── COMPILING.md # Build instructions
├── TOOLS_OVERVIEW.md # Overview of all tools
└── README.md # Main readme
Key Directories
src/ - Main Source Code
The source is organized into modular directories by functionality:
Core Components
-
util/- Fundamental utilities and data structures- Base data structures like
irept,exprt,typet - String handling, expression utilities
- Foundation for everything else
- Base data structures like
-
goto-programs/- GOTO intermediate representation- Core IR data structures:
goto_programt,goto_functiont,goto_modelt - The heart of CBMC's program representation
- Core IR data structures:
-
linking/- Linking GOTO programs together- Combines multiple GOTO programs
-
big-int/- Big integer arithmetic- Arbitrary precision integer operations
- Used throughout CBMC for large numeric computations
Language Front Ends
-
langapi/- Language API interface- Abstract interface for language front-ends
-
ansi-c/- C language front-end- Parsing and type-checking for C
-
cpp/- C++ language front-end- C++ specific parsing (depends on
ansi-c)
- C++ specific parsing (depends on
Analysis and Verification
-
goto-symex/- Symbolic execution engine- Core symbolic execution implementation
- Transforms GOTO programs into logical formulas
-
analyses/- Static analyses- Various static analysis passes
- Abstract interpretation implementations
-
pointer-analysis/- Pointer analysis- Points-to analysis and pointer tracking
-
goto-checker/- Verification orchestration- Coordinates the verification process
Solvers
solvers/- Decision procedures- SAT/SMT solver interfaces
- Bit-blasting and encoding
Tools (Executables)
cbmc/- Main CBMC toolgoto-cc/- Compiler wrappergoto-instrument/- Program instrumentationgoto-analyzer/- Abstract interpretation toolgoto-diff/- Diff tool for GOTO programsgoto-harness/- Test harness generationgoto-bmc/- Bounded model checkingmemory-analyzer/- Memory analysis with gdbsymtab2gb/- Symbol table to GOTO binary
Other Components
json/- JSON handlingxmllang/- XML supportassembler/- Assembly support
jbmc/ - Java Bounded Model Checker
Parallel structure to main CBMC for Java:
jbmc/src/- Java-specific source codejava_bytecode/- Java bytecode front-end- Parsing and analysis of Java .class files
- Java-specific type system and language features
- JVM instruction handling
jbmc/- Main JBMC tool executable- Entry point for Java verification
janalyzer/- Java static analyzer- Abstract interpretation for Java
jdiff/- Diff tool for Java programs- Comparison of Java GOTO programs
miniz/- ZIP compression library- Used for reading JAR files and compressed class files
jbmc/regression/- Java regression testsjbmc/unit/- Java unit tests
regression/ - Regression Tests
Extensive test suites organized by tool and feature:
cbmc/- Main CBMC testsgoto-instrument/- Instrumentation testsgoto-analyzer/- Analysis testscontracts/- Contract testscbmc-cpp/- C++ specific testssmt2_solver/- SMT solver tests- Many more specialized test directories
See regression/README.md for test tags and categories.
unit/ - Unit Tests
Unit tests using the Catch framework:
- Organized by module matching
src/structure - Tests for individual components and utilities
- Run with
unitexecutable
doc/ - Documentation
-
architectural/- Architecture documentationbackground-concepts.md- Key conceptscbmc-architecture.md- High-level architecturecentral-data-structures.md- Core data structuresfolder-walkthrough.md- Directory guidegoto-program-transformations.md- Instrumentation passes
-
ADR/- Architecture Decision Records- Documents key architectural decisions
- Useful for understanding design rationale
-
cprover-manual/- User manual -
man/- Man pages for tools
scripts/ - Development Scripts
- Build helpers and utilities
cpplint.py- Style checkerprofile_cbmc.py- Performance profiling tool (see Profiling CBMC)profiling/- Profiling package (analysis, benchmarks, runner, utils)test.pl- Regression test runner (inregression/)- CI/CD related scripts
Architectural Concepts
CBMC Pipeline
CBMC follows a compiler-like architecture with these stages:
Source Code → Preprocessing → Parsing → Type Checking
↓
Goto Conversion
↓
Goto Program (IR)
↓
Instrumentation/Transformations
↓
Symbolic Execution
↓
SAT/SMT Encoding
↓
Decision Procedure
↓
Counterexample/Trace
GOTO Programs
The GOTO program is CBMC's intermediate representation (IR):
- Language-agnostic representation of programs
- Similar to control flow graphs (CFGs)
- Can be saved to "goto binaries" (by
goto-cc) - Processed by all back-end tools
Key Concepts
- Symbol Table - Maps identifiers to their definitions
- GOTO Functions - Collection of functions in IR form
- GOTO Instructions - Individual instructions with guards and types
- Symbolic Execution - Explores program paths symbolically
- Bounded Model Checking - Unwinds loops to finite depth
- Decision Procedures - SAT/SMT solvers that check satisfiability
Central Data Structures
goto_modelt
The top-level data structure representing a complete program:
class goto_modelt {
symbol_tablet symbol_table; // All symbols (variables, functions, types)
goto_functionst goto_functions; // All functions in GOTO form
};
goto_functionst
A map from function names to function definitions:
// Conceptually: map<identifier, goto_functiont>
goto_functiont
Represents a single function:
class goto_functiont {
goto_programt body; // Function body (instruction sequence)
std::vector<irep_idt> parameter_identifiers; // Parameter names
};
goto_programt
A sequence of GOTO instructions forming a function body:
class goto_programt {
std::list<instructiont> instructions; // Ordered list of instructions
};
See src/goto-programs/goto_program.h for details.
goto_instructiont
A single instruction in the GOTO program:
class goto_instructiont {
goto_program_instruction_typet type; // Instruction type (ASSIGN, GOTO, etc.)
codet code; // The actual code/statement
exprt guard; // Boolean condition (optional)
source_locationt source_location; // Original source location
// ... and other fields
};
Instruction Types include:
ASSIGN- AssignmentFUNCTION_CALL- Function callRETURN- Return statementGOTO- Conditional/unconditional jumpASSUME- Assumption (path constraint)ASSERT- Assertion to verifySKIP- No-op- And more...
symbolt
Represents a symbol (variable, function, type):
class symbolt {
irep_idt name; // Unique identifier
typet type; // Type of symbol
exprt value; // Initial value (if applicable)
source_locationt location;
// ... other metadata
};
irept - The Foundation
The base data structure for most CBMC types:
class irept {
// Tree structure with:
// - An ID (string)
// - Named sub-trees (map)
// - Ordered sub-trees (vector)
};
Key classes built on irept:
exprt- Expressionstypet- Typescodet- Code/statementssource_locationt- Source locations
Important: Use the specific subclass methods rather than raw irept access.
exprt and typet
exprt- Represents expressions (operators, literals, variables, etc.)typet- Represents types (int, pointer, array, struct, etc.)
Both inherit from irept and provide type-safe accessors.
Directory Dependencies
Key dependency relationships:
- Tools (cbmc, goto-cc, etc.) → goto-instrument → goto-symex
- goto-symex → solvers, pointer-analysis
- Languages (cpp, ansi-c) → langapi → goto-programs
- Almost everything → util
- util → big-int
See doc/architectural/folder-walkthrough.md for the full dependency graph.
Build System
Build Dependencies
CBMC requires bison, flex, a C- and C++ compiler, and make or CMake. To
speed up rebuilds, install ccache.
CMake Build (Recommended)
CBMC uses CMake 3.8+ as the primary build system.
Quick Start
# 1. Update submodules
git submodule update --init
# 2. Generate build files
cmake -S . -Bbuild
# 3. Build
cmake --build build --parallel $(nproc)
# 4. Run tests
ctest --test-dir build -V -L CORE
Configuration Options
# Use specific compiler
cmake -S . -Bbuild -DCMAKE_CXX_COMPILER=clang++
# Build with different SAT solver
cmake -S . -Bbuild -Dsat_impl=cadical
# Debug build
cmake -S . -Bbuild -DCMAKE_BUILD_TYPE=Debug
# Release build
cmake -S . -Bbuild -DCMAKE_BUILD_TYPE=Release
Build Locations
After building, executables are in:
build/bin/- Main executables (cbmc, goto-cc, etc.)build/lib/- Libraries
Makefile Build (Alternative)
Traditional makefiles are also available:
cd src
make minisat2-download
make -j$(nproc) # Parallel build
Configuration in src/config.inc (SAT solver paths, etc.).
SAT Solver Integration
CBMC can use various SAT/SMT solvers:
- MiniSat (default)
- CaDiCaL
- Glucose
- Z3
- And others
CMake automatically downloads MiniSat during configuration.
See COMPILING.md for detailed build instructions for all platforms.
Testing Framework
Regression Tests
Location: regression/
Running Regression Tests
# Run all regression tests
make -C regression test
# Run specific test directory
cd regression/cbmc
make test
# Using CMake
ctest --test-dir build -V -L CORE -j$(nproc)
Test Structure
Each test directory contains:
- Test cases (
.c,.cpp,.javafiles) - Test descriptor (
test.desc) with flags (seeregression/test.pl --helpfor format details)
Test Tags
Important tags (see regression/README.md):
smt-backend- Requires SMT backendbroken-smt-backend- Known issues with SMTthorough-smt-backend- Too slow for CI- Similar tags for specific solvers
Unit Tests
Location: unit/
Running Unit Tests
# Build and run all unit tests
make -C unit test
# Using CMake
cmake --build build --target unit
cd unit && ../build/bin/unit
# Run specific test suite
cd unit && ../build/bin/unit "[solvers]" # Run only solver tests
Test Framework
- Uses Catch2 testing framework
- Tests organized by module
- Each test is a
TEST_CASEorSCENARIO
Writing Tests
Regression Test Example:
# In regression/cbmc/my-test/
main.c # Test input
test.desc # Test configuration
test.desc format:
CORE
main.c
--bounds-check --unwind 5
^VERIFICATION SUCCESSFUL$
Unit Test Example:
TEST_CASE("My feature test", "[my-module]")
{
// Setup
// Test
REQUIRE(result == expected);
}
Coding Standards
CBMC follows strict coding standards documented in CODING_STANDARD.md.
Formatting
Enforced by clang-format - Run before committing!
Key rules:
- 2 spaces for indentation (no tabs)
- 80 character line limit
- Matching
{ }in same column (except initializers/lambdas) - Spaces around binary operators (
=,+,==) - Space after comma and colon (in for loops)
*/&attached to variable name:int *ptr;- No trailing whitespace
- Newline at end of file
Control Flow
// Correct
if(condition)
{
do_something();
}
else
{
do_other();
}
// Single-line blocks (allowed)
if(condition)
do_something();
// For loops
for(int i = 0; i < n; i++)
{
// body
}
Comments and Documentation
- No
/* */style comments (use//instead) - Every file must start with author comment and
\fileDoxygen tag
/// \file
/// Brief description of this file's purpose
- Document all classes, functions, and non-obvious members
/// Brief description ending with period. Longer description can follow.
/// \param arg: Description of parameter
/// \param [out] result: Output parameter description
/// \param [in,out] state: In-out parameter description
/// \return Description of return value
int my_function(int arg, int &result, state_t &state);
Code Organization
- Methods > 50 lines should be broken into smaller functions
- Use blank lines to separate logical blocks
- Prefer clear variable names over comments
- Type safety: Use proper const-correctness
- Error handling: Use descriptive INVARIANT messages
Interface Stability
- Consider impact on external users
- Public interfaces should be stable
- Document deprecations clearly
- Interfaces = anything used outside a single directory
Best Practices
- Const-correctness - Mark const what should be const
- Type safety - Avoid casts when possible
- Error handling - Use INVARIANT/PRECONDITION/POSTCONDITION
- Documentation - Prioritize readability
- Testing - Include regression tests for changes
Documentation Practices
Doxygen Documentation
CBMC uses Doxygen for API documentation.
Building Documentation
cd src
doxygen
# Output in doc/html/
Documentation Style
Follow LLVM guidelines with extensions:
/// This is the brief description (first sentence).
///
/// More detailed explanation can follow in subsequent paragraphs.
/// Feel free to break into multiple paragraphs for readability.
///
/// \param param1: Short description
/// \param param2: Longer description that needs multiple lines.
/// Additional lines indented by two spaces for clarity.
/// \param [out] output: This parameter is modified by the function
/// \return Description of return value
Documentation Types
- File documentation - Every
.cppand.hfile - Class documentation - Purpose and usage
- Function documentation - Parameters, return values, behavior
- Complex algorithms - Explain the approach
- Non-obvious code - Clarify intent
Existing Documentation
Read before coding:
CODING_STANDARD.md- Style and conventionsCOMPILING.md- Build instructionsTOOLS_OVERVIEW.md- Tool descriptionsdoc/architectural/- Architecture deep-divesdoc/ADR/- Design decisions- Doxygen output - API reference
Common Development Workflows
1. Making Changes to Source Code
# 1. Create a feature branch from develop
git checkout develop
git checkout -b feature/my-improvement
# 2. Make changes following coding standards
# Edit files in src/
# 3. Format code
# (clang-format is enforced in CI)
# 4. Build
cmake --build build
# 5. Run relevant tests
ctest --test-dir build -V -L CORE -R <relevant-module>
cd unit && ../build/bin/unit "[relevant-module]"
# 6. Commit with clear message
git commit -m "Add feature X to improve Y (explains WHAT)" -m "Doing X is important, because ... (explain WHY and possibly HOW)"
# 7. Push and create PR targeting develop
git push origin feature/my-improvement
2. Adding a New Feature
# 1. Implement the feature in appropriate src/ directory
# 2. Add unit tests in unit/
# 3. Add regression tests in regression/
# 4. Update documentation if needed
# 5. Ensure all tests pass
# 6. Create PR with detailed description
3. Fixing a Bug
# 1. Create regression test that reproduces the bug
# 2. Confirm test fails with current code
# 3. Fix the bug
# 4. Confirm test now passes
# 5. Ensure no other tests break
# 6. Create PR referencing the issue
4. Working with GOTO Programs
# Generate GOTO binary from C code
goto-cc -o program.gb program.c
# View GOTO program
goto-instrument --show-goto-functions program.gb
# Instrument GOTO program
goto-instrument --bounds-check program.gb instrumented.gb
# Verify with CBMC
cbmc instrumented.gb
5. Running Specific Regression Tests
# Single test
cd regression/cbmc
../test.pl -C -p -c ../../../src/cbmc/cbmc my-test
# All tests in a category
cd regression/cbmc
make test
6. Profiling CBMC
The profiling tool (scripts/profile_cbmc.py) profiles CBMC's pre-solver
stages using perf and generates flamegraphs. Solver time is excluded by
default so results reflect only CBMC's own code.
Prerequisites: Linux with perf installed.
# Profile a single file
scripts/profile_cbmc.py test.c -- --bounds-check --unwind 100
# Run 3 built-in benchmarks (linked_list, array_ops, structs)
scripts/profile_cbmc.py --auto
# Extended suite (10 benchmarks) plus CSmith-generated tests
scripts/profile_cbmc.py --auto-large --auto-csmith
# Multiple runs for statistical significance (reports mean ± stddev)
scripts/profile_cbmc.py --auto --runs 3
# Source-level call site resolution (build a debug binary first)
cmake -S . -Bbuild-debug -DCMAKE_BUILD_TYPE=RelWithDebInfo -DWITH_JBMC=OFF
cmake --build build-debug --target cbmc -j$(nproc)
scripts/profile_cbmc.py --auto --debug-binary build-debug/bin/cbmc
# Differential profiling: compare two git refs
scripts/profile_cbmc.py --diff develop my-optimization-branch
Outputs (in profile-results/ by default):
flamegraph.svgper benchmark - Interactive flamegraphaggregated.svg- Combined flamegraph across all benchmarkssummary.txt- Text summary with hotspot analysis and optimization suggestionsresults.json- Machine-readable results
CI integration: The profiling.yaml workflow runs --auto --runs 3 on
every PR, posts the summary to the GitHub step summary, and uploads
flamegraph SVGs as downloadable artifacts.
Navigation Tips
Finding Code
By Functionality:
- Parsing C code →
src/ansi-c/ - Symbolic execution →
src/goto-symex/ - SAT/SMT solvers →
src/solvers/ - Main CBMC tool →
src/cbmc/ - Instrumentation →
src/goto-instrument/
By Data Structure:
- GOTO programs →
src/goto-programs/goto_program.h - Expressions →
src/util/std_expr.h,src/util/expr.h - Types →
src/util/type.h,src/util/std_types.h - Symbols →
src/util/symbol.h - Symbol table →
src/util/symbol_table.h
By Concept:
- Loop unwinding →
src/goto-symex/andsrc/goto-instrument/ - Pointer analysis →
src/pointer-analysis/ - Static analysis →
src/analyses/ - Abstract interpretation →
src/analyses/
Using grep/ag/ripgrep
# Find where a class is defined
rg "class goto_programt" src/
# Find usages of a function
rg "goto_convert\(" src/
# Find test cases for a feature
rg "bounds.check" regression/ -l
# Find documentation
rg "\\page" doc/ -A 5
Understanding Module Dependencies
Each source directory has module_dependencies.txt:
# Check what a module depends on
cat src/goto-symex/module_dependencies.txt
Following the Data Flow
To understand how data flows through CBMC:
- Start - Source code input
- Frontend -
src/ansi-c/orsrc/cpp/parses to AST - Type Checking - Language-specific type checking
- Symbol Table - Symbols populated in
symbol_tablet - GOTO Conversion - AST →
goto_programt - Goto Model - Complete
goto_modeltcreated - Instrumentation -
goto-instrumenttransforms - Symbolic Execution -
goto-symexexplores paths - Solver - SAT/SMT solver in
src/solvers/ - Result - Verification result or counterexample
Reading the Code
Start with:
src/cbmc/cbmc_parse_options.cpp- Entry point for CBMCsrc/util/irep.h- Core data structure of all intermediate representations- Headers in
src/goto-programs/- Core IR structures doc/architectural/- Architecture documentation
Understand patterns:
- Most data structures inherit from
irept - Use
id2string()to convertirep_idttostd::string - Expression/type casting with
expr_cast.h - Visitors for traversing expressions/instructions
Important Links
Documentation
- CProver Documentation - Complete developer docs
- CBMC Architecture - High-level overview
- Background Concepts - Key concepts
- Developer Tutorial - Getting started
In This Repository
- CODING_STANDARD.md - Coding conventions
- COMPILING.md - Build instructions
- TOOLS_OVERVIEW.md - All tools explained
- FEATURE_IDEAS.md - Mini-projects for contributors
- README.md - Main readme
Architecture Documentation
- doc/architectural/folder-walkthrough.md - Directory structure
- doc/architectural/central-data-structures.md - Core data structures
- doc/architectural/goto-program-transformations.md - Instrumentation passes
- doc/architectural/compilation-and-development.md - Development guide
Architecture Decision Records (ADRs)
- doc/ADR/ - Design decisions
- doc/ADR/cpp_api_modularisation.md - API design
- doc/ADR/symex_ready_goto.md - Symex design
External Resources
- Main Website - User documentation
- GitHub Repository - Public repository
- CProver Manual - User manual
Quick Reference Card
Common Tasks
| Task | Command |
|---|---|
| Build everything | cmake --build build |
| Build CBMC only | cmake --build build --target cbmc |
| Run all tests | ctest --test-dir build -V -L CORE -j$(nproc) |
| Run unit tests | cd unit && ../build/bin/unit |
| Format code | clang-format -i <file> |
| Generate docs | cd src && doxygen |
| Create GOTO binary | goto-cc -o out.gb input.c |
| View GOTO program | goto-instrument --show-goto-functions prog.gb |
| Run CBMC | cbmc program.gb or cbmc program.c |
| Profile CBMC | scripts/profile_cbmc.py --auto --runs 3 |
Key Files to Know
src/goto-programs/goto_program.h- Core IR structuressrc/util/irep.h- Base data structuresrc/util/expr.h- Expressionssrc/util/type.h- Typessrc/util/symbol.h- Symbolssrc/goto-symex/goto_symext.h- Symbolic executionsrc/solvers/- SAT/SMT interfaces
Module Map (Key Dependencies)
cbmc → goto-instrument → goto-symex → {solvers, pointer-analysis}
goto-cc → cpp → ansi-c → langapi → goto-programs
goto-programs → util → big-int
Tips for AI Assistants
When Adding Features
- Check existing patterns in similar code
- Follow the module structure (don't cross module boundaries unnecessarily)
- Add tests (unit and regression)
- Update documentation
- Follow coding standards (formatting, comments)
When Debugging
- Check if there's a regression test that demonstrates the issue
- Use
goto-instrument --show-goto-functionsto inspect IR - Look for similar fixed bugs in git history
- Check module dependencies if getting linker errors
When Refactoring
- Understand data flow first (see Navigation Tips)
- Check impact on public interfaces
- Run full test suite
- Update documentation
Common Pitfalls
- Don't break 80-char line limit (enforced by CI)
- Don't use
/* */comments - Don't forget Doxygen comments on public interfaces
- Don't skip regression tests
- Don't modify
ireptdirectly; use subclass accessors - Don't forget to update submodules after pulling
Understanding Output
- CBMC outputs verification results and traces
- Traces show path through program leading to property violation
- Check
source_locationtin instructions for source mapping
Last Updated: 2026-01-19
This guide is maintained to help AI coding assistants work effectively with CBMC. For questions or updates, refer to the main documentation or ask the development team.
Repository README
Describes ItamarZand88/awesome-agent-conventions as a whole, which may contain artifacts other than this one. Where this artifact had no useful description of its own, its summary was taken from here.
Awesome Agent Conventions
A curated field guide to the convention files AI agents read, write, and act on.
22 conventions across 11 categories. From common project instruction files to newer agent-web discovery and trust formats.
Agent tools increasingly rely on plain files in a repository or website root: instructions, memory, rules, tool connections, prompt assets, discovery metadata, and protocol hints. The names are easy to mix up, and the adoption levels vary a lot.
This repo keeps the map practical:
- Know what a file is for. Each entry names the convention, usual filename, primary readers, and spec or source.
- Study real examples. Examples are fetched from public repositories by script, with provenance kept at the top of each file.
- Separate practice from proposal. Maturity labels show what is widely used, what is early, and what is still only proposed.
Contents
- Instruction & context · category page
- Memory & state · category page
- 🟢 MEMORY.md
- 🟢 Memory Bank
- Spec-driven development · category page
- Skills & prompt assets · category page
- Tooling & connections · category page
- Rules & ignore files · category page
- Design · category page
- Web & discoverability · category page
- 🟢 llms.txt
- 🟢 pricing.md
- Agent-web trust · category page
- Identity & protocols · category page
- Proposed namespace · category page
What counts
This list is intentionally narrow. A file belongs here when it is a convention for agent behavior or agent-readable metadata: instructions, memory, skills, rules, tool config, prompt assets, or web-discovery hints.
Any file type can qualify - .md, .txt, .prompty, .json, dotfiles, or a
directory pattern. Human-first project docs such as README.md,
CONTRIBUTING.md, SECURITY.md, and CHANGELOG.md stay out unless the file has
become an agent convention in its own right.
Maturity tiers
The badge is a claim about adoption, not quality. It keeps a proven convention from being presented the same way as a new idea.
| Badge | Tier | Meaning |
|---|---|---|
| 🟢 | Adopted | Used in production by multiple tools, projects, or teams. |
| 🟠 | Emerging | Published by a real organization, but still early or limited in adoption. |
| 🔵 | Proposed | Publicly described, but without clear adoption beyond the proposal. |
Instruction & context
Standalone page: categories/instruction-context.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | AGENTS.md | AGENTS.md | Most coding agents - OpenAI Codex, Cursor, Jules, Aider, Gemini CLI, Zed, and others | spec ↗ |
| 🟢 | CLAUDE.md | CLAUDE.md | Claude Code, and tools that read the Claude memory convention | spec ↗ |
| 🟢 | Tool-specific instruction files | GEMINI.md AGENT.md QWEN.md WARP.md CONVENTIONS.md copilot-instructions.md | Each file is read by its namesake tool - Gemini CLI, Amp, Qwen Code, Warp, Aider, GitHub Copilot - often alongside or as a bridge to AGENTS.md | spec ↗ |
| 🟠 | OKF (Open Knowledge Format) | .md | Agents over MCP (okfy, openknowledge, superops okf CLIs); Google's knowledge-catalog ingests bundles | spec ↗ |
- AGENTS.md - A plain-Markdown "README for agents" - build/test commands, conventions, and gotchas an agent needs before touching the code. The most widely adopted cross-tool instruction file.
- CLAUDE.md - Anthropic's memory file for Claude Code - loaded automatically at session start to carry project commands, style rules, and standing instructions across turns.
- Tool-specific instruction files - Per-tool instruction files that predate or coexist with AGENTS.md. Some tools now default to AGENTS.md while keeping legacy filenames alive, so these variants still matter when auditing real repositories.
- OKF (Open Knowledge Format) - A machine-first organizational knowledge base: a version-controlled folder of typed Markdown files (one concept per file) that any agent reads as ground-truth context. Open-sourced by Google Cloud in 2026 as the content layer to MCP's transport.
Memory & state
Standalone page: categories/memory-state.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | MEMORY.md | MEMORY.md | Claude Code's auto-memory - the per-project MEMORY.md index it writes and re-reads each session | spec ↗ |
| 🟢 | Memory Bank | projectbrief.md productContext.md activeContext.md systemPatterns.md techContext.md progress.md | Cline, Roo Code, and Cursor (via the Memory Bank custom-instructions pattern) | spec ↗ |
- MEMORY.md - A persistent, agent-maintained index of durable facts - written and re-read across sessions so an agent accumulates project memory instead of relearning each time.
- Memory Bank - Cline's structured memory system - a set of Markdown files an agent reads at the start of every task to reconstruct full project context after its session memory resets. The six files shown are Cline's set; tools like Roo Code use an overlapping but different variant.
Spec-driven development
Standalone page: categories/spec-driven-development.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | Spec Kit | constitution.md spec.md plan.md tasks.md | GitHub Spec Kit's slash-command agents (Copilot, Claude, Gemini, Cursor, and more) | spec ↗ |
| 🟢 | Kiro steering files | product.md structure.md tech.md | AWS Kiro (steering files are largely Kiro-specific) | spec ↗ |
- Spec Kit - GitHub's spec-driven workflow - a constitution plus per-feature spec → plan → tasks files that drive an agent through structured, reviewable implementation.
- Kiro steering files - Kiro's always-on steering docs - product, structure, and tech files that give the agent persistent project context outside of any single spec.
Skills & prompt assets
Standalone page: categories/skills-prompt-assets.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | SKILL.md | SKILL.md | Claude Agent Skills, Claude Code, Amp, Agent Skills-compatible tools | spec ↗ |
| 🟢 | Prompt asset files | .prompty .prompt system_prompt.txt | Prompty tooling, Azure AI / Semantic Kernel, and apps that load externalized prompts | spec ↗ |
| 🟢 | Claude Code commands | .md | Claude Code - project .claude/commands/ and user ~/.claude/commands/ | spec ↗ |
| 🟢 | Copilot prompt & instruction files | .prompt.md .instructions.md | GitHub Copilot in VS Code / Copilot CLI | spec ↗ |
- SKILL.md - A self-contained, model-invoked capability file that tells an agent when to load a reusable procedure and how to execute it.
- Prompt asset files - Externalized prompt files - Prompty's YAML-front-mattered .prompty, plain .prompt templates, and system_prompt.txt - that pull the prompt out of source code so it can be versioned and edited on its own. Only .prompty has a formal spec (prompty.ai); .prompt and system_prompt.txt are ad-hoc externalized-prompt filenames.
- Claude Code commands - A Markdown file Claude Code exposes as a /slash-command - a reusable, version-controlled prompt workflow, with optional frontmatter (allowed-tools, model, argument-hint) and $ARGUMENTS and shell placeholders (@file references are a general Claude Code prompt feature, not command-specific). Now converging with Agent Skills, but still widely committed in its own right.
- Copilot prompt & instruction files - Modular, path-scoped Copilot context: *.instructions.md auto-attach to matching files via an applyTo glob, while *.prompt.md are reusable prompts you invoke by name - the granular cousins of a single .github/copilot-instructions.md.
Tooling & connections
Standalone page: categories/tooling-connections.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | MCP server config | .mcp.json | Claude Code, Cursor, VS Code / Copilot, and Claude Desktop - every MCP host reads the same mcpServers schema, though the filename and path differ per tool | spec ↗ |
- MCP server config - A JSON file that tells an agent which Model Context Protocol servers to launch and how (command, args, env) - making a project's tool and data integrations portable, shareable, and version-controlled across every MCP-capable client.
Rules & ignore files
Standalone page: categories/rules-ignore-files.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | Rules files | .cursorrules .mdc .clinerules .clinerules/ (pattern) .windsurfrules | Cursor (.cursorrules / .mdc), Cline (.clinerules/ and legacy .clinerules), Windsurf (.windsurfrules) | spec ↗ |
| 🟢 | AI ignore files | .aiignore .cursorignore .codeiumignore .aiexclude | JetBrains Junie (.aiignore), Cursor (.cursorignore), Codeium/Windsurf (.codeiumignore) | spec ↗ |
- Rules files - Per-tool rule files that scope agent behavior - older single-file forms (.cursorrules, .clinerules, .windsurfrules) and newer directory-based, glob-scoped forms (.cursor/rules/.mdc, .clinerules/, .windsurf/rules/.md).
- AI ignore files - gitignore-syntax files that fence an AI agent out of paths - secrets, vendored code, generated output - so they're never sent to the model as context.
Design
Standalone page: categories/design.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | DESIGN.md | DESIGN.md | Google Stitch natively; and coding agents (e.g. Claude Code) when pointed at it as design context | spec ↗ |
- DESIGN.md - A structured, machine-readable design specification - tokens, components, and layout intent - that an agent reads to generate or keep UI consistent with an established system. Open-sourced by Google Labs in 2026 as a cross-tool draft spec.
Web & discoverability
Standalone page: categories/web-discoverability.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟢 | llms.txt | llms.txt llms-full.txt (pattern) | Docs sites publish it for LLM tools and crawlers - though no major provider has confirmed reading it | spec ↗ |
| 🟢 | pricing.md | pricing.md | Agents and LLM browsers fetching a clean, parse-able pricing page | spec ↗ |
- llms.txt - A proposed-turned-widely-published standard: a root-level Markdown file giving LLMs a curated, link-rich map of a site's docs. Published across hundreds of developer-docs sites - though whether the major LLM providers actually read it remains unproven.
- pricing.md - The Markdown twin of a pricing page - same URL with a .md suffix - so an agent gets structured plans and numbers instead of scraping marketing HTML. A concrete, shipping instance of the page.md pattern.
Agent-web trust
Standalone page: categories/agent-web-trust.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟠 | auth.md | auth.md | Agents discovering how to authenticate to a service (early adopters) | spec ↗ |
| 🔵 | ai.txt | ai.txt | AI training/data-mining crawlers that voluntarily honor AI usage preferences; crawler support is not yet reliable | spec ↗ |
- auth.md - A Markdown file that tells an agent how to authenticate with a service - discovery of auth endpoints and flows. Shipped by WorkOS as a real, working convention, but adoption beyond it is still early.
- ai.txt - A text file declaring machine-readable consent, licensing, or policy preferences for AI training and data-mining. Spawning popularized the deployed root-file pattern, and a 2026 Internet-Draft now proposes a well-known URI; adoption and crawler obedience are still thin, so it stays 🔵.
Identity & protocols
Standalone page: categories/identity-protocols.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🟠 | Agent Cards (A2A) | agent-card.json agent.json (pattern) | A2A-compatible agents discovering another agent's capabilities | spec ↗ |
- Agent Cards (A2A) - The Agent2Agent (A2A) capability card - a JSON document at a well-known path advertising an agent's skills, endpoints, and auth so other agents can discover and call it. Now a Linux Foundation project at v1.0; adoption is growing but early.
Proposed namespace
Standalone page: categories/proposed-namespace.md
| Convention | Files | Read by | Spec | |
|---|---|---|---|---|
| 🔵 | The protocols.md namespace | proof.md | - (no demonstrated readers; aspirational) | spec ↗ |
- The protocols.md namespace - A single maintainer's pre-registered namespace of ~74 aspirational .md "protocols" (proof.md, signature.md, reputation.md, …) staked as Schelling points for a future agent web. Published concept, no demonstrated adoption - see the page for the audited, honest caveats.
Maintaining examples
Example files are fetched, not invented. The extractor pulls them from public
sources, stores them under conventions/<slug>/examples/<source>/<filename>,
and adds a line-1 provenance comment. The examples remain under their upstream
owners' licenses and terms; see
THIRD_PARTY_EXAMPLES.md before reusing them.
To refresh everything:
pip install -r scripts/requirements.txt
python scripts/extract.py # fetch real files + rebuild each convention's README
python scripts/build_readme.py # rebuild this README from scripts/targets.json
Re-running is idempotent. A missing target prints a miss and is skipped.
Examples are representative samples: any file over 256 KB (for example, a
multi-MB llms-full.txt) is truncated with a marker pointing back to the full
source. scripts/targets.json remains the source of truth for conventions that
have not been migrated yet; the skill-md pilot uses local convention metadata
instead. Edit the relevant source and re-run both scripts.
Shortcut targets are available in the Makefile:
make verify # schema + generated files + example provenance + links
make extract # refetch public examples and rebuild generated docs
make license-report # summarize upstream licenses for vendored examples
CI keeps the generated files and links honest. The
verify workflow checks that generated docs match
catalog metadata and migrated local metadata, and that every spec, example, and
instance URL still resolves on each pull request and weekly. Run the same link
check locally with
python scripts/check_links.py.
Contributing
Read CONTRIBUTING.md. In short: an entry must pass the filter
above and carry evidence for its maturity tier. Add sources to
scripts/targets.json for non-migrated conventions, run the scripts, and open
a PR. The skill-md pilot uses local convention metadata instead. Do not
hand-write example files.
Before proposing adjacent standards, check WATCHLIST.md. Project direction lives in ROADMAP.md.
License
The curation, scripts, and original prose in this repository are MIT. Vendored example files remain under their upstream owners' licenses and terms; see THIRD_PARTY_EXAMPLES.md.
Trustgrade A
- passBody integrity
Whether the stored document is plausibly the kind of file the artifact declares, rather than something fetched by mistake.
- passType matchnot applicable to this artifact type
Whether the artifact is really the kind of thing its metadata claims it is.
- passFreshness
How long since the source repository was last pushed to.
- passPrompt injection
Scans the artifact's own text for instructions aimed at your agent rather than at you.
- passLicense
Whether the source repository declares an SPDX license permissive enough to redistribute.
How the grade is calculated
Each check contributes 0 points when it passes, 1 when it warns, and 2 when it fails. The total maps to a letter:
- Aevery check passed
- Bone warning
- Ctwo warnings
- Dprompt injection or body integrity failed, or three warnings
- Fone of those failed, and something else is wrong
These are automated hygiene checks, not a security audit, and not a dependency or vulnerability scan. A grade of A means nothing was flagged — not that the artifact is safe.
Versions
git-d29dbfaf6ba92026-08-04