How to get the Sapling Commitment Tree for a given block height?

Note sure if this is the right place to ask but here it goes…

In the library librustzcash and in particular in, there is a function to initialize the blocks table at a given height, understandingly to avoid having to scan from the activation height. The last parameter is the sapling_tree which is the serialized Sapling commitment tree.

I looked at a few implementation that provide checkpoints. For instance

I don’t get why the sapling_tree are so short. I thought they would contain all the note commitments as a incremental merkle tree and I was expecting thousands of hashes per tree. How is this tree constructed exactly?



I believe it’s only the Merkle frontier of the tree, i.e. a Merkle path from the last used leaf to the root. That’s sufficient if we know that all note witnesses needed by the wallet will be after that point.

Thanks, I think I understand now. Just to be sure, is it because it is an incremental merkle tree? Nodes are always appended, therefore you only need to keep the latest node and path to root in order to build the anchor?