agentic-context-engine: Instructions file for Codex

AGENTS.md

agentic-context-engine AGENTS.md is an instructions file for Codex, OpenCode from kayba-ai/agentic-context-engine. It costs 1,359 tokens per session, scanned A, original, Apache-2.0.

Repository instructions for a codebase whose new functionality must be built from reusable pipeline steps. A pipeline is an ordered workflow, and each step declares the information it needs and produces.

In plain words
What is it for?
Use them when adding features, composing branches, handling reflection or evaluation logic, updating context, and deciding where integration-specific data belongs.
Why use it?
They prevent new code from bypassing the project's shared workflow system or changing shared data in unsafe ways.

Instructions file for CodexOpenCode

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

This is kayba-ai/agentic-context-engine's own configuration. It tells Codex and OpenCode how to work on agentic-context-engine 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-context-engine configures →

About the project

Agentic Context Engine is an open-source engine that gives AI agents a persistent learning loop, helping them remember successful strategies and learn from failures across sessions. It is used to improve production agents, and also powers Kayba’s hosted service. Catalogue add-ons support workflows for operating and configuring the engine.

kayba-ai/agentic-context-engine · 2,608 stars · on GitHub · kayba.ai

Reuse

Borrowing it

Nothing to install: this file belongs to kayba-ai/agentic-context-engine. 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/kayba-ai/agentic-context-engine/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/kayba-ai/agentic-context-engine

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-context-engine AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/kayba-ai/agentic-context-engine/agents-md/github.svg)](https://agentmods.dev/instructions/kayba-ai/agentic-context-engine/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/kayba-ai/agentic-context-engine/agents-md"><img src="https://agentmods.dev/badge/instructions/kayba-ai/agentic-context-engine/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-context-engine AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/kayba-ai/agentic-context-engine/agents-md"><img src="https://agentmods.dev/badge/instructions/kayba-ai/agentic-context-engine/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 1,359 This file is loaded in full into every session.
When invoked 1,359 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.01359 $0.01359
Opus 5.5 $0.00544 $0.00544
Sonnet 5.5 $0.00272 $0.00272
Haiku 4.5 $0.00136 $0.00136

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

Security

Grade A, and why

agentic-context-engine 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.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

AGENTS.md · 99 lines

How it starts

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

AGENTS.md

This file provides guidance to coding agents working in this repository.

Repository Guidelines

Pipeline-First Development (MANDATORY)

All new functionality MUST be implemented as pipeline Steps composed via the Pipeline engine. Do NOT write standalone scripts, ad-hoc loops, or inline logic that bypasses the pipeline. Before writing any code:

  1. Read docs/design/PIPELINE_DESIGN.md to understand the Step → Pipeline → Branch model.
  2. Implement logic as a Step class with requires/provides declarations and a __call__(self, ctx) -> ctx method.
  3. Compose steps using Pipeline().then(...) and .branch(...) — never manual for-loops or direct function chaining.
  4. Use StepContext.replace() for immutable context updates — never mutate context directly.
  5. Put integration-specific data in metadata, not new context fields, unless the field is shared across multiple pipelines.

Anti-patterns to reject:

  • Writing a function that calls multiple steps manually instead of composing them in a Pipeline
  • Inline reflection/evaluation logic instead of creating a ReflectStep or EvaluateStep
  • Ad-hoc ThreadPoolExecutor usage instead of async_boundary and max_workers on steps
  • Standalone scripts that duplicate pipeline functionality without using the pipeline engine
  • Bypassing requires/provides contracts by accessing context fields not declared in requires

If a task seems like it cannot fit the pipeline model, explain why to the user before proceeding — do not silently circumvent it.

Core Code Protection

Do NOT modify core modules (ace/core/, pipeline/) without explicit user approval. Before proposing any change to these directories:

  1. Read the relevant design docs (docs/design/ACE_ARCHITECTURE.md, docs/design/PIPELINE_DESIGN.md) thoroughly.
  2. Evaluate whether the change is truly required or if it can be achieved outside the core (e.g., in an integration, step, or example).
  3. Clearly explain the proposed change and its justification to the user before making any edits.
  4. Wait for the user to explicitly accept before proceeding.

Read the full file on GitHub · 99 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 · 99 lines · 1,359 tokens per session scan A cfbb4d5cd26b

Subscribe to this mod's changes

agentic-context-engine AGENTS.md is an instructions file published in the GitHub repository kayba-ai/agentic-context-engine (2,608 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 1,359 tokens to every session, about $0.0054 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-context-engine AGENTS.md compared with instructions from other repositories

agentic-context-engine AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
agentic-context-engine AGENTS.mdkayba-ai/agentic-context-engineInstructions file2.6k1mo agoApache-2.0A1,359Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143ktodayMITA7,461Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode