碑文
銘文には任意の内容が刻まれ、ビットコインネイティブのデジタル人工製品が作られました。通常NFTと呼ばれています。の銘文には側鎖や個別のトークンは必要ありません。
これらの刻まれたコングは、ビットコイン取引転送を使用してビットコインアドレスに送信され、ビットコインUTXOに保存されます。これらの取引、アドレス、UTXOはすべての点で通常のビットコイン取引、アドレス、UTXOです。は単一の聡を送るために加えて、取引は序数理論に基づいて入力と出力の順序と値を制御しなければなりません
銘文の内容はワールドワイドウェブ基準に基づいている。銘文はコンテンツタイプ(MI MEタイプとも呼ばれる)とコンテンツ自体(バイト列)で構成されています。これにより、Webサーバーから銘文コンテンツを返すことができ、HTML銘文を作成して使用し、他の銘文コンテンツを再混合するために使用されます。
銘文の内容は完全にチェーン上にあり、保存されているtaproot script-path spendスクリプト内。のTaprootスクリプトはその内容に対する制限が少なく、証人割引を追加で受けることで、銘文内容の保存が比較的経済的になります。
taproot script-path spendスクリプトは既存のtaproot出力からしか生成できないため、そのため、は2段階のcommit/revealプロセスを使用して刻印されます。まず、commitでは、銘文の内容を含むスクリプトに提出するtaproot出力を作成します。次に、reveal取引では、commit取引による出力を使用して、チェーン上の銘文の内容を表示します。
銘文の内容は、実行されていない条件のデータプッシュを使用してシリアル化され "エンベロープ"と呼ばれます。封筒はOP_FALSE OP_IF…OP_ENDIF任意の数のデータプッシュを構成し、ラップします。エンベロープは実際には空の操作なので、それらを含むスクリプトのセマンティクスは変更されません。となり、他のロックスクリプトと組み合わせて使用できます。
文字列「Hello,world!」を含むのテキスト銘文を以下のようにシリアル化されています:
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
まず文字列'ord'がプッシュされ、銘文と封筒の他の用途との曖昧さを解消します。
`OP_PUSH 1'は、次のプッシュにコンテンツタイプが含まれていることを示します。'OP_PUSH 0'は、後続のデータプッシュがコンテンツ自体を含むことを示す。の大規模な銘文は複数回のデータプッシュを使用しなければならない。taprootの少数の制限の一つは、単一のデータプッシュが520バイトを超えないことであります。
The inscription content is contained within the input of a reveal transaction, and the inscription is made on the first sat of its input if it has no pointer field. This sat can then be tracked using the familiar rules of ordinal theory, allowing it to be transferred, bought, sold, lost to fees, and recovered.
内容
銘文のデータモデルはHTTP応答のデータモデルであり、銘文がウェブサーバによってサービスされ、ウェブブラウザで閲覧することを可能にします。
フィールド
銘文には、オプションの本文の前にフィールドを含めることができます。各フィールドにはの2つのデータプッシュ、1つのラベルと1つの値。
Currently, there are six defined fields:
content_type
, with a tag of1
, whose value is the MIME type of the body.pointer
, with a tag of2
, see pointer docs.parent
, with a tag of3
, see provenance.metadata
, with a tag of5
, see metadata.metaprotocol
, with a tag of7
, whose value is the metaprotocol identifier.content_encoding
, with a tag of9
, whose value is the encoding of the body.delegate
, with a tag of11
, see delegate.
本文の先頭とフィールドの末尾には "空のデータ"でプッシュが表示されます。
認識できないラベルの解釈は、偶数か奇数かによって異なり、稲妻ネットワーク"は奇数"にすることができるというルールに従います。
ラベルさえも、作成、初期割り当て、または銘文の転送に影響を及ぼす可能性のあるフィールドのために使用されます。だから、識別できない銘文でも、フィールドも"未バインド"として表示されなければなりません。つまり、場所がありません。
奇数タグは、追加のメタデータなど、作成、初期フィールド、割り当て、または転送に影響を与えないために使用され、したがって、無視することが安全であることを選択します。
銘文の身分ID
銘文は取引を明らかにする入力に含まれている。彼らを一意に識別するために、彼らには以下の形式のIDが割り当てられています:
521f8eccffa4c41a3a7728dd012ea5a4a02feed81f41159231251ecf1e5c79dai0
’i’の先頭部分は、トランザクションID(’txid’)である。i
の後の数字はを定義します。新しい銘文は、取引で常に銘記されたインデックスの位置(0から開始)
銘文は、入力の中の異なる入力の中にあってもよく、同じ入力であってもよく、あるいは両者の組み合わせであってもよい。いずれにしても、パーサーは入力を連続的にチェックし、すべての銘文『封筒を検索するため、順序は明確です
Input | Inscription Count | Indices |
---|---|---|
0 | 2 | i0, i1 |
1 | 1 | i2 |
2 | 3 | i3, i4, i5 |
3 | 0 | |
4 | 1 | i6 |
Inscription Numbers
Inscriptions are assigned inscription numbers starting at zero, first by the order reveal transactions appear in blocks, and the order that reveal envelopes appear in those transactions.
Due to a historical bug in ord
which cannot be fixed without changing a great many inscription numbers, inscriptions which are revealed and then immediately spent to fees are numbered as if they appear last in the block in which they are revealed.
Inscriptions which are cursed are numbered starting at negative one, counting down. Cursed inscriptions on and after the jubilee at block 824544 are vindicated, and are assigned positive inscription numbers.
サンドボックス化
HTML と SVG 銘文はサンドボックス化され、チェーンの下の内容を引用しないようにして、銘文の不変性と独立性を保ちます。
これは、HTMLとSVGの銘文を iframes
にロードし、銘文コンテンツを提供することによって行われる'sandbox'属性です。Content-Security-Policy”ヘッダ。
Self-Reference
The content of the inscription with ID INSCRIPTION_ID
must served from the URL path /content/<INSCRIPTION_ID>
.
This allows inscriptions to retrieve their own inscription ID with:
let inscription_id = window.location.pathname.split("/").pop();
If an inscription with ID X delegates to an inscription with ID Y, that is to say, if inscription X contains a delegate field with value Y, the content of inscription X must be served from the URL path /content/X
, not /content/Y
.
This allows delegating inscriptions to use their own inscription ID as a seed for generative delegate content.
Reinscriptions
Previously inscribed sats can be reinscribed with the --reinscribe
command if the inscription is present in the wallet. This will only append an inscription to a sat, not change the initial inscription.
Reinscribe with satpoint: ord wallet inscribe --fee-rate <FEE_RATE> --reinscribe --file <FILE> --satpoint <SATPOINT>
Reinscribe on a sat (requires sat index): ord --index-sats wallet inscribe --fee-rate <FEE_RATE> --reinscribe --file <FILE> --sat <SAT>