What is Nostr?
pkt / Peter Todd
npub1ej4…ndrm
2024-11-27 10:16:29
in reply to nevent1q…44rn

pkt on Nostr: For what people mainly want CTV for it would be sufficient to commit to the number of ...

For what people mainly want CTV for it would be sufficient to commit to the number of _hashed_ outputs, and then only hash those outputs. Secondly, only commit to the input index (typically zero).

That would allow additional inputs and change outputs to be added as needed. And to avoid N² hashing, commit to the outputs with a hashed linked list or tree.

Thing is, this additional complexity doesn't save that many bytes compared to just using keyless anchors and CPFP. Particularly in the UTXO tree case where we're getting a path down a tree mined.
Author Public Key
npub1ej493cmun8y9h3082spg5uvt63jgtewneve526g7e2urca2afrxqm3ndrm