Files
paperspec/schemas/submission.schema.json
T
alexm 62f54ed869
check / check (macos-latest) (push) Canceled after 0s
check / check (ubuntu-latest) (push) Canceled after 0s
Initial commit
2026-10-11 23:45:29 -04:00

110 lines
2.5 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://scient.ing/ns/schemas/submission.schema.json",
"title": "Submission",
"description": "scienting-submission/1: a student's answer, under a pseudonym; spec/19-exercises.md.",
"type": "object",
"properties": {
"format": {
"const": "scienting-submission/1"
},
"id": {
"$ref": "common.schema.json#/$defs/recordId"
},
"exercise": {
"type": "string",
"pattern": "^urn:scienting:annotation:[a-z0-9][a-z0-9._-]*/[a-hjkmnp-tv-z][0-9a-hjkmnp-tv-z]{6,25}$"
},
"doc": {
"$ref": "common.schema.json#/$defs/qualifiedKey"
},
"rev": {
"type": "integer",
"minimum": 0
},
"student": {
"type": "string",
"pattern": "^[a-z0-9][a-z0-9-]{3,63}$"
},
"answers": {
"type": "object",
"properties": {
"anchors": {
"type": "array",
"items": {
"$ref": "anchor.schema.json"
}
},
"verdict": {
"enum": [
"supports",
"partly",
"does-not",
"cannot-tell"
]
},
"chain": {
"type": "array",
"items": {
"type": "array",
"items": {
"$ref": "anchor.schema.json"
}
}
},
"value": {
"$ref": "common.schema.json#/$defs/decimal"
},
"flags": {
"type": "array",
"items": {
"type": "object",
"properties": {
"anchor": {
"$ref": "anchor.schema.json"
},
"verdict": {
"enum": [
"supports",
"partly",
"does-not",
"cannot-tell"
]
},
"note": {
"type": "string",
"minLength": 1
}
},
"required": [
"anchor",
"verdict"
],
"additionalProperties": false
}
},
"note": {
"type": "string",
"minLength": 1
}
},
"required": [],
"additionalProperties": false
},
"submitted_at": {
"$ref": "common.schema.json#/$defs/time"
}
},
"required": [
"format",
"id",
"exercise",
"doc",
"rev",
"student",
"answers",
"submitted_at"
],
"additionalProperties": false
}