-
Couldn't load subscription status.
- Fork 90
SIP-034: Dimension-Specific Tenure Extend Variants #236
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
bc34dc0
88656f1
dd5997d
4177324
97719e1
cb1b7aa
a807a68
991ef2a
2629a15
6ae99ba
80b224a
8821768
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,57 @@ | ||
| # Technical CAB Minutes | ||
|
|
||
| ## Meeting Information | ||
|
|
||
| **Location:** Discord (async) | ||
|
|
||
| **Recorded:** No | ||
|
|
||
| **Date:** | ||
|
|
||
| - Oct 17th, 2025 | ||
|
|
||
| **Time:** n/a | ||
|
|
||
| **Attendees:** | ||
|
|
||
| - Aaron Blankstein | ||
| - Brice Dobry | ||
| - j2p2 | ||
| - Friedger | ||
| - Radu | ||
| - Setzeus | ||
|
|
||
| **Topic(s):** | ||
|
|
||
| - [SIP-034: Dimension-Specific Tenure Extend Variants](https://github.com/stacksgov/sips/pull/236) | ||
|
|
||
| **Materials**: | ||
|
|
||
| - [SIP-034: Dimension-Specific Tenure Extend Variants](https://github.com/stacksgov/sips/pull/236) | ||
| - [Reference implementation](https://github.com/stacks-network/stacks-core/pull/6609) | ||
|
|
||
| ## 2025-10-15 Meeting Notes | ||
|
|
||
| Note: This vote was urgently needed to ensure it can proceed together with | ||
| SIP-033. The current chair, Jesse Wiley, is unavailable for this vote, so Brice | ||
| Dobry is acting chair for this vote. | ||
|
|
||
| The Technical CAB reviewed SIP-034 and the supporting materials, and concluded | ||
| that this change is necessary to support the ecosystem. | ||
|
|
||
| ## Vote Outcome(s) | ||
|
|
||
| | Name | Vote | | ||
| | ---------------- | ------- | | ||
| | Aaron Blankstein | abstain | | ||
| | Brice Dobry | yes | | ||
| | Friedger | yes | | ||
| | j2p2 | yes | | ||
| | Setzeus | yes | | ||
| | Radu | yes | | ||
|
|
||
| _Note_ Aaron Blankstein is the author of SIP-034, as such he abstained from | ||
| voting. | ||
|
|
||
| The Technical CAB approves SIP-034 with 5 yes votes and 1 abstention by the | ||
| author. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,199 @@ | ||
| # Preamble | ||
|
|
||
| SIP Number: 034 | ||
|
|
||
| Title: Dimension-Specific Tenure Extend Variants | ||
|
|
||
| Author(s): | ||
|
|
||
| - Aaron Blankstein <[email protected]> | ||
| - Jude Nelson <[email protected]> | ||
|
|
||
| Status: Activation-in-Progress | ||
|
|
||
| Consideration: Technical, Governance | ||
|
|
||
| Type: Consensus | ||
|
|
||
| Layer: Consensus (hard fork) | ||
|
|
||
| Created: 2025-10-15 | ||
|
|
||
| License: CC0-1.0 | ||
|
|
||
| Sign-off: | ||
| - Brice Dobry <[email protected]>, Acting Chair, Technical CAB | ||
| - Jason Schrader <[email protected]>, Chairperson, Governance CAB | ||
|
|
||
| Discussions-To: | ||
| * SIP pull request: https://github.com/stacksgov/sips/pull/236 | ||
| * SIP reference implementation: https://github.com/stacks-network/stacks-core/pull/6609 | ||
|
|
||
| Sign-offs: | ||
| * Technical CAB: https://github.com/stacksgov/sips/blob/feat/sip034/considerations/minutes/technical-cab/2025-10-17-sip-034.md | ||
| * Governance CAB: https://github.com/stacksgov/sips/blob/main/considerations/minutes/governance-cab/2025-10-17-sip-034.md | ||
|
|
||
| # Abstract | ||
|
|
||
| This SIP details a rider to SIP-033, including a new variant of the tenure change | ||
| control transaction. This variant allows the tenure change to specify which | ||
| dimension of the block budget to reset. | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Clearer: ...which dimension of the block budget is reset. instead of "...a specific dimension of the block budget to reset.". There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in 8821768 |
||
|
|
||
| # Copyright | ||
|
|
||
| This SIP is made available under the terms of the CC0 (Creative Commons Zero) | ||
| license, available at https://opensource.org/licenses/CC0-1.0. This SIP’s | ||
| copyright is held by the Stacks Open Internet Foundation. | ||
|
|
||
| # Introduction | ||
|
|
||
| The Stacks network controls total runtime and I/O expenditure during Nakamoto tenures | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ...Nakamoto tenures, I think it makes sense to reference SIP021 here [1]: https://github.com/stacksgov/sips/blob/main/sips/sip-021/sip-021-nakamoto.md#nakamoto-terminology There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in 8821768 |
||
| via a total tenure budget [1]. Costs are tracked using worst-case estimates of the actual | ||
| runtime or I/O expended to evaluate a given Clarity operation. In Nakamoto rules, | ||
| signers and miners may coordinate to include a `TenureChange` transaction in the miner's | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How does this SIP affect the effectiveness of the coordination between signers and miners? Before there were only two options which are less likely to be disputed. The SIP should address what happens if coordination fails, or why it is likely to improve the situation. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'll add this to the SIP. The coordination would basically be the same as it is now -- right now, the signers signal to miners (and to each other) when they will accept a Signers internally decide what this timestamp will be based on how much "idle time" they have observed (i.e. time not processing block proposals). This ensures that the rate of block appends is low enough that a crashed signer (or new follower) can quickly catch up to the chain tip. After this SIP is ratified, signers would similarly track notions of "idle time" for each of these cost dimensions, and share them amongst themselves and the miners. For example, they may require that the average rate of read I/O operations be beneath a certain threshold before they'll allow a miner to issue a read-count extension. This computation and sharing does not need to ship with the hard-fork since it is not consensus-breaking, but would be added shortly afterwards. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added in 97719e1 |
||
| next block which extends the current tenure by resetting the counters for its ongoing | ||
| runtime and I/O costs. | ||
|
|
||
| This mechanism allows the tenure's overall budget to grow, for example, there has been a long | ||
| delay between Bitcoin blocks. However, if the assessed Clarity costs are much higher | ||
| than the actual runtime or I/O characteristics of the executed blocks (i.e., the actual | ||
| block runtime is much faster than the worst-case scenario around which costs are modeled), | ||
| signers and miners have limited ability to address this. This is because a mismatch in one | ||
| dimension (e.g., read-count) should not result in another dimension being reset (e.g., write-count). | ||
| Resetting all dimensions of the block budget when only one was misaligned would open the | ||
| network up to denial of service (unintentional or otherwise). | ||
|
|
||
| To address these concerns, this SIP proposes to add a new variant to `TenureChange` transactions | ||
| which allows them to specify **which** cost dimension should be reset (or all of them). | ||
|
|
||
| # Specification | ||
|
|
||
| ## Wire Formats | ||
|
|
||
| The serialization of the `TenureChangePayload` will be a backwards-compatible extension of | ||
| the existing SIP-021 serialization [2]: | ||
|
|
||
| ``` | ||
| tenure consensus hash: 20 bytes | ||
| previous tenure consensus hash: 20 bytes | ||
| burn view consensus hash: 20 bytes | ||
| previous tenure end: 32 bytes | ||
| previous tenure blocks: 4 bytes, big-endian | ||
| cause: 1 byte | ||
| pubkey hash 20 bytes | ||
| ``` | ||
|
|
||
| The `cause` field serializes the new variant in a backwards compatible scheme: | ||
wileyj marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| ``` | ||
| 0x00 indicates NewBlockFound whole budget is reset. | ||
| 0x01 indicates Extend whole budget is reset. | ||
| 0x02 indicates Extend read-count budget is reset. | ||
| 0x03 indicates Extend read-length budget is reset. | ||
| 0x04 indicates Extend runtime budget is reset. | ||
| 0x05 indicates Extend write-count budget is reset. | ||
| 0x06 indicates Extend write-length budget is reset. | ||
| ``` | ||
|
|
||
| Values `0x00` and `0x01` are used today to indicate whether or not the | ||
| `TenureChangePayload` represents a change to a new tenure or the extension | ||
| of the ongoing tenure. No other values are accepted today. | ||
| This SIP proposes accepting values `0x02` through `0x06` for `cause`, and taking | ||
| the above actions to reset a specific cost dimension's budget. | ||
|
|
||
| ## Coordination Between Miners and Signers | ||
|
|
||
| This SIP only requires Stacks nodes to accept dimension-specific tenure budget | ||
| resets via these new `TenureChangePayload` transaction payloads. It does | ||
| not mandate a strategy for coordinating with miners to determine when | ||
| dimension-specific resets might be granted. However, a brief description of how | ||
| this might be achieved is provided here, for informational purposes. | ||
|
|
||
| In the reference implementation today, signers determine how often a miner can | ||
| submit a tenure-extension transaction based on how much "idle time" each signer has | ||
| observed in its node. This is the amount of time the node spends doing work | ||
| besides processing block proposals. Signers individually choose an amount of | ||
| idle time that must pass on their node before they will approve a tenure | ||
| extension. By choosing larger idle times, signers ensure that the chain does | ||
| not grow so quickly that it prevents miners and signers from catching up to and | ||
| staying at the chain tip. Signers advertize the earliest UNIX epoch time at | ||
| which they will accept a tenure extension as part of their block proposal | ||
| acknowledgements to the miner. | ||
|
|
||
| This behavior is not consensus-critical, and is outside the scope of this SIP, | ||
| but is worth mentioning because it informs how future coordination between miners | ||
| and signers could work. Signers may adopt similar notions of idle time for each | ||
| budget dimension in order to determine when they will accept a | ||
| dimension-specific tenure budget reset. For example, a signer may measure | ||
| the amount of time the node spends _not_ performing read I/O on the chainstate database | ||
| ("read I/O idle time") to determine when they will issue a read-count reset. | ||
|
|
||
| This SIP does not require a coordination strategy to be implemented before its | ||
| activation. | ||
|
|
||
| # Related Work | ||
|
|
||
| The Stacks blockchain measures a transaction's resource expenditures along five | ||
| dimensions: the number or indexed reads ("read count"), the number of bytes | ||
| read ("read length"), the number of indexed writes ("write count"), the number | ||
| of bytes written ("write length"), and the amount of CPU used ("runtime"). Each | ||
| miner is granted a budget of each measured resource to consume over the duration | ||
| of their tenure. Each Clarity operation consumes one or more of these | ||
| resources. A Nakamoto block is only valid if the additional resources its | ||
| transactions consume do not exceed the tenure's limits on each of these | ||
| resources. | ||
|
|
||
| The cost measurements for each Clarity operation were chosen to | ||
| ensure that a Stacks node would be able to reprocess the tenure much more | ||
| quickly than it is produced. If this were not the case, then Stacks nodes would | ||
| be unable to catch up to the chain tip. This is particularly dangerous for | ||
| Stacks signers, which may go offline for mundane reasons; signers must be able | ||
| to quickly catch up to the rest of the signer network. | ||
|
|
||
| An alternative approach considered to this SIP was to produce a more accurate | ||
| measurement of how much of each resource each Clarity operation consumes. The | ||
| current model is pessimistic, and assumes a worst-case resource consumption. It | ||
| also does not consider the size of the _value_ of the data being processed; it | ||
| instead considers the _worst-case size_ allowed by the data's _type_. | ||
| We believe that the approach in this SIP is superior building a more accurate | ||
| model (but does not negate a new model's usefulness) because it allows | ||
| signers to determine whether or not to allocate more resources to an ongoing | ||
| tenure based on their real-world observation of resource consumption when | ||
| evaluating block proposals. As long as the signers observe that resource | ||
| consumption in each dimension is below an acceptable threshold, such that a | ||
| crashed signer could quickly catch back up, then the signers can safely extend | ||
| individual resource budgets regardless of the current model's pessimism | ||
| This in turn allows signers to grow the chain's tenure budgets in response | ||
| to acquiring better harder, or running upgraded nodes with better | ||
| block-processing algorithms. | ||
|
|
||
| A future SIP may increase the granularity of tenure extensions. For example, | ||
| the signers may be able to choose the amount of each resource to extend. | ||
| This SIP does not call for this in order to speed its implementation. | ||
| Furthermore, signers have the option to enforce a more granular resource | ||
| consumption rate without a hard fork -- they announce to miners their target | ||
| resource consumption rates, and reject miner blocks that consume resources at | ||
| higher rate than their target rate. | ||
|
|
||
| # Backwards Compatibility | ||
|
|
||
| Per the Specification section above, the wire formats for `TenureChange` | ||
| transactions are backwards compatible with the existing wire format. All that | ||
| has been added are new values to represent the kind of tenure extension | ||
| requested. | ||
|
|
||
| # Activation | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If activation criteria are redundant because this is a rider to SIP-033, that should be explicitly stated with some criteria or process for clarity. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Fixed in 8821768 |
||
|
|
||
| This is intended as a rider SIP to SIP-033 [3]. If SIP-033 is ratified, then this | ||
| SIP will also be ratified. Similarly, if SIP-033 is not ratified, then this SIP | ||
| will not be ratified. No further criteria are needed for this SIP. | ||
|
|
||
| # Reference Implementation | ||
|
|
||
| This SIP's implementation is written in Rust, and is available here: https://github.com/stacks-network/stacks-core/pull/6609 | ||
|
|
||
| # References | ||
|
|
||
| [1] https://github.com/stacksgov/sips/blob/main/sips/sip-021/sip-021-nakamoto.md#nakamoto-terminology | ||
| [2] https://github.com/stacksgov/sips/blob/main/sips/sip-021/sip-021-nakamoto.md#block-structure | ||
| [3] https://github.com/obycode/sips/blob/feat/clarity-4/sips/sip-033/sip-033-clarity4.md | ||
Uh oh!
There was an error while loading. Please reload this page.