Metastable: mStable as a cross chain stablecoin AMM

I wanted to bring up an alternative vision for mStable as a crosschain liquidity/swap solution.

This was an idea I played with in December/January this year, but never really brought it to the attention of the community as other priorities came up. I think the premise of this idea (multichain world, multiple Ethereum jurisdictions, increased fragmentation of same peg assets and their yield) has only been confirmed as time goes on.

I’m keen to get feedback on this - no doubt it is a large vision for mStable and one that enters a crowded crosschain space, but I think it’s worth consideration.

Introduction

mStable was initially built to unite same peg assets. mAssets are backed by a diversity of the major pegged assets; Save is a optimised composite of lending protocols and stable yields; swap unlocks efficient liquidity between same peg assets, with feeder pools extending mStable to enable any pegged asset.

With a variety of credible layer 1s coming to market (Solana, BSC, Avalanche, Near, etc.) and several Ethereum scalability solutions (Polygon, Optimisim, Arbitrum and many more), the fragmentation problem has and will only increase. Further, a major pain point for these new crypto “jurisdictions” is lack of stablecoins and lack of economic infrastructure to generate yield on those assets.

What is needed is a robust and efficient way to connect same pegged asset liquidity and their yield.

Current Solutions

There are many decentralised crosschain solutions out now or coming to market, including:

  • ThorChain
  • Chainflip
  • Connext
  • RenVM

These crosschain custody the liquidity on their chain/MCP, exposing the liquidity to dangerous attack vectors.

This proposal suggests that instead of having the crosschain solution custody the assets and house each liquidity pool, instead create a lightweight state-chain that reads the balances of each mStable implementation. The state-chain would enable zero slippage cross-chain liquidity in mAssets, and then via redemption allow for low slippage swaps between bAssets.

In short, mAssets could be a very useful accounting mechanism in connecting different mStable implementations and therefore connecting liquidity and yield in different crypto jurisdictions.

Metastable

The mStable protocol would be built on each jurisdiction (Eth layer 1, Polygon, later maybe other EVMs and even Solana etc) and each mStable AMM would have its own mAssets( ie ETH mUSD, Polygon mUSD) and feeder pools. mStable implementations would aim to unlock deep on-chain liquidity and high yields on their chain, by having:

  • an automated market maker optimised for trading between pegged assets
  • per asset save rate: imUSD, imBTC, as interest bearing standard

This would work by:

  • state-chain mint/burning mAssets to bridge liquidity. For example, I want to trade BUSD on Binance Smart Chain for DAI on Ethereum Layer 1:

This would be the flow: deposit BUSD into BSC mStable, mint mUSD, metastable state-chain then burns the BSC mUSD and mints the same number of Eth mUSD on Ethereum; the Eth mUSD then redeems DAI from Eth mStable.

If you trade between mAssets it would be a 0 slippage transfer. If you trade between mAssets it would be a low slippage transfer.

  • The state-chain would enable capital to flow freely meaning it doesn’t matter where the collateral assets are: i.e. 100% of mAssets could be on Arbitrum even if 100% of bAssets (colalteral in the AMM) exist on Ethereum Layer 1. The imAssets (interest bearning assets) would earn the same rate wherever they are. We think new “juridications” would like it as they could effectively leverage existing DeFi economies on incumbents without building it from the ground up.
  • Save could one day be the liquidity pool for crosschain swaps. Users stake their mAsset into Save on each chain. This would create, for example, an ETH mUSD / Polygon mUSD pool. Interest would be paid to this pool, in a way similar to what happens today.

Summary

  • mStable unifies and connects pegged value crypto assets, everywhere, not only on-chain, but to also cross-chain and between layer 1 and layer 2
  • Current solutions have high slippage and attack vectors
  • mStable bridge doesn’t necessarily require liquidity pools, is zero slippage and does not require direct custody of funds
  • Major efficiency and security improvement to other cross-chain solutions
  • mAssets, yield assets as well as collateral assets will be able move freely between chains

I wrote the above very quickly- I just wanted to express the top line idea and am happy to answer any questions.

Looking forward to your thoughts.

7 Likes
2 Likes

I’m glad to see the parachain slide deck here, because this sounds like a great use-case for a parachain. Even if mStable couldn’t win a slot auction, it could participate as a parathread.

I don’t know anything about the Solana/Cosmos/etc chains, so I can’t comment on them though.

I know that Acala will have kUSD/aUSD on their respective relay chains. So that could potentially be a source of liquidity (or competition, I suppose).

I lack the technical chops to really scrutinize this though. I like the idea, and I suppose my input is “plz Polkadot kthx”

2 Likes

Hi,

First of all i really like this proposal and think it’s the endgame for mstable. Removing any source of fragmentation and friction vertically between layers 2 and Eth, plus horizontally with any USD stablecoin and other chain (Sol, Dot, thor…) is the go-to in order to succeed. Under it’s apparent simplicity, i.e. musd or imusd, metastable needs to unify every layer of complexity in order to attract every newcomer in mstable savings.

At the moment, there is 110 billion + in dollars of stablecoins and there will be many billions/trillions more in the years to come, as people are looking for decent yields. Adding to that the possibility of cross-chain yields if i understand it correctly, it could be a liquidity yield blackhole.

On the technical side, i understand that there is no necessity to bring liquidity on others chains as the smartcontracts mint-burns mAssets between chains ? If so, is there a need to implement oracles such as Chainlink which provides price feeds between chains ? or just in order to solidify its functioning against any abnormal market event or eventual elaborate hack/attack between chains ?

2 Likes

Love this idea. Consolidating cross chain liquidity is definitely something worth pursuing. It seems like the logical next step for mStable since it’s related to infrastructure for solving stablecoin fragmentation.

I’m interested to see what is developed and if the infrastructure on the new sidechains and roll ups will be advanced enough to support the current dApp. Might be worth considering a scaled down app to be first to market. Also, we will need to be wise in considering which and in what order each scaling solution should be included.

2 Likes

This is very much an interesting concept and a very acute problem in the ecosystem that is not yet sufficiently well solved.

I wonder mostly about 2 things in regards to this:

  1. How technically complex is this? From a developer’s standpoint, I assume this is not that trivial to do and I wonder how difficult these technical problems are to solve.

  2. Is this something where we want to take mStable? This goes into a wider discussion about what direction mStable should take. With our current products, I see us pretty much in the financial products and safe yield category (like a very easy-to-use savings account).
    With these cross-chain swaps, I see it more as Infrastructure. Having two battlefields to compete against others in the market might be somewhat difficult.
    Or is this a change in direction? Or maybe I am missing, that these are actually compatible products?

2 Likes

Thanks @Dimsome

  1. If we were to do it ourselves I suspect it would be quite complex and a departure from our current area (app layer EVM) to crosschain, probably Parachain kind of direction. I think the way to think of this is conceptually: what does a crosschain amm look like and are meta-stablecoins a useful accounting mechanism in providing liquidity between them? I think once we answer that we can work out how to build it. That said, I have organised a call with the founder of Connext to see if there could be room to collaborate on this / investigate the technical feasibility of this further.
  2. We should be laser focused on what we are; I completely agree with that. My thinking was that is could be coherent as a protocol.

I should mention that this is a blue sky idea and as a core team we don’t have plans to build it - more just wanted to get feedback

1 Like

Gigabrain stuff here James. I’m mesmerized by the idea of meta eth as a cross chain asset given all that we discussed here. My only question lies in solving the communication method between chains so that one chain knows to mint and the other knows when to burn, etc. Other than that (potential) hurdle, the premise behind it seems quite promising.

3 Likes

This is an interesting ‘infrastructure’ play for mStable. One need to think more about the use cases and the demand for something like this as it’s not straightforward from a technical standpoint. In addition some chains mentioned in the post have ‘native’ bridges already, meaning mAssets can use the existing bridges (Polygon, Avalanche etc).

Having thought about this a bit more, this could be a very powerful feature.

Maybe we could just start with our own mUSD Mainnet to mUSD Polygon Bridge. I would be very interested to know how Bridges work in general. If a bridge is just a smart contract, why couldn’t we do something with the asset while it sits in the contract?