Chaos Labs - Ethereum Token Converter - 10/24/24

Overview

Chaos Labs provides recommendations for the Ethereum Token Converter.

BNB Chain Solution

Building on the success of automated and optimized token conversions introduced by the Venus Protocol’s Token Converter on Binance Smart Chain, we now aim to implement a similar solution on the Ethereum network. Our previous recommendation provided a comprehensive analysis of historical data and gas costs to create a profitable conversion process for arbitrageurs without compromising protocol security.

The previous recommendation examined the WBNB/XVS converter, and had the benefit of historical transaction data, through which we obtained a 95th percentile gas fee of 0.0022 BNB. Incorporating this gas fee, we found that an arbitrageur could achieve profit even without a discount, provided they wait long enough.

Additionally, larger transactions tend to be more profitable, as the gas fee is worth relatively less compared to the arbitrage value.
Ultimately, we found that the most profitable conversion size was 7 WBNB, requiring the smallest discount (0.01%) to achieve 0.2% profitability.

Ethereum Considerations

On Ethereum, the primary differences are that the median gas fee is about 77 times higher (in USD terms), and block times are about four times longer, at 12 seconds compared to 3 seconds on BNB Chain. Additionally, the primary converter markets — as described by the team, likely to be the largest supply assets, swapped with USDC, USDT, WBTC, and XVS — on Ethereum are significantly more liquid than the previously analyzed WBNB/XVS markets. Below, for example, we can see the price impact for XVS-WBNB swaps, finding that liquidity has been volatile and a swap of just over $15K XVS for WBNB incurs 1% price slippage.

To use an example on Ethereum, we can see that a swap of $40M WETH for USDC incurs 1% slippage, significantly increasing the opportunities for arbitrage that are present in the converter by increasing the swap size that is possible and thus mitigating the effects of higher gas fees.

Finally, the longer block times are unlikely to have a major effect on Ethereum, given that DEX prices and oracle prices are both updated with equivalent frequency within a given network, presenting similar opportunities for arbitrage independent of block time. Given these factors, we find that the converter should largely function the same as on BNB Chain, with higher gas fees mitigated by larger transaction sizes that are supported by more liquid DEX pools.

Recommendation

If the objective is to enable arbitrageurs to profit by 0.2%, we recommend aligning the discount with that set on BNB Chain, at 0.01%. However, should this prove to be too little, as will be defined by a lack of transactions on the converter contracts, we recommend increasing the rate in increments, first to 0.02%, then 0.03%, and so on, finding that these increments will make material changes to arbitrage while limiting the additional discount provided. This process will allow us to find the lowest optimal discount rate.