Open-source platform for 3D AI agents. Turn text or a photo into a rigged, animated GLB avatar, give it an LLM brain, memory and a wallet, and embed it anywhere with one web component. Remote MCP server, x402 payments, Three.js, browser-native.
Task 11 — Production hardening + launch
Status: shipped, except the fleet-render performance box, which is carved out as task 12.
/agorais live and pushed; the boundary checks in step 5 are covered bytests/agora-act-validation.test.jsand the read model's 429 now carriesretry-after(tests/agora-read-model.test.js).
Goal: Take Agora from "works on my machine" to 100% production-ready and
launch it: tests across every new surface, all UI states audited, accessibility +
performance verified, security/spend review, real deploy verification, the
changelog + docs, and the push to threews. This is the gate — nothing ships
until every box here is true.
Depends on: all prior tasks (run last, or run incrementally as slices land).
Context to read first
CLAUDE.md(§ Definition of done, § Self-review protocol) anddocs/agora.md(§ Invariants).00-INDEX.md(global guardrails).- Everything Agora shipped:
api/agora/*,workers/agora-citizens/*,src/agora/*,pages/agora.html,packages/agora-mcp/*, the migration. tests/(house test style),data/changelog.json+npm run build:pages,data/pages.json.- The
completionistagent and/code-review— use them.
Build (scope)
- Tests. Vitest coverage (
npm testisvitest run && playwright test) for: the economy API shapes + empty/error paths (mock the DB/bazaar at the boundary only — never ship mocks in app code); the engine's loop transitions, idempotency (no double-projection), and failure isolation; each profession module's proof derivation;agora-mcptools; migration sanity. Add to the existing suite sonpm testcovers Agora. - Every state, audited. Walk each surface for loading / empty / error / populated / overflow (0, 1, 1000 citizens; very long names; mid-op network failure; expired session; insufficient funds; slashed stake). Fix any blank void, dead button, or unreachable state. Confirm the empty economy renders honestly end-to-end (no fabricated anything).
- Accessibility. Semantic HTML, ARIA on interactive elements, keyboard nav +
focus traps in panels, visible focus rings, color contrast,
prefers-reduced- motionhonored in all 3D FX. Run an a11y pass (axe/Lighthouse). - Performance. Lazy-load heavy modules + GLBs; paginate
citizens; debounce polls; pause render on hidden tab; dispose Three.js resources (no leak over 30 min); code-split the Agora bundle. Lighthouse perf budget met; 60fps with a busy board + a fleet. - Security + spend review.
/api/agora/act(and any mutating path): authenticated, input-validated at the boundary, idempotent, rate-limited, spend-capped; secrets never logged; mainnet $THREE behind explicit env + confirmation. Run/security-reviewon the branch. Confirm the bundler trap didn't bloatapi/*.js(head -1check). - Deploy verification. Build clean (
npm run build,npm run build:pages); confirm the worker image builds (workers/agora-citizensDocker/cloudbuild); smoke the deployed/api/agora/*+/agoraagainst real data; the life engine runs on devnet in the deployed environment. - Docs + changelog + index. Update
docs/agora.mdroadmap checkboxes to reflect reality; mark task status in00-INDEX.md; ensuredata/pages.jsonhas/agora; add the launchdata/changelog.jsonentry (feature) and runnpm run build:pages(it validates the entry). Community delivery (the Telegram channel; the X lane is retired and the cron never calls it) happens automatically via the/api/cron/changelog-pushcron after deploy. - Final self-review. Run the
completionistagent on the changed files and/code-reviewon the diff; resolve findings. Then the CLAUDE.md pride check.
Out of scope
New features. This task only hardens, verifies, documents, and launches what exists. If you find a missing feature, file it as a new task file, don't scope-creep.
Definition of Done (the launch gate — all must be true)
-
npm testgreen, including new Agora tests; meaningful coverage of API, engine, professions, MCP. - Every surface's loading/empty/error/populated/overflow states designed and reachable; no blank voids, no dead paths.
- Accessibility pass clean (keyboard, ARIA, contrast, focus, reduced-motion).
- Performance: lazy-load + pagination + dispose verified; no leak over 30 min; 60fps busy; Lighthouse budget met.
- Security: mutating endpoints authed/validated/idempotent/rate-limited/spend-
capped;
/security-reviewfindings resolved; no secret logging; mainnet gated. - Deployed
/api/agora/*,/agora, the worker, andagora-mcpall verified against real data (paste evidence: URLs, tx signatures, screenshots). -
docs/agora.md+00-INDEX.mdstatuses current;data/changelog.jsonentry added +build:pagespasses;/agoraindata/pages.json. -
git diffreviewed line-by-line;completionist+/code-reviewclean. - Pushed to
threews(the canonical remote). - You would proudly demo Agora to a room of senior engineers.
Verification
npm test
npm run build && npm run build:pages
head -1 api/agora/*.js api/agenc/*.js # ensure no esbuild bundle bloat
# a11y + perf: Lighthouse on /agora
# deploy smoke: curl the live /api/agora/* ; load /agora ; run the engine on devnet
Then completionist on changed files + /code-review on the diff.
Guardrails
- Do not relax any DoD box to "good enough." If something can't be verified, say so explicitly and don't claim done.
$THREEonly; no other coin anywhere (code, tests, fixtures, copy, changelog).- Stage explicit paths; re-check
git status/--staged(concurrent agents share the worktree). Push tothreewsonly; never pull/fetch from the retiredthreeDmirror.