flywheel: Instructions file for Codex

AGENTS.md

flywheel AGENTS.md is an instructions file for Codex, OpenCode from wsauret/flywheel. It costs 8,685 tokens per session, scanned A, original, Apache-2.0.

A repository-specific instruction file for contributors to the Flywheel project. It documents the project's runtime, interface technology, configuration format, and rules for working on the codebase.

In plain words
What is it for?
Use it as a reference when contributing to Flywheel, especially for its Bun runtime, OpenTUI and SolidJS interface, TOML configuration, and maintainer-specific guidance.
Why use it?
It gives coding agents and contributors the project context they need to make changes that fit the repository.

Instructions file for CodexOpenCode

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

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

Reuse

Borrowing it

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

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

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

Your own site · 80×15
<a href="https://agentmods.dev/instructions/wsauret/flywheel/agents-md"><img src="https://agentmods.dev/badge/instructions/wsauret/flywheel/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 8,685 This file is loaded in full into every session.
When invoked 8,685 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.08685 $0.08685
Opus 5.5 $0.03474 $0.03474
Sonnet 5.5 $0.01737 $0.01737
Haiku 4.5 $0.00869 $0.00869

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

Security

Grade A, and why

flywheel 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 yesterday.

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.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

| A direct raw external-process launch or shell wrapper in production code | Ordinary launches use `spawnOwned`, `runOwnedCommand`, or `openExternalUrl`; explicitly authorized survival uses only `src/infra/persistent-sub
AGENTS.md · 274 lines

How it starts

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

<coding_guidelines>

Flywheel CLI - Agent Instructions

Runtime: Bun (not Node) | TUI: OpenTUI + SolidJS | Config: TOML SolidJS requires the "browser" export condition. bin/flywheel handles this via bun --conditions=browser.

This file is the complete guide for contributors. The maintainer also checks out a small private companion repository at the gitignored private/ folder of the clone. Its @private/AGENTS.maintainer.md adds the rules for the maintainer's shared working tree, publication, and release readiness. That import is optional: a contributor's checkout has no private/ folder, the import then loads nothing, and every rule a contributor needs is in this file.

1. Hard Rules

  • MAXIMIZE ELEGANCE, NOT MINIMIZE CHURN! THIS IS THE MOST IMPORTANT PRINCIPLE FOR EVERY DESIGN! Always pick the design that maximizes elegance no matter how big the refactor. Better now than months down the line when there are even more dependencies in place.

  • docs/elegance.md is Flywheel's canonical project-specific definition of elegance and the rubric for architecture audits. Read it in full when judging whether the project is maximally elegant. This file operationalizes much of that standard for coding agents, but not in full.

  • Handle only reachable states. A state is reachable when a person or an external producer can cause it through a supported entry point: a client surface, the CLI, the published protocol as shipped clients use it, or an external boundary such as a provider stream, a subprocess, or the file system. A state that only a direct internal call or a test fixture can create is hypothetical: add no code for it, and do not treat a test that asserts it as a product requirement. Before you call a failure a regression, trace how a person reaches it. When a test fails on a state that no person can reach, rewrite the test around the reachable flow instead of changing the product.

  • This repository opts into the living product-intent authority indexed by docs/product-intent/README.md. Before changing or judging user-observable Flywheel behavior, read the index and the relevant domain file. A conflict with the persisted corpus is a bug or blocker, unless the person states a different intent; then the corpus changes to match it.

  • Before judging whether a subscription route follows its provider's terms, read docs/provider-terms.md. This covers the Claude engine route, the sign-in client IDs, the request headers that identify a client, and the use of several accounts of one provider. Flywheel follows precedent: a practice that widely used open-source agents ship publicly is acceptable. The page's section "How a review uses this page" lists the practices that the maintainer settled on that basis. A review or an audit never reports one of them as a finding, a blocker, or a risk, also when it finds provider terms that the page does not quote. Only the reopen events that the page names reopen a question.

  • Repository code, comments, and documents name no other coding-agent harness. docs/provider-terms.md is the one place that names such projects as precedent. Credit for borrowed work goes in THIRD-PARTY-NOTICES.md and the license bundles, and a file or directory that a notice cites by path keeps its upstream references. The only other names allowed are external identifiers that Flywheel must spell exactly to interoperate, such as an environment variable, a header, or a model id, and benchmark arms that run another harness as the comparison treatment. README.md and the website home page website/src/pages/index.astro may name other harnesses, because they market Flywheel to their users.

  • This repository opts into the living architecture-intent authority indexed by docs/architecture-intent/README.md. Before changing or judging Flywheel's internal organization, read the index and the relevant domain file. A conflict with the persisted corpus is a bug or blocker, unless the person states a different intent; then the corpus changes to match it. docs/terminology.md is the lexicon for Flywheel's terms.

Read the full file on GitHub · 274 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. yesterday Changed b99b81da1c9d
  2. 3d ago Changed · +32 tokens per session a202d0f1c4bb
  3. 4d ago First seen · 274 lines · 8,653 tokens per session scan A e53b33615d2c

Subscribe to this mod's changes

flywheel AGENTS.md is an instructions file published in the GitHub repository wsauret/flywheel (19 stars, last pushed yesterday), licensed Apache-2.0. It adds 8,685 tokens to every session, about $0.0347 per session on Opus 5.5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-03.

Related

flywheel AGENTS.md compared with instructions from other repositories

flywheel AGENTS.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
flywheel AGENTS.mdwsauret/flywheelInstructions file19yesterdayApache-2.0A8,685Codex, OpenCode
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA9,719GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149kyesterdayMITA4,680Codex, OpenCode
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA5,516GitHub Copilot
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195kyesterdayMITA3,093GitHub Copilot
deepseek-harness AGENTS.mddeepseek-ai/deepseek-harnessInstructions file274k2d agoMITA4,313Codex, OpenCode