magnitude: Instructions file for Codex

AGENTS.md

magnitude AGENTS.md is an instructions file for Codex, OpenCode from magnitudedev/magnitude. It costs 2,273 tokens per session, scanned A, original, Apache-2.0.

An instruction file for working on Magnitude, an AI coding-agent platform. It explains the project’s package structure, how its parts communicate, and rules for keeping those boundaries intact.

In plain words
What is it for?
Use it when changing Magnitude’s clients, shared client code, software development kit, daemon, agent runtime, or related packages.
Why use it?
It gives the coding agent the project context needed to place changes in the right package and avoid using internal components incorrectly. It also points the agent toward session inspection, testing, and type checking.

Instructions file for CodexOpenCode

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

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

About the project

Magnitude is an open-source inference server, meaning software that runs language models and answers requests on a user's own computer. It profiles available hardware, recommends suitable local models, and connects them to coding agents for private and offline use on macOS, Linux, or Windows through WSL. Its catalogue entries help agents set up and use Magnitude.

magnitudedev/magnitude · 7,308 stars · on GitHub · magnitude.dev

Reuse

Borrowing it

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

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

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/magnitudedev/magnitude/agents-md"><img src="https://agentmods.dev/badge/instructions/magnitudedev/magnitude/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 2,273 This file is loaded in full into every session.
When invoked 2,273 The same file — it is already loaded in full.
Security scan A 1 finding. 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.02273 $0.02273
Opus 5.5 $0.00909 $0.00909
Sonnet 5.5 $0.00455 $0.00455
Haiku 4.5 $0.00227 $0.00227

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

Security

Grade A, and why

magnitude AGENTS.md scanned grade A 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 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

Motel is a local OpenTelemetry collector with an HTTP API at `http://127.0.0.1:27686`. Query it with `curl` to inspect traces, spans, and logs from the application.
AGENTS.md · 156 lines

How it starts

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

TRESTING

Magnitude Project Context

You are working on Magnitude, an AI coding agent platform.

Package Layering

clients (cli/web) → client-common → sdk → acn (daemon)
  • Clients import only from @magnitudedev/client-common and @magnitudedev/sdk. Never from acn, agent, acn-protocol, ai, or providers directly.
  • client-common — shared state, hooks, display sync. Uses one connection-scoped Effect Query AgentClient over the shared SDK instance.
  • sdk — private, portable Effect RPC client, fixed-endpoint admission/recovery, and optional service-starter capability. Re-exports pure protocol contracts; no SQLite, process supervision, or query cache.
  • daemon-management — private desktop discovery/control, native child supervision, login registration. Only privileged host composition roots (CLI bootstrap, desktop main, development server) import it. The desktop bundles and owns ACN; clients never acquire or elect a standalone daemon.
  • client-common owns first-party Query/Mutation/Subscription definitions over SDK operations; providers owns provider-client construction.
  • acn — server daemon hosting agent runtime, sessions, file ops, display streams. Implements ACN protocol RPCs.
  • acn-protocol — wire contract (RPCs, schemas) shared by SDK and ACN. Not imported by clients.
  • ai — provider-agnostic contract (Provider, ModelCatalog, BoundModel, BaseCallOptions).
  • providers — concrete provider implementations + registry. See packages/providers/AGENTS.md.
  • agent — agent runtime, projections, workers, tools, display materialization.
  • event-core — event sourcing, projections, addressed state.
  • roles — role/slot definitions for worker specialization.
  • storage — persistent session/config/auth storage.

For a new backend operation, declare its Rpc.make once in the appropriate packages/acn-protocol/src/boundary/ domain, implement its handler in ACN, and consume the derived SDK method. Add first-party caching/synchronization policy in packages/client-common/src/operations/ as needed. Effect Query does not generate RPCs. The SDK may ask an injected starter to ensure availability; only daemon-management owns native application control. Plugin packages bundle the private SDK and inherit its exact RPC-version check.

Read the full file on GitHub · 156 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 · +10 lines · +431 tokens per session 6688f229df32
  2. 2d ago Changed · -13 lines · -146 tokens per session 70053cdd0b3e
  3. 12d ago Changed · +4 lines · +73 tokens per session 00eacd9327fc
  4. 26d ago Changed · -1 tokens per session a774e56bfa83
  5. 1mo ago Changed · +13 tokens per session f5e6e271e5ad
  6. 1mo ago Changed · +6 lines · +148 tokens per session e37380deb17c
  7. 1mo ago First seen · 149 lines · 1,755 tokens per session scan A 15c2894e8e85

Subscribe to this mod's changes

magnitude AGENTS.md is an instructions file published in the GitHub repository magnitudedev/magnitude (7,308 stars, last pushed today), licensed Apache-2.0. It adds 2,273 tokens to every session, about $0.0091 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 9,715 tokens

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,581 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).

microsoft/vscode · 5,262 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,680 tokens

deepseek-harness AGENTS.md

AGENTS.md instructions for deepseek-ai/deepseek-harness, covering agents.md, pre-stable apis and released session data, repository layout, commands and host sandbox failures.

deepseek-ai/deepseek-harness · 4,261 tokens

vscode copilot-instructions.md

Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).

microsoft/vscode · 2,731 tokens