Skip to content

Commit

Permalink
updated cdk docs formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchpolygon committed Dec 30, 2024
1 parent b744d8a commit dd3dbb9
Show file tree
Hide file tree
Showing 4 changed files with 144 additions and 161 deletions.
102 changes: 48 additions & 54 deletions docs/cdk/concepts/full-execution-proofs.md
Original file line number Diff line number Diff line change
@@ -1,83 +1,77 @@
## What Are Full Execution Proofs?
### What are Full Execution Proofs?

**Full Execution Proofs (FEP)** are zero-knowledge proofs that validate the correctness of a chain’s entire state transition. They ensure that the Virtual Machine (VM) underlying the chain (e.g., Polygon zkEVM, Succinct's zkVM, or MoveVM) executes state transitions in strict compliance with the protocol's specifications.
Full Execution Proofs (FEP) are zero-knowledge proofs that validate the correctness of a chain’s entire state transition. They ensure that the virtual machine (VM) underlying the chain (e.g., Polygon zkEVM, Succinct's zkVM, or MoveVM) executes state transitions in compliance with the protocol's specifications.

### Key Features of Full Execution Proofs:
- **Comprehensive Validation**: Verifies that all state transitions adhere to predefined rules.
- **Scalability**: Supports high-throughput applications in both rollup and validium modes.
- **Interoperability**: Facilitates seamless interactions across Layer 2 chains and with Ethereum Layer 1.
#### Key features:
- Comprehensive validation: Verifies that all state transitions adhere to predefined rules.
- Scalability: Supports high-throughput applications in both rollup and validium modes.
- Interoperability: Facilitates seamless interactions across Layer 2 chains and with Ethereum Layer 1.

By leveraging Full Execution Proofs, CDK configurations achieve scalability, security, and interoperability tailored to specific use cases.
By leveraging Full Execution Proofs, CDK configs achieve scalability, security, and interoperability tailored to specific use cases.

---

## Why Use Full Execution Proofs?
### Why use Full Execution Proofs?

- **Security**: Guarantees that all state transitions on the chain are executed correctly.
- **Flexibility**: Supports multiple configurations, including rollup and validium modes, balancing scalability and security.
- **Developer-Friendly**: Simplifies the process of building and deploying Layer 2 solutions with pre-built components.
- Security: Guarantees that all state transitions on the chain are executed correctly.
- Flexibility: Supports multiple configs, including rollup and validium modes, balancing scalability and security.
- Developer-friendly: Simplifies the process of building and deploying Layer 2 solutions with pre-built components.

Full Execution Proofs provide developers with the tools needed to build robust, secure, and interoperable Layer 2 chains.
Full Execution Proofs provide developers with tools to build robust, secure, and interoperable Layer 2 chains.

---

## How Full Execution Proofs Work
### How Full Execution Proofs work

Full Execution Proofs validate the entire state transition of a chain using cryptographic proofs. These proofs are generated by the chain’s prover and submitted to Ethereum Layer 1 for validation.

### Workflow:
1. **Transaction Submission**: Transactions are submitted to the chain’s sequencer.
2. **State Transition Execution**: The Virtual Machine (VM) executes all state transitions on the chain.
3. **Proof Generation**: The zkEVM Prover generates zero-knowledge proofs for the executed state transitions.
4. **Validation**: Proofs are submitted to Ethereum Layer 1, where they are verified for correctness.
#### Workflow:
1. Transaction submission: Transactions are sent to the chain’s sequencer.
2. State transition execution: The virtual machine executes all state transitions on the chain.
3. Proof generation: The prover generates zero-knowledge proofs for the executed state transitions.
4. Validation: Proofs are submitted to Ethereum Layer 1 for verification.

This workflow ensures that state transitions are secure, trustless, and fully validated.
This ensures that state transitions are secure, trustless, and fully validated.

---

## Architectural Components of CDK Configurations with FEP

The table below outlines the key components required for zk-rollup and validium configurations operating with Full Execution Proofs.
### Architectural components of CDK configs with FEP

| Component | Repository | Notes |
|--------------------------|---------------------------------------------------------------------------------------------|-------------------------------------------------------------|
| **Node (RPC and Sequencer)** | [cdk-erigon](https://github.com/0xPolygonHermez/cdk-erigon/releases) | Customizable; typically: <br>- Sequencer = 1 node <br>- RPC = multiple nodes |
| **zkEVM Prover (Hermes)** | [zkevm-prover](https://hub.docker.com/r/hermeznetwork/zkevm-prover/tags) | Generates zero-knowledge proofs |
| **Contracts** | [zkevm-contracts](https://github.com/0xPolygonHermez/zkevm-contracts) | Includes Layer 1 contracts for zk-rollup and validium functionality |
| **CLI Tool** | [cdk](https://github.com/0xPolygon/cdk/releases) | Simplifies deployment and configuration |
| **Transaction Pool Manager** | [zkevm-pool-manager](https://github.com/0xPolygon/zkevm-pool-manager) | Manages transaction storage |
| **Aggregator** | [cdk](https://github.com/0xPolygon/cdk/releases) | Combines multiple proofs for efficient validation |
| **Data Availability** | [cdk-data-availability](https://github.com/0xPolygon/cdk-data-availability) | Optional; used for validium configurations |
| Node (RPC and Sequencer) | [cdk-erigon](https://github.com/0xPolygonHermez/cdk-erigon/releases) | Customizable; typically:<br>- Sequencer = 1 node<br>- RPC = multiple nodes |
| Prover | [zkevm-prover](https://hub.docker.com/r/hermeznetwork/zkevm-prover/tags) | Generates zero-knowledge proofs |
| Contracts | [zkevm-contracts](https://github.com/0xPolygonHermez/zkevm-contracts) | Includes Layer 1 contracts for zk-rollup and validium functionality |
| CLI tool | [cdk](https://github.com/0xPolygon/cdk/releases) | Simplifies deployment and configuration |
| Transaction pool manager | [zkevm-pool-manager](https://github.com/0xPolygon/zkevm-pool-manager) | Manages transaction storage |
| Aggregator | [cdk](https://github.com/0xPolygon/cdk/releases) | Combines multiple proofs for efficient validation |
| Data availability | [cdk-data-availability](https://github.com/0xPolygon/cdk-data-availability) | Optional; used for validium configs |

---

## Component Descriptions

- **CDK Erigon Node**: A fork of [Erigon](https://github.com/ledgerwatch/erigon), responsible for:
- Managing multiple RPC nodes for transaction submission.
- Running a sequencer to execute transactions and create blocks and batches.
- **zkEVM Prover (Hermes)**: A cryptographic tool that generates zero-knowledge proofs for zk-rollup and validium configurations.
- **Contracts**: Smart contracts deployed on Ethereum Layer 1 to implement zk-rollup and validium functionality:
- `PolygonRollupManager`
- `PolygonZkEVMBridgeV2`
- `PolygonZkEVMGlobalExitRootV2`
- `FflonkVerifier`
- `PolygonZkEVMDeployer`
- `PolygonZkEVMTimelock`
- **CLI Tool**: Simplifies the deployment and configuration of CDK components through an intuitive command-line interface.
- **Transaction Pool Manager**: Stores and manages user-submitted transactions.
- **Aggregator**: Combines multiple proofs into a single proof for submission to Ethereum, optimizing the validation process.
- **Data Availability**: Ensures transaction data integrity; optional for validium configurations.
### Component descriptions

- Node (RPC and Sequencer): A fork of [Erigon](https://github.com/ledgerwatch/erigon) responsible for managing multiple RPC nodes and running a sequencer to execute transactions and create blocks and batches.
- Prover: A cryptographic tool that generates zero-knowledge proofs for zk-rollup and validium configs.
- Contracts: Smart contracts deployed on Ethereum Layer 1 to implement zk-rollup and validium functionality:
- PolygonRollupManager
- PolygonZkEVMBridgeV2
- PolygonZkEVMGlobalExitRootV2
- FflonkVerifier
- PolygonZkEVMDeployer
- PolygonZkEVMTimelock
- CLI tool: Simplifies the deployment and configuration of CDK components through an intuitive command-line interface.
- Transaction pool manager: Stores and manages user-submitted transactions.
- Aggregator: Combines multiple proofs into a single proof for submission to Ethereum, optimizing the validation process.
- Data availability: Ensures transaction data integrity; optional for validium configs.

---

## Support Services

### Bridge Services
- **[Bridge Service](https://github.com/0xPolygonHermez/zkevm-bridge-service)**: A backend service enabling interactions with bridge contracts via Merkle proofs.
- **[Bridge UI](https://portal.polygon.technology/)**: A user-friendly portal for managing deposits and withdrawals.
### Support services

### Explorer Services
- **[Blockscout](https://github.com/0xPolygonHermez/blockscout)**: Recommended for inspecting transactions and proofs. Alternative explorers can also be used.
#### Bridge services
- [Bridge service](https://github.com/0xPolygonHermez/zkevm-bridge-service): A backend service enabling interactions with bridge contracts via Merkle proofs.
- [Bridge UI](https://portal.polygon.technology/): A user-friendly portal for managing deposits and withdrawals.

---
#### Explorer services
- [Blockscout](https://github.com/0xPolygonHermez/blockscout): Recommended for inspecting transactions and proofs. Alternative explorers can also be used.
Loading

0 comments on commit dd3dbb9

Please sign in to comment.