Bharath Vedartham
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
      • Invitee
    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Versions and GitHub Sync Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
Invitee
Publish Note

Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

Your note will be visible on your profile and discoverable by anyone.
Your note is now live.
This note is visible on your profile and discoverable online.
Everyone on the web can find and read all notes of this public team.
See published notes
Unpublish note
Please check the box to agree to the Community Guidelines.
View profile
Engagement control
Commenting
Permission
Disabled Forbidden Owners Signed-in users Everyone
Enable
Permission
  • Forbidden
  • Owners
  • Signed-in users
  • Everyone
Suggest edit
Permission
Disabled Forbidden Owners Signed-in users Everyone
Enable
Permission
  • Forbidden
  • Owners
  • Signed-in users
Emoji Reply
Enable
Import from Dropbox Google Drive Gist Clipboard
   owned this note    owned this note      
Published Linked with GitHub
Subscribed
  • Any changes
    Be notified of any changes
  • Mention me
    Be notified of mention me
  • Unsubscribe
Subscribe
# PEPC-Boost V0 ## Contents 1. [Abstract](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Abstract) 1. [Glossary](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Glossary) 2. [Introduction](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Introduction) 3. [System Architecture](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#System-Architecture) 4. [Implementation-Specific Details](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Implementation-Specific-Details) 5. [Current State](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Current-State) 6. [Future Work](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Future-Work) 7. [Demo Video](https://hackmd.io/XUj5jkz6R2Kuq0cEizQr4g?both#Demo-Video) ### Abstract Integrated searcher-builders like HFT firms have superior capabilities to extract high-value top-of-block MEV opportunities like CEX-DEX arbitrages compared to smaller builders. Current PBS auctions, done through MEV relays, only auction off the entire block, which means that builders capable of extracting high-value top-of-block opportunities can easily outbid the rest of the other builders by winning the whole block auction, increasing the centralization and reducing the builder market's competitiveness. This article takes inspiration from [PEPC](https://ethresear.ch/t/unbundling-pbs-towards-protocol-enforced-proposer-commitments-pepc/13879?u=barnabe), a proposed in-protocol mechanism for more general block allocation mechanisms, to propose a new relay design called PEPC-Boost. PEPC-Boost holds separate auctions for the top-of-block and rest-of-block. PEPC-Boost relay allows searchers to bid separately to include their CEX-DEX arbitrage transactions on the top-of-block, and it allows builders to submit blocks that will get included in the rest-of-block. By selling the top-of-block and rest-of-block separately, PEPC-Boost aims to reduce the competitive advantage of integrated searcher-builders, which will help increase competitiveness and reduce centralization in the builder market. ### Glossary | Term | Description | | -------- | -------- | | ToB | Top of Block | | RoB | Rest of Block | | HFT Firms | High Frequency Trading Firms | | ToB value | The amount Eth searchers are willing to pay to the proposer for including their txs in the ToB slot | | RoB value | Validator payouts added by RoB builders | | Searchers | Actors who look to extract a lot of MEV | | Builders | Actors who build blocks and submit them to the MEV relayer, allowing them to bid for validator block space | | PEPC | Protocol Enforced Proposer Commitments | ### Introduction [PEPC](https://ethresear.ch/t/unbundling-pbs-towards-protocol-enforced-proposer-commitments-pepc/13879?u=barnabe) as proposed by Barnabe Monnot is a protocol mechanism to allow proposers to enter into commitments over the blocks they build. Some examples of possible commitments are [certain types of transaction ordering, parallel block building, etc.](https://efdn.notion.site/PEPC-FAQ-0787ba2f77e14efba771ff2d903d67e4#6775d4c031d545609434e24213a4fde2) [PEPC is useful](https://efdn.notion.site/PEPC-FAQ-0787ba2f77e14efba771ff2d903d67e4?pvs=25#b5d2966c2215482eaba942f93bdfb613) because it allows more general block allocation mechanisms in the protocol which removes specific locked outcomes which may have undesirable side-effects on the protocol. The current builder landscape is very [centralized](https://www.rated.network/builders?timeWindow=30d&network=mainnet&page=1). Integrated builder-searchers like HFT firms are more likely to win the PBS auctions because they can maintain private order flows and have access to specialized centralized exchange feeds, giving them superior top-of-block capabilities, which enable them to extract much more profit from CEX-DEX arbitrages than non-integrated builders and win the PBS block auctions which also reduces the competitiveness of the builder market. [PEPC-Boost](https://efdn.notion.site/PEPC-FAQ-0787ba2f77e14efba771ff2d903d67e4#2dfe02bc6dcd48878c82647676ca8d68%29) is a proposed out-of-protocol implementation of a specific PEPC-type allocation which splits a block into a top-of-block and rest-of-block lane (which is similar to the concept of lanes in [Skip protocol](https://skip-protocol-docs.netlify.app/chains/overview)). Searchers can engage in an auction to bid for [CEX-DEX arbitrage txs](https://arxiv.org/abs/2305.19150) they want to include in the top-of-block, and builders can bid to include their block in the RoB. This opens up the proposer block space by allowing different actors to construct segments of the whole block, which is a form of a [parallel block auction](https://efdn.notion.site/PEPC-FAQ-0787ba2f77e14efba771ff2d903d67e4#6775d4c031d545609434e24213a4fde2). Integrated searcher-builders are not incentivized to use PEPC-Boost relay as they already have superior capabilities to extract ToB opportunities, which enables them to build high-value blocks that can outbid other builders on the full block auction. Searchers who are capable of building RoBs can use PEPC-Boost to trustlessly pair up with searchers capable of producing high-value ToB txs to build high-value blocks, which can compete with the best builders. These blocks can potentially outbid large integrated searcher-builders, improving the builder market's decentralization and competitiveness. It also allows weaker builders to include their transactions, increasing the protocol's censorship resistance. Since the top integrated searcher-builders are not incentivized to use PEPC-Boost, we can expect the builders with a much lower block inclusion rate to connect with PEPC-Boost so that their txs are more likely to be included. Note that this is an analysis that needs to be done more thoroughly. ### System Architecture The PEPC-Boost relayer exposes a new endpoint that accepts a bundle consisting of ToB txs from the searcher and a payout tx to the proposer for including the bundle at the ToB. The relayer receives RoB blocks from builders through an endpoint dedicated to receiving RoB blocks. If the sum of the values of the ToB bundle proposed by a searcher and RoB block submitted by a builder is the highest value block seen for that particular slot, we assemble the ToB bundle and RoB block into a combined execution payload and store the final bid in the relay database. The value of the final bid is the sum of the ToB's value and the RoB's value. We are doing a "static evaluation" for the initial version to sum up the values and check if it's the highest. The actual value of the block might be lower because the txs in the RoB might revert due to state changes by the ToB. We are exploring solutions that can help us model RoB values more efficiently. Below is a diagram which shows the architecture of PEPC-Boost: ![PEPC-Boost Architecture Diagram](https://raw.githubusercontent.com/bharath-123/pepc-boost-docs/main/diagrams/PEPCBoost.png) Searchers send a bundle they want to include in the ToB for a given slot and on top of a particular parent hash which consists the ToB txs and a payout to the proposer via the `/relay/v1/builder/tob_txs` endpoint. The endpoint first simulates the bundle to check if the searcher has included a payout for the proposer of the given slot and if the ToB txs sent are valid non-reverting txs. This simulation happens via a `validateTobSubmission` RPC call. Once the simulation is successful, we check if the ToB tx in the bundle is a potential CEX-DEX arbitrage-related tx. In the initial versions of PEPC-Boost, we allow only one CEX-DEX arbitrage tx by the searcher, which currently is an Eth/USDC Uniswap V3 swap. By limiting the type of txs we accept on the ToB, we also reduce the chance of state conflicts with the RoB, reducing the chances of txs in the RoB reverting. In future versions, we will increase the number of ToB txs we accept in the bundle and allow a bundle with multiple CEX-DEX arbitrage-related txs. If the bundle is of the highest value seen so far, we store the bundle in the Redis cache of the PEPC-Boost relayer. For more details on ToB Auction and ToB tx checks, please refer to: * ToB auction: https://github.com/bharath-123/pepc-boost-docs/blob/main/TOB_AUCTION.md * ToB tx checks: https://github.com/bharath-123/pepc-boost-docs/blob/main/TOB_TX_CHECKS.md When a builder submits a RoB block via the `/relay/v1/builder/rob_blocks`, we check if a ToB bundle is present for the slot and parent hash of the submitted block. If there is a ToB bundle and the sum of the ToB value and RoB value is the highest seen so far, we send it to the `blockAssembler` RPC to assemble the ToB txbundles and the RoB block into a combined execution payload and store the final bid with this combined execution payload in the PEPC-Boost relay database. The RoB builder currently pays the proposer using the existing model by appending the payout to the proposer at the end of the block. For more details, please refer to: * ToB and RoB building: https://github.com/bharath-123/pepc-boost-docs/blob/main/TOB_ROB_BUILDING.md * Block Assembler: https://github.com/bharath-123/pepc-boost-docs/blob/main/BLOCK_ASSEMBLY.md Below is a sequence diagram highlighting the interactions in PEPC-Boost: ![enter image description here](https://raw.githubusercontent.com/bharath-123/pepc-boost-docs/main/diagrams/PEPCBoostInteractions.png) ### Implementation-Specific Details PEPC-Boost leverages the [Flashbots MEV-Boost Relay code](https://raw.githubusercontent.com/bharath-123/pepc-boost-docs/main/diagrams/PEPCBoost.png). https://github.com/bharath-123/pepc-boost-relay contains the code of the PEPC-Boost relay. We leverage [Flashbots Builder](https://github.com/flashbots/builder) to implement the RPCs for block assembler and ToB tx validation. https://github.com/bharath-123/pepc-boost-builder contains the implementations of the block assembler and ToB tx validation RPC. To test PEPC-Boost on local devnets, we have used [Kurtosis](https://github.com/kurtosis-tech/ethereum-package). Kurtosis allows to spin up local devnets very easily. For more details on using Kurtosis to test PEPC-Boost, please refer to https://github.com/bharath-123/pepc-boost-docs/blob/main/CUSTOM_DEVNET_SETUP.md. We have written scripts in https://github.com/bharath-123/pepc-boost-testing/tree/devnet-testing to send searcher txs to the PEPC-Boost relay to test it. https://github.com/bharath-123/pepc-boost-docs contains detailed documentation of each component. ### Current State In the initial version of PEPC-Boost, We have implemented a ToB auction that accepts one Uniswap v3 Eth/USDC tx and a proposer payout tx. We have introduced a new RoB block submission API to which builders send RoB blocks. We have integrated the block assembly RPC with the RoB block submission API, which is invoked whenever a builder's RoB tx is matched with valid ToB txs for the slot to get back an assembled payload of the ToB txs and RoB txs. We have implemented the block assembly RPCs and ToB validation RPCs in the builder. https://github.com/bharath-123/pepc-boost-relay contains the initial version of PEPC-Boost, and https://github.com/bharath-123/pepc-boost-builder includes the implementations of the RPCs for block assembly and ToB validation. We are testing PEPC-Boost in a local devnet we have setup using Kurtosis. We have also now deployed PEPC-Boost to Goerli! https://website.pepc-booost.com/ hosts the PEPC-Boost website. If you are running a validator, please feel free to connect to PEPC-Boost at https://api.pepc-booost.com/ ### Future Work As we move ahead with PEPC-Boost, below are some of the things we are looking at: 1. To increase the number of ToB txs allowed in the ToB bundle. 2. To model proposer payouts for the RoB builder more efficiently. Conflicts between the ToB txs and the RoB txs can cause RoB txs to revert, which could reduce the expected amount received by the RoB builder. Considering this case, we want to see if we can model proposer payouts better, which requires more research. 3. Optimize for higher block values by storing RoB partial blocks in the relay. We discard RoB blocks once we merge them with the ToB txs, which will not allow the PEPC-Boost relayer to combine subsequent ToB bundles with RoB blocks sent before the searcher sends the ToB txs to the relay, which could be of high value. As we advance, we want to cache the partial RoB blocks to build them with subsequently sent high-value ToB txs to get the highest value block possible. 4. To allow searchers to cancel ToB bundles they have sent. 5. To explore block cancellation by builders. Since two different actors are building a block, we need to research how complete block cancellations would work for the searcher and builder. Please find a complete list of items we are currently working on in PEPC-Boost here: https://github.com/bharath-123/pepc-boost-relay/issues ### Demo Video Below is a Demo video with a brief explanation of PEPC-Boost and a working demo. https://youtu.be/kUuDLqlsaSE ### Acknowledgments I want to thank [Barnabe Monnot](https://twitter.com/barnabemonnot) (EF), [Mike Neuder](https://twitter.com/mikeneuder) (EF) and [Terrence](https://twitter.com/terencechain) (Prysmatic Labs) for all their valuable feedback and discussions. I want to thank [Paritosh](https://twitter.com/parithosh_j) (EF) for guiding me to test PEPC-Boost better! I want to thank the [Kurtosis team](https://twitter.com/KurtosisTech) for building a solid product to set up local Ethereum devnets easily. The team is very helpful and super responsive, which has helped me immensely. I want to thank [Mario Havel](https://twitter.com/TMIYChao) (EF) and [Josh D](https://twitter.com/joshdavislight) (EF) for organizing the EPF program which has enabled me to put out this work.

Import from clipboard

Paste your markdown or webpage here...

Advanced permission required

Your current role can only read. Ask the system administrator to acquire write and comment permission.

This team is disabled

Sorry, this team is disabled. You can't edit this note.

This note is locked

Sorry, only owner can edit this note.

Reach the limit

Sorry, you've reached the max length this note can be.
Please reduce the content or divide it to more notes, thank you!

Import from Gist

Import from Snippet

or

Export to Snippet

Are you sure?

Do you really want to delete this note?
All users will lose their connection.

Create a note from template

Create a note from template

Oops...
This template has been removed or transferred.
Upgrade
All
  • All
  • Team
No template.

Create a template

Upgrade

Delete template

Do you really want to delete this template?
Turn this template into a regular note and keep its content, versions, and comments.

This page need refresh

You have an incompatible client version.
Refresh to update.
New version available!
See releases notes here
Refresh to enjoy new features.
Your user state has changed.
Refresh to load new user state.

Sign in

Forgot password

or

By clicking below, you agree to our terms of service.

Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
Wallet ( )
Connect another wallet

New to HackMD? Sign up

Help

  • English
  • 中文
  • Français
  • Deutsch
  • 日本語
  • Español
  • Català
  • Ελληνικά
  • Português
  • italiano
  • Türkçe
  • Русский
  • Nederlands
  • hrvatski jezik
  • język polski
  • Українська
  • हिन्दी
  • svenska
  • Esperanto
  • dansk

Documents

Help & Tutorial

How to use Book mode

Slide Example

API Docs

Edit in VSCode

Install browser extension

Contacts

Feedback

Discord

Send us email

Resources

Releases

Pricing

Blog

Policy

Terms

Privacy

Cheatsheet

Syntax Example Reference
# Header Header 基本排版
- Unordered List
  • Unordered List
1. Ordered List
  1. Ordered List
- [ ] Todo List
  • Todo List
> Blockquote
Blockquote
**Bold font** Bold font
*Italics font* Italics font
~~Strikethrough~~ Strikethrough
19^th^ 19th
H~2~O H2O
++Inserted text++ Inserted text
==Marked text== Marked text
[link text](https:// "title") Link
![image alt](https:// "title") Image
`Code` Code 在筆記中貼入程式碼
```javascript
var i = 0;
```
var i = 0;
:smile: :smile: Emoji list
{%youtube youtube_id %} Externals
$L^aT_eX$ LaTeX
:::info
This is a alert area.
:::

This is a alert area.

Versions and GitHub Sync
Get Full History Access

  • Edit version name
  • Delete

revision author avatar     named on  

More Less

Note content is identical to the latest version.
Compare
    Choose a version
    No search result
    Version not found
Sign in to link this note to GitHub
Learn more
This note is not linked with GitHub
 

Feedback

Submission failed, please try again

Thanks for your support.

On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

Please give us some advice and help us improve HackMD.

 

Thanks for your feedback

Remove version name

Do you want to remove this version name and description?

Transfer ownership

Transfer to
    Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

      Link with GitHub

      Please authorize HackMD on GitHub
      • Please sign in to GitHub and install the HackMD app on your GitHub repo.
      • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
      Learn more  Sign in to GitHub

      Push the note to GitHub Push to GitHub Pull a file from GitHub

        Authorize again
       

      Choose which file to push to

      Select repo
      Refresh Authorize more repos
      Select branch
      Select file
      Select branch
      Choose version(s) to push
      • Save a new version and push
      • Choose from existing versions
      Include title and tags
      Available push count

      Pull from GitHub

       
      File from GitHub
      File from HackMD

      GitHub Link Settings

      File linked

      Linked by
      File path
      Last synced branch
      Available push count

      Danger Zone

      Unlink
      You will no longer receive notification when GitHub file changes after unlink.

      Syncing

      Push failed

      Push successfully