From 5168f741b280140ff2d37f43c2b26627321bc3e9 Mon Sep 17 00:00:00 2001 From: krofax Date: Mon, 6 Jan 2025 17:04:46 +0100 Subject: [PATCH 1/6] cleaned up kona guide --- pages/chain/identity/individuals.mdx | 2 +- pages/chain/identity/projects.mdx | 2 +- pages/stack/fault-proofs.mdx | 4 +- pages/stack/fault-proofs/_meta.json | 1 + pages/stack/fault-proofs/cannon.mdx | 4 +- pages/stack/fault-proofs/explainer.mdx | 9 ++- pages/stack/fault-proofs/kona.mdx | 106 +++++++++++++++++++++++++ pages/stack/fault-proofs/mips.mdx | 2 +- words.txt | 12 +++ 9 files changed, 134 insertions(+), 8 deletions(-) create mode 100644 pages/stack/fault-proofs/kona.mdx diff --git a/pages/chain/identity/individuals.mdx b/pages/chain/identity/individuals.mdx index b7b234e86..85a23cb34 100644 --- a/pages/chain/identity/individuals.mdx +++ b/pages/chain/identity/individuals.mdx @@ -25,6 +25,6 @@ When you make attestations about individuals: * Leave the recipient address blank * Enter the users id into the attestation metadata -### Further reading +### Next steps For more details on individual identity in the Optimism Collective, refer to **[the governance docs](https://community.optimism.io/docs/identity/project-and-individual-identity-in-the-collective/#building-a-digital-identity)** on building a digital identity. diff --git a/pages/chain/identity/projects.mdx b/pages/chain/identity/projects.mdx index 98ae2a849..badeda028 100644 --- a/pages/chain/identity/projects.mdx +++ b/pages/chain/identity/projects.mdx @@ -20,6 +20,6 @@ All other project metadata is stored or referenced in the [Project Metadata Atte * The Project Metadata Attestation is re-issued whenever there's a change in metadata. * Apps displaying project metadata should refer to the most recent attestation for up-to-date information. -## Further reading +## Next steps For more information about identity in the Optimism Collective, see the [Identity Overview](/chain/identity/overview.mdx). diff --git a/pages/stack/fault-proofs.mdx b/pages/stack/fault-proofs.mdx index 4da08bb26..5e47ffd6b 100644 --- a/pages/stack/fault-proofs.mdx +++ b/pages/stack/fault-proofs.mdx @@ -8,11 +8,13 @@ import { Card, Cards } from 'nextra/components' # Fault Proofs -Documentation covering Cannon, Challenger, Explainer, Fp Components, Fp Security, Mips in the Fault Proofs section of the OP Stack ecosystem. +Documentation covering Cannon, Kano Challenger, Explainer, Fp Components, Fp Security, Mips in the Fault Proofs section of the OP Stack ecosystem. + + diff --git a/pages/stack/fault-proofs/_meta.json b/pages/stack/fault-proofs/_meta.json index 0bf43dd6e..c53db0534 100644 --- a/pages/stack/fault-proofs/_meta.json +++ b/pages/stack/fault-proofs/_meta.json @@ -2,6 +2,7 @@ "explainer": "Fault proofs explainer", "fp-components": "FP system components", "cannon": "FPVM: Cannon", + "kona": "FPVM: Kona", "challenger": "OP-Challenger", "mips": "MIPS.sol", "fp-security": "FP Mainnet security" diff --git a/pages/stack/fault-proofs/cannon.mdx b/pages/stack/fault-proofs/cannon.mdx index 4ad45ea78..a4f3a1e8c 100644 --- a/pages/stack/fault-proofs/cannon.mdx +++ b/pages/stack/fault-proofs/cannon.mdx @@ -203,7 +203,7 @@ As mentioned previously, Cannon is responsible for setting up all state that may Cannon is also responsible for interacting with the PreimageOracle Server, and directing OP-Challenger to provide Pre-images to the onchain `PreimageOracle.sol` if necessary for the instruction that will be run in `MIPS.sol`. -The PreimageOracle Server connection is instantiated in `run.go`, where the server itself is run locally with its own local Key-Value store. +The `PreimageOracle` Server connection is instantiated in `run.go`, where the server itself is run locally with its own local Key-Value store. `mips.go` communicates with the PreimageOracle Server when reading and writing Pre-images as part of MIPS syscall instructions, as well as hinting to the PreimageOracle Server. @@ -215,7 +215,7 @@ This ABI is implemented by the VM by intercepting the `read`/`write` syscalls to Note that although the oracle provides up to 32 bytes of the pre-image, Cannon only supports reading at most 4 bytes at a time, to unify the memory operations with 32-bit load/stores. -## Further Reading +## Next steps * [Cannon FPVM Specification](https://specs.optimism.io/experimental/fault-proof/cannon-fault-proof-vm.html) * [Merkle Proofs Specification](https://github.com/ethereum/consensus-specs/blob/dev/ssz/merkle-proofs.md) diff --git a/pages/stack/fault-proofs/explainer.mdx b/pages/stack/fault-proofs/explainer.mdx index 3afad066f..665f3e8f8 100644 --- a/pages/stack/fault-proofs/explainer.mdx +++ b/pages/stack/fault-proofs/explainer.mdx @@ -76,7 +76,6 @@ As a result, the trust assumption is reduced to requiring only that the Guardian It's not expected that normal users run `op-proposer` to regularly propose output roots. Users would generally just propose a single output root if they need to withdraw and the chain operator isn't proposing outputs for them via direct calls to the `DisputeGameFactory` via Etherscan or using the [`create-game`](https://github.com/ethereum-optimism/optimism/tree/develop/op-challenger#create-game) subcommand of `op-challenger`. -Documentation for `op-challenger` is forthcoming. ### How much ETH should a chain operator put aside to operate the Fault Proof System? @@ -100,4 +99,10 @@ The list-claims subcommand of op-challenger can also provide a good view of the ./op-challenger/bin/op-challenger list-claims --l1-eth-rpc --game-address 0xcf8f181497DAD07277781517A76cb131C54A1BEE ``` -See the [specs](https://specs.optimism.io/experimental/fault-proof/stage-one/bond-incentives.html) for more details. +## Next steps + +* For more info about how fault proofs works under the hood, + [check out the specs](https://specs.optimism.io/experimental/fault-proof/stage-one/bond-incentives.html). +* Read the explainer guide on [op-challenger](/challenger). +* Read the explainer guide on [cannon](/cannon). +* Read about the [components of the fault proof](/fp-components) system and how they work together to enhance decentralization. diff --git a/pages/stack/fault-proofs/kona.mdx b/pages/stack/fault-proofs/kona.mdx new file mode 100644 index 000000000..fcb205c38 --- /dev/null +++ b/pages/stack/fault-proofs/kona.mdx @@ -0,0 +1,106 @@ +--- +title: "Fault proof VM - Kona" +lang: en-US +sidebar_label: "FPVM: Kona" +description: "KLearn about Kona and its default operation as part of Optimism's Fault Proof Virtual Machine." +--- + +# FPVM: Kona + +Kona is an alternative fault-proof program for the OP Stack, providing a Rust-based implementation to complement the Asterisc fault-proof VM. Together, they form an equivalent system to Cannon and op-program but with distinct architectural and implementation differences. + + +## Overview + +Kona works as the fault-proof program within the Asterisc fault-proof system. It operates by executing program logic step-by-step and generating commitments for every state transition. These commitments allow disputing parties to identify and resolve divergences in execution traces through interactive fraud proofs. + +Key features of Kona include: + +* **Written in Rust:** High performance and memory safety. +* **Optimized for Asterisc:** Specifically tailored to work with the Asterisc RISC-V-based fault-proof VM. +* **Deterministic Execution:** Ensures consistency in state transitions during disputes. + +Kona + Asterisc is analogous to Cannon + op-program, providing an alternative pathway to secure optimistic rollups. + +## Relationship to Asterisc + +Kona is designed to: + +* Complement Asterisc, which serves as the RISC-V fault-proof VM. +* Validate execution traces using the interactive fraud-proof mechanism. +* Offer an alternative to the Cannon + op-program system, leveraging Rust and RISC-V for distinct performance characteristics. + +For more on Asterisc, see the [Asterisc documentation](./asterisc.mdx). + + + +## Key Differences + +### Architecture + +| System | Fault-Proof VM | Fault-Proof Program | Language | Architecture | +| ------------------- | -------------- | ------------------- | -------- | ------------ | +| Asterisc + Kona | Asterisc | Kona | Rust | RISC-V | +| Cannon + op-program | Cannon | op-program | Go | MIPS | + +### Performance + +* Kona benefits from Rust's memory safety and performance optimizations. +* Asterisc uses RISC-V, offering a simpler and more adaptable instruction set. + +## Getting Started + +To set up and use Kona, follow these steps: + +1. **Clone the Repository:** + ```bash + git clone https://github.com/anton-rs/kona.git + cd kona + ``` + +2. **Install Dependencies:** + Ensure you have the Rust toolchain installed. Use `rustup` to set up Rust: + ```bash + curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh + rustup install stable + ``` + +3. **Compile the Program:** + Build the Kona fault-proof program: + ```bash + cargo build --release + ``` + +4. **Run Tests:** + Execute the test suite to verify your setup: + ```bash + cargo test + ``` + +5. **Explore Further Documentation:** + Check the [Kona repo docs](https://github.com/anton-rs/kona) for advanced usage and implementation details. + +## Benefits of Kona + +1. **Rust-Based Implementation:** + * Provides performance advantages and memory safety. + +2. **Integration with Asterisc:** + * Designed to fully utilize the RISC-V-based VM's capabilities. + +3. **Focused Functionality:** + * Tailored for the OP Stack's fault-proofing needs without additional complexity. + +## Limitations + +Kona is not a general-purpose program and is specifically designed for use within the Optimism fault-proofing stack. It does not support arbitrary RISC-V programs, focusing solely on its role as the fault-proof program for Asterisc. + +Kona is currently in the experimental stage. While it provides a functional alternative, it may lack the maturity and stability of Cannon + op-program. Users are encouraged to contribute to its development and provide feedback. + +## Next steps + +* [Kona Repository](https://github.com/anton-rs/kona) +* [Kona Book](https://anton-rs.github.io/kona/) +* [Asterisc Documentation](./asterisc) +* [Optimism Fault-Proofs Explainer](/explainer) +* [Cannon Documentation](./cannon) diff --git a/pages/stack/fault-proofs/mips.mdx b/pages/stack/fault-proofs/mips.mdx index 3623ae991..b5e947fe4 100644 --- a/pages/stack/fault-proofs/mips.mdx +++ b/pages/stack/fault-proofs/mips.mdx @@ -253,7 +253,7 @@ The internal pure [`execute`](https://github.com/ethereum-optimism/optimism/blob | SC (Store Conditional Word) | 0x38 | - | - | | SYNC (Synchronize Shared Memory) | 0x00 | 0x0F | - | -## Further reading +## Next steps * [Cannon Overview](https://github.com/ethereum-optimism/optimism/blob/546fb2c7a5796b7fe50b0b7edc7666d3bd281d6f/cannon/docs/README.md) * [Cannon FPVM Specification](https://specs.optimism.io/experimental/fault-proof/cannon-fault-proof-vm.html) diff --git a/words.txt b/words.txt index 824d2acb0..04e763600 100644 --- a/words.txt +++ b/words.txt @@ -10,8 +10,10 @@ Allnodes Allocs allocs ANDI +Ankr Apeworx Arweave +Asterisc authrpc Badgeholder's Badgeholders @@ -150,6 +152,7 @@ holesky IERC IGNOREPRICE ignoreprice +Immunefi implicity Inator inator @@ -171,6 +174,8 @@ JSPATH jspath jwtsecret Keccak +Kona +kona leveldb lightkdf logfile @@ -199,6 +204,7 @@ minsuggestedpriorityfee Mintable Mintplex MIPSEVM +Mitigations Monitorism Moralis Mordor @@ -296,6 +302,8 @@ Proxied Proxyd proxyd pseudorandomly +Pyth +Pyth's QRNG Quicknode quicknode @@ -330,6 +338,9 @@ runbooks RWAs safedb Schnorr +SEPOLIA +Sepolia +sepolia seqnr SEQUENCERHTTP sequencerhttp @@ -403,6 +414,7 @@ VMDEBUG vmdebug VMODULE vmodule +voxel Warpcast xlarge XORI From b2e7f567faae478a04d624b4fb754eb4f2271eb6 Mon Sep 17 00:00:00 2001 From: krofax Date: Mon, 6 Jan 2025 17:19:38 +0100 Subject: [PATCH 2/6] fix broken links --- pages/stack/fault-proofs/kona.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/stack/fault-proofs/kona.mdx b/pages/stack/fault-proofs/kona.mdx index fcb205c38..382f05347 100644 --- a/pages/stack/fault-proofs/kona.mdx +++ b/pages/stack/fault-proofs/kona.mdx @@ -101,6 +101,6 @@ Kona is currently in the experimental stage. While it provides a functional alte * [Kona Repository](https://github.com/anton-rs/kona) * [Kona Book](https://anton-rs.github.io/kona/) -* [Asterisc Documentation](./asterisc) -* [Optimism Fault-Proofs Explainer](/explainer) +* [Optimism Fault-Proofs Explainer](./explainer) * [Cannon Documentation](./cannon) +{/* * [Asterisc Documentation](./asterisc) */} From 60929d86611b8dc6ce6c0d09abae92e1c748d1e5 Mon Sep 17 00:00:00 2001 From: Blessing Krofegha Date: Mon, 6 Jan 2025 17:20:32 +0100 Subject: [PATCH 3/6] Update pages/stack/fault-proofs/kona.mdx Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --- pages/stack/fault-proofs/kona.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/stack/fault-proofs/kona.mdx b/pages/stack/fault-proofs/kona.mdx index 382f05347..16dfa8fd7 100644 --- a/pages/stack/fault-proofs/kona.mdx +++ b/pages/stack/fault-proofs/kona.mdx @@ -2,7 +2,7 @@ title: "Fault proof VM - Kona" lang: en-US sidebar_label: "FPVM: Kona" -description: "KLearn about Kona and its default operation as part of Optimism's Fault Proof Virtual Machine." +description: "Learn about Kona and its default operation as part of Optimism's Fault Proof Virtual Machine." --- # FPVM: Kona From 78b8a33265a2767765aeb956111b756857b3a5e1 Mon Sep 17 00:00:00 2001 From: Blessing Krofegha Date: Mon, 6 Jan 2025 17:22:45 +0100 Subject: [PATCH 4/6] Update pages/stack/fault-proofs/explainer.mdx Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --- pages/stack/fault-proofs/explainer.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pages/stack/fault-proofs/explainer.mdx b/pages/stack/fault-proofs/explainer.mdx index 665f3e8f8..b11e74b7e 100644 --- a/pages/stack/fault-proofs/explainer.mdx +++ b/pages/stack/fault-proofs/explainer.mdx @@ -103,6 +103,6 @@ The list-claims subcommand of op-challenger can also provide a good view of the * For more info about how fault proofs works under the hood, [check out the specs](https://specs.optimism.io/experimental/fault-proof/stage-one/bond-incentives.html). -* Read the explainer guide on [op-challenger](/challenger). -* Read the explainer guide on [cannon](/cannon). -* Read about the [components of the fault proof](/fp-components) system and how they work together to enhance decentralization. +* Learn how to use [op-challenger](/stack/fault-proofs/challenger) to participate in the dispute process. +* Explore the [cannon](/stack/fault-proofs/cannon) fault proof system implementation. +* Understand the [components of the fault proof](/stack/fault-proofs/fp-components) system and their role in enhancing decentralization. From 0e9eea94b3e36e2d3f335a7a268bc3d84bf3cf3a Mon Sep 17 00:00:00 2001 From: Blessing Krofegha Date: Mon, 6 Jan 2025 17:23:23 +0100 Subject: [PATCH 5/6] Update pages/stack/fault-proofs/explainer.mdx Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --- pages/stack/fault-proofs/explainer.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/stack/fault-proofs/explainer.mdx b/pages/stack/fault-proofs/explainer.mdx index b11e74b7e..9f3f397da 100644 --- a/pages/stack/fault-proofs/explainer.mdx +++ b/pages/stack/fault-proofs/explainer.mdx @@ -102,7 +102,7 @@ The list-claims subcommand of op-challenger can also provide a good view of the ## Next steps * For more info about how fault proofs works under the hood, - [check out the specs](https://specs.optimism.io/experimental/fault-proof/stage-one/bond-incentives.html). + [check out the specs](https://specs.optimism.io/fault-proof/index.html). * Learn how to use [op-challenger](/stack/fault-proofs/challenger) to participate in the dispute process. * Explore the [cannon](/stack/fault-proofs/cannon) fault proof system implementation. * Understand the [components of the fault proof](/stack/fault-proofs/fp-components) system and their role in enhancing decentralization. From e44c215ab3869b592baf050c680e410e344f5841 Mon Sep 17 00:00:00 2001 From: krofax Date: Mon, 6 Jan 2025 18:58:09 +0100 Subject: [PATCH 6/6] update title cases --- pages/stack/fault-proofs/kona.mdx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pages/stack/fault-proofs/kona.mdx b/pages/stack/fault-proofs/kona.mdx index 382f05347..1a4dd494e 100644 --- a/pages/stack/fault-proofs/kona.mdx +++ b/pages/stack/fault-proofs/kona.mdx @@ -34,7 +34,7 @@ For more on Asterisc, see the [Asterisc documentation](./asterisc.mdx). -## Key Differences +## Key differences ### Architecture @@ -48,11 +48,11 @@ For more on Asterisc, see the [Asterisc documentation](./asterisc.mdx). * Kona benefits from Rust's memory safety and performance optimizations. * Asterisc uses RISC-V, offering a simpler and more adaptable instruction set. -## Getting Started +## Getting started To set up and use Kona, follow these steps: -1. **Clone the Repository:** +1. **Clone the repository:** ```bash git clone https://github.com/anton-rs/kona.git cd kona @@ -65,7 +65,7 @@ To set up and use Kona, follow these steps: rustup install stable ``` -3. **Compile the Program:** +3. **Compile the program:** Build the Kona fault-proof program: ```bash cargo build --release @@ -77,7 +77,7 @@ To set up and use Kona, follow these steps: cargo test ``` -5. **Explore Further Documentation:** +5. **Explore further documentation:** Check the [Kona repo docs](https://github.com/anton-rs/kona) for advanced usage and implementation details. ## Benefits of Kona