The ledger
The claim this project makes is not that the fly trades well. It is that you can check what the fly did. That only holds if the neural state and the trade are the same transaction, so they are.
Order within a tick
A tick is 60 seconds, integrated at a fixed step of not yet measured. Nothing is submitted part-way through. The sequence is fixed and the ledger records it in this order:
- Read the market. Volume and momentum for the five symbols are sampled once, at the start of the tick, and held constant for its duration.
- Redraw the terrain. Mesa heights and hatching densities are updated, including erosion on any mesa whose volume has decayed.
- Render the luminance profile from the fly’s current position and heading, and drive the photoreceptors with it.
- Integrate. The retained graph runs for the full tick. Spike counts accumulate per population.
- Read out heading from the EPG population vector and turn from the PFL asymmetry. Advance the body. This produces the new position.
- Derive weights from the new position by the barycentric rule.
- Commit. Spike counts, heading, delta, position, escape flag and weights are written, and the swap that moves the book to those weights is executed — in one transaction.
Step seven is the point of the whole arrangement. The state that explains the trade and the trade itself either both land or neither does. There is no window in which the book has moved and the reason has not been published, and no opportunity to publish a reason chosen after the fact.
Schema
Every field is committed as an integer. Floating point is not used anywhere in the committed state, because two machines that disagree in the last bit of a double would produce two different ledgers from the same simulation.
| Field | Type | Units | Notes |
|---|---|---|---|
| id | uint64 | — | Monotonic tick counter. Never reused, never reordered. |
| ts | uint64 | ms | Simulation time at the end of the tick, not wall-clock time at submission. |
| spikes | uint32[] | count | Spike count per retained population over the tick. Integer, so it survives replay exactly. |
| heading | int32 | millidegrees | EPG population vector angle at the end of the tick. Fixed point; no float is committed. |
| headingDelta | int32 | millidegrees | Signed turn since the previous tick. PFL output. |
| position | uint32[2] | 1e-6 of arena | Body position on the valley floor, x then y, in normalised arena coordinates. |
| escape | bool | — | DNp01 fired during this tick. If true, weights are all zero and no swap follows. |
| weights | uint16[5] | basis points | Derived from position. Sums to 10 000, or to 0 on escape. |
| graphHash | bytes32 | — | Hash of the retained graph and every constant in the model. Changes if anything about the simulation changes. |
Replaying a tick
Given the committed state at tick n, you should be able to run tick n+1 yourself and arrive at the same coordinates. What you need is the position, heading and membrane state carried forward from n, the market sample at n+1, and the graph identified by graphHash.
Determinism rests on four things, and all four are constraints on us:
- Fixed step. The integrator never adapts its step size to save time, because an adaptive step makes the trajectory depend on the machine.
- Fixed seed. Any stochastic input — background drive, sensory noise — is drawn from a counter-based generator keyed on the tick id, so it is reproducible without storing it.
- Integer commits. Spike counts are counts. Angles and positions are fixed point. Rounding happens once, at commit, in a specified direction.
- No wall-clock. Nothing in the simulation reads the time of day. The only clock is the tick counter.
If a replay diverges, that is a bug in this system and we want to know. A divergence is not a market condition and it has no benign explanation.
Chain
| Network | Robinhood Chain |
|---|---|
| Chain id | 4663 |
| Explorer | https://robinhoodchain.blockscout.com/tx/ |
Every row in the ledger on the front page links to its transaction at that base. Neuron identifiers shown alongside are the released male-cns:v1.0 identifiers, unchanged, so a spike count attributed to a population can be traced back to the specific neurons it came from.