How computation is done?
Rewards computation is done using an offchain script (which will be open-sourced soon). The compute function takes user data and programs as input and returns computed rewards.
You can access to a user computed rewards using: https://rewards.morpho.org/v1/users/[0xUser1]/rewards
Source of data
To compute rewards, we need user participation data over time within the protocol. We obtain this data using the following subgraph: Morpho Points Mainnet Subgraph.
Data manipulation
To provide advanced features on top of the programs, we need to perform data manipulation. This manipulation is carried out using offchain tools (which will be open-sourced soon).
We have implemented two key features: forwarding and blacklisting.
Forwarding
This feature is used to distribute Market programs. Since we have vaults on top of Morpho to supply in markets, without reallocation, rewards would be distributed to vaults. By implementing reallocation, we reallocate vault positions to vault suppliers, allowing us to directly distribute market rewards to the vault suppliers.
Blacklisting:
This feature removes the positions of blacklisted users. It allows protocols that bootstrap their markets to avoid incentivizing themselves.