|
| 1 | +# PRD: Prover Submission Cost |
| 2 | + |
| 3 | +- Owner: @LHerskind |
| 4 | +- Approvers: |
| 5 | + - Product: @joeandrews, @aminsammara |
| 6 | + - Engineering: @just-mitch, @Maddiaa0 |
| 7 | + - DevRel: |
| 8 | +- Target PRD Approval Date: 2025-03-21 |
| 9 | +- Target Delivery Deadline: 2025-04-07 |
| 10 | + |
| 11 | +> [!NOTE] |
| 12 | +> **Keywords** |
| 13 | +> The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC 2119](https://datatracker.ietf.org/doc/html/rfc2119). |
| 14 | +
|
| 15 | +# Background |
| 16 | + |
| 17 | +> [!NOTE] |
| 18 | +> **Key Terms** |
| 19 | +> - **Multi-Proofs**: Scheme that allows redundancy in proof submission and shares payment between all submitters. |
| 20 | +> - **Mana**: The unit of work on the Aztec rollup |
| 21 | +> - **BaseFee**: The amount of fee asset to pay per _Mana_ to cover costs |
| 22 | +> - **Congestion Multiplier**: A multiplier on top of the _BaseFee_ that depends on the usage of the chain to limit spam etc. |
| 23 | +
|
| 24 | +The act of producing blocks incurs a cost to the block builders: |
| 25 | + |
| 26 | +- The sequencer pays for publishing the block to the data availability layer and to perform some validity checks such as validating attestations. |
| 27 | +- The prover pays for producing the proof (proving) and then to publish and verify the proof to the base-layer. |
| 28 | + |
| 29 | +We build the background on assuming that you are familiar with the following past design docs: |
| 30 | + |
| 31 | +- Prover Coordination Design([cdfb3a72](https://github.com/AztecProtocol/engineering-designs/blob/cdfb3a72e9b3e4415dcbfe04bd92878996472e6d/in-progress/8509-prover-coordination/design.md)) |
| 32 | +- Fee Design Doc ([dac7fdfb](https://github.com/AztecProtocol/engineering-designs/blob/dac7fdfbffb0b0d10ce0dff85221f7a6ece1933b/in-progress/8757-fees/design.md)) |
| 33 | + |
| 34 | +The _BaseFee_ was designed to cover: |
| 35 | + |
| 36 | +1. the cost to prove the transactions in the block |
| 37 | +2. the cost to submit the block |
| 38 | +3. `1/N` cost to submit an epoch proof (`N` being epoch size) |
| 39 | + |
| 40 | +The BaseFee calculation originally assumed sufficient mana utilization per block to meet targets. Therefore, blocks with low utilization would not fully cover operational costs through fees alone. To address this, block rewards were introduced as a subsidy. |
| 41 | + |
| 42 | +Provers were compensated with a share of both fees and rewards, allocated according to their provided quotes. |
| 43 | + |
| 44 | +Then the move to [Prover Coordination: Multiproofs](https://hackmd.io/Ivn9axP1SFyEHjpAXVn62g) happened and the costs morphed into the following (`M` is number of proofs): |
| 45 | + |
| 46 | +1. the cost to prove the transactions in the block `M` times |
| 47 | +2. the cost to submit the block |
| 48 | +3. `M/N` cost to submit an epoch proof |
| 49 | + |
| 50 | +However, our model is currently flawed as it is: |
| 51 | + |
| 52 | +- not taking `M` proofs into account when computing the BaseFee |
| 53 | +- paying the proof submission cost to the sequencer, not the prover |
| 54 | + |
| 55 | +These flaws are remnants of the quote-based prover coordination. |
| 56 | + |
| 57 | +## Assumptions |
| 58 | + |
| 59 | +- There exists at least `M` provers that are willing to participate in block production. |
| 60 | + - If the true number is less than `M` we are overpaying for proofs. |
| 61 | +- The gas estimates of the proof submission cost is somewhat precise |
| 62 | + - Even though it happens potentially many blocks before the proof submission itself. |
| 63 | +- We expect submission cost to be greater than proving cost. |
| 64 | + |
| 65 | +# User Stories |
| 66 | + |
| 67 | +## End User |
| 68 | + |
| 69 | +As an end user, I want transaction fees to be predictable, transparent, and low, similar to using a single-sequencer system, so that I don’t face unexpectedly high costs. |
| 70 | + |
| 71 | +This is especially important during early network phases with low usage, when high fees might discourage me from continuing to use the network. |
| 72 | + |
| 73 | +> [!WARNING] |
| 74 | +> **Multi-proof overhead** |
| 75 | +> If the costs associated with submitting multiple proofs (M) are passed directly to users via the BaseFee, it may lead to significantly higher fees compared to centralized or single-proof setups. The additional application of the Congestion Multiplier on these inflated fees could further compound this issue, potentially causing users to abandon the network early on. |
| 76 | +
|
| 77 | +## Prover |
| 78 | + |
| 79 | +As an economically rational prover, I wish to participate in block production on the Aztec network, such that I can earn some money on all the machines that I have collected. |
| 80 | + |
| 81 | +In short, as a prover, I wish to: |
| 82 | + |
| 83 | +1. Collect blocks and transactions as the chain grows |
| 84 | +2. Run machines to prove transactions and roll them into an epoch proof |
| 85 | +3. Submit epoch proofs to the base-layer for a share of the rewards |
| 86 | +4. Profit??? |
| 87 | + |
| 88 | +> [!WARNING] |
| 89 | +> **Multi-proof commentary** |
| 90 | +> With the nature of the multi-proofs splitting rewards between all submitters and only paying out after. We won't know ahead of time if there is profit or not. |
| 91 | +
|
| 92 | +# Requirements |
| 93 | + |
| 94 | +## Functional Requirements |
| 95 | + |
| 96 | +### Earmarked Fees |
| 97 | + |
| 98 | +- **What**: Fees earmarked for specific actions (e.g., proof submission) **MUST** be directed to the entity incurring the associated cost. |
| 99 | +- **Why**: To maintain fairness and economic incentive alignment between actors. |
| 100 | +- **Where**: Derived from the current imbalance (sequencer receives funds without bearing costs). |
| 101 | + |
| 102 | +### Consistent Proving |
| 103 | + |
| 104 | +- **What**: Actors that consistently produce proofs **SHOULD** receive bigger share of the fees that inconsistent actors |
| 105 | +- **Why**: To maintain consistency in block production and provide some minimum quality of service |
| 106 | +- **Where**: Derived from concerns about potential abandonment during periods of low network utilization or initial adoption phases. |
| 107 | + |
| 108 | +### Protection from Excessive Multi-Proof Costs |
| 109 | + |
| 110 | +- **What**: Transaction fees charged to users **SHOULD** increase at most sub-linearly due to the introduction of multi-proof submissions compared to a single-proof sequencer setup. |
| 111 | +- **Why**: To prevent users from experiencing unexpectedly high fees resulting from internal design decisions (such as multiple proofs), ensuring network adoption and retention. |
| 112 | +- **Where**: Derived from concerns about potential abandonment during periods of low network utilization or initial adoption phases. |
| 113 | + |
| 114 | +## Non-functional Requirements |
| 115 | + |
| 116 | +### Prover profitability |
| 117 | + |
| 118 | +- **What**: Proving **SHOULD** be profitable in the presence of `<=M` submitters, even during periods of low activity. |
| 119 | +- **Why**: To ensure chain-growth and avoid avoid continuous pruning. |
| 120 | +- **Where**: Derived from other requirements on stable block production and looking at other chains and general economics. |
| 121 | + |
| 122 | +### Scalability |
| 123 | + |
| 124 | +- **What**: In the presence of `<=M` submitters their profit **SHOULD** scale with increasing transaction volume and overall network usage. |
| 125 | +- **Why**: To avoid creating incentives for provers and sequencers to collude, deliberately limiting network throughput to maximize their individual profits at the expense of network growth. |
| 126 | +- **Where**: Derived from concerns regarding potential economic collusion. |
| 127 | + |
| 128 | +### Inflation Bounds |
| 129 | + |
| 130 | +- **What**: The inflation of the staking asset **MUST** be less than 20% yearly |
| 131 | +- **Why**: Infinite inflation is not scalable. |
| 132 | +- **Where**: Common economic sends to limit inflation + @aminsammara for number. |
| 133 | + |
| 134 | +# Handling Tradeoffs |
| 135 | + |
| 136 | +When handling the tradeoffs, I believe we should step in the direction of "subsidise too much". |
| 137 | + |
| 138 | +For ignition there will be **no fees** since there are no transactions. If the provers cannot recoup their costs from the block rewards it is very limited who would be able **and** willing to participate. |
| 139 | + |
| 140 | +For alpha, it will also allow us to keep transaction fees low(er) while usage is low, making it easier for users to try the network. |
0 commit comments