move
move copied to clipboard
[Feature Request] Implementing more DeFi contracts in Move
π Feature Request
Motivation
DeFi contracts are gaining lots of attention these days as they bring new innovation to the crypto and finance market. However, most of the smart contracts are written in solidity. It is important for us to see if we can implement something similar in Move and use this experience to access our gap to a wilder adoption of Move.
Pitch
Under experimental folder, we've already implemented a few interesting contracts, including a primitive token type and a simplified uniswap protocol. It would be nice if we can implement more code like this to access the usability of Move in the DeFi space.
If you would like to contribute, please refer to this [tutorial] to see how the basic-coin
example is implemented and tested. This should offer you an overview of the developing flow of a Move package.
Here's a non-exhaustive list of DeFi contract that we might want to implement:
- Compound
- dydx
- Uniswap
- Oracle in Move?
Feel free to extend this list if there's any emerging new smart contracts.
Great move! We are very much interested! We are thinking of after implementing a few DeFi/NFT/Meta/Game projects, we can come up with an AutoMove Translator which can help porting Smart Contract DAPP projects from other blockchain eco-systems.
Would love to see these, especially if they include prover specs. Some other pointers I know of from StarCoin (and let me tag @lerencao @jolestar to see if there are more, as well as @mkurnikov from Pontem)
- https://github.com/starcoinorg/starcoin/blob/master/vm/stdlib/sources/YieldFarmingV2.move
- https://github.com/starcoinorg/starcoin/blob/master/vm/stdlib/sources/Oracle.move
- All of the different instantiations of
Coin<T>
from Diem, StarCoin, 0L, and Pontem. There are some very different minting/burning/issuance properties implemented in these coins, and it would be great to have them (as well as some toy examples) all in one place. Assets are the building blocks of DeFi--devs need to know how to create assets with fixed supply, algorithmic issuance, etc before they can start lending, swapping, etc.
Great move! There are already some Defi projects implemented with Move, can we collect them in one repo or document? like awesome-move?
- All of the different instantiations of
Coin<T>
from Diem, StarCoin, 0L, and Pontem. There are some very different minting/burning/issuance properties implemented in these coins, and it would be great to have them (as well as some toy examples) all in one place. Assets are the building blocks of DeFi--devs need to know how to create assets with fixed supply, algorithmic issuance, etc before they can start lending, swapping, etc.
We need to find a way to share Move library between Move blockchain projects. I hope the Move project dependency like:
βββββββββββββββ
βMove Std lib β
βββββββββββββββ
βββββββββββββββ βββββββββββββββββββββ
βMove DeFi libβ βMove Commons lib β
βββββββββββββββ βββββββββββββββββββββ
βββββββββββββββββββββββββββββββββ
β Move Chain independent lib β
βββββββββββββββββββββββββββββββββ
βββββββββββββββββββββ βββββββββββββββββββββ βββββββββββββββββββββ βββββββββββββββββββββ
β StarcoinFramework β β DiemFramework β β 0lFramework β β PontemFramework β
βββββββββββββββββββββ βββββββββββββββββββββ βββββββββββββββββββββ βββββββββββββββββββββ
Maybe we need to start a new issue to discuss this?
Great move! There are already some Defi projects implemented with Move, can we collect them in one repo or document? like awesome-move?
Fantastic idea. We should have done something like this a long time ago.
Spent some time building out https://github.com/MystenLabs/awesome-move with your links and several others--please share and contribute!
On package reorg, now that we have a packaging system, do you think we can get started by creating sub folders under experiment folder and have different crate relying on each other?
Maybe we need to start a new issue to discuss this?
I write an issue for this https://github.com/diem/move/issues/91