Spark Meridian Implementation
Spec:
Measure
Job definition
Each retrieval made from an SP is a job.
Data model
[
{
"job_id": "abcdef",
"peer_id": "<Libp2p Peer ID>",
"started_at": "2023-05-01 00:52:57.62+00",
"ended_at": "2023-05-01 00:52:58.62+00",
"status_code": 200,
"signature_chain": "<signature chain>",
"num_bytes": 200,
"ttfb_ms": 45
},
...
]Evaluate
Evaluation Stage I: Data preprocessing
Fraud detection function
The fraud detection function verifies a log’s UCAN signature chain. If the signature chain holds, the log line will be aggregated into Honest logs, otherwise Fraudulent logs.
Data model
{
"measurement_root": "<merkle root hash>",
"started_at": "2023-05-01 00:52:57.62+00",
"ended_at": "2023-05-01 00:52:57.62+00",
"measurements": {
"honest": {
"log_count": 13
},
"fraudulent": {
"log_count": 2000
}
}
}Evaluation Stage II
Evaluation Function
The evaluation function is simply a count of the number of successful requests with valid signature chains a Station has performed. Specifically, for node ,
where if the log with index of node is valid and otherwise.
Fraud detection
There is no secondary fraud detection in SPARK.
Roadmap
TODO