Skip to content

Commit

Permalink
Merge pull request #194 from PeggyJV/zaki/moreDocs
Browse files Browse the repository at this point in the history
Working on docs on positions and adapters
  • Loading branch information
zmanian committed Jul 4, 2024
2 parents 5c8e5d7 + 3c05f2c commit 5b3d89a
Show file tree
Hide file tree
Showing 3 changed files with 81 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ Cellar contracts for the Sommelier Network.
- [Permissions](./docs/permissions.md) Permissions in Cellars
- [Using Cellars](./docs/using_cellars.md) Using the Cellars Smart Contracts as a strategist
- [Fees](./docs/fees.md) How fees work for the strategist and the platform
- [Positions](./docs/positions.md) How positions are created and managed
- [Adapaters](./docs/adapters.md) How adapters are created and managed

### Development

Expand Down
70 changes: 70 additions & 0 deletions docs/adapters.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# Adapters

Adapters integrate Cellars with external DeFi protocols, enabling them to use the assets in the protocol.

We have an established catalogue of adapters that can be used to integrate with the following protocols:

## Aave

There are adapters for both Aave V2 and V3.

The adapters support both despoting assets and borrowing assets.

Frequent uses cases include:
- Leveraged Staking
- Stablecoin lending
- Leveraged Peg Arbitrage

## Aura

Adapter for Aura contracts using a specialized ERC4626 adapter.

## Balancer

Allows Cellars to interact with Stable and Boosted Stable Balancer Pools (BPs).

## Compound

Deposit and borrow assets in Compound.

## Convex

The Convex allows cellars to have positions where they are supplying, staking LPTs, and claiming rewards to Convex-Curve pools/markets.

## Curve

The Curve adapter supports creating and managing LP positions in Curve pools and depositing the LP tokens into guages to earn CRV rewards.

## Frax

The Frax adapter supports using the Frax lend protocol to deposit Frax and eary yield.

## Maker

Support for DAI staking to earn stablecoin yield.

## Morpho

## OneInch

Another source of swap liquidity.


## 0x

Another source of swap liquidity.

## Pendle

Enables the cellar to mint SY tokes and minting PT and YT tokens from the SY tokens.

The positions are these tokens and the adapter doesn't expose a position.

## Uniswap

The adapter supports swaps against both Uniswap V2 and V3. It supports holding multiple NFT LP positions in Uniswap V3.


## Staking Adapters

There is a universal template adapter that can specialied into staking assets into various protocols. We have support for the major LRT and LST protocols.
9 changes: 9 additions & 0 deletions docs/positions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Positions

A Position is an instantiation of an adapter for a specific asset. A cellar may have multiple positions using the same adapter.

The process for setting up a position is as follows:

1. A cellar add an adapter that has been trusted by Registry with `AddAdapterToCatalogue`,
2. A cellar adds a position that has been trusted by Registry with `AddAdapterToCatalogue`
3. `AddPosition` places the position in the internal index and passes configuration data to the adapter. This is connected to things like holding position, withdrawal order, etc.

0 comments on commit 5b3d89a

Please sign in to comment.