agentleFS
AlmxndBLAlmxndBL/Apex-core/AGENTS.md

Apex-core

AGENTS.md1 starsChanged 3 months agoMITView on GitHub

Universal, polyglot operating protocol for AI coding agents. Inspect the target file and root manifest together. Load only relevant domain adapters; high-risk work loads the adapter matching the touched stack. Low-risk work touching 1–3 files uses R0–R4 without loading adapters. For Auth, RBAC, money, PII, schemas, concurrency/OCC, or breaking APIs, load the adapter matching the touched stack: web-fullstack.md for UI, backend-data.md for Node/Prisma, or polyglot-core.md for Python/.NET. Load multiple adapters only for cross-stack changes. S1 Discovery → S2 Adaptive Plan…

  • Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.

    Of the AGENTS.md files we read, the 31,700 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.

  • In this repository5 other files it gives its agents.

The file

We split this AGENTS.md into the rules it gives an agent

3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read-only intent (explain, audit, why, เช็คให้หน่อย without an action verb) means diagnose only.

    line 9
  2. Distinctive:

    Before destructive changes (schema drops, data truncation, auth/session replacement, important file deletion), summarize impact and get …

    line 11
  3. Very specific:

    [R2] In-RAM Fast Targeted Verification: Run a fast, project-native targeted check (for example vue-tsc --noEmit, tsc --noEmit, pytest -q, …

    line 13

≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Apex Micro-Kernel (v7.0.0)

Universal, polyglot operating protocol for AI coding agents.

1. Golden Rules

  • [R0] Absolute Context Grounding: Act objectively; challenge weak assumptions. Distinguish [Direct] from [Inferred]; avoid flattery and false certainty; lead with the conclusion. Apex means Apex-core. Keep all agent instructions in this AGENTS.md; do not create parallel agent config files.
  • [R1] 3-Tier Dynamic Intent:
    • Read-only intent (explain, audit, why, เช็คให้หน่อย without an action verb) means diagnose only; make no edits.
    • Actionable intent (fix, add, refactor, implement) means diagnose, implement, and verify in one turn.
    • Before destructive changes (schema drops, data truncation, auth/session replacement, important file deletion), summarize impact and get explicit approval.
    • 1–3 files: fast track, no plan file. 4+ files or architecture changes: create a concise plan in docs/plans/YYYY-MM-DD-<slug>.md; mark it Commit or Ephemeral. Keep strategic memory in Nexus.
  • [R2] In-RAM Fast Targeted Verification: Run a fast, project-native targeted check (for example vue-tsc --noEmit, tsc --noEmit, pytest -q, or dotnet test). Do not run production builds for minor edits.
  • [R3] Strict Seam Binding: Include terminal results and label the seam [Verified: Test], [Verified: Compiler], [Syntax-Only], or [Unverified: Visual]. Never invent tests or stall when a suitable check is unavailable; state the fallback. After two consecutive unexpected failures, stop and report root cause and repair options. For legacy failures, prevent regressions rather than requiring an impossible clean baseline.
  • [R4] Surgical Diffs & Working Tree Purity: Change only what the defect requires; avoid drive-by refactors. Do not commit scratch/demo/dummy tests. Put architecture, PRD, and test specs under docs/; keep root to manifests, README, and configuration.

2. Deterministic JIT Adapter Bus & Risk Override Gate

Inspect the target file and root manifest together. Load only relevant domain adapters; high-risk work loads the adapter matching the touched stack.

SignalAdapterFast check
package.json uses Next, Nuxt, React, or Vueadapters/web-fullstack.mdvue-tsc --noEmit or tsc --noEmit
Prisma, Drizzle, or server/apiadapters/backend-data.mdTargeted API/route test
pyproject.toml, *.csproj, or *.shadapters/polyglot-core.mdpytest -q, dotnet test, or bash -n
Universal principles or securitycore/principles.mdApply universal baseline

Low-risk work touching 1–3 files uses R0–R4 without loading adapters. For Auth, RBAC, money, PII, schemas, concurrency/OCC, or breaking APIs, load the adapter matching the touched stack: web-fullstack.md for UI, backend-data.md for Node/Prisma, or polyglot-core.md for Python/.NET. Load multiple adapters only for cross-stack changes.

3. Execution Loop

S1 Discovery → S2 Adaptive Plan → S3 Execution → S4 Fast Verify

For new systems or substantial features, load Build workflow. Plan by uncertainty, dependencies, and risk as well as file count; retain the low-risk fast track. Use quality-verify for completion review. Kernel invariants govern references and adapters; user instructions and project conventions take precedence.

Optional Nexus MCP: When available, call nexus_get_state at project start and nexus_save_session at completion. Never invent memory when it is unavailable.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.