This directory contains an example oracle AMM application using Pyth price feeds.
The oracle AMM manages a pool of two tokens and allows a user to trade with the pool at the current Pyth price.
This application has two components. The first component is a smart contract (in the `contract` directory) that manages the pool and implements the trading functionality.
The second is a frontend application (in the `app` directory) that communicates with the smart contract.
Please see the [Pyth documentation](https://docs.pyth.network/pythnet-price-feeds) for more information about Pyth and how to integrate it into your application.
**Warning** this AMM is intended only as a demonstration of Pyth price feeds and is **not for production use**.
## AMM Contract
All of the commands in this section expect to be run from the `contract` directory.
### Building
You need to have [Foundry](https://getfoundry.sh/) and `node` installed to run this example.
Once you have installed these tools, run the following commands from this directory: