Skip to main content

Intro to Relay Mining Token Mint & Burn

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

Morse Readers

If you were involved in the "Morse" network of Pocket Network, approach this document from a first-principles perspective. Do not try to draw parallels.

Key Relay Cost Variables

ParameterParameter TypeScopeControllerDescription
RelayMiningDifficultyDynamicService SpecificOnchain protocol business logicThe probability that a relay is reward applicable
ComputeUnitsPerRelayStaticService SpecificService OwnerNumber of compute units each reward applicable relay accounts for
ComputeUnitsToTokenMultiplierStaticNetwork WideNetwork AuthorityNumber of onchain tokens minted/burnt per compute unit
ComputeUnitCostGranularityStaticNetwork WideNetwork AuthorityEnable more granular calculations for the cost of a single relay (i.e. less than 1 uPOKT)

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

Mathematic Representation

Claim.NumRelays=scaleDown(RelayMiningDifficult,ActualNumberOfRelays)ClaimedComputeUnits=Claim.NumRelays×ComputeUnitsPerRelayEstimatedOffchainComputeUnits=scaleUp(RelayMiningDifficult,ClaimedComputeUnits)uPOKT=EstimatedOffchainComputeUnits×ComputeUnitsToTokenMultiplierComputeUnitsCostGranularity\begin{aligned} \text{Claim.NumRelays} &= \text{scaleDown}(\text{RelayMiningDifficult}, \text{ActualNumberOfRelays}) \\ \text{ClaimedComputeUnits} &= \text{Claim.NumRelays} \times \text{ComputeUnitsPerRelay} \\ \text{EstimatedOffchainComputeUnits} &= \text{scaleUp}(\text{RelayMiningDifficult}, \text{ClaimedComputeUnits}) \\ u\text{POKT} &= \frac{\text{EstimatedOffchainComputeUnits} \times \text{ComputeUnitsToTokenMultiplier}}{\text{ComputeUnitsCostGranularity}} \end{aligned}
Rendering bug (ignore the duplication)

TODO(@olshansk): Look into why this equation renders twice: as latex and plaintext.

💰 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
Relay Mining Difficulty

The actual computation related to Relay Mining Difficlty is non-linear but used solely for demonstration purposes here.

Token Distribution (Global Inflation)

Steps 1-3 above represent the baseline mint=burn scenario where POKT is transferred from the Application to the Supplier.

Step 4 can optionally inflate the overall supply of POKT by minting additional tokens.

For example, assuming the following tokenomic module params:

{
"params": {
"mint_allocation_percentages": {
"dao": 0.1,
"proposer": 0.1,
"supplier": 0.7,
"source_owner": 0.1,
"application": 0
},
"dao_reward_address": "pokt10...",
"global_inflation_per_claim": 0.2
}
}

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.