Warning: This library is highly experimental and should be used for education purposes with caution. For reference implementation, see: https://github.com/lightninglabs/taro.
Work in progress Haskell library implementing parts of the Taproot Asset Representation Overlay (Taro) protocol:
- Asset Tree Representation (Encoding ⇔ Decoding)
- Asset Creation
- Asset Burning
- Asset Transfers
- Asset Universes
- Multi-Hop Taro Asset Transfer
- Address Representation (Encoding ⇔ Decoding)
- Sending
- Spending
- The Empty Hash Map
- Lookup / Insert / Delete elements
- Create / Verify Merkle Proofs
- Compress / Decompress Merkle Proofs
- Caching Optimizations
- Proof File Representation (Encoding ⇔ Decoding)
- Proof File Verification
- Asset Universes
- Asset Multiverses
- Pocket Universes
- Input Mapping
- Output Mapping
- State Transition Validation
The spec is still being developed so the BIPs may be out of date with the reference implementation. As library aims to track the behaviour of the reference implementation, here are some notable differences and elaborations from the BIPs (I think) the library has come across and has tried to replicate here:
genesis_outpoint.index
is in Big Endian, not in little endian as in the bitcoin wire formatprevious_asset_witnesses
has length prefix in BigSize, rather than u16- keys are encoding with their parity bytes: lightninglabs/taproot-assets#187
- bech32m encoding relaxes the 90 character length limit defined in BIP-173
- the TLV type
asset_type
is removed as it is now embedded inasset_genesis
compression_bits
of theCompressedProof
is serialised in after compacting the bits into bytes.
asset_inclusion_proof.proof_version
is the 1 byteasset_version
, not the 4 byteproof_version
taro_inclusion_proof.proof_version
is the 1 byteasset_version
, not the 4 byteproof_version
taproot_exclusion_proof.bip86 = 2
1 byte field added