MEV (Maximal Extractable Value) searchers use Flashbots bundles to extract arbitrage profits by submitting pre-validated transaction sequences to miners, where the searcher's contract executes swaps across different DEXs (like Uniswap and SushiSwap) using batched on-chain queries to efficiently retrieve market data, then pays miners a conditional fee only if the trade is profitable, ensuring miners have no incentive to include unprofitable bundles.
Flashbots MEV Searcher Walkthrough: Simple Arbitrage Bot Code
Added:and we'll review both of them source so this is actually like the meat of our med searcher here where all the logic happens uh and everything except for the extraction on jane happens here and then some tests that were written to ensure that the system's working as intended usually stuff happens in index so that's where i've started here got a bunch of imports not that much here to note other than uh if you're interacting with flashbots this is one repo called the flashbots bundle provider which is very special and you'll need to import this always and that just helps you submit and create bundles to send to the flashbacks relay i can say with some context that neither of us none of us shared when you are an mev searcher you will be interacting with the flashbacks relay this is like this middle point between searchers on one side and miners on the other so you submit your bundles to the relay we simulate them and if they are profitable for the miner and they don't have any errors then they get sent on to the miner and this is necessary to prevent spam attacks today uh eventually we're going to obviate this that will be decentralized but i won't go into those details so returning here to our index file a bunch of imports like stuff that we need to be able to interact with the chain as well as some transactions from ethers here some abis of our contract unit swap pairs uh a lot of the times you'll end up with a bunch of different addresses or abis that you need and so um beef 12. the repo is simple it's like flashbots simple arbitrage if someone else could put that in the chat that would be great um but it's pretty easy to find on our github anyway a lot of the times when you're making these things you'll be interacting with a bunch of different addresses and so it'll be useful just to create one file list all of your addresses uh and you can import this single file and then get your addresses from there instead of like posting them in one place across like six files and then needing to do that for a bunch of different addresses it's just like quality of life kind of thing you'll see a lot so in this case we're pulling different markets here that we're looking at as well as the token we want to arbitrage one part of it and a contract for you to deploy and then there's some um variables here for things that we're going to need to make this work you need a node which is your ethereum rpc url this is how you get this is how you get data off of the ethereum chain you need a private key i'm not gonna be using mine so no one will get that uh instead i'm like doing this is a bad habit but uh i'm just generating a random private key here for this purpose for this uh stream and then you need um to deploy a contract actually before you use this but since we're just like monitoring and talking about this um i used a random address that actually isn't the address of a contract here you need another private key to identify yourself to the flashbots relay this can be anything it doesn't need to be like what you're executing transactions with just a private key to sign your bundles with so we know who you are and um yeah that's that's how our permissionless authentication and identity works you can change this it doesn't really matter this is like uh this is um a random thing and then how much of your profits you're paying the miner if you get into mev searching you'll be upset at how much profit you pay to the miner yeah those are those are environment variables here not too much to say and we start this by setting up the things that we need in order to pull data off of the chain so that is our static json rpc provider this is how we will get information off the chain um we build up a wallet to sign our arbitrage transactions and then a wallet to sign our bundles to flush bots so this wallet on 38 is what you use for your transactions and then on 39 there's a separate wallet with a different private key that you use to identify yourself to the flash files relay actually yeah thanks for posting that scott and to answer your question milky shake i think there's a lot of opportunity in other places you will need to do things in a different way than we do here because you don't have flashbacks but some of the other chains have lower barriers to entry i think okay so this is the actual like function of the code that's run now after we've imported everything uh start out by creating a flashbots bundle provider this is the thing that you use to actually uh create bundles and send them to the flashbots relay and again that like that takes the thing we're using to provide data from the chain and our relay signing address and then we create this object called arbitrage it's its own class so i'm going to double click into this and see what it is arbitrage takes a couple different things here we have our flashbots bundle provider to send bundles we have a contract that we're interacting with and then a wallet that'll be sending transactions and all these things get set right here in the constructor so that they can be referenced later later and then it looks like this has a bunch of functionality um yeah so this has a bunch of functionality to evaluate markets that will be trading on and then send transactions later so there's two kind of important things here um the first is you're setting this up with some stuff that doesn't change so your the address that you change send bundles with or the private key rather and then the flashbacks bundle provider and your contracts you'll use that for every single transaction that you send and these stay the same because they're input in the co in the but then there's a bunch of other interesting functions here that will change according to each block that happens and you'll input new data per block so you construct this thing one time with your bundle uh executor contract your flashpots provider and then your signing key and then we will use this new arbitrage opportunity our arbitrage object to evaluate different markets and like keep on pumping data into it for new blocks okay so we'll we'll return to what um this this actually does and like the functions within it in a little bit but i'm going to go line by line here so we have this constant markets equals a weight unit swappy v2 each pair get unit swap markets by token that takes in our provider so this is getting different this is like the thing that we use to pull data off of the chain and then all of our factory addresses so what does this do um oh wow we've got like a bunch of people in here i didn't even notice that so welcome everybody excited that you're here i hope you learn a lot and feel free to answer ask questions um okay so what does this market thing do and what does this unismop2 eth paraffin do let's check it out so we're inputting like the provider that gets us data and then the factory addresses this line takes all of our different factory addresses within our address of this file and it in parallel will execute this call so on unit swappy v2 eth get unit swappy markets we'll input each factory address into this function so if you recall you've got all of these okay so here are factory addresses yeah and then on we'll plug each of these into this function here so each of these is a different fork of uniswap or it's uniswap itself um so i have no idea what this is but cro factory address that's like some unispot v2 fork zeus factory no clue what it is it's a uniform v2 fork though uh as is lua and like you all will know sushi swap and you mix well i think and then this will pump back the addresses for it and the reason why this is useful is because within the unit swap factory maybe i can do this we'll go and look at one of these so within the unit swap v2 factory for any of these [Music] they have a function that lets us get pairs i think this is what we're looking for yeah so um we first need to understand what markets we're looking for for arbitrage opportunities on and we have a bunch of these different factory addresses and like broad umbrellas of dexes but the way that uh uniswap v2 and v3 works is you have a factory contract that will deploy a bunch of little contracts that stand on their own and those little contracts actually are what you are trading on and it's where you can find prices of different assets not the factory contract itself but in order to perform arbitrage in order to get data from any of these things to find opportunities we then need to know where all the little contracts that have been deployed by the factory are and so this step of the code is really about looking at the factory and asking it where are all these little different pairs that you have created and using that we can then get their addresses so i just plugged out one of them here it's like some random pair if i click on it so it's a stable coin in usdc2 um if i do one i think this is like ethan dye firework correctly and with these addresses no ustc in east rather with these addresses we can then pull data from these individual pairs to understand what prices are and then later we can trade directly on them so that's why we need the factories that's sort of their purpose in here is just to tell us where these pairs are but the thing is that there are a huge number of pairs on unison um a v2 i think it's like 30 000.
maybe scott or steph knows that off the top of their head but it's like a it's a lot of different pairs um and you would just spend a huge amount of time if you sat here or even in a programmatic way and did like zero one two finding all these addresses like looking for the things that you want and so one of the the sweet tricks of this repo is instead of doing these lookup functions one at a time we do them in batches using this super cool contract that scott made called uniswapped query flash query you can see it here we are calling the get pairs by index range function here on the uniswap flash query function so this takes in a uniswap factory address just like the one that we were looking at here and then an index is start at and then index to stop at and it will look at the full length of the unit factory and instead of going through and uh doing this one at a time and like returning this data to us one at a time and then we go to the next one this executes uh the same operation but just in batches so it returns all this data in batches for us which is an extremely useful thing to do and the reason for that is that when you're interacting with your node it takes some time to take uh to get out data from your node get it to your software and then ingest it and it takes some time to like take uh the command that you're giving your node turn it into however the client understands it and then return it and so if you can instead of doing things in a one-off like many-to-many one two three four five six seven eight nine ten if you can just batch it all together do ten requests at one time you can make things much quicker and so this is a nice trick if you have a lot of data that you need to get off of the chain at one time it's like try to batch things together i'm not flash loaning uh pairs right now i'm just looking and trying to find them oh yes i am like sort of flesh learning addresses you are right igor we get all of these different pairs by index ranges and the other nice thing that this does is once we have the pair and its address we wrap it inside of this unisoi pair interface so that we know within our smart contract that we're interacting with a pair and because we know that we're interacting with a pair we can then call its functions so here i'm interacting with the pair and i call to see what the first token is a token zero it's kind of confusing and then what token one is or the other pair so this would be like usdc and this would be wef or something similar and then we construct this result object that has the address of the token one token the address of the other token and the address of the pair and through our whole loop we do this for every single pair that's in like the uniswap factory and we return this structure that has all the pairs as well as the tokens within those pairs and so now we know we have like all 43 750 different pairs on unit swap v3 our universal v2 and we know which tokens that belong to each of the pairs and we can start pulling data from them and interacting with them and that's also a very useful thing because we don't care about all pairs at least in this repo we don't care about all of them we just want single we just want pairs that have weft that have eth on one side of them and something else on the other side and anything that's like erc20 to erc20 we just immediately throw away because in simple arbitrage we're only looking at like width and die to die and wet arbitrage trades so okay that was a lot but this was the first step of like interacting with our query contract that makes it easier to get data off the chain in batches and again that makes it way faster and more simple to get this data off of the chain we do that for all of our factories and it returns like this pairs address this pair format which you saw here with a bunch of data of the tokens in there and then the pairs and so the next step for us is taking this giant array that has been created and we're just going to decompose this data now getting for each of the pairs that have been returned what's the pair address yeah for each of the pairs that have been returned what is the address of the pair which is the second thing and then uh what are the tokens that are inside of it and specifically we're looking for tokens that have heath in one side of them or wrapped each wealth and if it does not have heat inside of them then we're just going to restart our loop we're not going to do anything with that pair but if it does um we perform one check to see if this is blacklisted for some reason um maybe there's like a pair that acts really weird and you can never arbitrage it but it screws up your bot it's added to a blacklist but if it has eth and it is not on the blacklist we then create this object to help us interact with it and we push it to a list of different markets that we're having that we will interact with and yeah so the end result of this to reiterate is we've looked at all these different factories and using our query contract we've gotten all of the different pairs that existed on them we've narrowed them down to only things that have weft or eath inside of them and then we have pushed them into this uh array called market pairs i will try grug to leave this up but i'm not sure i don't know look i i haven't streamed before so this is new to me i will try to record it and make sure that you can even view it uh gatheus asks why only what pairs the reason is that we pay our costs in web and it's very simple to pay your costs in what you make profit in so if i start with one weft and i end with 1.01 and i pay like um you know 50 of that to the miner then i know i've made pure profit and i don't need to handle like pricing risk over time if one asset rose or fell and i don't need to think about what the profit of some other asset was at the time i know that like that's strictly profitable in terms of eth for me but if this was instead die and we were only arbitraging die pairs or something else i would need to think about what is the relationship between wealth and die am i long die am i like inherently long die if i'm taking profit and die but i'm paying costs and wealth so you can do that it's just more complicated and as long as you're fine denominating your profit and loss in eth it makes more sense to just strictly arbitrage to start and end any yeah all right so we have all our markets we know where we're getting data from um i think that all made sense i hope and yeah let's return i forget where i was all right so these are all our pairs all of our markets that we're getting data from oh and steph had to go thanks for joining stuff appreciate it so here we're just like transforming this object to make it a little bit easier to interact with we're telling where weft is on this instance scott you know typescript better than i do so maybe you can talk about why this is useful here if you're by your computer um when you're talking about the which part this chain yeah so 84 to 94 what are you doing here and why is this useful um this is just um some something called lowdash which just allows you to kind of more in more of a flow like extract bits of data without kind of creating a for loop and um you know like adding adding values to the end of an array it just sort of uh takes a bunch of these things and kind of makes it a little bit more like pythonic really kind of a little bit things kind of flow from one state to the other so it's just a simple way to group things yeah and like functionally you're looking for which of these you're like assigning and knowing where the position of wealth is and needs right and grouping them by that way is that right i think that's right and i think scott also yes yeah yes that is right yeah yeah okay great um yeah so that makes it much easier for us to interact with and nice tricks with lowdash here so then this is an important line we have 96 here we have all these different pairs and we need to have continuous data for them every single block and so we're going to update our reserves for those pairs like we've just structured these in a way that makes more sense so we're ending up with this object all market pairs here and we pass it into update reserves along with our provider which helps us get data so update reserves looks again at the contract that we're using to batch our queries here so unit swap prairie it will be familiar now if you're paying attention um we get that then we make a simple object that has all the addresses of pairs that we're interacting with and they should keep the same ordering of our market pair object as well just kind of for yeah for the console's sake we print how many addresses we're looking at and then this is where the the actual magic happens here of getting data so we we create this object called reserves which looks at our query function here and the get reserves by pairs and plugs in all of our addresses in this large array here so let's look at this okay so again it expects that you plug in an array of different addresses and actually this is a uniswap pair object so you can just directly call call functions on this instead of reinitializing a pair it's kind of useful and then we're going to be returning a bunch of data here in batches because that's faster again so we create this object that has a length according to the number of pairs because our our goal here is to return the reserves for each pairs so the array should be the length of the number of pairs so we'll have reserves for each and then we loop over each of the pairs and we call this get reserves function on them maybe i can just like show you all what that looks like on a random pair so i just like got a absolutely random pair i don't know what this is literally i have no idea but it doesn't matter since it's a unit swap pair they're all the same we're calling this function get reserves so a reserve is the amount of uh token that exists in a pair so if it's a unit swap and die then a reserve would be like the amount of you of a uni token you have or the amount of dye or the amount of eat or something like that and then it also returns this block timestamp lasts so when it was last interacted with but that's not as useful for us we're really looking for this reserve and this reserve because those can be used to figure out the price of different assets let's return here so we get result zero that's like the first reserve and then result one that is the second reserve and then result two here is the timestamp that's included with these things um and you loop over each pair and you do that for all of them uh fmo sturtz asks how would you get reserves such ticks prices on v3 the answer is i don't know so let me know i didn't spend the time figuring out v3 and like upgrading my searchers to that it has more of a learning curve and so it's much more difficult for a hobbyist to figure out and reason about but i imagine that it's like fairly simple i'm sorry fairly similar to what this is where there's a function that you can just get the result or get the ticks rather and then you'll need a reason about it in the same area that we do here and it probably makes sense to get them in batches so we go over each of our different pairs um and note that this this is for all pairs across all the markets we're looking at it's not just like uniswap or sushi swap it's uniswap and sushi swap and any other factory addresses and we get those and we return them in like this giant array here called result and then this step looks at for each of the different markets that we had before we're going to loop through those markets as well as our pairs and we're now going to set the balances of the reserves internally because that'll help us uh interact with it and pull data out before i'm sorry later when we're like figuring out pricing and like how much to trade where and what not so to double click on this section this is actually maybe the most important part of this entire process is how you get data off of the chain and how you structure it on your searcher it's super important to have like all the data that you need and then to do as many calculations as possible off chain uh and to do that in fast ways as well that's why we're using batching the reason why that's important is because flash pots bundles are prioritized according to gas price and so every single thing that you do on chain will lower your gas price and make your bundles less competitive according to someone else if you can do your computation off chain and only input the minimal amount that you need into your functions and only do the minimal amount that you need on chain then you will have more competitive bundles and oftentimes this is just more simple anyway so this process of figuring out what data you need and how to get it and how to do it in a quick way is extremely important um and for some of the recent searches that i've written this is the majority of the time that i spent is actually on this process of getting data figuring out what data i need and how to structure my bot and yeah not only have the data but store it in the right way and make sense of it so super important all right let's see so we updated the reserves and then what so it looks like here we're doing another low dash thing uh which helps make it a little bit more pythony uh you could like sort of think of this like a mini layer too that does save this computation i mean we're really like all this computation could be done on chain and it is done on chain regularly it's just not necessary to do it and if you can do it off chain that makes you more competitive hey tuba thank you for joining i am a uh huge dota fan also i was ranked 42 in the world for terra blade at one point just made my face a little bit larger as well so i'm gonna like put that a little bit down um we got our reserves we updated them and then we do like this low dash chain thing again which just helps us sort our our uh our object in a way that makes sense so for us we're filtering by pairs that have a balance of each that is greater than um this object ether and if you click into this we're looking for things that have a a balance of higher than one ether that's what this object is so we only want to look at pairs that have more than one ether because anything that has less than one ether it probably doesn't have very much money in it and there's not much money to be made and so we don't want to spend time and computation on those things so we're just gonna filter them out and then an important thing to to also realize here is we're using big number which is a library in ethers that helps handle really large numbers so on chain many numbers that you're interacting with are like 10 to the 10 times 10 to the 18th or you know 321 times 10 to the 24th these are extremely large and oftentimes the languages that you're working with cannot handle them normally and they'll like round up or do something funky and so to get really precise variables which we need we need precision you want to be able to do it down to the single way you need to use special libraries and in particular we're using this library called big number which is really good at handling big numbers as you might be able to tell we filter by the things that again have greater than one ether in them and we return those as well as our market pairs and let's come back so actually all of this happened in startup none of that actually did anything in production like not a single block has passed and i can run this for you all and you can see what it is i have like i i have some stuff in my environment here and then i'm just using random private keys for my addresses right now this will not output anything for a couple seconds because we're running like this really really large query to our smart contract doing this batch so first like in the background right now it's just like crunching numbers getting all these pairs by index and returning them from our node and then it's going to get the reserves by pairs and return that too so that that should run it'll like take a couple seconds to load up at the start because it's a really large computation so we'll go on and we are listening to a websocket here i think for the event of a new block so every single block you're going to want to return you're going to want to update the state of these reserves and then like see if there are new arbitrage opportunities so we watch for new block opportunities and we update the reserves in the way that you just saw that we did this is like a pretty usual architecture if you're looking at the last state of the chain for advanced bots you will be watching the mempool for pending transactions and that's like one big difference for other bots but for simple things like this bot it's fine to just watch for the the next block so we get all of our different reserves and we evaluate our markets here this is where some of the action goes on oh here we go we have a result from our initial computation so i just ran this script and that entire time that we were waiting between when i ran it was like this part literally like only this uh as well as the setup that was going on so it takes a really long time to start and then it'll take much less time going on after that but since you need to get all the pairs and that's doing like tens of thousand different calls it'll take like a long startup time so what did that do like again we yeah we got every single market across all those dexes and then we um narrowed it down to only a thousand two hundred and eighty of them because those are the only um the only 1 280 different pairs that have both each and more than one each balance in them so those are our conditions we don't want we don't want to look at anything else it's probably not profitable or it's profitable in a way that we don't care about like another token rather and we'll get into it and like how we got these numbers but uh it's actually like a very profitable block wow so just randomly i ran this and it was 3.5 worth of profit on a volume of two that like almost seems wrong so something may have gone on there but something wrong may have happened but uh a good sign yes so what happened here what happened here is that uh there are scam tokens out there and this thing does not filter out scams oh i see yeah so like would this have drained our bot or is this no no we would just i mean we would just simulate it and be like oh that's that's not valid or even when we send it to the chain it would be it's going to have it's going to ensure that it makes a profit but um just by looking at the reserves it might think that there's something profitable when those tokens are not transferable at all i see yeah interesting so i'm gonna keep on going here we evaluate our markets um and that performs the stuff that you're seeing in the console now like figuring out what the profit is as well as what volume need to trade and where so we take all of our markets here i've been talking for a while i feel like i'm going kind of slow so i'll try to speed up but let me know if i'm going too fast or too slow or whatever uh we get all of our markets by our tokens and we look at for each token in the market [Music] we create a for each token in these markets by tokens we then get out a new object called markets so what this is doing is it's like we want both eath as well as die and we want to know all the eath and die markets and by knowing all the eath and diet markets that like subsection of all the markets together the four or whatever there will be we can then uh compare those against each other to understand what the price of selling tokens in is and what the price of i'm sorry buying tokens is and selling tokens so we create like we filter down to one particular token um that is trading against eth and then we figure out what you can buy that token at or sell that token at which is kind of helpful for us and we do that for each token besides each itself if we know what price you can buy them at and what price you can sell them at there's like this very simple heuristic of can you sell the tokens at a greater price than you can buy them yeah and i think this is taking two different markets from each of those and saying like on unit swap can i buy mark can i buy tokens um at a better price than i can sell them on sushi swap and so you take both uniswap and sushi swap and you push it push these crossed markets where you have this price differential to this new object we're creating called across markets so this is where we actually figure out if there's an arbitrage opportunity at all or whether we should look at it but we haven't priced it yet we don't know how much to trade in and then now that we know which markets there's some kind of opportunity at we can get the best cross market so um let's see what does this do we put in all of our different markets that are crossed here and their token addresses so this is like uh every combination of unisop and sushi swap and like lua or whatever the other forks are for dye we're looking at what are the best crossed version of these so if i was going to trade die where would i trade it across all these markets so we break these down to where we're selling where we're buying and there's this like super naive way of pricing these things uh it makes me smile god bless you scott for making it this way um in production you probably don't want to do this but it works for just like a test case and naive you have a couple different volumes of things that we can trade in and this simple bot looks at each different size in this volume array and says for the size how much profit would i make by buying tokens on one market and selling them on another so if i'm buying um you know 1 100th of an eth on the first market taking that output and selling it on the second market how much profit would i make if anything and um if there is no best market and if it is uh less than the best market that we found thus far okay so if you haven't found a best market so far then we try to like optimize that a little bit more if we have found a best market and the profit on the current volume is less than our best market's profit then we try to optimize it a little bit more so this is like just a little bit more volume to this and actually all of this code is done off chain tessa sticks so all this is done in like javascript instead of solidity um so again if if our profit is greater than the past most profitable position we found for this particular market like dye unit swap sushi swap then we create this structure called best cross market and add it there to record like here's the best combination that we found for this thing and by looping through our different types of markets and our different sizes you can return that object to help us to then trade on again doing volume in in this way is kind of naive and it actually won't make you profit because someone will always be able to um price things in a better way but there is a great paper that you should read and try to figure out on your own that will help you price things in an optimal way it's written by a couple different folks that you probably know from twitter and it lays out the problem of how uniswap works and why and it gives you like a mathematical framework to reason about the price of unit swap uh how it relates to its reserves and how you can actually find the optimal arbitrage so how you can set up the mathematical problem such that uh you can get the amount in to give to a certain combination of pairs to get the maximum amount out and they don't give you that uh like just as is um so they won't tell you that in a lot of granularity but if you wanted to you could think about this in particular and derive the mathematical equation for yourself to get that optimal arbitrage and then there's something in the appendix as well that will help you with that if i recall correctly yeah so you want to take this maximization function and like implement it for the specific case of trading between two different unit swap v2 pairs uh and then solve it for the optimal amount in to maximize your function and i will like i won't leak any more alpha about this yeah this is a fun problem for you all to get through it's all right we have returned a bunch of markets uh with the tokens and the optimal amount for us to trade on them so we know for a given market i put in this amount and i get a certain amount out and given the reserves that we got earlier we know that that's profitable that's like the evaluation logic of any searcher that you'll have we went we got all this data we structured it in the right way and then we go through and we evaluate each of them and again we're doing all this off chain we don't want to do any of this on on chain please don't it will pain me if you do this so we'll physically be hurt if you do this on jane because it's gas inefficient so in first get data then we apply some evaluation logic to it to understand what uh our parameters would be to execute it on chain and now we have those parameters so we are about ready to make a trade you all and it is this section um here that you're looking at in the console log so this like we're printing each of our different cross markets with the profit and the volume down here along with what the tokens are and we return to our arbitrage function and to now capture these and execute some flashbacks bundles and some arbitrage make some money so we pass in our best cross market uh structure here which again tells us like how much to trade on what pairs and what our expected profit is and we generate some console logging about this that you see down here somewhere yep so send this much weft and that's in way so like token speak or whatever i think this says 2 eth actually 2 times 10 to the 18th and you expect to get 3.5 eth in return and then i'll like run you through what these are either and another very useful trick when interacting with these things is you don't actually always implement the function that you want to interact with directly on chain and instead you generate the byte code for what interacting with the function with a certain set of parameters would look like and you only pass that byte code in on chain and so in our case these payloads are the byte code for executing certain parameters on chain like buying a certain amount of asset on a certain unit swap pair so this fight code right here is like for our uh like scam token earlier albiet of a profit of 3.5 each with volume 2.
on the first pair i want to buy 2 eth worth of this token and then the second thing in the payload array is now that i have these tokens i'm going to sell them for 5.5 heath and make the 3.5 profit so we're this by calls thing right here is generating that byte code data because we're gonna it's like easier to interact with pairs in that way instead of directly implementing that interaction on jane although you could do that too scott maybe you can talk about like what the advantages of using this payloads and target method is over like implementing a pair swap directly in a smart contract like why did you make this design sure um so there's a couple reasons one is that this is very kind of uniquely enabled by flashbots before flashbots you would submit a transaction and you know you don't really know what block it's going to land in you don't really know where in the block it's going to land in and so what happens is in a normal arbitrage that didn't use flashbots you you you have here's what a pair looks like i need to like wake up i need to like see what the reserves are right now because they could have changed between when i created this transaction when it landed i need to do that calculation because i don't know what those values are but but with flashbots because you target blocks and you always land at the head of the block you have this just massive optimization where you're like i already checked this in my code i already know what the reserves are i don't need to ask those questions on chain and so the the gas savings that you can get from um from kind of just constructing off chain just the exact payloads means that not only does this like save just an absolute ton of storage reads that you don't need to do it also means that you can upgrade this contract to use brand new um brand new exchanges and not even upgrade your contract because all you need to do is pass in new targets with new call data um because it doesn't even know that it's talking to uni-swap it just knows if i send this contract this these bytes i'm going to go from this much asset to that much assets so it's just it's ultimately flexible very very cheap and very um very uh enabled by the way the flashbots works amazing that was a excellent and succinct answer so thank you i didn't even think about like the storage reads that you would do um if you're not interacting directly with this but yeah it physically pains me like i'm not even joking i cringe whenever i see a bot that like gets the reserves when they're using flashback bundles because i know they're less efficient than they could be they could be making more money and winning more um so yeah this stuff gets input into our smart contract i guess it's like the right time to look at that where this is actually executed we saw the monitoring smart contract already but let's look at the bundle executor smart contract so we in our arbitrage where did that go so we've gotten these calls of buying and selling things and our targets here were to point these calls these pieces of data um go to that is a good question bombardier and i will get to that in just a moment so we have like this data for a function that we're going to point it at something but we need to know where to point it so we pointed at our targets here and our targets are ordered as our payloads are so our first target is the first pair corresponds to the first payload second target second pair second payload right it's one of our inputs here and we plug that into our contract here under targets and payloads uh in addition to some other parameters like how much we pay the miner and how much we're trading with and we first select sanity check before we do anything are our targets and our payloads the same length if not you messed up not sure like where but somewhere you messed up not really sure how you do that but and then we look at what our balance was before this is super useful in order to make sure that we made profit here and we optimistically transfer our eth to the first pair um so we interact directly with web here we go to the first target so our first pair and um this is the volume that we're going in here right so this answers your question bombardier do you need approvals and the answer is no you don't need approvals because of a nuance of how unit swap v2 works in unit swap v2 uh if you look at the actual code for a swap i think it's called swap yeah if you actually go into the code for the swap there's no approval it doesn't take any uh any eath from you it just assumes that ethan sent the contract and then it performs some calculations in order to make sure that the amount of eath that you are asking for at out makes sense so it's a little bit weird of a flow but you send eth to it and then you ask it for a certain amount of eth out and the contract assumes that you've done this and it'll check to make sure that like the amounts that you're getting out makes sense and don't break the x times y is equal to k constant function and this actually has some gas savings as well so it's very nice not needing to do approvals it saves you the gas of doing that and we in fact are calling the low level swap function here which is what our payloads are so we transfer eth to the first market um and then we start looping through our different targets here and start calling our target we go to the first pair call with this first payload which is basically i want to buy this amount of asset and i want to get out this amount and our payload is like some information for this swap function here so actually our payload says like i want x amount of amount 0 out i want y amount of the other token out i want it to go to this address and then we never really touch this parameter it's useful for flash loans and nothing else so i'm just going to like say ignore this parameter you you won't need it at least in the simple arbitrage repo that's what our payload is it's just like parameters that go into these in this function and so we're calling at some address in our target address that function with whatever the parameters are in our payloads and we make sure that it's successful and we get a response if we want uh we have a require so all of our like swaps need to be successful and that's actually where the swaps happen in our trades here um so if you went you looked at a trade on unit swap i'm sorry someone arbitraging these things that's this is the line where the swaps actually happen after all that stuff off chain yeah sorry david i'm like trying to record i don't not entirely certain whether or not i'm recording or not um maybe twitch has like a native recurring recording thing and then after our swaps have happened we just make sure that we didn't get wrecked somehow that our balance of our contract in weft is greater than what it started so before we did any of the swaps we got the balance of wef and then after we did our swaps we got it after and then we just have this very simple requirement our balance after needs to be higher than our balance before uh plus the amount that we paid to the minor so it's like overall profit if we're not paying anything the minor i'm not sure why um if you're using flashbots you'll never get in but nonetheless if you're not then we return we're done here if we are paying something the minor then we need to make sure that we have enough eath in order to call this very special function to the minor that pays them so this yeah we're getting like the right amount of eath here making sure that we have it and this is super important for flashbots so pay attention to you all um normally when you send transactions not to flashbacks bundles you need to pay fees to the miner for including your transaction through gas fees so tengwei it's like what you see on metamask something like that through flashbots bundles and our special client ethereum client called mevguf you have the ability to pay the miner through a smart contract call called block.coinbase.transfer and this enables like a lot of super interesting things in particular in this code our block.coinbase.transfer happens after our requirement that our balance of wealth is greater than it started okay so we make sure that we've made profit here and then after that we pay the miner through block.onebase.transfer ether amount to coinbase right and what this means is that if this condition that our eat after is not greater than before uh plus coinbase transfer then we won't pay the miner anything they'll get zero and um since they get zero amount of eth the miner has no incentive to include our bundle so the miner will only get paid if we are profitable and since they're only paid if we're profitable the miner only has an incentive to include our bundle if we make profit and everything goes as expected and then you can do a bunch of other fun things here so like if some other condition is not equal to true uh then return or you change the amount of coinbase accordingly like else if some random state is not equal to whatever then change the amount of coinbase that you're paying so being able to dynamically change the amounts you're paying and require that you're successful in order to pay the miners and fees is extremely powerful and i suggest that you leverage it very much so that is actually the smart contract where we are where we're actually arbitraging markets and interacting with them and executing our trades that is most of it folks oh i i should also see how you uh not the founder of youth for some reason i just look older in my picture everybody says i look like 45 i'm 25.
that drawing of me just makes me look really old i don't really understand it looks young to me but thank you gibbs i appreciate it i think question mark but uh so our last thing here is like we have our transaction instead of just sending it normally we're going to get the details of the transaction so we can send it in a different way yeah i'm trying to record this everybody i'm not really sure how to do that and a couple people have told me but i don't have twitch studio uh i'm using obs so there's like a let me see this yeah i'm now recording on my local aubs not sure if twitch will record it as well uh someone eat this bro for twitch studio i didn't know that was a thing so let me see i'll get back to the code in just a moment but i will try to record this really quick yeah so i'm not using a stream key um i'm just using obs and i connected my twitch account and i hit start streaming so i don't really know what else to do there should be under settings and streams nope not there folks well my promise to you all is that if i don't have this recorded at some other point in the future i will do more of these sorry i'm not good at twitch but well i do have record now on obs uh but yeah i wasn't doing that the whole time though that's the unfortunate thing i i'm going to return to this now so sorry everybody um now we so yeah we have our transaction and you just saw how we would execute it unchained with our contracts and whatnot instead of just sending it on we populate the details of it and we're going to send it in a special way so in a flashbots bundle particularly so this is like sanity check right here we estimate the gas of our transaction and a lot of the times if uh alexton i will answer your question on latency i see it and i will address it but let me get through this so a lot of the times if you simulate a transaction with estimate gas and it fails that means that your transaction was going to fail for whatever reason you don't really know why but like estimating something and if it fails to estimate gas uh most of the time you should just discard it and put it away and say like i'll get the next one so we try to estimate our gas here and if it does not work then we just throw away our transaction and we have like another guard for it being like weirdly large in case we get wrecked for some reason like if someone was using us to print a bunch of chai tokens or something but if our gas estimation succeeds that means our transaction probably will as well uh if it landed on chain and we go on to create a bundle so flashbacks bundles look like this if like an array of transactions including the signer of the transaction and your transaction details and then we if you had a more advanced transaction you could just sequence a bunch of stuff like this so this is our first transaction number one but like maybe you want transaction transaction number two and transaction number three this is super cool extremely useful for unique uh opportunities and like things that you can't do in the normal mempool and in particular bundles and all these transactions need to be executed all or nothing and all in the order that they are so you could take some action with this first transaction and then immediately follow it up with some action with the second transaction followed up with the third as well and precisely bombardier you're right if i had a signed transaction i could plug that in here so i don't even need to make the transactions myself i can just go to the mempool and i can get a transaction and plug it in like this and again like doesn't need to be mine i can just pick a transaction out of the mempool and plug it in here and like for example maybe an oracle update or something like that where you're trying to back run it be the first to liquidate someone else so you put the signed transaction in your bundle and then the follow-up is liquidating the oracle update so this is super super useful and the entire transaction you want the signed transaction so it's like the rlp encoded transaction i don't really know what that means i just know that you need a transaction that has been signed by some ethereum key which is you can get that from the mempool um yep okay we we've created our bundle here we're almost done and then i'll let you all ask questions uh and yes you are right marty joe this is how they snipe liquidity events on uh the same block that they're deployed so for our sanity we uh console log the the bundle which is actually like what this looks like here this is a bundle with our signer and the transaction data flashbots takes signed bundles to authenticate so we sign the bundle with some private key we saw that earlier and we simulate the bundle of the flashbacks relay to make sure we're not just sending junk to it so you simulate it the flashbacks relay will return the simulation with some information about it like how much gas it used if there were any errors how much you paid to the miner and if there was no error then we continue and we actually send the bundle and one thing here that is uh important is we're sending our bundle not just for the next block but two blocks into the future because sometimes miners mine blocks really quickly so if a block is mined in like a second you want your bundle to be there and be valid for two blocks into the future so it could get executed then in addition to the next block that's why we send both here okay that is all of the simple arbitrage repo thank you all for like sticking through this is like a long stream now over an hour um scott if you're around and you have anything to add to that feel free to otherwise we can like take some questions um and there's one that i keep on putting off now i just want to say that this is uh it was named simple arbitrage really to highlight that it is extremely naive in many many aspects this is really not going to make you probably anything because many people run it and it's just not a very optimal way to perform arbitrage so it should serve as a framework to build um you know your own bots that have novel methods of extracting mev and maybe serve as a good example of that and not really something that you're going to get up and start printing money and please don't put money in it and expect us to help you if you don't know what to do it's like a big burden whenever that happens so please understand what you're doing if you throw a lot of money into this sorry to interrupt you scott no no it was otherwise really great but i appreciate the uh presentation i i learned something about my own code video what did you learn you wrote this card i just got i forgot how it all like fit together you know it was a different time you know yeah it was like six months ago for you so yeah i was figuring that out on the run it's been a while since i like read symbol or josh or ran it myself [Music] yeah let's take some uh let's take some questions you all uh so there's one question earlier that was on whether latency mattered the answer is kind of so there's a there's a block that's like every 14 seconds right and uh that means on average every 14 seconds but sometimes blocks are much quicker than that could happen one second or even quicker and if your bundle is there within that one second on like the very short end of block times you could be the only person that is competing for an opportunity this is a major alpha leak i don't think all searchers know this but um but it i'll tell you the alphabet whatever uh so if if you are really quick and on the short end of the block distribution say you can get a bundle there in a second you can underpay comparative to what you would pay later in the block or in like the block time distribution so at seven seconds in everyone else that's running simple arbitrage will have their bundles in and they'll be competing with you but at one second in you're going to be like the only person that has a bundle in and you'll have no competition and because you have no competition that means you can pay way less for the same opportunity and so the optimal strategy is actually to pay very little if you're very quick and then up your bid after that over time so alpha leak there latency sort of matters on some things [Music] but you can win it really depends on what you're doing and like you can underprice things if you're really fast i think that's why latency matters and you'll win a couple things um hope that made sense a 9800 says so if the block time is less than seven seconds you win like what the point i'm trying to make is is like the longer the block goes on the more opportunity there is for other people to submit opportunities and that means other people will probably be bidding higher amounts and if you can submit an opportunity in a really quick way then you don't have to be competing in the auction with them you may be the only bid in the auction so to speak so one second in you might pay 20 of your profits and seven seconds in you might have to pay 95 and those aren't uh exaggerations either okay so what sort of time frames should one allow to become proficient at that so at this sort of stuff uh it depends on your starting point but i feel like if you already know solidity and node.js um then i'd give yourself like three months something like that to try to write a new searcher and make profit if you're really dedicated to doing this like but that would be writing completely new searchers and making profit in new strategies um yeah i don't really have a good answer for that scott do you have any opinion like how long should someone give themselves for a learning curve before they stop i mean you should never stop you never give up um yeah i think that's good i mean you could probably get i would probably just start with like fake mev first you can land some like fake muv where you just like pay the miner you know 0.001 for nothing and then you know go from there to see if you can you know find some small little small little arbitrage maybe based on simple arbitrage or maybe try to optimize i think you can get there probably um i mean it's rising a few months there's just lots of weird little edge cases um one of the best ways i've i've found is that the the discord um we have for flashbots has a hashtag searchers and there's just like lots of people very open about their experience and where they're at and people from all different skill levels things are really great place to you know even learn about alpha people talk about new things in there and be like oh i'll try this this you know it's a really small thing maybe it's not worth other people's time but it's a great learning opportunity to like extract you know 0.01 per block or something yeah tons of alpha leaks there no unbelievable amount yeah so let's see um drew's apple question is it possible to deploy bundle executor inside of the bundle yes it's very cool um you sort of it's like virgin eth because you can start uh your searcher without having any you can use the profit from some opportunity to deploy a contract the transaction before it's like kind of mind bending but because a bundle is executed in a sequence in all or nothing you could deploy your contract in the first transaction and then execute an arbitrage opportunity in the second and actually this fellow on twitter called mev alpha league i had him in my bar any of the alpha league did this [Music] they are this bot operator i hope you're tuning in i love your content and your contract on jane but this bot operator that deployed their contract um in a bundle and then arbitraged it within the same bundle without having any from their contracts it's super super cool to do that so yeah you can definitely do that uh somebody asks i'm sorry i can't pronounce your name regarding this naive code is modifying naive assumptions enough to be at least effective with this bot i think you might catch some things if you got your pricing strategy better so uh this part where we're just doing um i'm gonna close this as well this part where we're just looking at different volumes and like uh running through each of them um if you could figure out the optimal amount of ether to put in then i think you would have a much better chance of landing stuff on chain and making a profit and yeah you'd probably have to bid pretty high in order to make that work but i think you could you could get in some transactions like this um you won't yeah i think so i think that's the big i agree that's the biggest problem the other thing is that it doesn't do multi token hops it's really just you know a to b b to a and so you're not going to find that many of those because most of the best ones are going to be multi-hop but it's not gas inefficient so you're not going to lose on gas and efficiency so any a to b b to a i think you could be competitive yeah so figure out how to do a b b to a in an optimal way and then implement multiple markets and that will be a little bit more efficient um so a98000 asks do you resend the bundle with higher coinbase transfer that was like the earlier thing about the auction and latency uh yeah you would so that's how you like rebid um royal roar right oc i think that's how you pronounce your name i don't know uh asks if i could submit something live i don't have a contract that's set up to do that um but i can like run this code and that does everything except for submit um so this will run in the background and it'll do everything except for submit but i don't have the contract set up unfortunately so let's see uh where would the flashlight be be at the high level oh you asked the right questions so i actually in the very very very very early days of flashbots um like january i think i made a pull request that you can find here yeah january 18th i added a flashlight to this thing and you can look at my code here for how that works but in short um everything is the same and how you actually execute stuff except you need to call of a and get a flash loan in the way that they expect so you pass in data through this params object then you ask ave for the flash phone here ave calls back your contract on this execute operation function so right here you have your eth and then you're able to execute the same parameter basically as before of swapping on particular particular pairs with the parameters done through payloads like before so then it's the same that's how the flashlight version works and we're coming out i should also say that we are going to update this repo slightly and deploy a flash loan version that anyone can interact with so you won't need to deploy your own contract you won't need to have any you can just run this repo and point it at our smart contract and you'll get profits in your account actually which is pretty cool but um yeah all those caveats about this being naive and they're like being better ways but i will say the nice thing about it though is because it uses that really low level target plus call data you could even modify it to you know include v3 capabilities and um you know you could integrate v3 just by modifying client-side code and not even having to redeploy a new contract and so the only thing um is is you need to look at v3 and see whether this wealth transfer is still applicable right yeah i think that what v3 might be a bad example i think that that might not actually be possible because they think that b3 always requires a callback but you know any other you could implement anything in there you wanted to so yeah i'd like three maybe personally done used essentially this code with a little bit of alteration um to transfer like first unit swap v2 and then curve second or balance or something like that uh those two i know are possible so you could edit this yeah to scott's point to like look at different markets and use the same contract to do that all right um i'm getting to the chat here you always i'm sorry kind of kind of slow what's what's my take on flash loans probably too gas expensive and you will not be competitive but it's a good way to get started somebody says dydx flash lines are cheaper than ave that is right in that they are cheaper in fees if you're moving in size ave flush loans are cheaper in gas so if you want to take out small flush loans use ave if you're taking out large ones use dydx and that is right um the other aspect is because because this is unison b2 i think there's actually like nearly free flash zones kind of just built into doing any swap on v2 so that could be something to consider for your own modifications just relying on the v2 built-in bytes called data oh yeah that's a good idea yeah yeah i don't know how that would work though but so you can figure that out you can figure that out i think that that idea like makes a lot of sense to me please open a pr if you figure that out contribute back we'd love to see it um oh and like in the background here i am trying to submit bundles and failing because i don't have a contract deployed but this is actually what it looks like when you're running in production maybe i'll just like pull this up you all can see it um somebody asks is there a way to make a sandwich bot suffer from an uncle block uh yes there is that is too much alpha and uh i'm not gonna tell you how to attack other searchers unfortunately you have to figure that out um jay says you mentioned the public github repo in your youth global talk uh i don't know what the time frame is on that i need to clean it up and it seems like the synthetics people may actually go ahead with that liquidation opportunity in which case like i'll make money from it and i don't really want to hand that money on a platter for other people to take from me so at least i hope i will so whenever the opportunity passes i'll open source it i thought that it was no longer available it apparently still is and i just like showed everybody my code which is unfortunate uh yeah so david o bentley says can we try these mev arbs and test out other chains is there an ethylene you can test it on gourley um so unit swap v2 exists on gourley as does flashbots so you can send bundles there maybe like a little bit weird trading on v2 but you could uh create artificial arbs on gourley um if you wanted to and test it there um so i think that's like peter dinero pet no pedro dinero uh says you mean multiple hops not multiple markets uh yeah so we mean um both of those things so could you go from like eath to die to usdc back to eat as opposed to just eat die eat that's one thing and then you could also trade like uni swap the curve to balancer to unispot something like that a red hawk yep the repo is open but the other one is not you're gonna need to integrate v3 yourself unfortunately then so foster fm moster says something about whether collusion between searchers plays in the success of an arb strategy i'd say when there's a small amount of people that are all going for the same things then definitely for this code what you're looking at probably not because there are so many different people running it you're not gonna be able to get into contact with them um and so there's no real way to collude but there are relatively few people who um submit arms uh and as such if you can find all those for v3 people you can actually collude with them but since the v2 arms are like much more difficult uh collusion actually makes sense there so only if there's a small amount of people on your strategies tessa uh all swaps and v2 are flash flops uh i don't know if all swaps are drew that's a good question i don't don't know um if your bundle's using too little gas how would you increase the usage it's like a weird question because there's like very few things that you would legitimately do that get under that limit um it's kind of weird but uh if you really wanted to you could just split your coinbase payment into like 10 things so i could show you how to do that so uh yeah here in the block.com based on transfer instead of doing it once you could do it like two times or you could just do something where your bundle consumed more gas i think most of the time when people complain about that they're they're like stuff is actually broken um and they're not submitting anything that makes sense because there's like very little where that does make sense uh i hate kasha says can you use suganodi i don't know what that is uh so no idea what you're talking about but the answer is like maybe um sugandees oh i got wrecked you're right there you go wouldn't be proper proper uh proper twitch without having getting wrecked tweet about it get your clout i'm sure so any other any other questions folks otherwise i will wrap up i honestly didn't even read what you're saying a 98 000.
um yeah alex you're totally right so before flashbots uh when oracle updates were sent they'd be sent with like super super low now my friends are laughing at me in the background so so thanks uh katja but before flashbots um oracle updates were sent with super low gas prices and you just be like super annoyed because your your thing is about to be liquidated um you need the oracle update to go through or you're about to liquidate something you need the oracle update to go through and you just sort of had to wait for the low gas price oracle updates but you are right that now if you wanted to you could find an oracle update it in your bundle and then and then submit that through yeah and essentially like subsidize their gas to get it in earlier or you you could like include it in your bundle and then liquidate alone or something like that it's all right anything else you all and it's fine kasha i understand why you why you need to wreck me um thanks for joining david sure i'll try to do this more it's kind of fun i think next time i'll be quicker i like i spent a lot of time here at length explaining this stuff so next time i'll try to take less time up marty joe asks uh is sniping listing something that is supported by flashlights flashbots uh we do not discriminate against what people do on our platform so we're permissionless you can use uh flashbacks for anything including token snipings if you want or like wrecking other bots there's some things that are like i won't encourage you to do but i can't stop you so if you want to go like snipe the latest token and for whatever reason like go for it i can't stop you nobody can i hope you make a lot of money um jay jonah says using flash loans are not as profitable with flashbacks because of extra gas costs yeah so it doesn't necessarily have anything to do with flashbots it's rather like you will not win as much because of the extra gas cost so the gas price of your bundle will be lower because you have more gas because your bundle gas price is lower that means other people will win more often you need to be more competitive by raising your gas price higher uh i will try i will try saving this red hawk i like yeah um it'd be very nice if this like hour and 40 minutes of a walk through would be saved somewhere so i don't really want to go through this repo again for two hours um and then i can just point people to this but i'm not sure whether it was saved or not because i don't have twitch studio or whatever yeah uh and yeah of course like thanks to scott as well for jumping in at very late notice also with other people around so that was that was amazing he actually wrote this repo um lady gaga little monster asks is that contract deployed and by that contract i think you mean the uh like uniswap monitoring one the answer is it is deployed and anybody can use it so i'll go to it you can see yep it's here it's on etherscan it's in the repo you can like go find it and whatever all right folks i will take one more round of questions and then i will end um kasha we're we're not gonna let you wreck us anymore um any more hints on how to make the bundle more competitive in terms of gas uh i think that you need to like i think being very good at solidity helps and then understanding what data you can do ofchain and then what data um you need to do on chain and like thinking very hard about that doing everything you can off chain then learning solidity optimizations that also helps the very advanced stuff you can get all the way down in the evm um but in order to like have basic strategies if you're not competing for the v3 arms i think you'll be fine without getting down to the level of the evm um yeah so lady gaga low monster says can you also explain again why using a contract this is my last question um scott knows he picked up on that i got wrecked but lady gaga low monster says can you explain again why using a contracted query data is faster than doing it locally the reason is that if you are just interacting directly with the pair you need to make many different queries to your node so if i wanted to get 40 000 pairs on uniswap which is what you're doing when you run the script and i need to make 40 000 different requests to my node and that means i make a request my node needs to like make sense of my requests and then run it locally do some computation return that and then pass it back to me and each stage there incurs some cost of time and like in particular it takes time on the networking layer to return stuff to me and it it takes time to make sense of the json rpc requests as well like what you have what happens when you um interact with your node and if you instead can make one giant request that gets all the data that you want then you don't need to incur the cost of like making n different requests to your node and the time that it takes like makes sense the json rpc there and then you also need to incur the cost of like returning the data and the like the networking time that it takes to get the native data back to you um so instead of making you know n number of requests uh and then incurring those costs end times in terms of time you can make one giant request that gets your n different sets of data and it just like makes it way faster an order of magnitude quicker i have another one for you you might find interesting about the reason to batch your lookups oh yeah yeah yeah uh yeah so um so it is it is it is faster um there's like latency you know for all the reasons he stated the other one is that um if you are doing something like looking at the reserves for two different pairs if you ask those as two different rpc calls you could be asking you know you could be getting results from two different blocks whereas if you make the query inside of like a multi-lookup on chain you are definitely getting consistent state returns to you from at least the perspective of one block that's good yeah i didn't think about that that is kind of interesting um i didn't think about that before i guess that does happen fairly oh and then you're always synchronized on your code like all of your all of your reserves for everything is always synchronized as opposed to having like one on one reserve or one on block one another reserve is on block two another reserves on block three it could get like very messy without the reserves very quick yeah so any other advice you want to give to searchers scott anything else like last thoughts uh no i don't think so i think that the you know searchers definitely make the most money when they uh when they work together i mean you know the miners need to be paid for the services but you know let's not bid each other up to 99.99 uh right away and you know come over to to discord hashtag searches it's actually a really really cool um cool place just to talk to other people that you know maybe you're meeting on chain or maybe that people are more surprising surprisingly helpful uh even when there's there's money at stake which i think is probably one of the most fascinating discoveries from from starting flashbacks it's just how open people are with their elf i mean even um you know even bert today talking about like the timing that you know this timing escalation um i don't know there's it's the love of the game you know we do it for the clout this is why we do it cloud yeah yeah i don't want money i want twitter followers my whole game is is just monetizing and turning other people's alpha into my twitter followers so you leak alpha in mev searchers or our searchers channel i will post it on twitter and i'll get the cloud so all right folks i think that is it thank you again scott so much for jumping on uh and riffing on this repo all the advice and thank you to the couple people that tuned in um and thank you i hope to twitch for recording this i hope i can just like post this on youtube so thanks everybody i will catch you all another time gonna stop recording now until next time see you on jane
Up Next

Building a Uniswap V3 Arbitrage Smart Contract in Solidity
@smartcontractprogrammer
9.8K views•2024-03-24

Torrent File Format & Bencoding: A Technical Deep Dive
@AsliEngineering
12.5K views•2022-08-08

Operational Security Essentials: A Guide for Hacktivists (OPSEC)
@hitbsecconf
157.4K views•2012-11-26

Understanding Ethereum: A Comprehensive Beginner's Overview
@99Bitcoins
3.1M views•2018-06-26
Related Study Plans & Knowledge Roadmaps
Structured learning paths in Blockchain & Crypto



















![블록체인 핵심 개념 'MEV', 알트코인 수익을 최대로 끌어올리는 힘이다?|딥[DEEP]파이](https://i.ytimg.com/vi_webp/x3hwjS5iMJE/maxresdefault.webp)













![Weekly Updates SPECIAL EDITION BIG AMA with Alex Shevchenko [2022-12-30]](https://i.ytimg.com/vi/-8hAVyrE4fU/maxresdefault.jpg)





