I connected an authentic fruit fly brain to Polymarket order books via WebGL
Description and use
The author built a WebGL visualizer driven by a fruit fly neural network that reacts in real time to Polymarket order book data, showcasing a novel neuro‑inspired trading interface.
Problem
Traditional algorithmic trading bots rely on simple heuristics or basic LLM prompts, limiting their ability to capture complex market dynamics.
Outcome
A live demo where a WebGL character, driven by a fruit fly neural model, reacts in real time to Polymarket order book dynamics, showcasing a novel neuro‑inspired trading interface.
Workflow
- 1. Capture top-of-book depth imbalance and bid/ask spread velocity via Polymarket CLOB WebSocket.
- 2. Normalize these signals and inject them as synaptic currents into sensory neuron clusters.
- 3. Run an 8.333 ms Leaky Integrate‑and‑Fire (LIF) loop to compute membrane voltages.
- 4. Scale octopamine levels with spread velocity to modulate action‑potential thresholds.
- 5. Use descending neurons to trigger 3D character animations and execution decisions in real time.
- 6. Render the visualizer with Three.js/WebGL2 and stream live via Kick.
Evidence
We built Degeneret Fly, an open‑source pipeline that drives a WebGL character using authentic reconstructed MaleCNS v1.0 fruit fly neuron morphology and live market telemetry.
The repository, SWC parsing scripts, and LIF solver are 100% open source under the MIT license.
- Record date: 2026-09-19T09:15:32.423Z