Summary
This proposal seeks to integrate Chaos Labs' Risk Oracle into the GMX protocol to improve the efficiency and accuracy of market parameter updates. The Risk Oracle will enable real-time and automated adjustments to market configurations, reducing manual intervention and enhancing the overall trading experience. This step aligns with GMX’s commitment to ensuring transparency and antifragility, while delegating critical tasks like risk-based market parameters and protocol upkeep to trusted, independent leaders in the space.
Motivation
Chaos Labs is the Risk Manager for GMX DAO, providing essential market parameters for GMX V2. Currently, these parameters are updated manually after periodic reviews or in response to significant events affecting pools (e.g., changes in pool sizes, open interest, or external liquidity). While this process is effective, it introduces delays, leading to conservative parameters and higher fees to account for potential market fluctuations.
By integrating Chaos Labs' Risk Oracle, GMX will automate these updates, allowing the protocol to adjust critical parameters like price impact and max open interest in real-time. This integration will result in:
- More competitive execution costs
- Reduced price manipulation risks
- Less manual workload for developers
Overall, the integration ensures more precise, responsive, and secure risk management.
Rationale
The integration of Chaos Labs' Risk Oracle will bring several key advantages to GMX:
- Real-time updates and automated adjustments: They will ensure that critical parameters, such as price impact and max open interest (OI) configurations, are updated automatically. This will lead to better execution costs, more competitive pricing for traders, and added protection against price manipulation and imbalanced pools.
- Enhanced Market Stability: The system will dynamically adjust based on data from both centralised and decentralised exchanges (CEXs and DEXs), ensuring the protocol remains resilient against sudden market changes.
- Increased Resilience: The protocol becomes more antifragile by reducing its reliance on contributors for updates while still maintaining contingency mechanisms through Admins and the Security multisig as a fallback.
Specification
- Risk Oracle Integration
- Data Source: GMX will read risk parameters from the Chaos Labs' Risk Oracle.
- Parameter Updates: The Keeper will observe, validate, and execute transactions to update on-chain market configurations based on Oracle data.
- Control Mechanism: The Keeper will not directly control parameters; instead, GMX’s contract will retrieve values from the Oracle during transaction execution.
- Update Frequency
- All Parameters will be updated periodically, but the period for different parameters can differ. Our Keeper will always execute txn’s with new parameters immediately.
- Validation and Safety
- The Keeper will automatically validate updates within a predefined valid range and ensure that only whitelisted parameters are updated, while also applying validations to Chaos Labs' data. Additionally, contract-side validations will explicitly allow updates for specific parameters and markets, further ensuring the protocol's safety and integrity.
- Initial updates will use narrower ranges for extra security.
Implementation Plan
- Phase 1: Support for maximum open interest updates
- Phase 2: Position price impact updates
- Future: Expanding to parameters like swap price impact, max pool size, funding rate, and borrowing rate.
Conclusion
Integrating Chaos Labs' Risk Oracle will allow GMX to adapt quickly to market conditions by accessing real-time data from CEXs and DEXs. Automating key market updates will improve trading conditions, bolster protection against market manipulation, and reduce manual intervention.
Next Steps
We invite the GMX DAO to vote on this proposal, moving forward with The integration of Chaos Labs' Risk Oracle to strengthen the protocol.