Skip to content

Conversation

@fakela
Copy link
Contributor

@fakela fakela commented Nov 21, 2025

Closes #559

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No documentation issues detected.

@fakela fakela marked this pull request as draft November 25, 2025 05:02
@fakela fakela marked this pull request as ready for review November 26, 2025 03:37
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No documentation issues detected.

@fakela
Copy link
Contributor Author

fakela commented Nov 28, 2025

Category: Should we simplify the sentence so the links sit on the naturally related word (i underlined the word). This would mean that we might have to rewrite the sentence sligtly in some cases

  1. Screenshot 2025-11-28 at 02 29 44

  1. Screenshot 2025-11-28 at 02 57 15

  1. Screenshot 2025-11-28 at 03 05 30

  1. Screenshot 2025-11-28 at 03 07 32

  1. Screenshot 2025-11-28 at 03 15 58

  1. Screenshot 2025-11-28 at 03 15 58

  1. Screenshot 2025-11-28 at 03 19 42

  1. Screenshot 2025-11-28 at 03 20 49

  1. Screenshot 2025-11-28 at 03 22 20

  1. Screenshot 2025-11-28 at 04 12 01

  1. Screenshot 2025-11-28 at 04 52 23

  1. Screenshot 2025-11-28 at 04 55 57

  1. Screenshot 2025-11-28 at 04 59 02

  1. Screenshot 2025-11-28 at 05 20 01

  1. Screenshot 2025-11-28 at 05 31 13

@fakela
Copy link
Contributor Author

fakela commented Nov 28, 2025

Category: I used chapter number reference cause they were too long(below is how long the descriptive links were)

Screenshot 2025-11-28 at 02 59 27 Screenshot 2025-11-28 at 03 11 39 Screenshot 2025-11-28 at 04 16 05 Screenshot 2025-11-28 at 04 29 22

@fakela fakela closed this Nov 28, 2025
@fakela fakela reopened this Nov 28, 2025
@fakela fakela marked this pull request as ready for review November 28, 2025 05:20
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update on foundations/whitepapers/tblkch.mdx: there is one inline suggestion to keep the document consistent with the style guide, so please apply the inline suggestion.

@@ -198,7 +198,7 @@ The account state itself approximately consists of the following data:
- Its *storage usage statistics*, including the number of cells and bytes kept in the persistent storage of the smart contract (i.e., inside the blockchain state) and the last time a storage usage payment was exacted from this account.
- An optional *formal interface description* (intended for smart contracts) and/or *user public information* (intended mostly for human users and organizations).

Notice that there is no distinction between "smart contract" and "account" in the TON Blockchain. Instead, "simple" or "wallet" accounts, typically employed by human users and their cryptocurrency wallet applications for simple cryptocurrency transfers, are just simple smart contracts with standard (shared) code and with persistent data consisting of the public key of the wallet (or several public keys in the case of a multi-signature wallet; cf. [1.7.6](#1-7-6-example%3A-creating-a-cryptocurrency-wallet-smart-contract) for more detail).
Notice that there is no distinction between "smart contract" and "account" in the TON Blockchain. Instead, "simple" or "wallet" accounts, typically employed by human users and their cryptocurrency wallet applications for simple cryptocurrency transfers, are just simple smart contracts with standard (shared) code and with persistent data consisting of the public key of the wallet (or several public keys in the case of a multi-signature wallet; [Example: creating a cryptocurrency wallet smart contract](#1-7-6-example%3A-creating-a-cryptocurrency-wallet-smart-contract) for more detail).
Copy link
Collaborator

@verytactical verytactical Nov 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't there be a link on a "wallet" instead?

@@ -214,7 +214,7 @@ In addition to shardchain blocks and their states, the TON Blockchain contains *

## 1.3 Consistency conditions

In addition to the data structures contained in the block and in the blockchain state, which are serialized into bags of cells according to certain TL-B schemes explained in detail later (cf. Chapters [3](#3-messages%2C-message-descriptors%2C-and-queues)—[5](#5-block-layout)), an important component of the blockchain layout is the *consistency conditions* between data kept inside one or in different blocks (as mentioned in [1.2.3](#1-2-3-interaction-with-other-blocks-and-the-outside-world-global-and-local-consistency-conditions)). This section describes in detail the function of consistency conditions in the blockchain.
In addition to the data structures contained in the block and in the blockchain state, which are serialized into bags of cells according to certain TL-B schemes explained in detail later (Chapters [3](#3-messages%2C-message-descriptors%2C-and-queues)—[5](#5-block-layout)), an important component of the blockchain layout is the *consistency conditions* between data kept inside one or in different blocks (as mentioned in [Interaction with other blocks and the outside world. Global and local consistency conditions](#1-2-3-interaction-with-other-blocks-and-the-outside-world-global-and-local-consistency-conditions)). This section describes in detail the function of consistency conditions in the blockchain.
Copy link
Collaborator

@verytactical verytactical Nov 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The *consistency conditions* should be a non-italic link instead. (as mentioned in ...) should be removed.

@@ -273,11 +273,11 @@ Of course, the "witness" value $f(x):Y$ may be included inside the (modified) da

### 1.3.8. Example: consistency condition for *InMsgDescr*

For instance, the consistency condition between $X:=\textit{InMsgDescr}$, the list of all inbound messages processed in a block, and $Y:=\textit{Transactions}$, the list of all transactions present in a block, is of the above sort: "For any input message $x$ present in *InMsgDescr*, a transaction $y$ must be present in the block such that $y$ processes $x$".<sup>[8](#fn8)</sup> The procedure of $\exists$-elimination described in [1.3.7](#1-3-7-constructive-elimination-of-existence-quantifiers) leads us to introduce an additional field in the inbound message descriptors of *InMsgDescr*, containing a reference to the transaction in which the message is actually processed.
For instance, the consistency condition between $X:=\textit{InMsgDescr}$, the list of all inbound messages processed in a block, and $Y:=\textit{Transactions}$, the list of all transactions present in a block, is of the above sort: "For any input message $x$ present in *InMsgDescr*, a transaction $y$ must be present in the block such that $y$ processes $x$".<a id="ref-fn8"></a><sup>[8](#fn8)</sup> The procedure of $\exists$-elimination described in [Constructive elimination of existence quantifiers](#1-3-7-constructive-elimination-of-existence-quantifiers) leads us to introduce an additional field in the inbound message descriptors of *InMsgDescr*, containing a reference to the transaction in which the message is actually processed.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$\exists$-elimination should be a link here.

@fakela
Copy link
Contributor Author

fakela commented Nov 29, 2025

@verytactical I have clarified this new approach with Alexy, as I had some questions around it (based on the screenshots I shared above). I'll adjust the sentences especially those with described in, explained in, etc and place the links on the natural occuring text.

@fakela fakela marked this pull request as draft November 29, 2025 00:19
fakela and others added 2 commits November 29, 2025 00:26
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

<span id="ref-4">**[4]**</span> N. Durov, *Telegram Open Network Virtual Machine*, 2018.
[4] N. Durov, *Telegram Open Network Virtual Machine*, 2018.


## Footnotes
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dublicate
Screenshot 0007-12-01 at 13 55 46

@@ -59,7 +59,7 @@ where $[A]$ equals one when condition $A$ is true, and zero otherwise.

- Next, $\lceil l/8\rceil$ data bytes follow. This means that the $l$ data bits of the cell are split into groups of eight, and each group is interpreted as a big-endian 8-bit integer and stored into a byte. If $l$ is not divisible by eight, a single binary one and a suitable number of binary zeroes (up to six) are appended to the data bits, and the completion tag (the least significant bit of the descriptor byte $d_2$) is set.

- Finally, $r$ references to other cells follow. Each reference is normally represented by 32 bytes containing the SHA-256 hash of the referenced cell, computed as explained below in [1.1.4](#1-1-4-the-sha256-hash-of-a-cell).
- Finally, $r$ references to other cells follow. Each reference is normally represented by 32 bytes containing the [SHA-256 hash of the referenced cell](#1-1-4-the-sha256-hash-of-a-cell) computed.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link doesn't work

Screenshot 0007-12-01 at 14 00 40

@@ -102,7 +102,7 @@ Signatures are an excellent example of the application of representation hashes.

### 1.1.10. Higher hashes of a cell

In addition to the transparent and representation hashes of a cell $c$, a sequence of *higher hashes* $\text{Hash}_i(c)$, $i=1,2,\dots$ may be defined, which eventually stabilizes at $\text{Hash}_\infty(c)$. (More detail may be found in [[4](#ref-4), 3.1].)
In addition to the transparent and representation hashes of a cell $c$, a sequence of [*higher hashes*](/foundations/whitepapers/tvm#3-1-generalities-on-cells) $\text{Hash}_i(c)$, $i=1,2,\dots$ may be defined, which eventually stabilizes at $\text{Hash}_\infty(c)$.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't see why the original higher hash link leads to 3.1 of TVM; the reader may also be confused. As for me, 3.1.5 or 3.1.6 TVM works better as a reference for explanation.

cc @verytactical
Screenshot 0007-12-01 at 14 11 23

@@ -163,15 +163,15 @@ Originally, each outbound message is included into *OutMsgQueue*; it is removed

### 1.2.8. Layout of *InMsgDescr*, *OutMsgDescr* and *OutMsgQueue*

All of the most important non-split shardchain data structures related to messages are organized as *hashmaps* or *dictionaries* (implemented by means of Patricia trees serialized into a tree of cells as described in [[4](#ref-4), 3.3]), with the following keys:
All of the most important non-split shardchain data structures related to messages are organized as *hashmaps* or *dictionaries* (implemented by means of [Patricia trees](/foundations/whitepapers/tvm#3-3-hashmaps,-or-dictionaries) serialized into a tree of cells), with the following keys:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.3.2 of TVM seems better as an accurate reference for [Patricia trees].

Screenshot 0007-12-01 at 14 25 38

@@ -198,7 +198,7 @@ The account state itself approximately consists of the following data:
- Its *storage usage statistics*, including the number of cells and bytes kept in the persistent storage of the smart contract (i.e., inside the blockchain state) and the last time a storage usage payment was exacted from this account.
- An optional *formal interface description* (intended for smart contracts) and/or *user public information* (intended mostly for human users and organizations).

Notice that there is no distinction between "smart contract" and "account" in the TON Blockchain. Instead, "simple" or "wallet" accounts, typically employed by human users and their cryptocurrency wallet applications for simple cryptocurrency transfers, are just simple smart contracts with standard (shared) code and with persistent data consisting of the public key of the wallet (or several public keys in the case of a multi-signature wallet; cf. [1.7.6](#1-7-6-example%3A-creating-a-cryptocurrency-wallet-smart-contract) for more detail).
Notice that there is no distinction between "smart contract" and "account" in the TON Blockchain. Instead, "simple" or "wallet" accounts, typically employed by human users and their cryptocurrency wallet applications for simple cryptocurrency transfers, are just simple smart contracts with standard (shared) code and with persistent data consisting of the public key of the wallet (or several public keys in the case of a [multi-signature wallet](#1-7-6-example%3A-creating-a-cryptocurrency-wallet-smart-contract)).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The link should be set on the regular "wallet", since the example is a regular wallet

Screenshot 0007-12-01 at 14 31 12

@@ -273,11 +273,11 @@ Of course, the "witness" value $f(x):Y$ may be included inside the (modified) da

### 1.3.8. Example: consistency condition for *InMsgDescr*

For instance, the consistency condition between $X:=\textit{InMsgDescr}$, the list of all inbound messages processed in a block, and $Y:=\textit{Transactions}$, the list of all transactions present in a block, is of the above sort: "For any input message $x$ present in *InMsgDescr*, a transaction $y$ must be present in the block such that $y$ processes $x$".<sup>[8](#fn8)</sup> The procedure of $\exists$-elimination described in [1.3.7](#1-3-7-constructive-elimination-of-existence-quantifiers) leads us to introduce an additional field in the inbound message descriptors of *InMsgDescr*, containing a reference to the transaction in which the message is actually processed.
For instance, the consistency condition between $X:=\textit{InMsgDescr}$, the list of all inbound messages processed in a block, and $Y:=\textit{Transactions}$, the list of all transactions present in a block, is of the above sort: "For any input message $x$ present in *InMsgDescr*, a transaction $y$ must be present in the block such that $y$ processes $x$".<a id="ref-fn8"></a><sup>[8](#fn8)</sup> The procedure of [$\exists$-elimination](#1-3-7-constructive-elimination-of-existence-quantifiers) leads us to introduce an additional field in the inbound message descriptors of *InMsgDescr*, containing a reference to the transaction in which the message is actually processed.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Broken link in the section 1.3.7, whether ommit this or fix this:
Screenshot 0007-12-01 at 14 35 15


In most cases when we need to assign logical time intervals, we use the minimal logical time intervals just described.

### 1.4.6. Logical time in the TON Blockchain

The TON Blockchain assigns logical time and logical time intervals to several of its components.

For instance, each outbound message created in a transaction is assigned its *logical creation time*; for this purpose, the creation of an outbound message is considered an atomic event, logically dependent on the previous message created by the same transaction, as well as on the previous transaction of the same account, on the inbound message processed by the same transaction, and on all events contained in the blocks referred to by hashes contained in the block with the same transaction. As a consequence, *outbound messages created by the same smart contract have strictly increasing logical creation times*. The transaction itself is considered a collection of atomic events, and is assigned a logical time interval (cf. [4.2.1](#4-2-1-logical-time-of-a-transaction) for a more precise description).
For instance, each outbound message created in a transaction is assigned its *logical creation time*; for this purpose, the creation of an outbound message is considered an atomic event, logically dependent on the previous message created by the same transaction, as well as on the previous transaction of the same account, on the inbound message processed by the same transaction, and on all events contained in the blocks referred to by hashes contained in the block with the same transaction. As a consequence, *outbound messages created by the same smart contract have strictly increasing logical creation times*. The transaction itself is considered a collection of atomic events, and is assigned a [logical time](#4-2-1-logical-time-of-a-transaction) interval.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link text should be a [logical time interval]. Link should lead to the logical time interval (1.4.3. Logical time intervals)

cc @verytactical
Screenshot 0007-12-01 at 14 46 43

@@ -446,7 +446,7 @@ In particular, when we say that a block *must* import in its *InMsgDescr* the me

## 1.6 Configurable parameters and smart contracts

Recall that the TON Blockchain has several so-called "configurable parameters" (cf. [[3](#ref-3)]), which are either certain values or certain smart contracts residing in the masterchain. This section discusses the storage of and access to these configurable parameters.
Recall that the TON Blockchain has several so-called ["configurable parameters"](/foundations/whitepapers/ton), which are either certain values or certain smart contracts residing in the masterchain. This section discusses the storage of and access to these configurable parameters.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we provide a more specific link or delete this? It seems just as extra confusion, redirecting to the entire whitepaper under the "configurable parameters" link text.

Screenshot 0007-12-01 at 14 51 31

@@ -964,13 +966,13 @@ nanograms$_ amount:(VarUInteger 16) = Grams;

If one wants to represent $x$ nanograms, one selects an integer $\ell<16$ such that $x<2^{8\ell}$, and serializes first $\ell$ as an unsigned 4-bit integer, then $x$ itself as an unsigned $8\ell$-bit integer. Notice that four zero bits represent a zero amount of Grams.

Recall (cf. [[3, A](#ref-3)]) that the original total supply of Grams is fixed at five billion (i.e., $5\cdot10^{18}<2^{63}$ nanograms), and is expected to grow very slowly. Therefore, all the amounts of Grams encountered in practice will fit in unsigned or even signed 64-bit integers. The validators may use the 64-bit integer representation of Grams in their internal computations; however, the serialization of these values the blockchain is another matter.
Recall that the original total supply of [Grams](/foundations/whitepapers/ton#a-the-ton-coin-or-the-gram) is fixed at five billion (i.e., $5\cdot10^{18}<2^{63}$ nanograms), and is expected to grow very slowly. Therefore, all the amounts of Grams encountered in practice will fit in unsigned or even signed 64-bit integers. The validators may use the 64-bit integer representation of Grams in their internal computations; however, the serialization of these values the blockchain is another matter.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Broken link [Grams]
Screenshot 0007-12-01 at 15 04 17

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cross-link tblkch.pdf

4 participants