๐ŸŒŠThe Vault

Overview

Starfish's fundamental component is the Vault; it is a smart contract that stores and controls all tokens in each Starfish pool. The Vault also serves as the gateway via which most Starfish operations (swaps, joins, and exits) are carried out.

Protocol AMM Logic

Contrary to conventional AMMs, the Starfish protocol distinguishes the AMM logic from the token management and accounting. Token management/accounting is administered by the vault, while each liquidity pool follows an individual AMM logic. As such, the pools are contracts external to the vault, the pool administrator can implement any arbitrary, customized AMM logic, such as fee and interest allocation, as per their preference.

Gas Efficiency

The Starfishโ€™s protocol vault executes a smart swap by transferring uniquely the net token amounts from and to the vault, regardless of swaps being carried out in batches against multiple pools. This mechanism economizes a significant amount of gas fee in the process.

Since only final net amounts are transferred, the threshold of conducting arbitrage trades is significantly lowered. For example, an arbitrager with no tokens in his wallet detects a price asymmetry among different Starfish pools, might trade USDC for USDT in pool 1, USDT for SEAN in pool 2, and finally SEAN for USDC in pool 3, which could make him a profit in USDC.

A more realistic scenario would be, if a user trades token A for token B, knowing that he will soon trade token B for token A in a few hours, it is likely that he does not need to โ€œreceiveโ€ token B immediately after the first trade. Starfish can keep both tokens in the vault which may be used for the next trades, thus avoiding multiple ERC20 transactions before โ€œfinalizingโ€ the intended trade. It is expected to have external aggregators, and curators relying on Starfishโ€™s internal balances to provide trades with the lowest gas costs to their users.

At launch, the Starfish protocol will offer weighted pools (constant weight) and stable pools which are suitable for tokens that are soft pegged to each other.

Shortly after the launch, there will be smart pools, allowing ongoing parameter changes. The Starfish team expects a great variety of pools would be created by other partners, and users as the protocol development matures. All pools will be able to provide trading liquidity thanks to the smart order router.

Starfish Pools

At launch, the Starfish protocol will offer Weighted Pools (constant weight) and Stable Pools which are suitable for tokens that are soft pegged to each other.

Shortly after the launch, there will be smart pools, allowing ongoing parameter changes. The Starfish team expects a great variety of pools would be created by other partners, and users as the protocol development matures. All pools will be able to provide trading liquidity thanks to the smart order router.

Last updated