Architecture
Torinox Protocol has two runtime parts: an immutable Solidity contract (TorinoxEntropy) on Robinhood Chain, and an offchain keeper that reveals the next preimage after a request. The contract, not the keeper, is the verification authority.
| Network | Robinhood Chain mainnet |
| Chain ID | 4663 |
| Oracle (TorinoxEntropy v10) | 0xd8a0680e7699526b57140ed4eafdcc7219dc0a0c |
| Provider / keeper | 0x8741b8a825644D9Ef18Faf2DAB5e9b47B900F2b6 |
| Fee | exact 0.000025 ETH via getFeeV2() |
| Refund delay | 6 L1 blocks (~60-90s) |
| Hash chain length | 500,000 registered |
| SDK | @diceprotocol/sdk |
| Agent paid path | $0.05 USDG fixed over x402 |
Commit-reveal hash chain
The provider builds a Keccak256 chain from a secret seed and registers the commitment (live registered length: 500,000). Reveals walk the chain in reverse. Anyone can hash a reveal and check it against the stored commitment. Future values stay unknown while the seed stays private.
seed → h1 = Keccak256(seed) → h2 = Keccak256(h1) → ... → h500000 = commitment Reveal order: h500000 first, then h499999, ...
Request, reveal, callback
- Consumer calls
requestV2(provider, userRandom, gasLimit)withmsg.valueexactly equal togetFeeV2(). - Contract emits a request event and stores the request.
- Keeper submits the next preimage via
revealWithCallback. - Contract verifies the preimage, combines user and provider contributions, and calls
entropyCallback(seq, provider, random). - If no reveal arrives, the requester can call
refundRequestafterrefundDelayBlocks = 6L1 blocks (~60-90s).
Final random word
Torinox returns a full bytes32. Apps map that word in deterministic code. There is no onchain min/max parameter.
randomNumber = Keccak256(userRandomness ‖ providerContribution)
Under the stated model, neither side unilaterally picks the word when the commitment holds and the provider seed stays secret. A provider can still withhold service; that is a liveness issue handled by refund, not by inventing a result.
What is not in the contract
- No proxy and no upgrade path on TorinoxEntropy v10.
- Single designated provider on the live deployment.
- Keeper liveness is operational, not cryptographically enforced.
- Latency of ~1-3 seconds is observed operations language, not an SLA.
Addresses
Oracle 0xd8a0680e7699526b57140ed4eafdcc7219dc0a0c
Provider 0x8741b8a825644D9Ef18Faf2DAB5e9b47B900F2b6
Integration samples: /docs/quickstart/. Verification steps: /docs/verification/.
Home · RNG for Robinhood Chain · Docs · Architecture · Security · SDK · x402 · GitHub