gcontext: Instructions file for Codex

AGENTS.md

gcontext AGENTS.md is an instructions file for Codex, OpenCode from bleak-ai/gcontext. It costs 667 tokens per session, scanned A, original, MIT.

Project instructions for gcontext that describe its handbook, rules, and how agents should update project knowledge. The handbook is a set of Markdown documents recording what is true and why.

In plain words
What is it for?
They are for guiding agents to read the right handbook pages, follow project rules, and review proposed additions or changes to the handbook.
Why use it?
They help people and agents use the repository consistently and keep its stored project knowledge accurate.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md.

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

Reuse

Borrowing it

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

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 gcontext AGENTS.md

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/bleak-ai/gcontext/agents-md"><img src="https://agentmods.dev/badge/instructions/bleak-ai/gcontext/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 667 This file is loaded in full into every session.
When invoked 667 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.00667 $0.00667
Opus 5.5 $0.00267 $0.00267
Sonnet 5.5 $0.00133 $0.00133
Haiku 4.5 $0.00067 $0.00067

Measured today against content hash 73f9224679a6, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

gcontext 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 today.

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 · 33 lines

How it starts

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

gcontext

gcontext gives a coding agent a handbook: a folder of Markdown files with the knowledge and the know-how of a project. When a session of the agent is finished, gcontext proposes what that session adds to the handbook. A new handbook on one machine accepts the proposal by itself, and gcontext undo takes it back. Else a person accepts or rejects each proposal, or the server accepts it by itself. The agent reads the handbook at the start of each session.

These are the rules for anyone who works on this repo, a person or a coding agent.

The handbook of this repo

docs/ is the handbook of gcontext. It holds what is true now and the reasons. Start at docs/index.md: its table says what to read for each task. Read only what your task needs. The vision is docs/product/vision.md. Where another document says something else, the vision holds.

manual/ holds the pages for users. The README links them.

Rules

  • A model call costs money. Run one only when you mean it. A model call is claude -p, a Jev call, a capture, a Preanalyse, Ask, and a Claude build of the fact index. Which command makes one: docs/development/checks/model-calls.md.
  • During development, never write in ~/.gcontext, in your handbooks, or in a project repository. Set GCONTEXT_DATA_DIR to a temporary folder.
  • Do not write unit tests. The proof of a change is the E2E test and the type check (npm run check, 0 errors). Which proof: docs/development/checks/.
  • Before you change a prompt, a template, a rules file, or a handbook, read docs/development/text-changes/.
  • Prompt texts live in their own .md files next to the code that uses them, with {{...}} blanks. No prompt text in a .ts file.
  • Use uv run for Python. No pip, and no direct Python command.
  • Use short sentences, plain words, and active voice. No en dashes, no em dashes. Use the words of docs/product/words/ in text that a user sees. Do not use and in file or folder names.
  • Keep secrets in env files outside the repo.

Read the full file on GitHub · 33 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. today Changed · +1 tokens per session 73f9224679a6
  2. yesterday First seen · 33 lines · 666 tokens per session scan A af72b2566d50

Subscribe to this mod's changes

gcontext AGENTS.md is an instructions file published in the GitHub repository bleak-ai/gcontext (25 stars, last pushed today), licensed MIT. It adds 667 tokens to every session, about $0.0027 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-11-29.

Related

gcontext AGENTS.md compared with instructions from other repositories

gcontext AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
gcontext AGENTS.mdbleak-ai/gcontextInstructions file25todayMITA667Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file196ktodayMITA9,887GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file144ktodayMITA7,230Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file196ktodayMITA5,685GitHub Copilot
langchain AGENTS.mdlangchain-ai/langchainInstructions file150kyesterdayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file196ktodayMITA3,303GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file289k2d agoMITA4,393Codex, OpenCode