Solana Labs has announced the launch of a permissionless time-weighted average market maker (TWAMM) service on the Solana blockchain. This innovative solution aims to help traders execute large orders more efficiently by pooling them together, breaking them down into smaller pieces, and executing them over a specified time interval. The project, based on an idea by Paradigm, is designed to reduce the price impact of large orders, provide better average prices, lower execution fees, and maintain full custody of tokens while orders are executed.
The TWAMM service consists of three main components: a web user interface (UI), a backend Typescript program, and an on-chain program. The web UI displays active user orders, trade progress, min/max/avg fill prices, and allows users to submit order instructions to the on-chain program. The backend program triggers on-chain cranks and serves as an example of how permissionless cranks can be executed. The on-chain program handles order instructions, stores user and token pair-related information, and holds tokens to be swapped and fees in custody.
Key design considerations of the TWAMM service include the ability to cancel orders fully or partially at any time, and the pooling of orders for all time intervals to reduce fees, the number of swaps, and price impact. Cranks are permissionless by default but can optionally require authority, and the frequency of cranks is based on the amount swapped in each iteration.
The project leverages Jupiter to settle the net outstanding balance and opens the opportunity for any liquidity providers to settle trades at the oracle price. This allows market makers or anyone to perform a swap against TWAMM pools, saving on swap fees for themselves and the protocol.
The service supports various time-in-force (TIF) periods for new orders, with a limit of ten different options per token pair. Users can modify existing order quantities or place multiple orders for the same token pair if they have different TIFs. Order expiration times are uneven and based on how long ago a particular period started on the chain, giving users the option to join existing virtual pools or place scheduled orders for the next interval.
The launch of Solana's permissionless TWAMM service marks a significant advancement in the decentralized finance (DeFi) space, offering traders more efficient and cost-effective ways to execute large orders while maintaining transparency and full custody of their tokens.
Interested in accessing Solana Labs' TWAMM tool? Apply here.