Skip to main content

Relay Mining Estimation & Parameters

A gentle high-level introduction to token minting and burning, intended to understand the different variables involved and how they interact.

Mathematic Representation

Claim.NumRelays=scaleDown(RelayMiningDifficulty,ActualNumberOfRelays)ClaimedComputeUnits=Claim.NumRelays×ComputeUnitsPerRelayEstimatedOffchainComputeUnits=scaleUp(RelayMiningDifficulty,ClaimedComputeUnits)uPOKT=EstimatedOffchainComputeUnits×ComputeUnitsToTokenMultiplierComputeUnitCostGranularity\begin{aligned} \text{Claim.NumRelays} &= \text{scaleDown}(\text{RelayMiningDifficulty}, \text{ActualNumberOfRelays}) \\ \text{ClaimedComputeUnits} &= \text{Claim.NumRelays} \times \text{ComputeUnitsPerRelay} \\ \text{EstimatedOffchainComputeUnits} &= \text{scaleUp}(\text{RelayMiningDifficulty}, \text{ClaimedComputeUnits}) \\ u\text{POKT} &= \frac{\text{EstimatedOffchainComputeUnits} \times \text{ComputeUnitsToTokenMultiplier}}{\text{ComputeUnitCostGranularity}} \end{aligned}

Relay Mining Parameters & Function

ParameterTypeScopeControllerDescription
RelayMiningDifficultyDynamic ParameterService SpecificOnchain protocol business logicThe probability that a relay is reward applicable
ComputeUnitsPerRelayStatic ParameterService SpecificService OwnerNumber of compute units each reward applicable relay accounts for
ComputeUnitsToTokenMultiplierStatic ParameterNetwork WideNetwork AuthorityNumber of onchain tokens minted/burnt per compute unit
ComputeUnitCostGranularityStatic ParameterNetwork WideNetwork AuthorityEnable more granular calculations for the cost of a single relay (i.e. less than 1 uPOKT)
scaleDownOffchain procedureService SpecificRelayMiner & Onchain ParamsA methodology to ensure RelayMiner scalability
scaleUpOnchain procedureService SpecificValidator & Onchain Business LogicA methodology to ensure fair token distribution

Claim & Relay Estimation Flow

The end-to-end flow can be split into 4 key steps (steps 1-3 capture in the diagram below):

  1. Tree Construction: Converts actual offchain number of relays to the probabilistic number of reward applicable relays
  2. Claim Creation: Sums up the total number of reward applicable relays in the tree into a single claim
  3. Claim Settlement: Estimates the total number of consumed compute units based on the claim and service parameters
  4. Token Distribution: Converts the estimated compute units into uPOKT and distributes it to relevant stakeholders

💰 Example with Numbers

Assume the following Offchain market driven numbers:

  • POKT price: $0.1/POKT
  • Market rate: $5M for 1M relays
  • Session: Num actual offchain relays between App (User) & Supplier (Operator)
Num RelaysDescriptionRelayMiningDifficulty (RMD)ComputeUnitsPerRelay (CUPR)ComputeUnitsToTokenMultiplier (CUTTM)ComputeUnitCostGranularity (CUCG)Estimated Compute Units (CU)uPOKT ResultUSD
(at $0.10/POKT)
1,000,000Baseline values1.01.05011,000,000 x 1 x 1
= 1,000,000
1,000,000 × 50 / 1
= 50,000,000 uPOKT
= 50 POKT
$5.00
1,000,000High multiplier
High granularity
1.01.050,000,0001e61,000,000 x 1 x 1
= 1,000,000
1,000,000 × 50,000,000 / 1,000,000
= 50,000,000 uPOKT
= 50 POKT
$5.00
1,000,000High compute units per relay1.05.05011,000,000 x 1 x 5
= 5,000,000
5,000,000 × 50 / 1
= 250,000,000 uPOKT
= 250 POKT
$25.00
10,000,000Adjusted relay mining difficulty0.11.05011,000,000 x
(0.1 / 0.1) x 1
= 1,000,000
1,000,000 × 50 / 1
= 5,000,000 uPOKT
= 5 POKT
$5.00

FAQ

Why do we need relay mining difficulty?

To be able to scale a single RelayMiner co-processor to handle billions of relays while being resource efficient.

How do we prove the claim?

Visit the claim and proof lifecycle docs for more information.

Why is every relay the same number of compute units?

We will handle variable compute units per relay in the future.

How does rate limiting work?

Rate limiting is an optimistic non-interactive permissionless mechanism that uses a commit-and-reveal scheme with probabilistic guarantees, crypto-economic (dis)incentives, and onchain proofs to ensure that suppliers do not over-service applications.

How does burning work?

Burning is a mechanism that puts funds in escrow, burns it after work is done, and puts optimistic limits in place whose work volume is proven onchain.