cgp AGENTS.md

Repository instructions for CGP, a family of Rust libraries developed across related repositories. They explain the current pre-release version, the difference from the older crates.io release, which crates are published, and where sibling-project information lives.

In plain words
What is it for?
Use them before changing CGP crates, publishing the workspace, checking release versions, or coordinating work with sibling projects.
Why use it?
They prevent agents from using incompatible documentation or changing versions unnecessarily. They also clarify which packages are real release targets and which are test-only.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/contextgeneric/cgp/agents-md
Clone the repo
git clone --depth 1 https://github.com/contextgeneric/cgp

Made for: Codex, OpenCode.

Per session 5,994 This file is loaded in full into every session.
When invoked 5,994 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
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 $0.05994 $0.05994
Opus 5 $0.02997 $0.02997
Sonnet 5 $0.01199 $0.01199
Haiku 4.5 $0.00599 $0.00599

Measured 2d ago against content hash fe648963752f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cgp 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 2d 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 · 335 lines

How it starts

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

AGENTS.md

This file provides guidance to LLM agents when working with code in this repository.

Project status

This working tree is the upcoming v0.8.0 release. Every crate under crates/ is versioned 0.8.0-alpha in its Cargo.toml — the pre-release of v0.8.0 — and the documentation in the knowledge base already refers to the current version as v0.8.0, so nothing needs a version edit when v0.8.0 ships.

The stable release on crates.io is still v0.7.0, and it is not compatible with this tree. v0.7.0 carries legacy features and syntax that v0.8.0 has removed or changed, so code or documentation written against v0.7.0 will not compile here. Treat crates.io v0.7.0 as a separate, older line and do not reconcile this tree's syntax against it.

Only the library crates are published. The five crates under crates/tests/ are marked publish = false, so cargo publish --workspace skips them and publishes just the real CGP crates.

The sibling projects

cgp is one repository in a family that is developed together, so a task here routinely reads — and often updates — another one. sibling-projects.md is the authoritative list: where each project lives, which revision of it to read, and the rules for finding a sibling locally versus linking to it. Three of them matter constantly.

This repository's documentation lives in cgp-knowledge-base. There is no docs/ directory here. The construct reference, the concepts, the guides, the error catalog, and the macro-implementation notes are all in that repository's cgp/ directory, and the worked examples sit at its top level. It is a consolidated base — cargo-cgp's documentation is the neighbouring section — which is why an error class here and the tool's handling of it are now one directory apart. Treat the knowledge base as part of this repository's surface: a change to a construct's behavior carries its documentation change, and when the checkout is missing, say plainly what needs updating there.

Read the full file on GitHub · 335 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. 2d ago First seen · 335 lines · 5,994 tokens per session scan A fe648963752f

Subscribe to this mod's changes

cgp AGENTS.md is an instructions file published in the GitHub repository contextgeneric/cgp (248 stars, last pushed 29d ago), licensed Apache-2.0. It adds 5,994 tokens to every session, about $0.0300 per session on Opus 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.