Options delta neutrality as a crypto native uncorrelated asset class
To get a local copy up and running follow these simple steps.
- npm
npm install npm@latest -g- Clone the repo
git clone- Install NPM packages
npm installor
yarn- Add environment variables
Create free API keys for alchemy and infura
a. Create /packages/contracts/.env with:
ALCHEMY_KEY=<your-alchemy-key>b. Create /packages/front-end/.env with:
REACT_APP_INFURA_KEY=<your-infura-key>- Start a hardhat node as mainnet fork
cd packages/contracts
npm run mainnet-forkFrom a new terminal window
- Compile contracts
cd packages/contracts
npm run compile- Deploy contracts and update ABIs + address
cd packages/contracts
npm run deploy:localhost- Start the React app
cd packages/front-end
npm run startComplete steps 1 to 3 from above:
Compile all files
npm run compileRun all tests
npx hardhat testTo run a specific test suite, e.g. LiquidityPool.ts
npx hardhat test test/LiquidityPool.tsRun test coverage
npm run test-coveragecontracts
├── hedging
│ ├── PerpHedgingReactor.sol
│ └── UniswapV3HedgingReactor.sol
├── interfaces
│ ├── AddressBookInterface.sol
│ ├── IAuthority.sol
│ ├── AggregatorV3Interface.sol
│ ├── GammaInterface.sol
│ ├── IERC20.sol
│ ├── IOptionRegistry.sol
│ ├── ILiquidityPool.sol
│ ├── IHedgingReactor.sol
│ ├── IMarginCalculator.sol
│ └── IOracle.sol
├── libraries
│ ├── BlackScholes.sol
│ ├── CustomErrors.sol
│ ├── NormalDist.sol
│ ├── OptionsCompute.sol
│ ├── OpynInteractions.sol
│ ├── AccessControl.sol
│ ├── SafeTransferLib.sol
│ └── Types.sol
├── tokens
│ └── ERC20.sol
├── Authority.sol
├── LiquidityPool.sol
├── OptionRegistry.sol
├── OptionHandler.sol
├── Protocol.sol
├── PortfolioValuesFeed.sol
├── VolatilityFeed.sol
└── PriceFeed.sol


