Schema
qem-matrix.schema.json
Public QuantBayes validation schema.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://quantbayes.com/schemas/qem-matrix.schema.json",
"title": "QuantBayes QEM matrix",
"description": "Schema for QuantBayes QEM evidence structures. TRUE maps to 0, FALSE maps to 1, NA maps to 0.",
"type": "object",
"additionalProperties": false,
"required": [
"case_uid",
"profile_uid",
"items",
"outcomes"
],
"properties": {
"case_uid": {
"type": "string",
"minLength": 1
},
"profile_uid": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{2,95}$"
},
"standard": {
"type": "string",
"const": "SGA-QEM-1.0"
},
"items": {
"type": "array",
"minItems": 1,
"items": {
"$ref": "#/$defs/item"
}
},
"outcomes": {
"type": "array",
"minItems": 1,
"items": {
"$ref": "#/$defs/outcome"
}
},
"matrix": {
"type": "array",
"items": {
"type": "array",
"items": {
"type": "integer",
"enum": [
0,
1
]
}
}
}
},
"$defs": {
"item": {
"type": "object",
"additionalProperties": false,
"required": [
"item_uid"
],
"properties": {
"item_uid": {
"type": "string",
"minLength": 1
},
"item_type": {
"type": "string"
},
"label": {
"type": "string"
},
"metadata": {
"type": "object"
}
}
},
"outcome": {
"type": "object",
"additionalProperties": false,
"required": [
"item_uid",
"rule_uid",
"raw_outcome"
],
"properties": {
"item_uid": {
"type": "string",
"minLength": 1
},
"rule_uid": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{2,63}$"
},
"raw_outcome": {
"type": "string",
"enum": [
"TRUE",
"FALSE",
"NA"
]
},
"xij": {
"type": "integer",
"enum": [
0,
1
]
},
"source_value": {
"type": "string"
},
"notes": {
"type": "string"
},
"provenance": {
"type": "object"
}
}
}
}
}