What is Cy[bord] CBRC-20?

Disclaimer: This is a proposal for a new Convention Of Usage.
Convention Proposition. Read every word if you decide to test. This will be worthless. Play at your own risk :-)

Introduction

Cy[bord] CBRC-20 is the proposal of an efficient Metaprotocol standard for fungible tokens on Bitcoin through Ordinals. By utilizing the newmetadataandmetaprotocolfields introduced in ord 0.10+, which allow for arbitrary properties to be stored directly within the Inscription envelope, CBRC-20 keeps the same functional logic of the BRC-20 Metaprotocol while reducing the cost of each inscription and simplifying the indexing process.


Overview of CBRC-20 Features

Before we cover the CBRC-20 Metaprotocol Convention, let’s first take a moment to understand what ametaprotocolis.

WTF is a Metaprotocol?

Quick History of Metaprotocols

"Metaprotocol" is a term used by the Ordinals Community to describe an interactable "protocol" formalized through off-chain indexing of on-chain information, like BRC-20, SNS, Bitmap, etc. Until recently, an "Ordinal metaprotocol" was a conceptual term not officially recognized in the Ordinal client. This changed with ordv0.10, when the Ord Team introduced fields for writingmetaprotocolandmetadatainformation directly in the inscription envelopes. This update allows for the official flagging of Metaprotocols on Ordinals.

The Current Metaprotocol Situation

For Ordinal Metaprotocol token standards, the journey has been complex. To address issues arising post-ord v0.9, all BRC-20 indexers have decided to "freeze" on ord v0.9 for BRC-20 indexing. This means that BRC-20cannotleverage the "metaprotocol" or "metadata" fields introduced in the latest versions of ord 0.10+, hindering the BRC-20 Metaprotocol's ability to upgrade and become more efficient. As a result, the future of BRC-20 Indexing is stuck in a state of uncertainty, despite market perceptions.

CBRC-20, on the other hand, fully utilizes both the "metaprotocol" and "metadata" field features for token data, leading to significant savings in inscription fees and blockspace. This efficiency is achieved as there are no JSON files inscribed on Bitcoin for CBRC-20, positioning it as the first "real" Ordinals Metaprotocol token standard (according to the latest rules and version of the ord client).

Now let’s get into what CBRC-20 looks like!

CBRC-20 Deep Dive

The Ordinal Envelope

The Ordinal Envelope is a fundamental component of the Ordinals protocol, enabling the unique capability to embed data on individual satoshis within the Bitcoin blockchain. It plays a vital role in creating distinctive digital assets directly on Bitcoin.

Let's take an example of an Ordinal Envelope containing the message "Hello, world!" to understand its structure and function:

OP_FALSE
OP_IF
  OP_PUSH "ord"
  OP_PUSH 1
  OP_PUSH "text/plain;charset=utf-8"
  OP_PUSH 0
  OP_PUSH "Hello, world!"
OP_ENDIF

Inscribing Metadata with CBOR

To push the Ordinal community in a good direction, the developers of the Ordinals protocol, in version 0.10+, have integrated CBOR as a key component. This integration permitsmetadatato be inscribed in Ordinal Envelopes using the CBOR format, which is very efficient as CBOR data is 60%-70% smaller in byte size than equivalent data in JSON format.

This inclusion of themetaprotocolfield and the usage of CBOR for storingmetadatain the Ordinal envelope also significantly enhances data handling efficiency for Indexers. These choices allow for more compact and rapid processing of token-related data. As a result, the Ordinal envelope becomes not just a container, but a robust tool for sophisticated data interactions within the Bitcoin blockchain.

These advancements in the Ordinal envelope pave the way for more dynamic and versatile usecases. Developers can now leverage these improvements to create more nuanced and efficient token-based solutions, further expanding the capabilities of the Bitcoin network. You can read more about CBOR and metadatahere.

Definition of a Metaprotocol

In the world of CBRC-20,metaprotocolis a property defined in the ordinal framework (specifically in ord v0.10+), and serves as a field that can carry a "metaprotocol" or "community convention", as well as its metaprotocol operational codes. CBRC-20 is the first proposed standard to utilize this field and definition ofmetaprotocolproperly.

The CBRC-20 Metaprotocol Convention

We use themetaprotocolfield in line with theUniform Resource Name standard, adhering to this syntax:

<metaprotocol>:[op]:[tick]=[amt]

The CBRC-20 Metaprotocol Syntax

For example, a CBRC-20 mint inscriptionmetaprotocolfield would look like this:

cbrc-20:mint:BORD=1000

And a CBRC-20 transfer inscriptionmetaprotocolfield would look like this:

cbrc-20:transfer:BORD=500

The CBRC-20 Metaprotocol Logic

The CBRC-20metaprotocolrules follow directly with BRC-20, meaningCBRC-20 tokens adhere to the exact same rules as the BRC-20 token standard(such as the First is First principle, 4-character names, default decimal of 18, etc, you can read the existing BRC-20 ruleset outlinedhere)

However, for CBRC-20mintandtransferinscriptions, there's no need to include the "p", "op", "tick" or "amt" characters whatsoever, as they are specifieddirectlyin the Ordinal Evelope. There is nometadatarequired formintortransferinscriptions as we are simply signaling operational actions of an existing token,thus lowering the cost of CBRC-20 mint/transfer inscriptions compared to BRC-20/TAP. Metadata is onlyrequiredfordeployinscriptions.

Definition of Metadata

Newly defined in the official ord client (ord >0.10),metadatais a field designated for carrying arbitrary informationdirectlywithin an Ordinal Inscription envelope in the form of a CBOR file. You can read aboutmetadatain ordinal envelopeshere.

In CBRC-20 the only timemetadataisrequiredis when deploying a new CBRC-20 token. We will now go over some examples of what deploying, minting, and transferring CBRC-20 tokens looks like!

HOW TO PLAY WITH CBRC-20

Read from here if you just want to play!

How to Play [EZ Mode]

If you want to play with CBRC-20right nowbut don't have access to an ord 0.10+ client, we've got you covered :D

You can use theCBRC-20 EZ Crafterwe made soeveryonecan instantly PLAY!

TheCBRC-20 EZ Crafterallows for the inscribing of CBRC-20 deploy, mint, and transfer inscriptiondirectly in your browser with 0% fees(feel free to donate if you enjoy playing <3)

How to Play [Hard Mode]

If you DO have an ord 0.10+ client running locally and want to inscribe in local, here's how CBRC-20 works!

How to Deploy a CBRC-20

Deploying a CBRC-20 token is a straightforward process:

  1. Create a JSON File: Let's say you're creating a "Cy[bord]" token with the ticker "BORD".Because you want to deploy a new CBRC-20, you MUST inscribe your token "metadata" in the CBOR format.To do this, you must first create a JSON file like this:
{
    "tick": "BORD",
    "max": "21000000",
    "lim": "1000",
    "dec": "8"
}
  1. Convert to CBOR File:

After saving your JSON file, use the Cy[bord] JSON to CBOR converter to create your .cbor file.

  1. Inscribe Your Token:

You can inscribe the BORD token using this command:

ord wallet inscribe  --fee-rate FEE_RATE  --metaprotocol=cbrc-20:deploy --cbor-metadata ./deployBORD.cbor --file <literallyanyfile>

How to Mint a CBRC-20

Minting a CBRC-20 token is very easy.

  1. Choose Your File to Inscribe

Choose any file you want to inscribe (cheapest option is a txt file containing only the number0).

  1. Inscribe Your Mint Operation:

Execute the minting process with the following command:

ord wallet inscribe --fee-rate FEE_RATE --metaprotocol=cbrc-20:mint:BORD=1000 --file <yourchosenfile>

This command will mint the specified amount of "BORD" tokens.

How to Make a CBRC-20 Transfer Inscription

  1. Choose Your File to Inscribe

Choose any file you want to inscribe (cheapest option is a txt file containing only the number0).

  1. Inscribe Your Transfer Operation:

Use the following command to inscribe the transfer of your "BORD" tokens:

ord wallet inscribe --fee-rate FEE_RATE --metaprotocol=cbrc-20:transfer:BORD=500 --file <yourchosenfile>

This command will create a CBRC-20 transfer inscription which can then be sent to a Bitcoin address as a one-time use "ticket" to signify an ownership change of CBRC-20 tokens,exactly the same as the BRC-20 transfer inscription logic.

BRC-20 vs CBRC-20

Summarized from this document, here are some of the key of advantages of CBRC-20 over BRC-20

  1. Reduced Inscription Costs:

  2. A Simplified Indexing Process:

  3. Support for All MIME Types:

  4. No Limitations of Ordinal Client:

  5. Innovative Token Interaction Possibilities:

Ending Thoughts from CyBORg

Here you have it folks, the Cy[bord] CBRC-20 convention. A proposed alternative to BRC-20 standard that follows the exact same logic but in a more efficient/cheaper way thanks to ord 0.10+. The realization of “what could have been” for BRC-20 if Indexers did not decide to freeze to ord v0.9.

This is purely an experiment and should not be treated as an investment.

Let’s keep on finding new ways to play together :-)

Glossary

BRC-20:A token standard for creating and managing fungible tokens on the Bitcoin blockchain, utilizing the Ordinals protocol for data inscription.

CBOR (Concise Binary Object Representation):A binary data serialization format that offers compact size and efficient data processing, used in the context of blockchain for efficient data storage and transmission. Similar to JSON, but more efficient.

Cy[bord] / CBRC-20:A proposed metaprotocol standard for creating and managing fungible tokens on Bitcoin, leveraging the Ordinals protocol. It aims to be more efficient and cost-effective than the traditional BRC-20 standard by using the newmetadataandmetaprotocolfields.

Metaprotocol (Term):A concept used to describe a protocol within a protocol, often referring to a set of standards or rules established on top of an existing blockchain protocol, like Ordinals.

Metaprotocol (Field):A specific field within the Ordinal envelope used to identify and distinguish different protocols or conventions within the blockchain, utilized in the CBRC-20 standard.

Metadata (Field):A field within the Ordinal envelope that carries arbitrary information, such as a token's deploy-related details, in a CBOR file format. This field plays a significant role in the CBRC-20 standard for storing token data efficiently.

MIME Type:A standard that indicates the nature and format of a document, file, or an assortment of bytes. It stands for Multipurpose Internet Mail Extensions and is used in CBRC-20 for flexibility in token operations.

Ordinal Envelope:A data structure within the Ordinals protocol, featuring extendable properties for storing and managing data related to Ordinal Inscriptions.

Ordinal Inscription:A feature of the Ordinals protocol allowing for the embedding of arbitrary data directly into Bitcoin transactions.

Uniform Resource Name Standard (URN):A protocol for assigning a unique and persistent name to resources. In the context of CBRC-20, it's used in themetaprotocolfield to adhere to specific naming conventions for protocol instructions.

References

  1. Ordinals v0.10 Release: Detailed release notes of Ordinals version 0.10, which introduced themetaprotocolandmetadatafields, are availablehere.

  2. Uniform Resource Name (URN) Standards: Learn more about the URN standards, crucial for themetaprotocolfield syntax in CBRC-20, atRFC 2141.

  3. BRC-20 Token Standard Documentation: For insights into the BRC-20 token standard and its operational rules, visit theLayer 1 documentation.

  4. Ordinals Inscriptions Metadata: A guide to understanding themetadatafield in ordinal envelopes can be foundhere.