KIP-20 covenant ID tracing a verified lineage through successive Kaspa UTXO state transitions
KIP-20 Explained: Covenant IDs and Consensus-Traced Lineage
May 28, 2026
Kaspa Stratum bridge rejecting an oversized TCP line before miner authorization
Kaspa Stratum Security Fix: What Miners and Pool Operators Should Do
May 29, 2026

KIP-21 Explained: Partitioned Sequencing Commitments for Scalable Proving


KaspaBuy
July 16, 2026

KIP-21 replaces a single global per-block sequencing stream with an authenticated set of active application-lane tips while keeping one header commitment. A prover can focus on the activity of one lane and later reconstruct global order with merge indices. The design changes proof structure, not Kaspa’s block rate or transaction guarantees.

Key takeaways

  • KIP-21 keeps one 32-byte accepted_id_merkle_root in each chain-block header but changes what that value commits after activation.
  • Accepted transactions are grouped into lanes by their 20-byte subnetwork_id, and each active lane has a recursive tip plus its last-touch blue score.
  • A sparse Merkle tree authenticates active lane entries, while selected-parent recursion anchors the state across chain blocks.
  • Lane-local witnesses target work proportional to relevant lane activity rather than all global chain-block activity.
  • Global ordering remains reconstructible with merge_idx; the partition does not mean independent or unordered consensus.

Why replace the linear sequencing commitment?

An application-specific prover usually cares about one state machine, not every transaction accepted by the network. Under a linear global recurrence, proving an application transition may still require processing global activity in each intervening chain block. As throughput grows, that couples one application’s proof cost to unrelated use.

The merged KIPs PR #36 proposes a lane-based commitment so a witness can isolate the application’s touched lane. The maintained KIP-21 specification states the primary objective as O(activity)-style proving: the lane-diff portion should scale with activity in that lane, not simply with the number of chain blocks between anchors.

That notation needs care. It is not a claim that every prover operation is constant or that proof generation becomes cheap. Sparse-Merkle inclusion paths, witness serving, application execution, payload data, and cryptographic verification still consume resources.

How does Kaspa define an application lane?

For this KIP, a lane ID is the transaction’s 20-byte subnetwork_id. Native and coinbase transactions use their dedicated system IDs, while a valid user lane uses a four-byte namespace followed by 16 zero bytes. Hashing that ID yields the 256-bit key used in the active-lanes sparse Merkle tree.

The specification caps a block at 50 distinct non-coinbase lanes and limits aggregate gas per non-coinbase lane to 1,000,000,000. Native and reserved system lanes use zero gas. These admission rules bound local update work; the separate activity window and purge rules bound the recently active set.

Each active entry stores a lane-tip hash and the blue score when that lane was last touched. A block’s accepted transactions are grouped by lane, ordered deterministically, and folded into the appropriate lane tip. Quiet lanes remain unchanged until the inactivity rule purges them.

What is inside the new commitment tree?

The active-lanes sparse Merkle root authenticates the currently active entries. KIP-21 combines that root with an inactivity shortcut under ActivityRoot. It also commits a context hash containing the selected-parent timestamp, accepting-block DAA score, and blue score, plus a root over mergeset miner payloads.

These pieces form a state root, which is chained to the selected parent’s sequencing commitment. The result is stored in the existing accepted_id_merkle_root header field and remains consumable by OpChainblockSeqCommit. Keeping one header field avoids adding a second unauthenticated application root.

The sparse Merkle definition includes collapsed single-leaf subtrees. That makes typical witnesses depend on the branching depth of the actual active set rather than always carrying 256 empty siblings. The full hashed lane key remains committed, so the collapse is part of the normative root calculation, not merely a local storage trick.

This commitment supplies authenticated inputs that a proving system can reference; the separate KIP-16 ZK verification primitive determines how a supported proof can be checked inside a Kaspa spending script.

How can a lane proof preserve global order?

Partitioning transactions by lane does not discard their global position. Every transaction in an accepting block has a zero-based merge_idx. A party reconstructing global order collects the relevant per-lane transaction sets and sorts by that index, then verifies lane witnesses and the sparse-Merkle diff under the global anchors.

For a lane-local proof, the intended model provides a starting and ending SeqCommit, inclusion evidence for the lane at both anchors, and a compressed lane-diff witness between the two tips. The diff size follows that lane’s activity between anchors. If the lane becomes inactive and later reappears, non-inclusion and reactivation evidence becomes part of the proof story.

The KIP-21 inactivity-shortcut guide explains how a committed older anchor helps traverse long quiet spans without a linear header walk.

Why commit time, scores, and miner payloads?

Based applications may need a verifiable clock-like value, progress index, or miner-provided data. KIP-21 commits the selected-parent timestamp because it is already fixed when a block template is built, along with the accepting block’s DAA and blue scores. Touched lane tips include the same context hash.

The specification cautions that Kaspa timestamps are not strictly monotonic along the selected-parent chain. An application that requires monotonic time must enforce that property at its own layer. Similarly, committing raw mergeset coinbase payloads proves inclusion under the root; it does not make arbitrary payload content truthful.

KIP-21 also operates at a different level from KIP-20 covenant IDs. Covenant IDs trace membership through UTXO transitions. Lane commitments authenticate accepted activity across chain blocks. A sophisticated application may use both, but their guarantees should remain separate.

Limitations: what O(activity) does not mean

O(activity) is a scoped proving objective, not a network throughput guarantee. The proposal does not increase block rate, remove script limits, make proof generation instantaneous, or guarantee low fees. An application with heavy activity still produces a large lane diff, and a proof relying on intermediate miner payloads may need block-level witnesses beyond the lane path.

The commitment also does not provide data availability. A root can authenticate data that a prover has, but cannot force a witness service to retain or serve it. Operators and application designers need explicit retention, reconstruction, and fallback strategies around pruning boundaries.

Finally, PR #36 added a specification to the KIPs repository. Its merge documents a reviewed design; deployment depends on the corresponding rusty-kaspa implementation and network activation.

Frequently asked questions

Does each lane have its own blockchain?

No. Lanes are partitions inside one Kaspa sequencing commitment. They share the same chain-block anchors and consensus, and global order remains reconstructible.

Can a lane ID be any 20-byte value?

No. KIP-21 defines valid native, coinbase, and user-lane encodings and reserves other shapes for future system use.

Does purging erase historical transactions?

No. Purging removes an inactive lane entry from the bounded active set. Historical commitments and whatever data nodes retain under the wider pruning model are separate concerns.

Source and verification note

This article is based on kaspanet/kips PR #36, merged on May 28, 2026, and the maintained KIP-21 specification. Lane encoding, admission limits, commitment structure, context fields, and proving complexity are drawn from those primary sources. Implementers should verify the current specification subdocuments and activated rusty-kaspa release before producing consensus-sensitive witnesses.

Related Posts

KIP-21 Explained: Partitioned Sequencing Commitments for Scalable Proving
This website uses cookies to improve your experience. By using this website you agree to our Data Protection Policy.
Read more