Author: Johan TorĂ¥s Halseth 2023-04-28 08:48:07
Published on: 2023-04-28T08:48:07+00:00
Johan is interested in a proposal that can achieve powerful capabilities with simple opcodes. He asks Salvatore to provide an example of how this would look on-chain for a simple game like "one player tic-tac-toe" with two tiles. Johan wants to know how one such state transition (going from [ X, _ ] -> [ X, X ]) would be encoded in Bitcoin script. Salvatore explains that the computation step encoded in a leaf needs to be simple enough for Script to verify it. For academic purposes, he suggests reducing the computation all the way down to a circuit where each step (leaf) is as simple as what can be checked with {OP_NOT, OP_BOOLAND, OP_BOOLOR, OP_EQUAL}. However, in practice, it is better to use Script to its fullest and not compile a SHA256 computation to something else, but rather use OP_SHA256 directly.In another email thread, Billy Tetrud mentions Verkle trees, which he finds to be a very interesting construction that could be super useful as a tool for something like Utreexo. However, he points out that the cryptography used to get those nice properties of Verkle trees isn't quantum-safe. Although many things in Bitcoin seem to be going down the path of quantum-unsafe, there are still many people who think quantum safety is important in many contexts.Salvatore also discusses a fun construction on top of the fact that f is committed to in the contract. He explains that one could build a universal state channel where parties can enter any contract among themselves (e.g., start playing a chess game) entirely inside the channel. The state of this universal channel would contain all the states of the individual contracts that are currently open in the channel, and even starting/closing contracts can happen entirely off-chain. Salvatore believes these constructions are practical and worth exploring further to figure out useful applications of this approach.
Updated on: 2023-06-16T03:02:11.522584+00:00