* docs(agents): fold CLAUDE.md into AGENTS.md, leave the pointer CLAUDE.md now only points at AGENTS.md, the fleet's one agent-file shape (bitbaum/fleet scripts/ci/agent-rules.mjs). The rules move into AGENTS.md: the four-layer design system, choice rows, AI form assist, SSOT rules, data flow, security, cloud vs local, how to ask George, which token the sweep holds, the box-runner update hold, package installs and "create website for <Name>". The component map and the views table, which are reference rather than rules, move to docs/development/surfaces.md so AGENTS.md stays readable. Checked against the tree: - Only @bitbaum/accountkit still installs from GitHub; chatkit, searchkit and whenkit come from the registry. The install section says so. - Dropped restatements of fleet rules (no dead ends, the merge chain) and the duplicate Database section. globals.css excluded CLAUDE.md from Tailwind's source scan because its "never write" examples are bracket classes; AGENTS.md and the surfaces doc now carry them, so they are excluded too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmuJhiHPASaR5k8raL9 * docs(surfaces): name the model chip by family, not a version Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmuJhiHPASaR5k8raL9 --------- Co-authored-by: Claude <noreply@anthropic.com>
3.5 KiB
REVIEW.md — loki review bar
Judge the DIFF against these gates, in order. Flag correctness and requirement gaps only — lint owns style. Global standards load via AGENTS.md; this file is ONLY loki's scars.
Fatal invariants (one violation = block)
- API envelope is
{ok: true|false}— NOT the global{success, data}convention. This repo deliberately overrides it (see AGENTS.md). - Dispatch/orchestration state has ONE owner — no new
/tmpsignal files, no newclaude-*compat paths, no second writer to dispatch status. The split-authority loop is the repo's #1 historical bug source (13 of 15 recent commits were dispatch reliability fixes). Regression net:scripts/test/dispatch tests — extend, never bypass. - Design system — only
ui-*component classes + tokens from globals.css; no arbitrary hex/radius/shadow. Checkcheck:designpasses. - Runner protocol changes need a runner RELEASE — publishing goes through
the
loki-releasesfeed (NOTloki); a protocol change without a release strands every installed runner.
Repo gotchas that have bitten before
- Tailwind v4 silently drops an entire
@layer componentsblock if any rule uses a responsive variant inside@apply(e.g.sm:p-6) — no error. If component classes vanish, check this first. - bashrc zellij auto-attach can hijack a runner-owned PTY — guard with
$BASH_EXECUTION_STRING(already in dotfiles; don't regress it).
Process gates
npm run test:unitgreen (auto-discoversscripts/test/*.ts); CI green on PR.- Diff updates AGENTS.md/docs if it changes documented structure/behavior.
- Second fix of the same bug class ships the rule/test that ends the class.
Definition of done for a page (a scar, 2026-09-28)
A PR that adds a link to a page is not done until the target page has been RENDERED with what that link carries and LOOKED AT at 390px. Not the source read, not the types checked: the pixels.
What happened: #959 sent an owner from My feedback to /feedback?project=<id>.
The inbox filtered by project NAME, so the page printed "Nothing waiting on
you for 5936f8fb-7239-…" at the person who had just pressed Implement — on a
page whose chips, stat cards and section heads were each drawn in a different
style. Every check was green. The owner found it on his phone.
Two rules, both mechanical:
- A link carries what the target reads. Before wiring
hrefto?param=, open the target and read how it consumes that param (name vs id, slug vs uuid). If the two disagree, the target resolves both, and the PR says so. Never trust that a page "takes a project". - Render before claiming.
node scripts/preview/build-feedback-preview.mjs(or the page's ownbuild-*-preview.mjs) renders the real/feedbackinbox with fixture rows at phone and desktop widths, in both themes, for every?project=shape, and fails on horizontal overflow or a console error. Run it and OPEN the PNGs in.tmp/feedback-preview/— the tool cannot see ugly, only broken. A new surface that has no harness gets one in the same PR (a*.preview.tsxentry that mocksfetch, and a three-line script overscripts/preview/render-harness.mjs); the harness does not need a database or a session, which is exactly why "I could not test it in the sandbox" is not a reason.
The same sentence, from the person who found it: "before you say that something is done, why would you not go through it and test it?"