LAST LIGHT
LAST LIGHT is the programmable liquidity component of the protocol, a Uniswap v4 hook attached to the VSPR/USDC pool.
Responsibilities
- session-aware pool behavior
- dynamic fees
- final-hour activation
- fee normalization after the window
- eligible protocol revenue routing
Normal Session
fee = baseFeeFinal Hour
During the final 60 minutes of the configured equity session:
fee = baseFee + ramp(timeToClose)As timeToClose approaches zero, the fee approaches its configured closing level.
Revenue
Trading Activity → LAST LIGHT → Protocol Revenue → ReserveThe mechanism is deterministic: the Hook reads current session state and applies predefined logic rather than relying on a daily manual trigger.
Current Schedule
As implemented in hooks/LastLight.sol:
| Session state | Fee |
|---|---|
| Open, 09:30 to 15:00 ET | 30 bps |
| Last light, the final 60 minutes | 30 bps at T-60, rising linearly to 200 bps at T-0 |
| After the close, closed, pre-market | 100 bps |
fee = 30 + 170 x (3600 - secondsToClose) / 3600 (bps)The pool fee is updated only when the schedule has moved at least 5 bps from the last applied fee. Half of every fee (the protocol share, owner-settable) is captured by the hook on the unspecified currency and accumulated per 8-hour cycle.
Settle
Once a cycle has ended, anyone can call sweep(). The captured amount moves to the Treasury and the hook emits CycleSettled(cycleId, amount0, amount1, sessionState). There is no keeper. The next cycle pays out:
reward = min(captured at the close + bond proceeds, excess reserves)If the close captured nothing, the cycle pays nothing.