MsgCreateAIDataSource. In the Oraichain system, anyone could become an AI Provider.
MsgCreateAIDataSourcesent to the system. The AI Data Source metadata will be stored on Oraichain for transparency and for everyone to see using the
AIDataSourcestruct. There are some parameters given in the message as follows:
MsgCreateTestcase. Similar to the AI Provider, anyone can be a test case provider.
TestCasestruct. Below are the attributes of a test case that are stored on-chain:
MsgCreateOracleScriptto Oraichain. The contents of the message includes:
AIrequestto Oraichain to use a provided AI service. Oraichain stores basic information of an AI request for querying, and other systems can use the request's result for their business logic. Behind the scenes, users invoke an oracle script call, where the system chooses randomly a set of validators that execute the oracle script and collect the results. The results are stored on Oraichain for other users or system to re-use in the future. Note that users can specify the number of validators that they want to run the script. Below are the required attributes for an
Report. A report has the following fields:
AIRequestResultstores the final result after aggregating the results from the reports of an AI request, which are immutable and can be reused. It contains:
AIRequestResult. It can be in pending, finished, or expired mode. It is in pending mode when there are not enough reports, but the deadline is not reached. An
AIRequestResultdeadline counts as a threshold for a specific number of blocks passed from the block that has added the create AI request transaction. For example, an AI request is added into block ten, and the threshold is ten. As a result, the deadline is block twenty. If the
AIRequestResultreceives less than the number of required reports, it will be considered as expired. Other than that, the
AIRequestResultis in finish mode.
Rewardstruct to incentive entities that have contributed in the process. Even when an
AIRequestResultis in expired mode, those who have reported or data sources, test cases that have run successfully and correctly will be rewarded. In order to do so, there are a few parameters for this
Rewardstruct that we need to consider:
Rewardstored on chain.