The cycle

An agent is a loop. Each turn of the loop is a cycle, and each cycle is nine steps. Every step writes a line to the journal, so a cycle can be read from top to bottom after the fact.

Timing

Session (New York time)Cycle every
Pre-market 05:00 to 09:30cycleMin (default 15 min)
NYSE open 09:30 to 16:00cycleMin
After-hours 16:00 to 20:00cycleMin
Night 20:00 to 05:0060 min
Weekend, Friday 20:00 to Sunday 20:00, and NYSE holidays60 min

The calendar is the NYSE one for 2026 to 2028, with US daylight saving. The same code runs in the engine and in the site header.

The nine steps

1. SLEEP

If there is no capital yet, or it is a weekend and the book holds no stock, the cycle stops. The model is not called and no money is spent on inference. A flat weekend costs nothing.

2. SCAN

The engine reads each Uniswap v3 pool: slot0 for the spot price, liquidity for depth, and observe for averages from the pool's own oracle (5 minute windows ending now, one hour, six hours, one day and three days ago). ETH is priced through the WETH/USDG pool. A line is written with the session, the ETH price, the four prices and the book value.

3. SNAPSHOT

The facts for the model are assembled, serialised in a canonical form, hashed with SHA-256 and written to snapshots/<hash>.json. See snapshots and verification.

4. THINK

The model is called with the snapshot as the user message and the mandate in the system prompt. See the model and its budget. If the inference budget is used up, or the agent is paused, or the call fails, the step records why and the book holds.

5. DECIDE

The answer is parsed into target weights, a confidence and the reasoning. All three are written to the journal with the snapshot hash. If the model gave no usable answer, the target is the current weights: no trade.

6. RISK

The target goes through the risk engine. The result is a list of orders and a list of refusals, each with its reason. Both are journaled.

7. ORDER

For the orders that survived, an intent id is computed: the SHA-256 of the snapshot hash and the order list. It is saved to the ledger before anything is sent. If the same intent id already exists, nothing is sent and the journal says so. A restart in the middle of a cycle, or a replayed cycle, cannot trade twice.

8. FILL

The executor sends the swaps (execution). The fill is measured from wallet balances before and after, then applied to the ledger. In paper mode the fill is simulated at the pool price plus the pool fee plus the estimated price impact.

9. PNL and BUYBACK

The book is marked to market. The time-weighted index, the benchmark, the drawdown and the day's change are updated. If the book made new profit above its previous high-water mark, a share of that new profit buys the coin and burns it (fees). Finally the status files the site reads are rewritten.

Order of precedence

If several things apply in one cycle, they apply in this order: operator controls (pause, flatten), the drawdown breaker, then the model. The model is only consulted when neither of the first two has already decided.