Skip to content

Commit 8586da5

Browse files
remove pics
1 parent d187c2c commit 8586da5

23 files changed

+36
-300
lines changed

docs/cdk/agglayer/agglayer-go.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
## Overview
22

3-
The AggLayer Golang is a web service designed to receive zero-knowledge proofs (ZKP) from CDK chains, ensure they are valid, and send them to the L1 verifier contract for final verification.
3+
The AggLayer-go is a service designed to receive zero-knowledge proofs (ZKP) from various CDK chains and verify their validity before sending them to the L1 for final settlement.
44

55
!!! warning
6-
This service is being deprecated and replaced with a more robust and efficient [Rust implementation](agglayer-rs.md).
6+
This service is being deprecated n favor of the more robust and efficient [Rust implementation](agglayer-rs.md).
77

88
## Architecture
99

10-
The AggLayer Golang architecture supports interoperability among connected CDK chains by using ZKPs to ensure safety. It uses a PostgreSQL database for storage and interacts with both L1 and L2 chains through configured RPC nodes.
10+
The AggLayer golang architecture supports interactions with multiple CDK chains for proof-verification. It uses a PostgreSQL database for storage and interacts with both L1 and L2 chains through configured RPC nodes.
1111

12-
The diagram below shows the full start-up, running, and shutdown sequence for the AggLayer Golang application and its components.
12+
The diagram below shows the full start-up, running, and shutdown sequence for the application and its components.
1313

1414
<center>
1515
![CDK architecture](../../img/cdk/agglayer/agglayer-go.png)
@@ -97,4 +97,4 @@ Refer to the `cmd` and `client` directories for API implementation details. Docu
9797
9898
---
9999
100-
For more information, visit the [AggLayer Golang repository](https://github.com/AggLayer/agglayer-go).
100+
For more information, visit the [AggLayer-go repository](https://github.com/AggLayer/agglayer-go).

docs/cdk/agglayer/agglayer-rs.md

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,10 @@
11
## Overview
22

3-
The AggLayer is a Rust-based web service designed to ensure safety for cross-chain asset transfers among heterogeneous blockchain networks. This safety is provided using ZKPs, allowing end-users to interoperate with no additional trust assumptions.
4-
5-
The service verifies the validity of proofs from various CDK chains before forwarding them to L1 for verification.
6-
7-
It replaces the previous [Golang implementation](agglayer-go.md).
3+
AggLayer-rs is a Rust-based service designed to receive zero-knowledge proofs from various CDK chains and verify their validity before sending them to the L1 for final settlement. It replaces the previous [Golang implementation](agglayer-go.md).
84

95
## Architecture
106

11-
### Components
12-
13-
- Unified bridge: A shared bridge contract for all AggLayer-connected chains, allowing for the transfer of native assets.
14-
- Pessimistic proof: A novel ZKP that provides safety for the assets on the unified bridge by ensuring no chain can withdraw more tokens of any type than have been deposited into it. Pessimistic proofs are validated by the verifier contract on the L1.
15-
16-
### Data flow
17-
18-
- Input: Proofs of execution generated by CDK chains.
19-
- Processing: Verification of proofs.
20-
- Output: Verified proofs sent to L1.
21-
22-
[pic-here]
7+
The AggLayer Rust architecture supports interactions with multiple CDK chains for proof-verification. Its architecture is the same as `agglayer-go`, but without the PostgreSQL database for storage.
238

249
## Getting started
2510

docs/cdk/agglayer/bridge-and-call.md

Lines changed: 0 additions & 79 deletions
This file was deleted.

docs/cdk/agglayer/overview.md

Lines changed: 11 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,27 @@
11
!!! info "Disclaimer"
2-
- Much of the content in this section is discussing technology in development and not ready for release.
2+
- Some of the content in this section discusses technology in development and not ready for release.
33
- Please check against the main documentation site for any live releases.
44
- Feel free to experiment with any code in public repos.
55

66
## Welcome to AggLayer documentation
77

8-
The culmination of Polygon Lab's innovation and design, AggLayer is an evolving ecosystem of zk-based (zero-knowledge) interacting chains. It addresses the current industry focus on interoperability and shared liquidity.
8+
The AggLayer is an in-development interoperability protocol that allows for trustless, cross-chain token transfers and message-passing, as well as more complex operations. The safety of the AggLayer is provided by zero-knowledge proofs.
99

10-
While most rollup environments follow a modular approach, where developers pick-and-choose components such as execution and data availability layers for example, the AggLayer vision is uniquely centered around zk-proof technology.
11-
12-
<center>
13-
![CDK architecture](../../img/cdk/agglayer/mono-modu.png)
14-
</center>
10+
The AggLayer currently connects chains built with Polygon CDK, a developer toolkit for designing ZK-powered Layer 2s. The long term goal for the protocol is to be flexible enough to provide interoperability among a growing range of blockchain architectures, including L2s, appchains, and non-EVM chains.
1511

1612
## AggLayer components
1713

18-
AggLayer connects CDK chains and provides a zero-knowledge prover for validity and security.
19-
20-
<center>
21-
![CDK architecture](../../img/cdk/cdk-architecture.png)
22-
</center>
23-
24-
### Chain development kit (CDK)
25-
26-
- CDK chains connect to AggLayer.
27-
- CDK chains are similar to other rollup stacks but enforce unique zk-based cryptographic proofs for transaction validation to ensure robust security and efficiency.
28-
- Non-CDK chains will also eventually connect to AggLayer.
29-
30-
### AggLayer
31-
32-
- Running now on the unified bridge technology, AggLayer takes a many-to-many approach to CDK chain interactions which focuses on validity, interoperability, and security.
33-
- It aggregates and batches proofs from multiple CDK chains into a single proof, significantly lowering the verification cost across chains as the ecosystem grows.
34-
35-
<center>
36-
![AggLayer overview](../../img/cdk/agglayer/agg-layer-overview.png)
37-
</center>
38-
39-
- AggLayer ensures seamless and correct ordering of cross-chain transaction execution and securely-shared liquidity across all zk-based chains.
40-
41-
### Provers
14+
### Polygon CDK
4215

43-
- Provers generate cryptographic proofs for zk-based chains that verify the validity of transactions.
44-
- Ethereum smart contracts then validate those proofs.
45-
- The cost of proof validation on Ethereum remains fixed regardless of the number of transactions.
46-
- AggLayer offers a modular approach to provers. Options include the Polygon zkEVM prover technology and the SP1/Plonky 3 prover currently in development.
16+
The AggLayer connects chains built with Polygon CDK, which use ZK proofs to generate state transitions that are cryptographically secure.
4717

48-
<center>
49-
![AggLayer overview](../../img/cdk/agglayer/prover.png)
50-
</center>
18+
### Unified bridge
5119

52-
## What to expect
20+
The unified bridge is a single bridge contract for all AggLayer-connected chains, allowing for the cross-chain transfer of fungible (non-wrapped) tokens. In the abstract, it is the source of unified liquidity for the AggLayer.
5321

54-
These documents introduce you to the current unified bridge technology that inspires and underpins AggLayer.
22+
!!! tip "More information"
23+
See the [unified bridge documentation](unified-bridge.md) for details.
5524

56-
We also document some of AggLayer's key technology in development now; such as the Go and Rust libraries, the bridge and call API, and Plonky prover technology.
25+
### AggLayer service
5726

58-
We also document a little about what the future has in store.
27+
The AggLayer service is a service designed to receive zero-knowledge proofs from various CDK chains and verify their validity before sending them to the L1 for final settlement. Currently, the AggLayer service has two implementations: [agglayer-go](agglayer-go.md) and [agglayer-rs](agglayer-rs.md).

docs/cdk/agglayer/pessimistic-proof.md

Lines changed: 0 additions & 87 deletions
This file was deleted.

docs/cdk/agglayer/roadmap.md

Lines changed: 0 additions & 13 deletions
This file was deleted.

docs/cdk/agglayer/token-flows.md

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,8 @@
1-
The following document describes how token and message transactions are implemented by the unified bridge across various L1 and L2 permutations.
1+
The following describes how token transfers and message passing are implemented by the unified bridge across various L1 and L2 permutations. While the examples provided describe only token transfers, the sequence is the same for arbitrary messages in this current implementation of the AggLayer.
22

3-
<center>
4-
![Token flows](../../img/cdk/agglayer/tx-flows.png)
5-
</center>
3+
## L1 to L2
64

7-
### L1 to L2
8-
9-
1. If a call to `bridgeAsset` or `bridgeMessage` on L1 passes validation, the bridge contract appends an exit leaf to the L1 exit tree and computes the new L1 exit tree root.
5+
1. If a call to `bridgeAsset` or `bridgeMessage` on L1 passes validation, the unified bridge contract appends an exit leaf to the L1 exit tree and computes the new L1 exit tree root.
106

117
2. The global exit root manager appends the new L1 exit tree root to the global exit tree and computes the global exit root.
128

@@ -16,25 +12,25 @@ The following document describes how token and message transactions are implemen
1612

1713
5. A call to `claimAsset` or `claimMessage` provides a Merkle proof that validates the correct exit leaf in the global exit root.
1814

19-
6. The bridge contract validates the caller's Merkle proof against the global exit root. If the proof is valid, the bridging process succeeds; otherwise, the transaction fails.
15+
6. The unified bridge contract validates the caller's Merkle proof against the global exit root. If the proof is valid, the bridging process succeeds; otherwise, the transaction fails.
2016

21-
### L2 to L1
17+
## L2 to L1
2218

23-
1. If a call to `bridgeAsset` or `bridgeMessage` on L2 passes validation, the bridge contract appends an exit leaf to the L2 exit tree and computes the new L2 exit tree root.
19+
1. If a call to `bridgeAsset` or `bridgeMessage` on L2 passes validation, the unified bridge contract appends an exit leaf to the L2 exit tree and computes the new L2 exit tree root.
2420

25-
2. The L2 global exit root manager appends the new L2 exit tree root to the global exit tree and computes the global exit root. At that point, the caller's bridge transaction is included in one of batches selected and sequenced by the sequencer.
21+
2. The L2 global exit root manager appends the new L2 exit tree root to the global exit tree and computes the global exit root. At that point, the caller's bridge transaction is included in one of the batches selected and sequenced by the sequencer.
2622

2723
3. The aggregator generates a zk-proof attesting to the computational integrity in the execution of sequenced batches which include the transaction.
2824

29-
4. For verification purposes, the aggregator sends the zk-proof together with all relevant batch information that led to the new L2 exit tree root (computed in step 2), to the consensus contract.
25+
4. For verification purposes, the aggregator sends the zk-proof together with all relevant batch information that led to the new L2 exit tree root (computed in step 2), to the verifier contract.
3026

31-
5. The consensus contract utilizes the `verifyBatches` function to verify validity of the received zk-proof. If valid, the contract sends the new L2 exit tree root to the global exit root manager in order to update the global exit tree.
27+
5. The verifier contract utilizes the `verifyBatches` function to verify validity of the received zk-proof. If valid, the contract sends the new L2 exit tree root to the global exit root manager in order to update the global exit tree.
3228

33-
6. `claimMessage` or `claimAsset` is then called on the bridge contract with Merkle proofs for correct validation of exit leaves.
29+
6. `claimMessage` or `claimAsset` is then called on the unified bridge contract with Merkle proofs for correct validation of exit leaves.
3430

35-
7. The bridge contract retrieves the global exit root from the L1 global exit root manager and verifies validity of the Merkle proof. If the Merkle proof is valid, the bridge completes. Otherwise, the transaction is reverted.
31+
7. The unified bridge contract retrieves the global exit root from the L1 global exit root manager and verifies validity of the Merkle proof. If the Merkle proof is valid, the settlement completes, otherwise, the transaction is reverted.
3632

37-
### L2 to L2
33+
## L2 to L2
3834

3935
1. When a batch of transactions is processed, the bridge contract appends the L2 exit tree with a new leaf containing the batch information. This updates the L2 exit tree root.
4036

0 commit comments

Comments
 (0)