Skip to content

Commit

Permalink
Add new sections for unifi (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonVranek authored Sep 13, 2024
1 parent 6cbe929 commit 5041b87
Show file tree
Hide file tree
Showing 11 changed files with 7,820 additions and 4,825 deletions.
99 changes: 99 additions & 0 deletions docs/unifi-avs-background.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,99 @@
---
title: Background
slug: /unifi-avs-background
---

## The Ethereum Scalability Challenge πŸ—οΈ

Ethereum faced scalability issues due to its limited transaction throughput and high gas fees. This led to the development of a rollup-centric roadmap focused on scaling Ethereum using Layer 2s.

### The Role of Rollups

Rollups aim to increase Ethereum's transaction capacity by processing transactions off-chain and then submitting batched results to the Ethereum mainnet. However, traditional rollups face challenges:

- 🐒 Slow Finality: It takes at least 12s for Ethereum block confirmations and 12 minutes for finality.
- πŸ”’ Security Trade-offs: Some solutions compromise on security for speed.
- 🌐 Fragmented Liquidity: Different rollups have isolated liquidity pools and users.
- 🎯 Centralization: Centralized sequencers can be point of failure for rollups.

## Based Rollups: A Step Forward ⚑

[Based rollups](https://ethresear.ch/t/based-rollups-superpowers-from-l1-sequencing/15016) offer a promising solution to many of these challenges.

### Key Features of Based Rollups

Based rollups are a type of rollup that:

- πŸ”„ Have transactions sequenced by Ethereum validators
- πŸ”— Inherit Ethereum's security directly
- 🀝 Unlock synchronous composability between different based rollups
- πŸ’° Align economic incentives with Ethereum L1

### The Speed Challenge for Based Rollups

Despite their advantages, based rollups still face a critical issue:

- ⏳ Slow Confirmation Times: Based rollups are limited by Ethereum's block time (12 seconds), leading to slower transaction confirmations than desired for many applications.

## Preconfirmations: The Latency Solution πŸš€

To address the speed limitations of based rollups, the concept of [preconfirmations](https://ethresear.ch/t/based-preconfirmations/17353) was introduced.

### What are Preconfirmations?

Preconfirmations provide near-instant transaction assurances by leveraging a network of Ethereum validators. Here's how they work:

- ⚑ Offer ~100ms transaction confirmations, drastically reducing wait times
- Validators quickly process and sign off on incoming transactions
- These signatures serve as immediate assurances before the block is published to the L1
- πŸ›‘οΈ Backed by economic security from Ethereum validators
- Validators stake ETH as collateral, ensuring honest behavior
- Breaking preconf promises can result in slashing of staked assets
- 🌐 Maintain neutrality and decentralization
- Multiple validators participate, preventing single points of failure
- Open participation ensures no central authority controls the process
- πŸ”„ Bridge the gap between transaction submission and block confirmation
- Users receive rapid feedback on transaction validity
- Rollups can process transactions with confidence before L1 finality

### Requirements for a Preconfirmation Protocol πŸ› οΈ

To build an effective preconfirmation protocol for based rollups, several key requirements must be met:

1. **Validator Network**: 🌐
- A network of Ethereum validators willing to participate in preconfirmations
- Open system allowing any eligible validator to join

2. **Economic Incentives**: πŸ’°
- A system to reward validators for honest participation
- Penalties (e.g., slashing) for malicious behavior (safety faults) or non-performance (liveness faults)

3. **Security Guarantees**: πŸ”’
- Cryptographic proofs of validator commitments
- Mechanisms to ensure the integrity of preconfirmations

4. **Standardization**: πŸ”§
- On-chain registry of participating validators
- Common interfaces for validator software

5. **Capital Efficiency**: πŸ’Ό
- Mechanisms to allow validators to participate without locking up additional capital
- Potential integration with restaking protocols

By addressing these requirements, a preconfirmation protocol can provide the necessary infrastructure to enable near-instant, secure transaction confirmations for based rollups, significantly enhancing the user experience and efficiency of the Ethereum ecosystem.

## UniFi AVS: Pioneering Preconfirmations πŸ¦„

UniFi AVS steps in as the first instantiation of a preconfirmation protocol for based rollups.

By combining EigenLayer's restaking capabilities with Commit-Boost's standardization, UniFi AVS creates a robust, efficient, and secure preconfirmation system for based rollups.

This unique combination allows UniFi AVS to offer:

1. 🟒 Permissionless validator participation
2. πŸ“Š On-chain registry for transparency
3. βš–οΈ Slashing mechanisms for accountability
4. πŸ”— Seamless integration with based rollups
5. ⚑ Near-instant, secure transaction confirmations

Learn how in the following sections πŸ‘‰
67 changes: 67 additions & 0 deletions docs/unifi-avs-getting-started.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
title: Getting Started
slug: /unifi-avs-getting-started
---

# Getting Started with UniFi AVS

This guide provides simple steps for operators to register with UniFi AVS.

## Prerequisites

Before you begin, ensure you have the following:

- An Operator registered in EigenLayer's contracts ([see guide](https://docs.eigenlayer.xyz/eigenlayer/operator-guides/operator-installation#goerli-smart-contract-addresses))
- Access to an [Ethereum mainnet RPC](https://chainlist.org/)
- [Git](https://git-scm.com/downloads) installed
- [Node.js and npm](https://nodejs.org/) installed
- [Yarn](https://yarnpkg.com/getting-started/install) installed
- [Foundry](https://book.getfoundry.sh/getting-started/installation) installed

## Setup

1. Install Foundry (if not already installed):
```
curl -L https://foundry.paradigm.xyz | bash
foundryup
```

2. Clone the UniFi repository:
```
git clone https://github.com/PufferFinance/UniFi.git
```

3. Navigate to the cloned directory:
```
cd UniFi
```

4. Install dependencies:
```
yarn install
```

5. Navigate to the l1-contracts directory:
```
cd l1-contracts
```

6. Install Foundry dependencies:
```
forge build
```

## Phase 1 - Register to UniFi AVS
During phase 1 of UniFi AVS mainnet, Operators can register as follows.

1. **Register as an Operator**
Run the following Solidity script:
```
forge script script/UniFiAVSScripts.sol:UniFiAVSScripts --sig "registerOperatorToUniFiAVS(uint256 signerPk)" 'YOUR_OPERATOR_PRIVATE_KEY' --private-key 'YOUR_OPERATOR_PRIVATE_KEY' --rpc-url 'YOUR_MAINNET_RPC_URL' --broadcast
```
Replace `YOUR_OPERATOR_PRIVATE_KEY` and `YOUR_MAINNET_RPC_URL` with your actual values.


:::tip
Phase 2 of UniFi AVS will be coming soon as EigenLayer introduces new features around rewards and slashing.
:::
91 changes: 91 additions & 0 deletions docs/unifi-avs-intro.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
---
title: Hello UniFi AVS πŸ¦„
slug: /unifi-avs-intro
---

> ###
:::info About UniFi AVS
UniFi AVS is an EigenLayer-based solution addressing challenges in Ethereum's preconfirmation (preconf) ecosystem. It offers permissionless validator participation, an on-chain registry, and slashing mechanisms for accountability.

Built on EigenLayer and integrating [Commit-Boost](https://commit-boost.github.io/commit-boost-client/architecture/overview), UniFi AVS aims to provide fast, secure, and neutral preconfirmations for based rollups, enhancing Ethereum's scalability while maintaining its core principles of decentralization and security.
:::

## What does UniFi AVS bring? πŸš€

### **Protocol Features**

- 🟒 Permissionless: Any restaked validator on EigenLayer can participate.
- πŸ“Š On-Chain Registry: Transparent and discoverable preconfer registry.
- βš–οΈ Slashing Mechanism: Enforces accountability for preconfirmation promises.
- πŸ”— EigenLayer Integration: Leverages restaking for capital efficiency.
- 🌟 Innovation Catalyst: Enables rapid innovation without altering Ethereum's core protocol.

### **Preconfirmation Service**

- ⚑ Fast Confirmations: Near-instant transaction confirmations (~100ms).
- πŸ”’ Security: Strong assurances from Ethereum validators, backed by economic security.
- 🌐 Neutrality: Commitment to impartiality and unbiased operation.
- πŸ’ͺ Binding Promises: Unlike centralized sequencers, preconfirmations are backed by real economic consequences.

### **Makes Based Rollups Viable**

- πŸ”„ Liveness Guarantees: Inherit robust liveness from Ethereum L1.
- πŸ›‘οΈ Simplicity and Security: Leverage Ethereum's existing infrastructure.
- πŸ’° Economic Alignment: MEV flows back to Ethereum L1.
- 🀝 Synchronous Composability: Interact across different based rollups.
- ⚑ Enhanced Speed: Overcome the limitation of long L1 block times.

### **Commit-Boost**

- 🌟 Open Source: Developed as a public good.
- πŸ”§ Standardization: Facilitates easier integration with validator software.

-----

### The UniFi AVS Ecosystem 🌐

<div style={{textAlign: 'center'}}>

![UniFiAVSFlywheel](/img/unifi-avs-flywheel.png)
</div>

UniFi AVS creates a robust ecosystem that enhances Ethereum's capabilities without compromising its core principles. It brings together validators, users, and the broader Ethereum community to provide faster, more secure, and more efficient transaction processing.

The ecosystem is driven by **Validators** and **Users**:

- **Validators** can participate in UniFi AVS by owning an EigenPod and running Commit-Boost software. They provide preconfirmation services and earn additional rewards while contributing to the network's security and efficiency.

- **Users** benefit from near-instant transaction confirmations (~100ms) for both L1 transactions and based rollup transactions. This significantly improves the user experience, making it comparable to or better than alternative L1 blockchains.

### Why be a Validator on UniFi AVS? πŸ€–

Validators can leverage their existing restaked ETH to participate in UniFi AVS, offering several benefits:

- πŸ’° Additional Rewards: Earn extra rewards by providing preconfirmation services.
- πŸ”’ Capital Efficiency: Use restaked ETH as preconf collateral without additional deposits.
- 🌐 Network Contribution: Play a crucial role in enhancing Ethereum's transaction speed and user experience.
- πŸš€ Innovation Participation: Be part of cutting-edge advancements in the Ethereum ecosystem.

:::tip
UniFi AVS allows validators to participate in preconfirmations without requiring additional collateral beyond their restaked ETH. If you're already running validators on EigenLayer, you're perfectly positioned to join this new opportunity!
:::

### Why use UniFi AVS? πŸš€

For users and developers, UniFi AVS offers significant advantages:

- ⚑ Speed: Experience near-instant transaction confirmations (~100ms).
- πŸ”’ Security: Benefit from strong assurances backed by economic security.
- 🌐 Ecosystem Improvement: Contribute to a more efficient and user-friendly Ethereum ecosystem.
- πŸ”— Compatibility: Seamlessly integrate with based rollups for enhanced scalability.
- πŸ—οΈ Building Opportunity: Perfect platform for building next-generation rollups with lightning-fast confirmations and unified liquidity.

:::tip
UniFi AVS brings the speed of alternative L1s to Ethereum without compromising on security or decentralization. It's not just an improvement - it's a revolution for Ethereum!
:::

UniFi AVS prioritizes the security and efficiency of the Ethereum ecosystem. To ensure this, the protocol:

- Requires validators to own EigenPods and run Commit-Boost software.
- Implements slashing mechanisms for accountability.
- Maintains neutrality by avoiding governance token requirements for participation.
Loading

0 comments on commit 5041b87

Please sign in to comment.