forgeax-engine / templates
AGENTS.md70 starsChanged 18 days agoApache-2.0View on GitHub
AI-first TypeScript game on @forgeax/engine. Hard rules and routing here; open a reference only when its task applies. Never read whole large SKILL.md files; stop after their short start section unless the task needs more. 1. Imports and signatures: the API index before searching node_modules. 2. Effects in an empty project: the effects cookbook indexes topics; open ONLY one. 3. Commands: the Quick contract atop forgeax-engine-cli; exact inputs come from pnpm exec forgeax help <path> --json, never guesses. 4. Pick…
- Installs packages
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,774 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 repository25 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- forgeax-engine-appSkill
- forgeax-engine-assetsSkill
- forgeax-engine-audioSkill
- forgeax-engine-cliSkill
- forgeax-engine-debug-drawSkill
- forgeax-engine-debugSkill
- forgeax-engine-ecsSkill
- forgeax-engine-evolveSkill
- forgeax-engine-materialSkill
- forgeax-engine-mathSkill
- forgeax-engine-modelingSkill
- forgeax-engine-navigationSkill
- forgeax-engine-performanceSkill
- forgeax-engine-physicsSkill
- forgeax-engine-render-pipelineSkill
- forgeax-engine-rhi-debugSkill
- forgeax-engine-rhiSkill
- forgeax-engine-sdkSkill
- forgeax-engine-shaderSkill
- forgeax-engine-stateSkill
- forgeax-engine-vfxSkill
- forgeax-engine-wechatSkill
- forgeax-scriptable-pack-reviewSkill
The file
We split this AGENTS.md into the rules it gives an agent
4 rules. About 0 are common, 1 is distinctive, and 3 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.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 31
Import only @forgeax/engine or @forgeax/engine/<package-directory>, never @forgeax/engine-*.
- Very specific: line 33
Add dependencies with pnpm add <name>, not by editing package.json.
- Very specific: line 38
Run pnpm exec forgeax <path> --json.
- Distinctive: line 41
Before delivery, list each requested requirement.
≈ “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.
Files
ForgeAX Game Project Guide
AI-first TypeScript game on @forgeax/engine. Hard rules and routing here;
open a reference only when its task applies. Never read whole large SKILL.md files;
stop after their short start section unless the task needs more.
Start here
- Imports and signatures: the API index before searching
node_modules. - Effects in an
emptyproject: the effects cookbook indexes topics; open ONLY one. - Commands: the Quick contract atop
forgeax-engine-cli; exact inputs come frompnpm exec forgeax help <path> --json, never guesses. - Pick the route in Run, test, build, and release, then edit.
- Rendering has native equivalents for most Three.js core features: look an effect up in the Three.js equivalence guide (with gaps) before simplifying it.
Hard rules
forge.jsonowns project configuration andforge.json#rootsis the sole plugin assembly authority; stable GUIDs own asset identity. Never add parallel manifests, lifecycles or runtime entrypoints.- Assets: author source → importer/cooker → DDC → catalog →
assets.load(guid, kind). Author inassets/(*.pack.ts,*.pack.json,<file>.meta.json); never editdist/,pack-index.json, DDC or.forgeax/, or fetch assets manually. - Content made during play skips Packs: bind
ctx.assets.create(...)output, release it from the effect (forgeax-engine-assets). - Each Pack
build()key is asourceKey: lowercase segments matching^[a-z0-9][a-z0-9._-]*(/[a-z0-9][a-z0-9._-]*)*$(mesh/crate). GUID =UUIDv5(packageId, sourceKey). ScriptablePack files end in.pack.ts. - Import only
@forgeax/engineor@forgeax/engine/<package-directory>, never@forgeax/engine-*. - Add dependencies with
pnpm add <name>, not by editingpackage.json. If a frozen lockfile rejects an edit orpackageManagerchange, runpnpm install --no-frozen-lockfile. - Game logic is a native Cordis
Plugin; cleanup belongs toctx.effect(). DOM, Web Audio and browser SDKs belong to the frontend root, never Engine Workers. - Expected failures return
Result: branch on.code, keep.expected/.hint/.detail. - Run
pnpm exec forgeax <path> --json; add--detailonly foromitted.fieldsyou need. game-3dcontent is a reference, not the game: record its Template Disposition first.- Before delivery, list each requested requirement; the playthrough asserts each through
the read projection and saves one named screenshot per requirement (every ending, each
object type, multi-enemy states, the core input's visible effect; failure and debug
frames belong in
.forgeax/diag/, notartifacts/). Never bend game code for the test (enemies spawned ahead, exposed aim targets). See Requirement coverage. - Append confirmed Engine/SDK issues to
docs/feedback.mdat once (no secrets);project packageships it. - Edit this project directly. A ForgeAX closed loop needs explicit user agreement.
- Capture with
forgeax-engine-rhi-debugonly for unexplained black frames, missing objects, wrong lighting or flicker, before editing shaders; never to deliver.
Run, test, build, and release
- Iterate locally:
pnpm exec forgeax dev startserves source; Vite/DevKit handles TypeScript and Pack assets as needed. No priorproject build, separate asset build, or manual TypeScript compilation is required. - Build and preview:
pnpm exec forgeax project buildproduces the productiondist/through Vite and asset producers;pnpm exec forgeax project previewserves it.pnpm typecheckis a separate check, not a launch prerequisite.
| User intent | Route |
| Create, change or locally play (default) | Local playable delivery |
| Publish, deploy or distribute | Game release |
| Engine/SDK change, SDK publication, performance | Owning package, SDK production, performance skill |
pnpm exec forgeax project check --json
pnpm test && pnpm typecheck
pnpm exec forgeax project play scripts/playthrough.mjs --jsonAccept local delivery only on the final code: project play (or dev verify) passes; you opened the PNG, see the requested scene/UI and passed the
visual self-review; you drove
the core input and saw its result; both survive a reload. A build, URL, HTTP 200 or unit
test alone accepts nothing. A blocked check stays unverified: report it, never a pass.
Evidence comes only from these commands' owner browser. Hand over the dev status URL;
never open or drive another tab for acceptance (it may be backgrounded; its
live-bridge-not-owner warning is expected). Run project play and dev verify blocking
in one call with a large exec yield (21+ min at default budgets: ~14 per play, +7 when queued),
or lower --timeout-ms; never background or poll them. Each prints one JSON result and at
most one stderr progress line per 30 s. The live owner is optional: dev observations start
it on demand; upkeep is only dev start/dev stop. For timers or long waits, call
play.advance(seconds), not play.wait/long waitFor timeouts. Fix its layout warnings (HUD text overlapping
or clipped at 1280x720/1280x600) before committing.
On an unchanged empty template, play-runtime-failed with reason flat-canvas is the
expected start, not an environment failure.
Task routing
| To | Read |
| Layout, SDK setup, skill links, Engine model, View | project guide |
| Asset forms, import, verify | Asset authority, then forgeax-engine-assets |
| Roots, plugins, third-party SDK startup | Game code, forgeax-engine-app |
| Pick Engine capabilities | SDK skill table; feature catalog on demand |
| Camera, lights, shadows, post | Quick contract of forgeax-engine-render-pipeline |
| Materials, textures, WGSL | forgeax-engine-material, forgeax-engine-shader |
| Input, frame loop, HUD, pointer lock | forgeax-engine-app; cursor games call gameHost.setPointerLockAllowed(false) once |
| Physics, character motion | forgeax-engine-physics |
| Blocked checks, Linux headless, release | delivery guide |
| Scripted playthrough and acceptance | forgeax project play in the CLI skill quick contract; edit scripts/playthrough.mjs |
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
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.

