ZKML-Supported Risk Underwriting

Ion Protocol 's lending market internalizes validator demographic data via direct validator risk underwriting to determine variables such as interest rates, LTVs, and more.

Overview

Based on the type of asset being used for slashable security, Ion uses a trustless risk engine that intakes many different variables surrounding a given validator group's historical performance and uses zero-knowledge machine learning to determine the relative associated risk of slashing attributable to the asset connected to the group.

This is facilitated within a zero-knowledge circuit, designed in collaboration with Modulus Labs, enabling the data analysis to occur off-chain but be completely verifiable on-chain. This allows Ion to execute complex compute without having to incur the gas costs associated with doing so on-chain, which are prohibitive to machine learning-based operations.

ZKML frameworks also enable the protocol to create verifiable inferences, allowing any external actor to verify that the outputted risk rating of a collateral type was correctly generated using a pre-committed model and input data.

Modulus Labs: https://www.modulus.xyz/

Modulus x Ion Clarity Dashboard: Coming Soon!

This risk engine allows Ion Protocol to trustlessly create dynamic interest rates that react to the changing characteristics of the validator set over time, allowing for more robust protocol health across different market conditions and more performant lending outcomes for its users.

The Model

Data Origin

The majority of the data was retrieved from Beaconcha.in. This consisted of income, performance, and activation historical data.

Preprocessing

  • Several oversampling techniques were used such as ADASYN, SMOTETomek, SMOTE, and SMOTEENN on the minority class (i.e. slashed validators).

  • Additionally, grid search was utilized to narrow down the best decision boundary when prioritizing AUROC. This helped to generalize the decision boundary to future test sets to test the performance of our model on the AUROC metric.

Training

The model was trained over the history of the beacon chain, verifying the performance by backtesting on historical data.

Post-Processing

After the model in production runs, it returns the probabilities of being slashed for each validator in a validator group. Then the mean of the probabilities for each protocol is taken and its average probability of slashing is found for the entire subgroup. Ion Protocol internalizes these probabilities from each provider to inform the interest rate module and parameterize the market for each collateral.

Last updated