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

ec clarifications and updates #334

Merged
merged 8 commits into from
Jul 16, 2019
Merged

ec clarifications and updates #334

merged 8 commits into from
Jul 16, 2019

Conversation

bvohaska
Copy link
Contributor

Updates to definitions, ticket generation, and electionProof generation

@sternhenri
Copy link
Contributor

@pooja review plz :D

@sternhenri sternhenri requested a review from pooja July 10, 2019 18:05
Copy link
Contributor

@sternhenri sternhenri left a comment

Choose a reason for hiding this comment

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

touched up for recent changes

A ticket is a shared random value stapled to a particular block in the chain. Every miner must produce a new ticket each time they run a leader election attempt. In that sense, every new block produced will have one or more associated tickets (in the case the block took multiple leader election attempts to produce).

```go
type Ticket struct {
Copy link
Contributor

Choose a reason for hiding this comment

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

please update this to the new IPLD schema syntax

Copy link
Contributor

Choose a reason for hiding this comment

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

Holding off on specifying methods and the like for now, if that is what is meant...


```go
type ElectionProof struct {
TODO HS
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe make it a bit more clear that this is not an actual field 😆

definitions.md Outdated
@@ -101,6 +105,12 @@ The Generation Attack Threshold is equal to the Polling Time + some Grace Period

#### GHOST

GHOST is an acronym for `Greedy Heaviest Observable SubTree`, a class of blockchain structures in which multiple blocks can validly be included in the chain at any given height or round. GHOSTy protocols produce blockDAGs rather than blockchains and use a weighting function for fork selection, rather than simply picking the longest chain.
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe a link to a reference?


#### Height

`Height` refers to the number of `TipSets` that have passed between this `TipSet` and the genesis block (which starts at block height 0). If a `TipSet` contains multiple blocks, each block in the TipSet will have the same `height`.
Copy link
Contributor

Choose a reason for hiding this comment

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

please say how this interacts with null blocks here

Copy link
Member

Choose a reason for hiding this comment

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

FWIW the go-filecoin code, and everyones intuitions, say that "height" is the number of rounds, not the number of tipsets. We'll be swimming upstream to redefine that here. At present, the code doesn't have a use for a count of the non-null tips.

Copy link
Contributor

Choose a reason for hiding this comment

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

to be handled in a different PR per #351

definitions.md Outdated
@@ -203,7 +217,9 @@ Repair refers to the processes and protocols by which the Filecoin network ensur

#### Round

A round refers to the period over which a new leader election occurs and a block is generated if a leader is found. Typically this means a new block will be mined at every round, though some rounds may see 0 or multiple blocks generated.
A round refers to the period over which a new leader election occurs and a block is generated if a leader is found. Typically this means a new block will be mined at every round, though
Copy link
Contributor

Choose a reason for hiding this comment

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

missing . at the end

definitions.md Outdated
- to elect a leader in Expected Consensus.

See more on [Expected Consensus](expected-consensus.md) and [PoSTs](proofs.md).
A `ticket` is used as a source of randomness in EC leader election. Every block depends on an `ElectionProof` derived from a `ticket`. At least one new `ticket` is produced with every new block. Ticket creation will be described [here](./expected-consensus.md#Ticket-generation).
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe "is described here"?

definitions.md Outdated

#### TipSet

A collection of blocks mined by different miners, each an elected leader of a given epoch. All tip sets have the same parent-set and epoch number (height). TODO add picture.
A `TipSet` is a set of blocks that have the same parent set and same number of `tickets`, which implies they will have been mined at the same `height`. A `TipSet` can contain multiple blocks if more than one miner successfully mines a block at the same `height` as another miner. `TipSets` contain 1 or more blocks (i.e. null blocks are not included in `TipSets`).
Copy link
Contributor

Choose a reason for hiding this comment

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

This is a bit circular Above it says that height is the number of tipsets passed since genesis, and here it is tipset are the blocks with the same height.

Copy link
Contributor

Choose a reason for hiding this comment

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

i.e. null blocks are not included in TipSets

then where are they included? aren't they part of the block technically?

Copy link
Contributor

Choose a reason for hiding this comment

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

Disagree with circularity. The circular bit is just a reframing that helps cement what height is here. Re null blocks, removed. Confusing bit. A Tipset can never include just a null block, they are indeed included as part of the block, technically (through the ticket array).

Null blocks is a confusing concept overall we should get rid of.

definitions.md Outdated

#### Verifiable

Something that is verifiable can be checked for correctness by a third party.

#### VDF

A verifiable function that guarantees a time delay given some hardware assumptions and a small set of requirements. These requirements are efficient proof verification, random output, and strong sequentiality. Verifiable delay functions are formally defined [here](https://eprint.iacr.org/2018/601). A VDF will receive {set of public parameters (similar to [these](https://eprint.iacr.org/2018/712.pdf)), seed} and output {proof of correctness, output value}.
Copy link
Contributor

Choose a reason for hiding this comment

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

maybe add the title of these publications?

Copy link
Contributor

Choose a reason for hiding this comment

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

also the use of curly braces is very confusing

@@ -1,70 +1,42 @@
# Expected Consensus
# Expected Consensus
Copy link
Contributor

Choose a reason for hiding this comment

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

too much space ;)

@dignifiedquire dignifiedquire changed the title bvohaska/ec ec clarifications and updates Jul 11, 2019
@sternhenri
Copy link
Contributor

sternhenri commented Jul 12, 2019 via email

@dignifiedquire dignifiedquire merged commit 2b7f902 into master Jul 16, 2019
@dignifiedquire dignifiedquire deleted the bvohaska/ec branch July 16, 2019 17:26
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.

4 participants