Author: Byte; Source: Byte Yuan CKB
Recently, a Spore DOB-0 protocol[1] on the Spore GitHub aroused great interest in the author.
Spore is a universal digital object creation protocol deployed on the CKB blockchain. It supports multiple content types such as images, links, videos, audio, text, and code (such as Lua scripts, Markdown). The generated DOB (Digital Object) is not only tamper-proof, but also completely stored on the chain.
The Spore DOB-0 protocol is the first protocol built on the basis of Spore, and it is also a protocol that is more inclined to the application layer. The difference between it and Spore is similar to the difference between the HTTP protocol and the TCP protocol.According to the description, this Spore DOB-0 protocol aims to create a flexible DNA byte rendering process. In more popular terms, it is to introduce how to parse the DNA of Spore DOB. Although the content of this agreement is brief, its potential is immeasurable.
How the Spore DOB-0 protocol is implemented
The Spore DOB-0 protocol sets a new standard for the "text" content type, which is to store the most important thing of DOB - DNA, instead of ordinary text, in the Cell of the CKB blockchain, and then the on-chain Decoder decodes the DNA according to the Pattern, and finally renders it on the front end and displays it to the user.
Specifically:
When a user casts a DOB, the on-chain contract reads the current block height and Cell ID and hashes them. The resulting hash value is the DNA of the DOB.
The Decoder deployed on the CKB blockchain decodes the DNA according to the Pattern pre-defined by the creator or artist. Pattern is a segment of bytes, which can be a binary number or a string, or any format. Its format is determined by the Decoder, and the creator or artist needs to define and upload it before the user casts the DOB. Pattern defines which bytes represent what attributes, how to assign values, and specifies the code location of the Decoder, etc.
Finally, the front-end (wallet, browser, trading platform, etc.) renders DOB according to the content decoded by Decoder and displays it to the user.
From the above process, we can see that for creators and artists, they need to create Pattern and Cluster in advance. In Pattern, creators and artists need to define and assign values to various attributes of DOB, so Pattern is like a code book, which determines how Decoder decodes the DNA of DOB.
It is reported that in order to lower the user threshold and facilitate operation, the development team will launch a tool later, allowing creators and artists to create a Cluster Cell that already contains Pattern directly on the chain like filling in the blanks. Cluster is similar to the concept of Collection, but more flexible and independent than Collection. By creating a Cluster and filling the ID corresponding to the Cluster into the DOB, you can mint a Spore DOB belonging to this Cluster, so the Cluster can also be regarded as a directory index of the Spore DOB.
For protocol developers, they need to deploy a Decoder contract on the CKB blockchain in advance and publish its address. Decoder is equivalent to a decoder or decryptor, and its main responsibility is to decipher the information expressed by the DNA string according to the instructions on the "code book" (that is, the Pattern mentioned above). Since CKB is a permissionless public chain, in the foreseeable future, as more and more DOBs adopt the Spore DOB-0 protocol standard, more and more developers will deploy various Decoders, and even customize Decoders for certain projects for creators and artists to choose from.
For users, as long as they know the Cluster ID published by the creator or artist and fill in the ID when minting DOB, they can mint a Spore DOB belonging to that Cluster. It is very simple and easy to operate.
Derived from Loot, Beyond Loot
The Spore DOB-0 protocol is inspired by Loot. Loot is adventurer equipment randomly generated and stored on the Ethereum blockchain. It has only a few lines of text, no numerical values, no images or anything else. These are intentionally omitted so that others can interpret and use them in any way.
Loot writes the attribute pool, that is, Pattern, into the contract, which is equivalent to Decoder and Pattern being written together, with a high degree of coupling, so a Loot contract can only correspond to one Loot NFT theme. The Spore DOB-0 protocol decouples Pattern and Decoder, further improving composability, and the same set of Decoders can have completely different DOB themes with different Patterns.
Loot has only one dimension in random number generation, that is, it generates a random number, and then all attribute pools use this random number. When casting DOB through the Spore DOB-0 protocol, a DNA string will be generated, and different attribute pools in the Pattern will use specific fragments in the DNA as random numbers, and the random dimension is wider.
In addition, in terms of overall design philosophy, Spore DOB is obviously more beautiful than Loot.
First, casting DOB requires obtaining CKB tokens as "raw materials", and melting DOB can retrieve the occupied CKB. This gives DOB a body and soul, as well as the concept of life and death.
Secondly, the world is made up of time and space. PoW is essentially a decentralized clock, and Cell is a space that can store any type of content. The combination of PoW + Cell allows the CKB blockchain to build a decentralized universe. In this decentralized universe, when a DOB is born, it will hash the time and space (block height and Cell ID), and the result is its "birth date" (i.e. DNA). Therefore, there is a certain degree of randomness when casting DOBs through the Spore DOB-0 protocol, which echoes the randomness of the birth process of life in real life.
One of the characteristics of the hash function is anti-collision, that is, changing only one character of the input information will also produce a completely different hash value, which can ensure that the DNA of each DOB is different, just like the DNA of each life in the real world is also different.
The word Cell in Chinese means cell, in which DNA is stored, and DNA contains the most important information of organisms. By cultivating cells, we will eventually get a living organism, which can continue to mate, reproduce, and evolve continuously. DOB minted through the Spore DOB-0 protocol has strong flexibility and composability. Users can enrich the content expressed by DNA according to their preferences, and display it in the community through various methods such as painting, modeling, music, and text descriptions. They can even connect to the AI big model on the front end, so that DOB can continue to evolve with the continuous iteration of the big model.
Spore has many advantages over Loot, such as no transaction fee (miner fee) for transferring DOB on the chain, and each DOB has CKB tokens as value support, etc. It is recommended to read the previous article "Understand Spore, a digital object creation protocol on the CKB chain" and consult the Spore documentation [2], which will not be introduced here one by one.
The future vision of Spore DOB-0 protocol
DeFi Lego blocks have made everyone aware of the powerful power of "composability". Different DeFi protocols are used in conjunction with each other and integrated layer by layer, consolidating and expanding the boundaries and height of the DeFi world. The Spore DOB-0 protocol separates Pattern, DNA, and Decoder in design. The advantage of this is that it brings flexibility and composability, providing unlimited possibilities for subsequent ecological development.
"One gives birth to two, two gives birth to three, and three gives birth to all things." Since DNA only stores the most important attributes of DOB, the abstraction is very high. Therefore, DOB minted based on the Spore DOB-0 protocol is the "one" in front. Anyone else can continue to build, improve, enrich and supplement this "one" and make secondary and tertiary creations based on DOB: people who like pictures can throw the decoding results of DOB DNA to AI drawing tools such as Midjourney to generate images of various styles; people who like film and television works can throw the decoding results of DOB DNA to AI video tools such as Sora to reproduce DOB in film and television works; people who like literary works can set DOB as a character in the novel, and so on.
In addition, DOB minted through the Spore DOB-0 protocol is also open and extensible. Other blockchain projects can reference these DOBs (Cell is a referenceable storage unit). For example, a full-chain game or a GameFi project can directly reference DOB as the underlying database of props information such as characters, weapons, and equipment in the game project. Moreover, the same set of DOB can be used in different games, achieving the limitation that props and weapons in traditional Web2 games cannot be used across games.
In short, openness, flexibility, composability, and scalability give the Spore DOB-0 protocol unlimited imagination space, and it can be used to build various possibilities.No one can know exactly what will happen in the future now, but the ecological development based on the Spore DOB-0 protocol is definitely worth looking forward to.