We have been researching & developing TWAMMs built on top of Balancer as a custom pool. Balancer grants DAO has been extremely supportive of our endeavor and we’re excited to launch next month. You can learn more about the project here:
TWAMMs and Balancer pools in general are complicated to interact with in absence of a UX. We are building a dedicated relayer that abstracts the complexity from the end-user and provides safety in terms of slippage protection and error handling.
We want to do this all from a smart contract thus maintaining the advantages of a fully on-chain protocol: permissionless, composability, & decentralization. Additionally, we don’t want our protocol to be restricted by hostile regulatory regimes that target Web UX.
Below are the two ways to interact with the core TWAMM contracts today via Gnosis Safe or Etherscan. Without a dedicated UX, the user would have to know how to set slippage, handle errors, etc themselves.
A user would have to create
tuples and be knowledgeable of Balancer’s Vault infrastructure. Furthermore, they would have to
abi.encode data specific to TWAMM like intervals, swap type, etc.
Here the user would specify very simple inputs (similar to in a UX) in order to execute a long-term swap.
We will create our Relayer, similar to Balancer Relayer (https://github.com/balancer/balancer-v2-monorepo/blob/master/pkg/standalone-utils/contracts/relayer/BalancerRelayer.sol), but with added abstractions for the following functions:
- The core contracts have been fully audited by SpearbitDAO: https://github.com/spearbit/portfolio/blob/master/pdfs/CronFinance-Spearbit-Security-Review.pdf
- The periphery contract will be audited by SpearbitDAO as well.
- Users of this relay will have to explicitly approve the relayer before using it.
- Relayer actions will be scoped to:
join, exit, swap
- We will scope the relay to only interact with TWAMM pools recognized by our Factory contract:
⛔️ Attack vectors: addressed in the security section ✅ Ease of use for a new pool type ✅ Expand Balancer pool interaction to fully on-chain ✅ Exploring & developing the Relayer ecosystem for other teams, integrators
⛔️ Increase of attack surface ✅ Vastly improved on-chain UX ✅ Moat against copycats, vampire forks ✅ Simplified onboarding of different user personas: whales, protocols, 3rd party front-ends
⛔️ Additional gas costs of the periphery ✅ Interact directly without UX/3rd party ✅ Ease of use and integration ✅ Safety and slippage checks are done by the periphery ✅ Abstract TWAMM complexity
We would like governance to approve this relayer so we can onboard users faster, improve user experience, and reduce the complexity to interact with TWAMMs.
Balancer’s architecture requires governance approval for
CronFi: Relayer for these actions: