Definition
The Template Distribution Protocol (TDP) is the Stratum V2 sub-protocol that moves freshly built block templates from a Bitcoin node — the Template Provider — into the mining stack. It is the plumbing that makes miner-side transaction selection practical: rather than trusting a remote pool to assemble blocks, a miner runs its own node and pulls templates locally over TDP. Every other piece of the sovereign-mining story sits on top of this one connection.
The Template Provider role
A Template Provider is a Bitcoin node exposing the TDP interface — historically a patched Bitcoin Core build maintained for the Stratum V2 ecosystem. It watches its own mempool and chain tip, and streams a new template whenever either changes, so the miner is always working on a current, fee-optimized block. Because the template originates on hardware the miner controls, there is no opportunity for a third party to silently insert, reorder, or censor transactions in transit. Your node's view of the network becomes your block, directly.
How the message flow works
The protocol is compact. The client opens by sending CoinbaseOutputDataSize, telling the provider how many bytes and signature operations the pool will need to add to the coinbase outputs, so templates leave exactly that much room. The provider then streams NewTemplate messages carrying everything needed to build the block: version, coinbase construction details, the value available to the miner, and the merkle path for the transaction set. A template flagged as a future template is pre-delivered so the very instant a new block arrives, a matching SetNewPrevHash activates it — the miner loses essentially zero time switching to fresh work. RequestTransactionData lets downstream software fetch the template's full transaction list when it needs it, and when the miner finds a block, SubmitSolution hands the complete solution — including the full coinbase transaction with witness data — back to the node for assembly and broadcast.
Where it fits in the stack
TDP rarely operates alone. In a fully sovereign pooled setup it feeds the Job Declaration Protocol, which declares the locally built template to a pool so the miner still receives smoothed payouts while mining its own block. The pairing delivers a combination that was structurally impossible under Stratum V1: the income stability of pooled mining with the censorship resistance of solo block construction. A solo miner can also consume TDP directly, mining its own templates with no pool in the loop at all.
Why sovereign miners care
Under Stratum V1, the pool alone decides which transactions every connected machine works on — transaction selection for much of the network concentrates in a handful of operators. Running your own Template Provider closes that last gap: no outside party shapes your blocks, and censorship at the pool layer loses its leverage. It is the difference between renting your voice in consensus and owning it. For a home miner already running a node for wallet verification, pointing the mining stack at that same node over TDP is the natural next step — one more layer decentralized, using hardware that is already humming on the shelf.
Practically, the barrier to entry is lower than the acronyms suggest: the Stratum V2 reference stack ships the Template Provider role and the proxy pieces that consume it, and the node hardware requirements are the same as any full node — the template work is bookkeeping, not hashing. The real cost is operational commitment: your node must stay synced and reachable, because your mining stack now depends on it for fresh work. That is a fair trade for the property you get in return, which no pool can grant and no pool can revoke: the blocks your machines work on are assembled, transaction by transaction, on your own hardware, from your own view of the mempool.
In Simple Terms
The Template Distribution Protocol (TDP) is the Stratum V2 sub-protocol that moves freshly built block templates from a Bitcoin node — the Template Provider —…
