ZKDARKPOOL(8)The Dark Room ManualZKDARKPOOL(8)

Sealed by time. Matched in the dark.Proven in the open.

connecting to the room
next close▌
batch #… open · quicknet round …
0 sealed orders of 64 in this batch
room
offline: open batches expire and refund
cadence
5 min · cutoff 15 s · expiry 30 min
last batch
no batch settled yet
last proof
none yet
prove time
about 2 s a batch on the room's GPU
dmesg: the room, as it happensconnecting
reading the chain…▌

1.Name

zkdarkpool - a dark pool for tokenized stocks, run as one contract and one room process.

2.Synopsis

deposit   USDG | stock token | ETH           any time, withdraw when no order is open
seal      market side qty limit             until 15 s before the close
close     every 5 min, at a quicknet round   before it, nobody can read an order
match     pro-rata at the pool's 60 s TWAP   5 bps a side, same price for everyone
prove     Groth16 proof over all 64 slots    made on the room's GPU, checked by the contract
expire    close + 30 min                     an unsettled batch unlocks every balance

3.Description

You deposit USDG, stock tokens or ETH into the room. To trade, your browser builds the order (market, side, size, limit), encrypts it to the room's key, then locks that ciphertext to the drand quicknet round of the batch close. What goes onchain is the locked ciphertext and a commitment to it. Until the close nobody can open it, and that includes the operator.

At the close the beacon publishes the round, the room opens every order of the batch and applies one rule. Orders whose limit crosses the price take part; the smaller side fills in full, the larger side shares pro-rata, everyone at the same price, so being first in a batch gains you nothing.

The room then proves it. The proof says that the published fills are exactly what the rule gives over every committed order of the batch, and the contract checks it before moving a single balance. Matched orders become public prints. Unmatched orders stay dark forever.

4.What is public

before the closeafter the close
publicnothing of the ordercan open the time lock, still faces the room-key layer
the roomnothing: it has the key but not the roundreads every order of the batch
youyour own orderyour own order
  • Always public: that your address sealed an order in batch N, and when; your deposits and withdrawals.
  • Public after settlement, matched orders only: owner, market, side, size, limit and fill. These are the prints.
  • Never public: an unmatched order. Its slot reads "dark" and nothing else.

A balance held only in USDG suggests a buy; keeping both assets in the room, and more than you trade, blurs side and size. Details.

5.The proof

Public inputs: the batch id, the room key of the day, the price of every market, and for each of the 64 slots its commitment, its owner and its outcome. The circuit opens each committed ciphertext with the room's secret key, checks the order belongs to its owner and batch, and recomputes eligibility, pro-rata and leftover units. If one outcome differs from the rule, no proof exists.

no proof yet
The first batch with orders will show its proof here.

The proof is Groth16, produced on the room's GPU: multi-scalar multiplications and number-theoretic transforms run in CUDA. A batch takes about 2 seconds on the GPU, 1.3 s of it the proof itself, as measured live on the room's machine. Each batch page shows which device made its proof and how long it took. The setup is a public ceremony with independent contributions; what it covers.

6.Markets

slotsymbolissuerprice sourcequote
0NVDANVIDIA logoNVIDIAv3 pool, 60 s TWAPUSDG
1TSLATesla logoTeslav3 pool, 60 s TWAPUSDG
2AAPLApple logoApplev3 pool, 60 s TWAPUSDG
3GOOGLAlphabet logoAlphabetv3 pool, 60 s TWAPUSDG
4AMZNAmazon logoAmazonv3 pool, 60 s TWAPUSDG
5SPCXSpaceX logoSpaceXv3 pool, 60 s TWAPUSDG
6QQQInvesco QQQ logoInvesco QQQv3 pool, 60 s TWAPUSDG
7-kept for Pons coins: spot mark taken onchain between cutoff and close, quote WETH

The price is the onchain pool's, not an exchange's. Tokenized stocks follow their issuer's terms.

7.Fees

5 basis points a side on matched notional, in the quote asset. Unmatched orders pay nothing. The room pays the gas of every settlement.

8.Built with

drand
Uniswap
Global Dollar USDG
NVIDIA

9.See also