Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: data square layout specs update part 1 #1905

Merged
merged 9 commits into from
Jun 16, 2023

Conversation

evan-forbes
Copy link
Member

Overview

closes #1606, although I still think there is work to update this portion of the specs. I didn't want to leap to that yet, so I've limited the changes here to mostly updating to the new non-interaction rules

Checklist

  • New and updated code has appropriate documentation
  • New and updated code has new and/or updated testing
  • Required CI checks are passing
  • Visual proof for any user facing features like CLI or documentation updates
  • Linked issues closed with keywords

@evan-forbes evan-forbes added the specs directly relevant to the specs label Jun 12, 2023
@evan-forbes evan-forbes self-assigned this Jun 12, 2023
@MSevey MSevey requested a review from a team June 12, 2023 02:00
@github-actions
Copy link

github-actions bot commented Jun 12, 2023

PR Preview Action v1.4.4
🚀 Deployed preview to https://celestiaorg.github.io/celestia-app/pr-preview/pr-1905/
on branch gh-pages at 2023-06-15 19:34 UTC

@codecov-commenter
Copy link

codecov-commenter commented Jun 12, 2023

Codecov Report

Merging #1905 (1948b44) into main (b370d72) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    celestiaorg/celestia-app#1905   +/-   ##
=======================================
  Coverage   21.21%   21.21%           
=======================================
  Files         120      120           
  Lines       13695    13695           
=======================================
  Hits         2905     2905           
  Misses      10500    10500           
  Partials      290      290           
Impacted Files Coverage Δ
pkg/shares/non_interaction_rules.go 100.00% <ø> (ø)

@MSevey MSevey requested a review from a team June 12, 2023 14:42
specs/src/specs/block_proposer.md Show resolved Hide resolved
@@ -37,16 +36,16 @@ Specifically, blobs must begin at a new share. We note a nice property from this

This, however, requires the block producer to interact with the transaction sender to provide them the starting location of their blob, so that the sender can sign over the commitment based on that starting location. This can be done selectively, but is not ideal as a default for e.g. end-user wallets.

### Non-Interactive Default Rules
### Non-Interaction Rules
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
### Non-Interaction Rules
### Share Commitment Rules

or Blob Commitment Rules

Copy link
Collaborator

@rootulp rootulp Jun 13, 2023

Choose a reason for hiding this comment

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

[not blocking] or Blob Share Commitment Rules 🙂

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah I'm a fan of that

Copy link
Member Author

Choose a reason for hiding this comment

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

cc also curious what @adlerjohn thinks about the name

we've changed them to "Blob Share Commitment Rules" for now. Personally, I'd opt for something like "Blob Layout Rules" or just "Blob Commitment Rules", but bscr are suitable as well

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not too picky though, whatever people can get behind I'm good with

specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
specs/src/specs/shares.md Show resolved Hide resolved
rootulp
rootulp previously approved these changes Jun 13, 2023
specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
specs/src/specs/data_square_layout.md Outdated Show resolved Hide resolved
@cmwaters
Copy link
Contributor

I'm just going to pick this up (hope that's okay @evan-forbes)

Co-authored-by: Rootul P <rootulp@gmail.com>
cmwaters
cmwaters previously approved these changes Jun 15, 2023
@cmwaters
Copy link
Contributor

Meta comment here: In all honesty, you probably should not be able to approve a PR that you made commits too but whatever

@evan-forbes evan-forbes enabled auto-merge (squash) June 15, 2023 11:48
MSevey
MSevey previously approved these changes Jun 15, 2023

We want to arrange this data into a `k * k` matrix of fixed-sized shares, which will later be committed to in [Namespace Merkle Trees (NMTs)](../specs/data_structures.md#namespace-merkle-tree) so that individual shares in this matrix can be proven to belong to a single data root.
We want to arrange this data into a `k * k` matrix of fixed-sized [shares](../specs/shares.md), which will later be committed to in [Namespace Merkle Trees (NMTs)](https://github.com/celestiaorg/nmt/blob/v0.16.0/docs/spec/nmt.md) so that individual shares in this matrix can be proven to belong to a single data root.
Copy link
Collaborator

Choose a reason for hiding this comment

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

[no change needed][question] for consistency, should we refer to it as "Namepsace" or "Namespaced" Merkle Trees?

https://github.com/celestiaorg/nmt README says "Namespaced" but TBH I prefer "Namespace"

Copy link
Member Author

Choose a reason for hiding this comment

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

I'm good with either, but the LL paper uses "namespaced"


This is similar to [Merkle Mountain Ranges](https://www.usenix.org/legacy/event/sec09/tech/full_papers/crosby.pdf), though with the largest subtree bounded by the blob minimum square size rather than being unbounded.
In the constraint mentioned above, the number of rows/columns in the minimum square size should be a power of 2.
Copy link
Collaborator

Choose a reason for hiding this comment

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

[question] is this line still applicable? There is no reference to minimum square size above

Copy link
Member Author

Choose a reason for hiding this comment

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

resolved in bfa854b


Receiving a `MsgWirePayForData` object from the network follows the reverse process: verify using the [non-interactive default rules](../rationale/data_square_layout.md#non-interactive-default-rules) that the signature is valid.
Receiving a `MsgWirePayForData` object from the network follows the reverse process: verify using the [non-interaction rules](../specs/data_square_layout.md#non-interaction-rules) that the signature is valid.
Copy link
Collaborator

@rootulp rootulp Jun 15, 2023

Choose a reason for hiding this comment

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

[blocking][question] if we're renaming non-interactive default rules to non-interaction default rules, should we do a global find + replace of the codebase in this PR?

Copy link
Member Author

Choose a reason for hiding this comment

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

good point 2a24af8

Copy link
Member Author

Choose a reason for hiding this comment

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

I didn't touch the ADRs as there are an insane number of references, although we might want to in the future

Copy link
Contributor

@cmwaters cmwaters Jun 16, 2023

Choose a reason for hiding this comment

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

I thought we were going to rename it from non-interactive default rules to blob share commitment rules 🙃

@evan-forbes evan-forbes dismissed stale reviews from MSevey and cmwaters via 2a24af8 June 15, 2023 19:34
@MSevey MSevey requested a review from a team June 15, 2023 19:34
@evan-forbes
Copy link
Member Author

there were some merge conflicts, so I went ahead and updated them along with feedback from Rootul

Copy link
Contributor

@cmwaters cmwaters left a comment

Choose a reason for hiding this comment

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


Nooice

@MSevey MSevey requested a review from a team June 16, 2023 14:33
@evan-forbes evan-forbes merged commit 922cdf6 into main Jun 16, 2023
@evan-forbes evan-forbes deleted the evan/data-square-layout-specs-part-1 branch June 16, 2023 15:06
evan-forbes added a commit that referenced this pull request Jul 3, 2023
* docs: data square layout part 1

* docs: add power of 2 note

* Apply suggestions from code review

Co-authored-by: Rootul P <rootulp@gmail.com>

---------

Co-authored-by: Callum Waters <cmwaters19@gmail.com>
Co-authored-by: Rootul P <rootulp@gmail.com>
evan-forbes added a commit that referenced this pull request Jul 3, 2023
* docs: data square layout part 1

* docs: add power of 2 note

* Apply suggestions from code review

Co-authored-by: Rootul P <rootulp@gmail.com>

---------

Co-authored-by: Callum Waters <cmwaters19@gmail.com>
Co-authored-by: Rootul P <rootulp@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
specs directly relevant to the specs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update the non-interative default rules to reflect the changes from ADR013
5 participants