0xBeans Profile picture
@frame_xyz | Once upon a time a @coinbase engineer. Enjoys long walks on the beach and some Solidity. 사실 콩 안 좋아해.
Mar 3 18 tweets 4 min read
Ohm devs cooked something called Baseline that supposedly is infinite liquidity, no liquidation leverage, and up-only.

FYI I bought tokens but it's genuinely an interesting mechanism - NFA, it might go down + I have some improvements I would make.

Here's how it works: Image First of all, there are 2 distinct products: Baseline is the protocol and $YES is the first token launched on top of Baseline.

We will go over how everything works.

Baseline effectively is an automated liquidity manager for tokens.
Nov 16, 2022 25 tweets 7 min read
During dev con, I worked with @real_philogy and @yush_g to create what we think is a true blind vickery auction, fully on-chain.

This implementation is just a proof of concept but we think it could be a powerful primitive going forward for all auctions in the future. Image Before we dive in, major props to @real_philogy and @yush_g for coming up with the initial approach and mechanic. Shoot em a follow, they're working on some real cool stuff.
Oct 5, 2022 15 tweets 6 min read
There's still some money to be made during the bear, so here's some bear market alpha.

Not sure if we'd even consider this long tail MEV but here's what @rauchp_ @wawrencelu and me have been doing to earn ~$700 a day *relatively* risk free and automated (since sept 28). $700/day ain't a lot but considering the amount of work needed (only needed 2 simple boys), pretty worth. Take what you can get, just bear market tings 🤷‍♂️

This number will go down over the weeks but here's a tldr of it, similar opportunities will probs pop up every now and then.
Jul 14, 2022 11 tweets 4 min read
6 months ago, I approached the smartest friend I know and some of the best pixel artists in this space (imo) to create something unique.

We came up with @OfficialMirakai and after 6 months, it's finally minting in 2 hours.

I want to tell you some of the coolest parts. First, there's a bunch of mechanics involved - deflationary items, changing rarities, token dripping, game theory, and re-rolling.

We had 3 main goals, create public goods, push the space forward, and create an interactive on-chain project. I think we succeeded at that.
Jul 12, 2022 9 tweets 3 min read
Just looked at the @WZRDSxyz contract and yep, they can definitely arbitrarily burn your NFT. It doesn't matter whether it's listed for sale or not, they can burn it (without paying you if it's listed).

They can also arbitrarily transfer your NFT to whoever as well.

Here's how: Image Typically, when you try to transfer an NFT or a contract tries to transfer your NFT on your behalf, the NFT contract checks whether you're the owner of the token or if you gave explicit approval/permission to the contract trying to transfer your token. Image
May 25, 2022 9 tweets 2 min read
I get like 5-10 DMs a day asking about how to get better at solidity (some even ask if Im taking interns lol).

While this may be rudimentary and somewhat "obvious" knowledge, I'll try to explain the concept that really helped me "get it" when I first started learning. When you interact with Ethereum, a majority of the time you're transferring some sort of token from your own wallet to another.

It's common to think "transferring a token" is an actual action of sending something to someone. ie the token is actually getting "sent".
May 24, 2022 4 tweets 2 min read
Im curious if theres any cool implications by fractionalizing NFTs into 1155s vs ERC20s - talking specifically about fractional ownership of NFTs

Most (if not all) fractionalization protocols split NFTs into fungible ERC20s - this causes slight disconnect between the two. NFTs are typical viewed/bought on marketplaces but ERC20s are bought on AMMs

But fractionalizing via 1155s would let both the NFT and fractions be viewed/bought on the same marketplaces -> less context switching, more seamless?

Also you can make the 1155s look pretty too lmao
Apr 30, 2022 12 tweets 4 min read
Just did a brief review of the Yuga OtherDeeds contract.

Here are some interesting things I found:

First, there is a lot of logic for a Dutch Auction. Yuga clearly said they're not doing a DA but the public mint still relies on a DA pricing functions. Unless Yuga is lying, I believe they wrote this logic previously when they did actually decide to do a DA but just left in this code when they decided not to do the DA (or just forgot).

A little weird though, I would think Yuga would've cleaned up their code before launch 🤷‍♂️
Apr 28, 2022 9 tweets 4 min read
If you want to experience the seamlessness of not having to 'claim' tokens, and just getting tokens dripped to your wallet, I deployed a Test ERC20 that uses DRIP20 on the Goerli test net.

Add your wallet to start getting drips. You'll accumulate .25 tokens per block (~1600/day) This is the contract goerli.etherscan.io/address/0x7947…

The token is called "mock". These tokens are worthless but its just to showcase how token dripping works.

Here are the steps to add your wallet and start getting token drips:
Apr 4, 2022 16 tweets 5 min read
Still nerding out so here's a little thread: 😆

First, the core insight is the fact that bitwise operation EVM opcodes uses far less gas than the arithmetic exponent EVM opcode. Bitwise operations use 3 gas while arithmetic exponent uses variable amounts of gas dependent on the number of bytes in the exponent.

For my use case, it was about 2-3x cheaper to use bitwise ops.

Just to illustrate:

uint256 var << 14 (338 gas) vs uint256 var ** 2 (782 gas). ImageImage
Mar 24, 2022 15 tweets 5 min read
Had a big surge in following this week! Since Twitter is atrocious at organizing threads, here are all my past threads (a mix of solidity/smart contract content).

Will add any new threads to this master list :)

Enjoy! 🧵 MEV sandwich breakdown 🥪 :

Mar 22, 2022 19 tweets 6 min read
Gonna end the $APE content with 1 final thread. Let's dive into how this absolute fucking chad borrowed 5 bored apes, claimed $APE for all of them, returned the apes, and subsequently netted ~600k.

A story of how a bot looked for value where no one else did. First we have to understand what flash loans are.

Flash loans are a DeFi concept that allow a contract to borrow large sums of money as long as the loan gets paid back within 1 txn.

If the loan isn't paid back in 1 txn, everything is reverted (as if nothing happened).
Mar 21, 2022 23 tweets 5 min read
Here's the awaited follow up :)

I'll clarify some questions that people have asked and also go over some easy ways to prevent getting sandwiched. How does the bot sell their coins at a higher price if the buyer already bought coins?

On DEX's, there is no buyer/seller. You're swapping tokens directly from a liquidity pool based on *math* that makes this profitable (I wont go over how DEX's work, lots of resources online).
Mar 19, 2022 19 tweets 6 min read
The viral txn of an MEV bot "selling 2.4 $APE for 946 ETH"

A few people asked me how this happened. In short, it didnt happen.

Seems like a lot of people that got hooked on NFTs weren't around during DeFi Summer in 2020 and arent familiar with MEV bots. Let me try to explain :) This txn is only 1 of 3 that are relevant. The bot didn't make $2.7M (and no trader paid $2.7M).

This is known as a sandwich attack. A lot of smart ppl have explained this, but Ill go over how this works with a real example (Im assuming you know how eth works on a high level).