How it works

One frame through the machine

the eye · three laya-text · short memory · Qwen the coach

A Street Fighter II player with no rules written into it. A frame of the game becomes a few words, three small models vote on a move, and a memory grown from what has actually worked decides and presses a button. Between rounds a big model reads the log and re-weights the memory. Here it is running, live.

Street Fighter II: Chun-Li versus Ryu
What the eye sees — one SNES frame. func_img_txt reads pose, distance and stage from these pixels.
monitor_tui terminal dashboard
What we watch — the live TUI: bee quorum firing, Qwen's rule churn, win-rate climbing.
Live

The whole loop, playing itself

▶ live · auto-playing
System 1 (top) runs every frame: a frame goes to the eye, func_img_txt turns it into words, three laya-text models vote, short memory decides, the gamepad acts. System 2 (bottom) runs between rounds: the log fills, a digest goes to Qwen, whose rule re-weights a cell of short memory. The dots are events; watch a cell light up when Qwen fires.
Why it's built this way

Six questions

Q1
Why do we need laya-text at all?
Because memory alone is too slow to play. On a fresh or thin context the table has nothing to look up, so it would flail and learn at a crawl. laya-text is a fast, learned prior: it reads the moment and proposes a sensible move instantly, so the player is competent from the first frame while the memory fills in behind it.
Q2
What is "base laya"?
A small text model fine-tuned to play the game. It learned the moves, when to use them, and how to read position and spacing — so from the situation it can pick a reasonable action on its own, before any opponent-specific memory exists.
Q3
What is func_img_txt?
The image → text function. It indexes the frame to recover the real state: the character's pose, the stage/setting, the distance between fighters, who's attacking, whether a fireball is out — turning pixels into the words the models reason over. No RAM peeking; it reads the picture.
Q4
Why three?
Variation — to learn faster. One proposer explores one idea; three give the quorum options to try. Different bees push different moves, so good moves surface sooner than a single deterministic policy would ever find them.
Q5
What is "memory"?
The short memory — a value table keyed by context (range · posture · fireball · opponent) holding each move's real net-HP outcome. A table today, growing toward a per-character store (a tree). It's what the quorum weights votes by, and what Qwen re-weights.
Q6
What is Qwen doing here?
System 2 — the coach. Between rounds, in the background, it reads the accumulated game log and writes one rule that re-weights the table, citing a specific cell. The slow, reflective learner that nudges the fast reflex over time.
Teaching a new character

How a new fighter learns

No animation — just the recipe. Seed from the closest fighter already known, then tighten a loop that finds where this one is different and pushes only there, until the gains go flat.

1
Seed the tablestart
  • Pick the closest fighter already known.
  • Copy its table as the starting weights — relative > archetype > floor > blank.
  • Cap the inherited counts, so new evidence can still move them.
2
Probe gameexplore
  • Play one short game.
  • The probe bee deliberately samples the least-tried cells.
  • Collect honest net-HP, not just the moves it already likes.
3
Delta studymeasure
  • Compare own results to the seed: own-mean − prior-mean.
  • Rank by |Δ|·√n.
  • The biggest deltas are where this character is genuinely different — the headroom.
4
Three focus beesexploit
  • Aim 3 bees at the top-Δ directions.
  • Push them in a short game.
  • Keep a bee if it wins, ditch it if it loses.
5
Qwen reviews → updates the tablereflect
  • Qwen reads the new log and writes a rule, citing a cell.
  • The table's weights move along what actually paid off.
6
Delta study again → looprepeat
  • Re-measure: did the push actually grow?
  • Each round the top delta shrinks.
  • ↺ loop back to step 2 — until Δ goes flat (keep-best stops). That's saturation.

The whole point in one line: the fast reflex plays every frame; the slow coach re-weights its memory between rounds; and a new fighter is trained by finding, round after round, only where it's different.