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.
npx agentmods add instructions/rightnow-ai/automegakernel/agents-mdgit clone --depth 1 https://github.com/RightNow-AI/AutoMegaKernelWrote 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.
[](https://agentmods.dev/instructions/rightnow-ai/automegakernel/agents-md)<a href="https://agentmods.dev/instructions/rightnow-ai/automegakernel/agents-md"><img src="https://agentmods.dev/badge/instructions/rightnow-ai/automegakernel/agents-md.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.02279 | $0.02279 |
| Opus 5 | $0.01140 | $0.01140 |
| Sonnet 5 | $0.00456 | $0.00456 |
| Haiku 4.5 | $0.00228 | $0.00228 |
Grade B, and why
AutoMegaKernel AGENTS.md scanned grade B with 1 finding 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 5d 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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
## Codex MCP server config (`~/.codex/config.toml`) How it starts
The opening of the file, as written. The whole thing — 149 lines — stays where its author put it; the contents beside it link to each section on GitHub.
AGENTS.md, AutoMegaKernel for native coding agents (Codex / Claude Code)
This is the Codex/native-agent guide to driving AutoMegaKernel (AMK), the Codex analogue of
CLAUDE.md. It tells an agent exactly what AMK is, the one edit surface it owns, the canonical
tool/CLI names, the non-negotiable honesty rules, and a copy-paste optimization loop. Everything
here maps 1:1 to existing, verified code; nothing is faked.
For the full human/agent contract read HARNESS.md. For what AMK is and what is
measured-real today, read README.md.
What AMK is
AMK compiles a HuggingFace Llama-family model into ONE persistent CUDA megakernel, the whole forward pass fused into a single cooperative kernel launch, and self-improves the schedule over its own baseline, correctness-gated, unattended. It is the sibling of AutoKernel (which tunes one kernel); AMK tunes the whole-model megakernel via a new search axis: the schedule.
The agent's job is to search the schedule, not to write kernels. The frozen VM deterministically
lowers a ScheduleConfig into a runnable megakernel and proves it deadlock/race-free before any
launch. An unsafe config is a clean REJECTED, never a hung GPU.
The edit surface, ScheduleConfig + kernel_knobs ONLY
You edit one structured object: a ScheduleConfig (a JSON dict of typed knobs), optionally with
a kernel_knobs sub-object. You NEVER touch raw kernel code, vm/, Task.sm, or the frozen ABI.
The schema is [schemas/schedule_config.schema.json]; the live, machine-readable knob list comes
from amk_propose(...)["search_space"]. The knobs:
| knob | type | choices | meaning |
|---|---|---|---|
tiling.gemv.N_tile |
int | 64,128,256,512 | GEMV output-column tile width (the one tiling knob lowered today) |
tiling.attention.kv_block |
int | 64,128,256 | KV window block (recorded; not yet lowered) |
fusion_grouping |
list[list[str]] | [], [["gate","up"]], ... |
op groups to co-reside (a safe hint) |
sm_assignment |
str/dict | round_robin/load_balance/map |
SM placement policy |
pipelining_depth |
int | 0–4 typ. | instructions ahead to prefetch weights (hides the HBM bubble) |
page_allocation |
str | graph_color/linear/none |
activation page reuse policy |
threads_per_block |
int | 128,256,512 | persistent VM block size (occupancy-proven) |
smem_bytes_per_block |
int | 0,16384,49152 | dynamic SMEM opt-in (over-cap = clean reject) |
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.
- 5d ago First seen · 149 lines · 2,279 tokens per session scan B dc41872134a9
AutoMegaKernel AGENTS.md is an instructions file published in the GitHub repository RightNow-AI/AutoMegaKernel (137 stars, last pushed 2mo ago), licensed MIT. It adds 2,279 tokens to every session, about $0.0114 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other instructions, from other repositories
flashinfer AGENTS.md
AGENTS.md instructions for flashinfer-ai/flashinfer: This repository’s agent instructions live in CLAUDE.md.
gpu-server-setup AGENTS.md
Instructions for EvilFreelancer/gpu-server-setup, covering authoring & maintaining the gpu-server-setup skill, repository layout, editing rules, keeping metadata in sync and what this skill does not do.
flashinfer CLAUDE.md
Claude Code instructions for flashinfer-ai/flashinfer, covering claude.md, project overview, quick reference, quick start for development and installation.
cuopt AGENTS.md
AGENTS.md instructions for NVIDIA/cuopt, covering agents.md — cuopt ai agent entry point, skills directory (flat), rules, common (concepts only; no api code) and installation.
cuda-metal AGENTS.md
AGENTS.md instructions for Lulzx/cuda-metal, covering agents.md — cumetal development guide, project identity, current focus, repository structure and non-negotiable constraints.
VeloQ AGENTS.md
Instructions for lucifer1004/VeloQ, covering veloq — contributor guidelines, wire-format invariants (do not break casually), workspace layout, shipped commands (status roadmap) and code conventions.