Q-04: Sandwich Logic (Membrane)
The wiring membrane between Pi and RG. How do they talk?
Scope: - HTTP API — endpoints (GET /state, POST
/invoke, POST /checkpoint, GET /health, GET /wiki/{path}). FastAPI +
uvicorn confirmed. - State sync — polling at 100ms confirmed (16ms
latency). Poll vs stream decision. - Gamepad input → invoke flow — how
D-pad + button presses translate to HTTP calls to Pi - State payload —
5.9KB for 36 nodes confirmed. No bottleneck. - Wiki serving — how the RG
fetches wiki pages. GET /wiki/nodes/hex_14.md → rendered on
RG. - Error handling — Pi unreachable? RG caches last state.
“Connecting…” overlay. - Tailscale — confirmed both devices on 1.96.4
with SSH. MagicDNS short names not supported on RG (use IPs). - Gamepad
input adoption — which sub-agent patterns (radial menus, chips,
branching interviews, tags/presets) get adopted?
Depends on: Q-03 (what state looks like), Q-05 (what the RG UI looks like)