Codex plan — what to do next, ranked
> **Topology correction, 2026-04-26:** Mac4 is the current Unity Editor / GUI smoke-test host and real-Femto capture host. Mac5 is still the synthpub LaunchAgent / synthetic fallback host. Do not blindly replace all Mac5 references; see `software/demo/TOPOLOGY-CORRECTION-2026-04-26.md`.
Full Public Reader
Codex plan — what to do next, ranked
> Topology correction, 2026-04-26: Mac4 is the current Unity Editor / GUI smoke-test host and real-Femto capture host. Mac5 is still the synthpub LaunchAgent / synthetic fallback host. Do not blindly replace all Mac5 references; see `software/demo/TOPOLOGY-CORRECTION-2026-04-26.md`.
_Read `CODEX-CONTEXT.md` + `ARCHITECTURE.md` first. This file is the
priority-ordered action list. Each item has: scope, success criteria,
files to touch, things to avoid, and when to escalate to Mohamed._
Reading order
1. `CODEX-CONTEXT.md` — origin, evolution, decision log.
2. `unity/lume_pcloud/ARCHITECTURE.md` — current state mental model.
3. This file (`CODEX-PLAN.md`) — next actions.
4. `MAC5-CODEX-HANDOFF-2026-04-26.md` — bootstrap prompt with
commit ledger + smoke-test commands.
5. `DUNCAN-GAP-ANALYSIS.md` — what's left to match Duncan's stack.
6. `Reference/Duncan/INDEX.md` — 83 reels + 69 analyses.
Status snapshot (2026-04-26 ~16:00 local)
- 22 commits on `main`, no push, Mac1 source-of-truth.
- Mac5 sync deferred — Tailscale 100
- 10 Unity components (5 base + 5 Wave 4-5 additions).
- 37 pytest tests passing (33 fast + 4 slow).
- Wave 5 score: 4 of 5 priorities shipped (impulse, calibration,
motion-gate, ARCHITECTURE.md). Remaining: fluid sim, marching cubes.
P0 — Reachability + smoke-test (you can't move without these)
P0.1 — Get Mac5 back online
ping -c 1 -t 2 mac5
ssh -o ConnectTimeout=5 mac5 'echo alive'If both fail:
- Mac5 is physically off (cable / power)
- Tailscale on Mac5 is dead — needs manual restart
- Tailscale on Mac1 is dead — `tailscale status` will reveal
Escalate to Mohamed if it's been >2h offline. Don't try to remote-fix
Mac5 from Mac1 — there's no out-of-band channel.
P0.2 — Catch-up rsync (when Mac5 reachable)
cd Desktop/lume-commerce/software/demo
rsync -av --no-perms --no-owner --no-group \
--exclude='*.mp4' --exclude='Library/' --exclude='Logs/' \
--exclude='Temp/' --exclude='UserSettings/' \
./ mac5:Desktop/lume-commerce/software/demo/The `Reference/Duncan/reels/*.mp4` files are gitignored symlinks
pointing to `[home-path]`. They're per-machine —
don't rsync them.
Verify after rsync:
ssh mac5 'cd Desktop/lume-commerce/software/demo && python3 -m pytest tests/ -q'Success criterion: `33 passed` on Mac5.
P0.3 — Mac4 GUI smoke-test (Mohamed's hands, ~10 min)
This is the only honest validation that the 22 commits actually
render. Walk Mohamed through `MAC5-SMOKE-TEST.md` if needed.
6 stages, each with expected visual outcome.
Don't skip this. Wave 5 fluid sim + marching cubes ports below
need real Editor compilation feedback to ship safely; you can't
extend the pipeline blind.
---
P1 — Wave 5 fluid sim (~1 day after smoke-test green)
Scope
Vendor `keijiro/StableFluids` (URP-compatible 2D Eulerian fluid sim)
into the project. Expose 6 named presets matching Duncan's
nomenclature: `Default`, `Default_Smooth`, `LongThrow`, `MidThrow`,
`ShortThrow`, `InvertedObstacle`. Reflective wall boundaries. Wire
motion-gate's `_LumeTimeScale` global as a delta-time multiplier so
the sim slows on stillness.
Audio coupling rules (Duncan E512 verbatim, MUST match)
> 1) Fluid sim preset with shorter range works better at full screen scale.
> 2) Audio response boosting position directly (rather than feeding into
> force levels) makes it nice and snappy without blowing up the fluid sim.
> 3) EQ before auto-gain (or fixed dynamic range with no auto-gain).
> 4) Bass should affect sim large low-freq positional offsets, mid range
> and highs work nicely when the timer cycle causes higher-freq position
> offsets.
So: bass band (`_AudioLevels.y`) → big slow positional bumps. Mid+high
bands → fine timer-cycled offsets. NEVER feed audio into force directly
— that blows up the integrator.
Files to create
- `Assets/Shaders/LumeFluidSim.compute` — advection / projection / jacobi
iteration kernels. ~200 lines HLSL.
- `Assets/Scripts/LumeFluidSim.cs` — MonoBehaviour, allocates RG16F or
RGBA32F velocity field, dispatches kernels in LateUpdate.
- `Assets/Scripts/LumeFluidPresets.cs` — ScriptableObject with 6
named-preset configurations.
- `Assets/Resources/LumeFluidPresets.asset` — instance.
- `Assets/Scripts/LumeFluidSim.cs.meta` — stable GUID.
Files to NOT touch
- Anything in the don't-touch list (`CODEX-CONTEXT.md`).
- The existing optical-flow / depth-reproject compute shaders.
Success criteria
1. `python3 -m pytest tests/ -q` still 33 green (no new test additions
required — this is a Unity-side ship).
2. `Lume → Bootstrap Scene → Procedural Tunnel` then attach `LumeFluidSim`
from Inspector → Play → fluid field visible as a screen-space overlay
that swirls on motion and pulses on bass.
3. Switching presets at runtime via Inspector dropdown changes the
sim character without restart.
4. `_LumeTimeScale` low → fluid visibly slows. High → fluid runs full.
Escalation triggers
- Compute shader compile errors that aren't obvious (.shader log >5 lines):
capture full log + commit-stash, ping Mohamed.
- StableFluids vendor license incompatible with our use: stop, document.
- Performance < 30 fps on Mac5 with 256² fluid grid: stop, profile, ping.
---
P2 — Wave 5 twin-mesh marching cubes (~1 day after fluid)
Scope
Vendor `keijiro/ComputeMarchingCubes`. Add a "twin-mesh" mode where
two MC passes run with different ISO thresholds (`_InnerThreshold`,
`_OuterThreshold`), inner pass is a glass-like translucent material,
outer pass is a thin gold-leaf shell. Per Duncan E427.
Files
- `Assets/Shaders/LumeMarchingCubes.compute` (~150 lines, vendor)
- `Assets/Shaders/LumeMcGlass.shader`, `LumeMcGold.shader`
- `Assets/Scripts/LumeMarchingCubes.cs`
Success criterion
`Lume → Bootstrap Scene → Add Marching Cubes` (new menu) → Play →
twin-mesh visible from any Femto-fed depth source. Inner glass + outer
gold readable separately at 60 fps.
---
P3 — Wave 6 deferrals (DON'T start yet)
These need hardware that's not onsite:
- Skeletal avatar — needs mocopi PRO or Sapiens skeleton stream.
No skeletons → no Wave 6.
- Human Kaleidoscope — needs Camera Stack + 16 rotated VFX submission
passes. ~3 days; hold until product cadence is set.
- Wordmark-as-blendshape — requires modeling the LUME wordmark as
a real Mesh (not just a Blender deboss) + driving a blendshape from
audio. Holds until product copy is finalised.
- Strip particles + pinscreen mesh — Duncan-specific aesthetic;
evaluate after Wave 5 lands and we see what's actually missing.
---
P4 — Cross-domain pivot (only if LUME blocked)
If you can't move on LUME (Mac5 down + no fluid-sim verification path),
work on these instead:
- Param Golf v3 H100 3-seed run — Codex-reviewed PR ready
(`parameter-golf-v3-implementation.md`). Fire on a Vast.ai A100.
- Vercel breach rotation — 98 rows in `/tmp/vercel-audit/new-secrets.tsv`,
user rotates upstream then runs `/tmp/vercel-audit/rotate.py`.
- Koatji NY/LA outreach — 11 leads from 2026-04-02.
- MotionMix stem-to-Strudel retrieval pipeline — Mac5 strudel runtime
live, retrieval pipe queued.
These are NOT your default — only if LUME is wedged.
---
What you must NEVER do
1. No git push. Local commits on `main` only.
2. No `--no-verify` / `--amend` on shipped commits.
3. No deletion of memory files. Append-only at the index level.
4. No deletion of `Reference/Duncan/`. It's the playbook reference.
5. No edits to `LumeAudioReactor.cs` / `LumeUdpReceiver.cs` /
`pointcloud_pub.py`. Use the public setters / additive sidecars.
6. No Mac4 SSH-with-camera attempts. TCC-blocked, won't work.
7. No silently downgrading scope. If you ship a stub, label it
`[SCAFFOLD — needs GUI verify]` in the commit + memory file.
What you MUST do
1. Memory file per commit. `lume-v{N}-{track}-progress.md` with
SHA + files + smoke-test recipe.
2. MEMORY.md index update per commit — one line at top of relevant
section.
3. Mac5 rsync after every commit (when reachable). Confirm via
`ssh mac5 'git log --oneline -1'` matches Mac1.
4. Stable .meta GUIDs (numeric pattern, not random).
5. End-of-session report to Mohamed: ≤200 words, what shipped +
what's pending + next 2 logical steps.
When you finish a session
# Generate session-end summary (paste into chat with Mohamed):
git log --oneline $(git merge-base main HEAD)..HEAD
ls [home-path] | xargs -n1 basename | tail -10
python3 -m pytest tests/ -q | tail -1That's the report — number of commits, fresh memory files, test count.
Plus one paragraph of "what's next, ranked."
Promotion Decision
Keep in the searchable backlog until it intersects a live paper or system.
Source Anchor
lume-commerce/docs/handoffs/CODEX-PLAN.md
Detected Structure
Method · References · Code Anchors · Architecture