Web3 Galaxy Brain 🌌🧠

Subscribe
iconiconicon
Web3 Galaxy Brain

Lending Protocol Arcadia Finance

21 July 2022

Summary

Show more

Transcript

Nicholas: Welcome to Web3 Galaxy Brain. My name is Nicholas, and each week I have a conversation with some of the brightest minds building Web3. On today's episode, I'm joined by Jasper and Thomas, the co-founder developers of Arcadia Finance. Arcadia is a forthcoming lending protocol whose modular contract architecture will allow users to deposit any on-chain asset into a user-controlled vault and withdraw a credit line against it. Arcadia lets users combine several types of collateral into a single basket and for loans to be borrowed against the cumulative value of that vault. A vault could contain NFTs, fungibles, and future asset types that have yet to be invented. Jasper and Thomas explain how this architecture allows for risk diversification and even more sophisticated funding strategies in the future. I had an exciting conversation with Jasper and Thomas. I really hope you enjoy the show. Jasper, Thomas, welcome to the show. Thanks for coming through.

Jasper: Hey, Nicholas. Thanks for having us.

Nicholas: Absolutely. I'm excited to talk today. We were just talking a little before we got started recording about NFT stuff. Do you guys, uh, do you guys buy NFTs often?

Jasper: Uh, for me personally, not so much, actually. Um, I have a couple NFTs related to some, uh, some blockchain games, but I'm not following the latest, let's say, trends with, uh, the newest NFT collections at the job, so I'm personally not really collecting a lot of different NFTs.

Nicholas: Yeah, it's hard. You got to pay a lot of attention to it.

Jasper: Yeah, indeed.

Thomas: Similar story from my side. I think I bought a few more NFTs than Jasper, uh, flipped a few, uh, I think a few months ago now I'm mainly collecting, uh, or bag holding the ones I, uh, I bought.

Nicholas: Yeah. I was reading the news earlier. I think I'm bag holding a bunch of staked ETH. Seems like Alameda is selling like hundreds of thousands of ETH worth of staked ETH or something. I saw a tweet earlier.

Jasper: Uh, do you guys know anything about that? It's crazy. Yeah. Yeah. Yeah. I've been following it a little bit. Um, but yeah, it's indeed strange that, that the, the state is, is depending a little bit from the, the normal ETH price. Um, yeah, maybe don't, they don't have a confidence in the merge happening anytime soon. Um, or they just want their, their, their liquid cash for, uh, yeah, now without having to wait for the merge complete for six months.

Thomas: Yeah. I don't know if deep bagging is the best word. Yeah. Since it's, it's not a synthetic token, really. It's, it's more a claim you have in the future. So I think it's more companies who are in need of liquid assets that can't wait until the merge that, uh, set it to a discount, but something like Luna can't happen with stake.

Jasper: Indeed. It's more the cost of money or the cost of time, uh, until you can actually use that, that, uh, those assets is locked there until you can get it out of the, uh, the beacon.

Nicholas: One thing that worries me, I mean, I, um, I'm not really worried about the merge not happening or happening late, whatever I did. My time horizons are not so tight and I'm not that good at managing capital that I need access to it. So, but obviously don't have everything in stake teeth, but I'm concerned about this, the LDO emissions being related to maintaining the peg. Obviously there's like some story in play with, uh, I've heard talk that in the Dow, they're considering, uh, issuing. LDO to compensate people for the socialized loss relative to the percent that people should be earning given that everybody who's in the queue waiting to be actually staked is also sharing in the current rewards. So they were, I heard they were talking about LDO emissions to cover that, which neither here nor there, although it sounds like a sort of variant on airdrop farming to have faith that they'll figure something out.

Jasper: Indeed. I think it's a thin line to walk. Um, if you have to start rewarding your, uh, your stakers with additional yield stokers, just to keep them there or to start to defend the page or, or not really the peg, but whatever. I think now that you mentioned it, we were once in, in, um, what was it called? Shared stake, I believe.

Thomas: Shared stake. Yeah, indeed. Competitor of Lido.

Jasper: Yeah. Yeah. They did indeed a similar thing. They also had some very high APYs, um, but that didn't really turn out quite well for them. Yeah. So for me, I think it's a thin line. If you have to start giving out token rewards or giving away equity just to start or just to try to get at the one, one, uh, ratio between state and eat again.

Nicholas: Yeah. But this is the, this is the actual part that scared me. Not so much the, um, yeah, the, the peg is somehow dependent on their LDO emissions to LPs on curve or something like this. Uh, that that's how the peg is maintained. I knew that there was some active management of the peg, uh, from the conversation we had actually on this show with, uh, some, a BD person from Lido. But, uh, that's kind of, I don't know. I don't love the idea of that.

Thomas: Yeah. But I think it's a bit of a panic reaction after what happened to Luna Tara. fiasco is like steak eat. Shouldn't keep the bag with eats. There's not a big problem if it's a bit under the. actually it's a bit normal. That's a bit under since it's not liquid. So it's a discount on non liquid assets. Um, but since people, it's a bit technical. So a lot of people see it similar as you are still losing the page and a lot of people want that it keeps it back. So they do it a bit as a panic reaction. But I think they shouldn't issue new tokens or sell tokens on the market just to keep the patient. I think it's a done by.

Nicholas: Yeah, it's, it seems dangerous, but I think it's actually, apparently it's somehow part of their, the whole system. And it's not just related to the panic recently that the, the peg is, I guess, socially maintained, the medically maintained through these emissions of LDO to keep the price, uh, despite the fact that the underlying staked eath is not liquid, but I don't know. I thought we were all betting on a monopoly here. I thought we were going to be.

Jasper: Yeah. But it was changed now with the, uh, the Robson merge, which went, yeah, let's say relatively quite successful. Uh, I think it was yesterday or day before. Uh, you would expect that the, the confidence in the merge has been increased and that's, that's, um, the other peg of stakes eat to eat would actually start to go into one again. Um, but apparently that wasn't, wasn't the case.

Nicholas: Yeah. It's a case for me. It's, I mean, I felt like I was late to Lido, like maybe four or five months ago, starting to swap, swap a bunch of money into state D and then, uh, and then it deep pegged and I am kicking myself now I could have got two or 3% more state eat, wait a minute. It's often funny how long it takes for CT to catch up to what's going on. It's like. Find it at NFTs a lot. You buy something and go to sell it. And then it turns out 48 hours later, Twitter finds out about the collection for the first time.

Thomas: Remember probably the, the private groups that are still more, uh, ahead of CT.

Nicholas: Yeah, totally. But, uh, but yeah, and actually another interesting thing on the state, the thing, just while we're talking about it is, uh, I've been looking a little bit into this, um, state teeth versus rocket ETH in terms of taxation, of course. I mean, I'm definitely not an accountant or any good, but et cetera, et cetera. But, uh, and it of course depends on where you are, but the rebasing mechanism actually does seem quite a bit. Uh, this is like relatively disadvantageous compared to rocket. There was a thread that went around a couple of weeks ago or a month ago that was suggesting this, but. As typical with these damn defy threads, it's they claim to say something clearly and then eight tweets deep vaguely explain the thing, but not in terms that make you confident that you fully understand, but I don't know if you guys have experience with this stuff, but it seems like the rebasing every at noon UTC every day, uh, means that you can't in, in rocket ETH, you can. You know, just account for things as capital gains upon sale of the rocket ETH at some point in the future. Versus state, all the rewards are tabulated every single day. So they're counting as income every single day, which is at least in the jurisdiction I'm in, if I'm correct in my assumptions, I think you can actually pay half as much taxes with rocket ETH on the reward.

Thomas: Yeah, indeed. It is. It of course depends in, uh, on the jurisdiction. I think here in Belgium from where, uh, just for an hour base, it's completely different, but you have similar things, even if you step out, out of crypto for a second here, it's also like if you buy ETFs, if they pay out dividends, your text board, and if it's accumulating, so that's very similar to the difference between a rocket pool and Lido that it's often for text better that you keep it in a vault and let it, uh, accumulate there instead of having a frequent rebates.

Nicholas: Yeah. It's interesting because rocket ETH, the price of rocket ETH relative to ETH, the rocket ETH will become more and more expensive over time, uh, versus state ETH. Uh, actually I think my pin thread is, is about the rebasing mechanism and how you, you actually have shares underlying your, your position in state ETH and it's the shares multiplied by the total amount of ETH in the Lido contract that gets you your needs, the token balance in your wallet. So I think people don't understand that. And I mean, I'm sure you guys, you know, obviously you guys do and people as regular folks don't understand that their token balance could be not, not, not even a mapping.

Thomas: No, it's actually quite, yeah, quite funny. It's, it's just what, it's actually just a display difference at the underlying accounting is very similar on the one token. You just display the shares, the other one, you display the underlying token. So from a technical point, it's almost identical, but just by the difference how you display it in the functions that your wallet reads out and it can be text different. So quite amazing.

Nicholas: Yeah, it's crazy. Actually, I wonder, I know cause. Lido also relies on an Oracle in order to update the balance of ETH in the, I guess, I don't, I don't understand exactly, but every day the rebasing requires an Oracle to, I guess, execute the transaction, but it's all the data. Shouldn't all the data really be on chain because the rewards are in another contract on chain?

Thomas: Yeah. Your might want to use an Oracle to avoid a flash loan attacks. But in this case, I don't know the details. So I don't know exactly why they do that.

Jasper: Yeah. Also, I haven't looked at it, let's say on a tech, from a technical perspective, but indeed if it's stored on a contract, you should be able to just fetch it on chain, but maybe you can mess it up by sending ETH to the contract and then the calculations or whatever will fail in the.

Nicholas: Hmm. Yeah. I wonder, I wonder if it also has something to do with this like queue for staking queue for spinning up the nodes. I don't know if there's more complexity to it, but in any case, I wonder if a Rocket ETH given their architecture has less Oracle dependence, I'll have to look into it. Anyway, we should, we should get to, to you guys in Arcadia Finance, the topic of the day. But I thought first we'll get into it and just as a preview lending protocol with a lot of cool features. So if you're interested, stick around. But I thought first we could get a little preview of sort of what your past is like, how you got into crypto. Maybe Jasper, we could start with you.

Jasper: I got into crypto quite early. I think in 2011, I started mining some Bitcoins on my laptop. It was still possible at the time. Then I always had a continued interest in, in blockchain and technology behind it. In the meanwhile, I went to university to get an engineering degree. They actually started working in software companies, let's call it the traditional software companies, more from a solution architect perspective. Up until 2019, I started another company with Thomas again, where we wrote some quick, let's say scripts for data management, data scraping, data analysis. Also rolled into a lot of blockchain development there, wrote a lot of MEV bots. And then up until 2021, we started with the idea of Arcadia Finance.

Nicholas: Awesome. And Thomas, what was your background?

Thomas: Most things will sound familiar indeed. I started a bit later than Jasper, 2016. First I thought, I think like many listening to this, probably that would become a great trader, but that didn't result in good results. So, so then I decided, let's focus on the tech side and building stuff. So then in 2019, I joined a company in Belgium working with blockchain, both permissioned as permissionless, IntellectEU. But as Jasper mentioned on the site, we started like our own smaller business. After hours, first, yeah, data scripting. And then soon we rolled into the world of DeFi, building MEV bots. And then during one of those MEV bots, we stumbled across the idea that then later became Arcadia Finance.

Nicholas: Yeah. So I know we talked a little bit earlier. So between this like 2016, 2019 era, you were, yeah. Tell me a little bit about the arbitrage and MEV bots. you guys, as much as you're able to share.

Jasper: Yeah. Blockchain development case, so to say. I was thinking 2016, 2017. When Thomas and I were like very long time friends from, from high school, even before. When we sat together, we were both interested in blockchain and everything related to it. We were both able to code, able to make some programs. And we started thinking, okay, maybe let's see what kind of opportunities there are here. And we started making an arbitrage bot on centralized exchanges. So back then it was just a stupid, simple Python script. Where we tried some, some triangular arbitrage on centralized exchanges. Was at the time, what was it called? Yeah. I don't even remember the exchanges names. They probably all went under by now. Yeah, probably. Yeah. So, so we did run it. It wasn't really successful. I assume it's because these exchanges, they have to order books themselves. And especially in that time, it was completely unregulated. So they probably did the arbitrage themselves. In any case, that was our first, let's say arbitrage and blockchain development experience that we had. But it was all with the same normal APIs, normal web sockets of traditional types of development. And then in, I think 2020 or so, with the DeFi summer, when it all started to came up. Yeah. We stumbled across our code for, for the decentralized exchanges and started thinking, okay, maybe there's something else we can do here. Or Thomas, I think it actually started with.

Thomas: Yeah, it started with Bioswap. So we were, we were yield farming and we were looking to the more exotic ones with the higher APIs. And then suddenly we found Bioswap and we saw on chain all the pools that existed and two of them didn't appear on the front end. So we saw that nobody could, so they already had their emissions, but we had a front end, nobody could get in. So then we wrote a small script with, with a web tree and then we got us first and only once into those two pools for a few days. So it was quite lucrative.

Jasper: And so we got all the rewards just with one dollar staked. Because at the end of the time you just had a UI, it was like this big staking aggregator, those big staking sites with like 20 different pools. And, and yeah, we could just stake one dollar in a pool and get the full pool rewards. So I don't even know what our API was, but it was probably somewhere in the tens of thousand percentages. I think that's how we, how we started. I would still consider that as MEV, not maybe the typical sense of MEV, but yeah, and that's, that's where it all started. And then we started looking at that, that, that code we had, or the way of working from our Tangle arbitrage script on those centralized exchanges. We wrote it to work on decentralized exchanges. So in the beginning it was more on, on XIA and now there was this chain where we started with Tangle arbitrage and not only triangles, but also squares and pentagons, if that's a thing. And then also, yeah, we also looked to some intex exchange arbitrage, but mostly also on the side chains. I think Thomas, then we went more to, to stable coin arbitrage and our lending applications.

Thomas: Indeed, indeed. Yeah. So then I think we, for the ones who know, you had like XIA USDF, which in setup was actually quite similar to Luna Terra, if you think back about it. But there as well, the mechanism was if the stable token was above cash, then you could buy on the markets XIA. No, you could buy on the markets, XIA, Mint, USDF, and then sell it on the market that make profits. So it's that type of arbitrage that we did with many stable tokens.

Nicholas: Then we also worked with...

Jasper: I think it was, it was used, it was dollar protocol and then iron finance as well. Yeah. Which also, as you would expect, similar, yeah, that spirals just like, like Luna and USD.

Nicholas: So you guys have seen it all. You've really seen everything from, I can only imagine what it feels like to find things like liquidity pools that aren't exposed in the front end. Yeah.

Jasper: But, but that was a little bit our strategy. Yeah. So, you know, Thomas and I were just two guys in our, in our basement, so to say. So our strategy was finding, yeah, finding, let's say, fresh MEV strategies, new MEV strategies, in really, let's say, niche markets or on new protocols or new chains, developing a bot for it and an arbitrage strategy for it and get it up as running as fast as possible. Then usually the strategies, they are, let's say, profitable for range from a couple of days to a couple of weeks. Then competition starts to come in and then it sort of runs down to a guess war. And then you have, let's say, per MEV strategy, we have just a couple, call it MEV searchers, who really specialize in, in one strategy, who are specialized in doing a certain guess war in that strategy. Our strategy was more find new arbitrage strategies and then just deploy it there as fast as possible. If the competition came in, do a little guess war in the beginning, but then just moved on to a new strategy. And that's also how...

Nicholas: New protocols, new chains, just getting...

Thomas: Yeah, exactly.

Nicholas: ...newest places.

Thomas: Yeah. And then the big advantage is that on new chains, most developers are not that creative. So often it's just a hundred percent copy of the protocols on main chain that they deploy on the new chains. So our arbitrage bots work as well for any Uniswap clone. If it's on buying a smart chain, an XDAI, an Avalanche. So every time there's a new copied protocol on a new chain, then you have like a few good days. If you're fast, then competition comes and then we move to the next thing.

Jasper: I think our, let's say, last big bot that ran, it was then back on ETH mainnet, was about the intersection between NFTs and DeFi. So it was when all the NFTs started coming up. We were running, I think, the first bot that did arbitrage between OpenSea and protocols providing executed liquidity for NFTs in their fractionalized form, such as an NFT or an NFT20. So essentially what our bot did was we continuously monitored OpenSea for new listings. Whenever a new listing was found that was actually below the floor price that we could get from those other protocols, we would in one transaction, in one transaction atomically, buy the NFT on OpenSea, dump it, for example, in an NFTX vault. I then receive a fractionalized ERC20 token, which you could then trade on a normal AM, like a Uniswap or a SushiSwap to ETH. And because this can all be done atomically, I just make sure that whatever ETH you put in in the beginning is less than what you, the amount of ETH that you get out in the end.

Nicholas: No risk, really. I guess maybe some gas risk, but pretty.

Thomas: Yeah, indeed. It's the gas risk is the only risk, but it can get quite costly because how do you beat other bots? It's by offering a higher gas price than they do. So a failed transaction can be very costly because often you go to far above a thousand kuai. So if you have like five losing arbitrage opportunities, then it can get costly. So you have to constantly monitor it.

Jasper: So it was either, you also have to monitor the pending transaction in the mempool. So if you saw that somebody went above you and you couldn't stop it up, you had to send a new transaction to cancel your own transaction, or you had to make sure that whenever your transaction failed, that it fails at the least gas usage. So a lot of, let's say, strategies to really go into that gas war.

Thomas: From a solidity developer point, it's also quite nice because you will always have very high gas prices. So if you can make the gas usage of your arbitrage, it's like a few gas cheaper than you could offer a bit more gas than your competitor. So you're really going into the niche gas scoffing games to make that contract a bit more efficient. For instance, also our contracts always started with a number of zeros in the beginning, because also you can save a few guests with each interaction. Just because you have a contract with zeros in the start.

Nicholas: I didn't realize there was a gas advantage to that.

Jasper: Yeah. And even your, your, your function selectors, you also have to make sure they start with, let's say the lowest hash available or the lowest possible hash in your, in all your functions in your contracts, because every jump to a new function costs again, 22 gas. So you have to make sure that the function that you use the most was on the top. So a lot of like small tricks and all these bits.

Nicholas: You're optimizing to have them towards the top of the contract, the compiled contract. And then it costs you more to jump between the top and the bottom or just having them at the bottom in the first place.

Jasper: Imagine, imagine if you have a contract with five different functions, it will be, if it's compiled in some order and you have to make sure that that's, for example, the first function will just be a zero extra costs. The second function, if you have to jump to it, will cost 22 extra gas. If you want to jump to the third function, it will be 44 gas in total. Oh wow. So the lot of, I mean, the gas golfing and, and, uh, yeah, the gas wars, it's, it's really a completely different world where you really have to find whatever you can or save whatever you can save. It's really fun. It's also really fun to sort of compete with other MEV bots or other MEV searches on the same strategy, especially on, on chains with, with lower gas. It's really nice because you have some bots who just start monitoring your own bots. And what they just do is whatever transaction you send out, they send it out with plus one way gas.

Thomas: Yeah. But then you can also, if you find bots that do that, you can then fight counter strategies that they start losing money and stuff. So it's a real PVP world, very competitive.

Nicholas: Crazy. And so in, in this world, you're, I'm curious about how the financial piece works at, given that it's PVP, like the, uh, Flashbots, not order book, but whatever, you know, the mempool of Flashbots is obscure to you. So how do you end up, is it through that process of people offering more, a greater and greater percentage of the proceeds for a known strategy versus people trying to exploit that strategy with like honeypot contracts that ends up resolving to the actual price that people are willing to pay the profitability?

Jasper: I don't think that the honeypot strategy is a strategy really to use to make money. It's more to wear out the competition or to sort of to mess around with the competition. It's not really a strategy, I think, to make money. It's probably even a strategy that loses you money.

Thomas: Yeah. But the thing is, if you fall in a honeypot, often you will shut down the bots to investigate. And in that time window that your bot is not running, your competitor catches all the opportunities in that time window. So it's really to get your competitor down for a few days to check out how they suddenly lost so much money. So they know they fell into a new trap. They first want to know the trap, find the counter strategy before they go live. And then in that time window, a competitor takes everything for himself.

Jasper: Yeah, maybe just to explain how it all got connected to Arcadia Finance. I would think our last large bot that we wrote with the arbitrage between NFTs and DeFi. So once that strategy became saturated, some arbitrage between OpenSea and, for We started looking at new strategies related to NFTs because we saw there's a lot of capital involved in NFTs, lots of capital stuck. Let's see what kind of other arbitrage opportunities there are with those NFTs or with the intersection between NFTs and DeFi. But we couldn't actually find a lot of these new protocols that you could start running on. So then sort of the idea came, the seed was planted in our heads. Maybe we should start something ourselves, a new protocol ourselves that uses or that unlocks the capital stuck in NFTs. And we were at the time in quite some Discord groups as well, NFT related Discord groups. We just saw a lot of times that people were saying, I have to sell the NFT of this collection because I want to buy the mint of a new collection and whatever. So we saw that there actually was a liquidity problem with users who have or are investing in NFTs. And then some fine tuning over the idea and eventually came to Arcadia Finance and maybe to, for the listeners who were not familiar with us yet. So Arcadia Finance is in the first stage a lending protocol in which users can deposit any type and any combination of any type of assets. So it means users can deposit their fungible ERC20 tokens combined with their collectibles or their NFTs, but also with their LP positions, so both Uniswap V3. They can all put it in a user controlled vault and then they can take out a loan against that vault.

Nicholas: So basically you can create a lending, you can borrow against a basket of assets that are from various ERCs. They can be fungible, non-fungible, even I know on the website you mentioned 777 is another one or even future ERCs or other kinds of assets are possible should like be written for the protocol. So that's pretty interesting. What I guess? to start off, what's the advantage of having a basket of different types of assets rather than just borrowing individually against a single NFT and then doing that across your whole portfolio or some portion of your portfolio?

Thomas: Yeah, I think the first one is it's much more capital efficient and easier to manage for users. If you have, for instance, five NFTs and it's just a single asset against a single loan, then you have to manage five different loans. So it's one difficult to keep track. what's the position of all five loans are instead of just one. And secondly, if one of your NFTs drops in value and another one rises, if they all have a separate loan, then you still have to top up the one loan with the NFT that loses value. While if you lend again the basket, then the rising value of one asset can compensate the drop of another asset.

Jasper: When you're having a position where you have a single asset against a single loan in terms of NFTs, you cannot simply top up your position with another NFT of the same collection. It's just one single NFT against one single asset. So if your value drops of your NFT, you either have to repay the loan or you get liquidated. Whereas you have, in our case, a portfolio of assets. Whenever one NFT would decrease in value, but it's compensated by another NFT, which increases in value, you still have a healthy position. And even if you only have a single NFT in one of our vaults and your vault decreases in value, you can just send some USDC or wrapped eat or something to your vault to again get or sort of top off your position and again get a healthy status of your vault.

Nicholas: So presumably a couple of things. So let's say I had a bunch of let's say I have 10 goblins. I don't actually have zero. I wanted to do a loan against one of them. Maybe I would say, OK, the goblins meta has certain properties. But in order to take a loan that I don't need to observe as closely, I might balance it with another NFT that has an inverse meta, like something that's very stable or something that's gamefy or something so that I can be a little bit more relaxed about that loan.

Thomas: Yeah, exactly. Yeah, it's a bit like why do people diversify their portfolio? It's also to decrease the volatility a bit. And for loans collateral, it's the same use case. If you have 10 assets, your swings in price over a day will be less than if it's just a single asset.

Nicholas: OK, so tell me a little bit. I guess now we have a overall view of what Arcadia is. So it's a protocol for lending and it allows me to use multiple assets as the stake capital for the capital at risk for the loan, which provides peace of mind and probably some actually really interesting strategies that we can get into a little bit later. But how does the protocol work as a user? What would I experience? And then even behind the scenes, what's actually going on? What contracts are connected to one another?

Thomas: Yeah, sure. Let's first focus on the borrower side, maybe. Yes. So people that want to take out a loan, what they first do is deploy an Arcadia vault via a factory contract that we wrote. If you deploy the vault, it's really user owned. So the vault ownership is completely with the account that's deployed the vault. It's not that we can do anything with the vault. Next, you deposit a number of assets into the vault so you can do a batch deposit. so you can select of all the assets you have, all the quality fungible tokens, also some quality non fungible tokens, also some DeFi primitives like LP tokens, AVA deposits. So now you have a vault with a lot of assets in it. And then we have pricing logic for each of the individual assets. And we can, with our logic, denominate on chain the total value of the basket in a single numeraire. And so a numeraire is like a unit of account. So we can denominate the complete vault, the total value in dollar, or we can denominate the total value in ETH, for example. So now we actually have a single price feed on chain of a basket of assets. And that's what then is used by our lending logic. So if you want to take a loan out in US dollar, we will call on your vault. our pricing logic, how much dollar value has your complete vault. And based on that value, you can take a loan. People are working over collateralized. So if you have 450k dollars in assets, for instance, you can take a loan up to 100k.

Nicholas: So whether you're using stablecoin valuation or ETH valuation depends on what currency I wish to take the loan out in. Yeah, yeah.

Thomas: Exactly.

Jasper: And you can form some different strategies with it. For example, if you're more focused on putting NFTs in your vault, it might be useful to actually take out your loan in ETH as well, because most of the NFTs, they are denominated in ETH. But it can also give you some opportunities if you want to short ETH, for example. So depending on your use case, you can actually choose the numeraire. And we'll probably go live with two, maybe three numeraires, being USD and ETH, maybe red Bitcoin. But it depends a little bit on the strategy of the user in which numeraire the user wants to make and to take his credit.

Nicholas: Yeah, thinking about borrowing against NFTs, if I were to do it, I would prefer probably that they be ETH denominated loans.

Thomas: Yeah, exactly.

Nicholas: USD price. Let's not talk about it.

Jasper: Indeed. Yeah, maybe it's also interesting as a side note. So our longer term vision is to actually become a collateral management infrastructure layer. So really the core product that we're now building on with our lending application are those Arcadia vaults which allow users to deposit multiple assets in it and essentially which returns a single vault being denominated in a single value and where that vault actually acts as a single asset as well. And then you can start building stuff on top of it, like as we are doing now, we can make lending protocols on it. And the protocol, essentially any protocol requiring collateral can then just interact with our vaults and use our vault as the one collateral assets. Like, for example, other margin trading platforms, escrow protocols or synthetic protocols, instead of them having to work with all different kinds of assets, all different kinds of pricing strategies, managing the collateral, managing liquidations, etc., they can just integrate one single asset being our vaults and then they can actually use or take advantage of actually being able to use multiple different types of assets underneath.

Nicholas: So currently what's the situation without Arcadia? What are they forced to do?

Thomas: Yeah, today they have to build all the logic we are building redundantly. So they have to make registries which assets are allowed. They have to integrate with oracles. They have to write logic to interpret the value of the oracles and to calculate it to US dollar or ETH or whatever they need. So today we see that every DeFi protocol in need of collateral has built redundantly the same logic to price assets, which is in our opinion, one not efficient. And also if there are new primitives or new type of assets, all those protocols have to add the new pricing logic to their protocol. Not all protocols have very modular pricing strategies, so they have to do a complete protocol upgrade. What we want to do is build this general infrastructure layer with very modular pricing. So for instance, if there comes a new AVA with a new type of A token that we can write new, like a new adapter, a new contract with the logic for that new token, we can just add it to our registry and then all protocols that built on top of our vaults can, if they want to now also allow that new token as collateral for their application as well. Okay.

Nicholas: Can we do an example of how this would work in the future with maybe an existing protocol? Like maybe Aave is a good example.

Thomas: Sure. In Aave, I think maybe DYDX is a better example for margin trading. And because of course Aave is also lending, so it's maybe competitive, but imagine DYDX, their core business is margin trading. So people have to deposit some assets as collateral so that they then can take leveraged positions. So today DYDX doesn't allow that many assets as collateral since that's not their core business. If they would integrate with us, the only thing DYDX has to worry about is the US dollar value of the collateral of one of their traders. So they're just scared. this user has so much dollar, so he can take this margin position. If now there comes a new big token, like an Aave V4, then we integrate with the Aave V4 tokens and any DYDX user can immediately use also their Aave V4 tokens as collateral to trade on DYDX. And DYDX doesn't have to build a new pricing logic themselves. Or escrow accounts also immediately have access to new types of tokens for their users to be used as collateral without them needing to do the integrations and do the pricing logic.

Nicholas: Great. So how does this compare to, I've heard about EIP-4626 tokenized vault standard. How does this relate to that?

Jasper: Yeah, so our vaults we have indeed, yeah, our KDR vaults, but the tokenized vaults are more used to break up a vault in multiple pieces to fractionalize your vaults, which is a use case that we're not having. So our vaults, they remain as a whole, they remain in one part and they remain ownership of the user who owns the vault. So although in our protocol, we're not using that EIP standard for our own vaults, it could be an asset or a collateral asset that we can allow in our protocol.

Nicholas: Okay. So one of the advantages that we're talking about in terms of the long-term vision for Arcadia is that it's a standard for valuing loan vaults, I guess?

Jasper: Yeah, just vaults and whatever you want to do with it. Whenever you need a single asset which needs a price, usually, yeah, most of the time it's only in protocols, in collateral, that's where our Arcadia vaults could come in.

Nicholas: Got it. Okay. And it's useful to something like DYDX because in addition to whatever kind of things that 4626 would give you, this is actually giving you the value of it. There's a logic that you can read.

Jasper: Yeah, so then, yeah, so DYDX could then actually use the liquidity user has in there for 4626, whatever kind of assets they have based on that standard, they can actually then take advantage of the value looked in those tokens because they can integrate with our vault. We will integrate with that new standards. Then any user who has a collateral position open with the DYDX can then immediately add those tokens to their vault and start using that value on DYDX.

Nicholas: So basically what you guys are building is the glue and that glue specifically is like a valuation engine for different types of assets. Yeah.

Thomas: Yeah. An on-chain valuation engine. Exactly. So you can maybe best compare it to a chain link. Yes. So what chain link does? is they bring off chain prices or data on chain. For instance, for the price feeds, the dollar eats a lot of protocols use it so that not all those protocols have to build to Oracle's themself. What we want to do is then to build this general structure based on off-chain price feed and on-chain data to have a pricing engine for a basket of assets, which then can be used by any other protocol that needs collateral and that they do not all have to build redundantly the logic to denominate multiple assets in a single value.

Nicholas: So the natural question is how do you do it and why should I trust you?

Jasper: Yeah. Good question. Of course. The, how do you do it? It depends on the, the asset type. So as we said a little bit before, our protocol is quite modular. And so for any assets type, or let's say any assets that we will allow, because even though technically we can allow any assets, we will still be working only with a list of quality assets. So we're not going to allow a random sheet token that you've just launched as collateral, because it would bring a whole range of security concerns, security issues. Yeah.

Thomas: We, we, we have a separate, a sub-registry, we call it per type of asset. So for instance, we have one for ERC20 tokens for which we do have a chain link price feed. So that pricing logic does not move nothing more than a fetch the chain link price and then rework the decimals. And it's also always with 18 decimals precision. So that's very simple. But then for instance, for a Uniswap V2 token, we have another module with logic. There we first break down the LP token in the two underlying ERC20 tokens for which we then both have a price feed. And then based on the first module we discussed, we fetch the chain link prices and as such, we can also price a Uniswap V2 token. If we then for instance, have a curve token, a tree pool, then we decompose the LP position in the curve pool in the tree underlying tokens, we fetch for it's the price via the first module. And as such, we can return the US dollar value of a curve LP position. Also for, for instance, NFTs, if we work with a collection for which have a floor price, we are chaining Oracle. We can return the floor value of that NFT through which we work to price it. And as such, if a new primitive comes up, we can build new pricing logic. that's more has a direct price feeds like with chain link, or we can decompose it in underlying tokens for which we have price feeds. And then we sum everything up.

Nicholas: I guess there would be additional price information or some calculation made on the fact that it's not just the individual tokens, but they're also in a Uniswap V2 pool. in that case, is there some additional risk and that affects the collateral value?

Jasper: Yeah. So every asset that we allow in our protocol will have a sort of accrediting. Credit rating essentially means how risky is the asset, how volatile is the asset, how much liquidity has the asset. And based on that credit rating that every asset has, we will calculate a certain interest rate and potentially also a different collateral threshold, for example. So even though your LP token can consist of, I know, a UBC die, it might have another credit rating than just a single UBC or a single die.

Nicholas: And that's going to be something that initially you two are coming up with, but it's like DAO is involved in or something?

Jasper: Yeah, indeed. Indeed. Initially we'll have to launch. And so upon launch, we will assign a credit rating to every allowed asset. But even on the short term, we're really looking to have it, let's say, more community based or with community inputs in the form of a DAO.

Nicholas: So, okay. Tell me a little bit about the financial model. So do you charge a fee? or at least you could charge a fee in the future?

Jasper: So for our lending application, we will indeed have an interest fee. So we'll take costs or there will be a costing at two points. One will be the interest fee. Whenever you take a loan with our protocol, there will be a couple of percentage per year that you have to pay in the form of interest fee. A large percentage of that interest fee will go to the liquidity providers who provide liquidity for the protocol to really have it as a sustainable yield, as a sustainable income for those liquidity providers. And a percentage of that will also go to, of course, to the treasury of the protocol. The second part where we capture value is on liquidations. So on most of the lending protocols, whenever you have an unhealthy position, for example, you have an NFT in your vault and the NFT drops in value. Once you reach a critical limit, the liquidation threshold, you have an unhealthy vault and your vault is up for liquidation. So whenever your vault is being liquidated, we will do such auction, probably most of the cases, where users can either buy the entire vault as is, or can buy a part of the vault itself. Like for example, if you have a vault with three NFTs in and five fungible tokens, but you as a user, you're very interested in buying one specific NFT, they can actually buy the specific NFT from a vault, which is in liquidation. And so on the liquidation, there will also be a liquidation fee, which is paid by the original owner of the vault.

Nicholas: I'm just thinking, does the fact that you can decompose them at the liquidation time, I guess, because you have presumably high confidence in your own valuation of the underlying tokens, you can break them up out of the basket and sell them separately without compromising the total value of the items?

Jasper: Yeah, indeed. Indeed. We know for each asset in a vault, how much we could get if you were to dump it now on all the protocols. So we know what the floor price or the immediate liquid price is for every asset and we can then start decomposing in the vault into the different assets underneath or not actually decomposing the vault, but we're in a vault in liquidation, we're allowing external users to buy a separate item in the vault and to sort of repay the debt on the vault. And it will be then, we can see at a market price for that assets.

Nicholas: I can see why the MEV experience is useful because you're able to, with confidence, predict what you could dump the tokens for. I do have...

Thomas: Yes, exactly.

Nicholas: Yeah, indeed.

Jasper: And it has played on quite some parts. So like whenever we were making our liquidation function, we were thinking, okay, if we were making a liquidation vault, well, what would be the best way, the most gas efficient way to liquidate this vault? Where we can be safe, guess. Is it best if you, whenever you liquidate a vault that you immediately get a transfer of tokens? Probably not because then you're paying multiple transfers. If you're doing multiple liquidations, you just want to be able to claim it all at once after whenever you're feeling for it. So a lot of those small things are actually really supported by our MEV, by our, let's say, experience in how to make protocols as efficient as possible for keepers for MEV books.

Nicholas: I'm curious how people deepen DeFi. Like, do you need publicity for your protocol to be successful? Or is it something where if it's just capital efficient and exists, people will just naturally gravitate to it?

Jasper: I think it always needs publicity in some form. I mean, the marketing in Web3 is not the normal Web2 marketing. It's not with advertisements in the local newspaper, but publicity can also be, I know one of the, let's say, evangelists or a very nice developer using your protocol and just tweeting about it. That's the type of publicity that would actually help us.

Thomas: And theory in the Twitter spaces is also a good one, of course.

Jasper: Yeah, absolutely. Absolutely. Yeah. You need some publicity in some way. You can make the best product out there that solves all of your problems, but if no one knows about it, it won't get used.

Nicholas: Totally. So two things just to finish on that topic. Do you have any sense of how a DAO could do the credit ratings for the assets? Is that something that's already been done in DeFi? or is that something to be figured out?

Thomas: I think there are always good examples to look to before you try it yourself. You don't have to reinvent the wheel. I think a lot of protocols already have quite good strategies in place to do it. Like MakerDAO, ANAVA there as well. It's often part of the DAO that can do proposals which are voted on. But most important with those is always to align incentives. People providing liquidity or people owning the governance token, they have the incentive to make sure that interest rates properly account for risks. So the people that are at risk should be able to do proposals and vote on proposals or models like in ANS also like where you delegate actually parts of your governance tokens to someone you believe in and you can switch at any moment in time. So you kind of like have a liquid democratic election of people or a council that can decide the interest rates for you. And as soon as they do something you're not behind, you can switch delegation to someone else. Because I think what we've seen with DeFi Summer, that's every project launched their own governance token that people vote once for the DAO and that's it. So you need to have working mechanisms, but there are good examples of DAOs who do it quite well in my opinion.

Nicholas: Do you think that they could be compensated for some of that labor that could be part of where the fees go?

Thomas: Yeah, they will for sure be compensated for the work they put in, but I think it's more important that incentives are aligned and that doesn't need necessarily to be with direct payments. If I own a lot of governance tokens of one protocol, or if I have a lot of liquidity provided in some protocol, I am incentivized to make sure that that protocol doesn't allow shit tokens with a low interest rate as collateral. Because then you don't reflect the real risk that that type of asset poses to the protocol, so to your own funds.

Nicholas: I wonder if you end up in like a curve convex situation with the voting power over the price estimation or reputability of the tokens.

Jasper: Yeah, I mean, yeah, that could be possible. I think that the credit rating is not our first intention to build a whole DeFi protocol. As Thomas said, we'll probably have to check out what the best ways would be, whether there are already existing manners in which we could, with quite some high confidence, provide credit ratings or with governance voting. I don't immediately see going towards a curve war type of credit rating, but it's certainly a possibility. that would be the best way to go forward.

Nicholas: I'm also curious, do you foresee, like you said, you're relying on Chainlink for some token prices currently, but I imagine in the future there could be superior methods for figuring those things out, even on chain. Some of the research I've seen seems to allow for that. Do you foresee upgrading entirely or offering alternate valuation schemes?

Thomas: No, so we have like what we call the Oracle Hub, which basically fetches prices depending on which asset address you pass to it. And there it can also be modular for different types of oracles. So I use Chainlink now as an example because most people know it, but we can also upgrade it and allow for more ways to price assets, so it can be other off-chain oracles or it can also be on-chain pricing strategies. So there as well, it doesn't have to be only Chainlink. If there are better possibilities for certain assets, we will use the best one available.

Jasper: And maybe to even build on that and to make it, let's say, more complex, imagine that you have different protocols that use our Arcadia vaults. For example, a DYDX and DYDX would say, we don't want to use you guys unless you use this type of oracle for evaluating the assets. In theory, we could then make, say, a separate oracle hub, which actually uses the oracle or the pricing logic that an external company dictates that we should use for evaluating the assets in a vault.

Nicholas: So you could have, so a basket, a certain loan could have a different value depending on which protocol is interfacing with it.

Jasper: The vault will still have only one value. So your vault is based on upgradable proxies, so you can actually upgrade it as well if you want to. And it could be that, for example, on vault one is, let's say for normal users using our lending application, vaults on version two is for users who have, or we are using a vault in DYDX with some specific logic. Could also be that DYDX says, okay, we want to use an Arcadia vault, but we're not allowing, I don't know, use of v3 positions, and then we need a different kind of whitelist as well for a specific version of a vault, which is possible in our, let's say, modular way because we've built the application with the idea in mind to become a generalized collateral management layer. So we already have these kinds of workings built into the protocol.

Nicholas: So basically a given vault would have a single Oracle price or whatever type of price at a given time, and you could change it to a different valuation mechanism, but at any given time, it only has one.

Thomas: Yeah. Yeah, indeed. And maybe interesting to mention here as well. It's not that we as a protocol can force a vault to upgrade. It's only the owner of the vault that can choose to go to a different version. I think our point of view here always is that if you interact with a smart contract, we really see it as a contractual agreement, so we cannot force someone who has already an open position to use new Oracle pricing logic because he might think when he interacted with the protocol the first time that the current development is fine, but they might not agree with future versions. So we can allow multiple versions. For instance, the Oracle hub, it's only the user that can upgrade an existing vault to a new version.

Jasper: And same with the liquidation thresholds and with interest rates. Whenever you're taking out your loan, at that moment, you agree with us or with the protocol that you take out this loan against these conditions, this interest rate, this collateral, this liquidation threshold, et cetera, and that won't change unless you perform an action like take out additional credits or whether you sink your interest manually as well. So we really are quite strict in that. We really want to provide that experience to the user where they know, okay, we agreed on these conditions when I've taken out my loan or my credit, it won't change.

Nicholas: This idea of like self custody through your own proxy is pretty important. And I guess that's different to a lot of other lending protocols.

Thomas: Exactly. Exactly. Because in a lot of lending protocols, the developers have superpowers and they can just change the complete pricing logic from one day on another. So in my opinion, it's not so decentralized. Uh, we really have that focus from the start. that is the user decides if they upgrade or not, and that, that sets us apart with many, not with all. others also use that philosophy, but it sets us apart with the majority of DFI protocols.

Nicholas: There's a thing on the website. It says, uh, on the FAQ, there's a question who provides the liquidity for the loans. And in the details of that, it says who provides the liquidity is better formulated as who wants to hold the synthetic tokens pegged to USD or ETH. Uh, we sort of talked about this, but can you get into a little more detail on what that means?

Thomas: So it's, it's similar to the maker and dime mechanism. If you take out a loan on your fault, basically you open a collateralized debt position and your minted an equal amounts of debt tokens. So you have this amount of debt tokens. The fact that you took out of a loan, you want to swap the newly minted debt tokens to an asset, which you can buy stuff. For instance, if you have a loan pegged or denominated in the U? S dollar, you want to have USDC to spend. So the liquidity providers are all persons that buy up the debt tokens and giving return USDC. So they now hold the debt tokens, which they then can stake in the contracts. And as such, um, they can receive both their principal back and any future interest payments.

Nicholas: Got it. So are there any like interesting applications of Arcadia that you think we should explore here, uh, before the end of the show, any, of course, there's tons, but I guess to just sort of paint the picture for the listener.

Thomas: Yeah, I think maybe two, uh, we want also users to be able to actively manage their collateral. So for instance, if you initially deposit that eat a red bit going in your vault and you have a loan, uh, but then you did, there is this, this new token you're also interested in

Nicholas: that it's,

Thomas: it will be able to, from your vaults with an active position on top to do swaps, for instance, uh, for red Bitcoin to another token. Same with maybe that's for future versions, then that you can, can stake certain tokens that are already in your vaults used as collateral. So you can really actively manage assets in the vault as collateral. I think that's one interesting application. And a second one is, uh, we're also talking with superfluid, um, to maybe have loans that can be taken out or repaid, um, as, uh, streams. And they're particularly, it is interesting for, for instance, Dallas, um, today, many Dallas pay out their, um, employees in their own governance token, meaning that the development team is actually a constant, uh, markets, uh, sell pressure of their own token. In our opinion, it would be much more interesting for Dallas that they deposit some assets as collateral, and then they can actually pay their employees with credits, which is then can stream constantly, um, to their employees from an Arcadia vault.

Jasper: And maybe if I can add one or two to that, we've all seen the, let's say the, the ape drop or the ape airdrop. So imagine you have three apes in an Arcadia vault, uh, you have a loan against it, but there is a new airdrop for whatever kind of token, uh, given out to, to board a boulders. So we'll provide say helper mechanism where you can do a flash mint of your number, take out your, your board apes, uh, redeem your, your airdrop, and then actually, uh, put your aves back in a vault and the repay the, the flash mint. Um, so we're also looking for, for solutions for these kinds of situations. Um, and maybe our last fun one is that your vault will also be an ERC 721 yourself. Uh, itself. So your vault is an actual NFT and interior, you can see it on open C, you can even sell it on open C or you can just transfer it along with all of its, its contents to a new owner as well.

Nicholas: Crazy. Okay. So basically a couple of things there. So the two that caught my attention most, and maybe it's just cause I didn't understand the other two as well, but the two that got my attention most is the idea that like a Dow or something could be borrowing against their assets, especially if those assets are not stable coins themselves. It could be useful to stream salaries out of the borrowed stable coin, for instance. Did I understand that example correctly?

Thomas: Yeah, exactly. Exactly. That's it.

Nicholas: That's pretty compelling because I know working in Dow's a little bit myself, there are these questions around how do we manage a treasury, especially in the sort of simple Dow's that I'm a part of a lot, often the treasuries are a hundred percent in ETH and that would be, I think a pretty compelling part of the solution to diversifying those portfolios and potentially earning a little bit or otherwise being intelligent about how they're managed. That could be very relevant.

Thomas: Yeah. It's also by talking with people from a super fluid and with people working for Dow's that we put it quite high on the priority list. It won't be there for our first version, but in a second upgrade, it will definitely be one of the first things you want to work on. On the math side, it gets a bit more complex since now you don't just have a fixed principal compounding interest, but you have like a fixed amount decreasing also, but yeah, that's something we'll have fun with in the next month.

Nicholas: I could see that. And actually it makes sense even that it could even apply to let's say Dow's that have NFTs as their primary assets or a port. Let's say a developer creates an NFT collection and reserves, you know, 10% of the collection to themselves or the development team or the Dow, whichever it might be, it could be interesting to be able to pay people's salaries out of those without giving them direct access to the NFTs. And similarly, the example you give about the flash minting or essentially having the assets inside of a vault be still productive assets if they're able to claim airdrops and things like that is pretty compelling.

Jasper: And then it's a need as well of users. And I can imagine if you have your assets locked up in a vault and if you think that you cannot use them anymore or cannot participate in the communities around it. Yeah, that will be a real bummer probably.

Nicholas: So in the example that you gave, it wouldn't affect the value of the vault at all because it would be atomically reinserted into the vault.

Jasper: Yeah, exactly. Exactly. At the end of the transaction, you either repay your mint or you've never taken it out and the transaction fails.

Nicholas: And would you have to have a custom vault for that? Or that would just be like typical behavior for the vault, given that it would atomically be reinserting the same amount of capital?

Nicholas: Extremely cool. Are there any other topics that we didn't discuss that you think are worth getting into about Arcadia or did we, do we pretty much?

Thomas: Yeah, I think. maybe a last important one. So we're not live yet, but next month we will launch on testnet. And to make it a bit more fun than just taking out loans with fake tokens, we'll do it in the form of a paper trading game. So within the paper trading game, you can use all the functionalities of a vault. So you can manage assets within the vault and you can take out loans so that you can build leverage positions. So we invite everyone to test out the protocol. Let us know what you did like, what you don't like. So it's both on the smart contracts site as on the user experience. No, a few weeks ahead, but we'll be there soon.

Nicholas: Awesome. Definitely let us know. That sounds like a lot of fun to play around with. And certainly for NFT smooth brains like me, getting experience with these protocols.

Thomas: And maybe one more thing to add as well. This morning we got our first security audit back and apart from three minor issues, everything was green. So that makes us confident to launch first on testnet and then later on mainnet later this year.

Nicholas: Awesome. Out of curiosity, which firm did you go with?

Jasper: We used Solidity Finance.

Nicholas: Okay, cool. I haven't heard of them. Are you considering doing any other kind of like bug bounties or?

Jasper: Yeah, definitely. We'll probably work with Immunify, their bounty program. But I think any decent or any DeFi protocol that takes itself seriously and knows about the dangers of being exploded. Yeah, we'll use a bug bounty in some form. Absolutely.

Nicholas: Yeah, very cool. I've just been learning about this a little bit in my day job. And yeah, we did some. we did traditional audits. We're also playing with Code Arena. Probably going to do a Code Arena challenge, which is kind of interesting to get a different type of audit perspective, but pre-launch style still. And then, yeah, Immunify seems like a great choice for post-launch. Give people an opportunity to not hack your protocol.

Jasper: Yeah, absolutely. And in our testnet launch, which is a trading competition, the winner would also get a prize. So if you're able to explode this, there will be some sort of a bug bounty related to it.

Nicholas: Oh, nice. Awesome.

Jasper: So yeah, open challenge for everybody who wants to start messing around with it.

Nicholas: Cool. So people to keep up with you can check out Arcadia Fi on Twitter. Anywhere else they should go? What's the URL?

Nicholas: Awesome. Guys, thank you so much for coming through today. This was super fascinating conversation. And definitely let me know when the protocol is launched on testnet. I want to give it a shot.

Jasper: All right. Will do. Thanks for having us.

Thomas: Great. Thanks.

Nicholas: Yeah. All right. Be well. Thank you, everybody, for coming through to listen and see you next week. You can follow me on Twitter at Nicholas with four leading ends. You can find links to the topics discussed on today's episode in the show notes. Podcast feed links are available at Web3GalaxyBrain.com. Web3 Galaxy Brain airs live most Friday afternoons at 5 p.m. Eastern Time, 2200 UTC on Twitter Spaces. I look forward to seeing you there.

Show less

Related episodes

Podcast Thumbnail

Reservoir with Peter Watts

11 July 2023
Podcast Thumbnail

Sudoswap v2 with 0xmons

22 June 2023
Podcast Thumbnail

Abacus with 0xGioMedici

28 March 2023
Lending Protocol Arcadia Finance