GEO-Framework / schema /source-book.schema.json
juliangauss1986's picture
Publish six-language machine-readable corpus
d9b9522 verified
Raw
History Blame Contribute Delete
6.23 kB
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://noblejackal.com/schemas/geo-framework-book-v1.json",
"title": "NobleJackal GEO Framework publication",
"description": "Schema for each versioned GEO Framework language edition, its human and machine publication surfaces, integrity record and normative boundaries.",
"type": "object",
"required": [
"schemaVersion",
"id",
"canonical",
"title",
"language",
"version",
"status",
"author",
"archiveRecord",
"normativeBoundary",
"integrity",
"access",
"chapters"
],
"properties": {
"schemaVersion": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" },
"id": { "type": "string", "format": "uri" },
"canonical": { "type": "string", "format": "uri" },
"machineBase": { "type": "string", "format": "uri" },
"title": { "type": "string", "minLength": 1 },
"subtitle": { "type": "string", "minLength": 1 },
"language": { "enum": ["en", "tr", "de", "es", "ru", "ar"] },
"htmlLocale": { "enum": ["en", "tr", "de", "es", "ru", "ar"] },
"direction": { "enum": ["ltr", "rtl"] },
"version": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" },
"status": { "enum": ["publication-locked-turkish-master", "publication-locked-language-edition"] },
"publicationDate": { "type": "string", "format": "date" },
"author": {
"type": "object",
"required": ["publishedName", "identity", "profile"],
"properties": {
"publishedName": { "type": "string" },
"identity": { "type": "string" },
"profile": { "type": "string", "format": "uri" }
},
"additionalProperties": false
},
"publisher": {
"type": "object",
"required": ["name", "url", "profile"],
"properties": {
"name": { "type": "string" },
"url": { "type": "string", "format": "uri" },
"profile": { "type": "string", "format": "uri" }
},
"additionalProperties": false
},
"rights": { "type": "string" },
"archiveRecord": { "$ref": "#/$defs/archiveRecord" },
"normativeBoundary": {
"type": "object",
"required": ["standardProposal", "externallyValidated", "accredited", "certificationProgramActive", "statement"],
"properties": {
"standardProposal": { "const": true },
"externallyValidated": { "const": false },
"accredited": { "const": false },
"certificationProgramActive": { "const": false },
"statement": { "type": "string", "minLength": 1 }
},
"additionalProperties": false
},
"integrity": {
"type": "object",
"required": ["algorithm", "canonicalMarkdown", "lockedReleaseDocx"],
"properties": {
"algorithm": { "const": "SHA-256" },
"canonicalMarkdown": { "$ref": "#/$defs/sha256" },
"lockedReleaseDocx": {
"anyOf": [
{ "$ref": "#/$defs/sha256" },
{ "type": "null" }
]
}
},
"additionalProperties": false
},
"access": {
"type": "object",
"required": ["human", "markdown", "json", "manifest", "citation", "docx"],
"properties": {
"human": { "type": "string", "format": "uri" },
"markdown": { "type": "string", "format": "uri" },
"json": { "type": "string", "format": "uri" },
"manifest": { "type": "string", "format": "uri" },
"citation": { "type": "string", "format": "uri" },
"docx": {
"anyOf": [
{ "type": "string", "format": "uri" },
{ "type": "null" }
]
}
},
"additionalProperties": false
},
"languageAlternates": {
"type": "object",
"required": ["en", "tr", "de", "es", "ru", "ar", "x-default"],
"additionalProperties": { "type": "string", "format": "uri" }
},
"frontMatter": { "$ref": "#/$defs/contentPart" },
"chapters": {
"type": "array",
"minItems": 10,
"maxItems": 10,
"items": {
"allOf": [
{ "$ref": "#/$defs/contentPart" },
{
"type": "object",
"required": ["number", "roman", "slug", "title", "part", "description"],
"properties": {
"number": { "type": "integer", "minimum": 1, "maximum": 10 },
"roman": { "type": "string" },
"slug": { "type": "string", "pattern": "^[a-z0-9-]+$" },
"title": { "type": "string" },
"part": { "type": "string" },
"description": { "type": "string" }
}
}
]
}
},
"backMatter": { "$ref": "#/$defs/contentPart" }
},
"$defs": {
"sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" },
"archiveRecord": {
"type": "object",
"required": ["repository", "language", "repositoryLanguage", "version", "repositoryVersion", "doi", "conceptDoi", "doiUrl", "conceptDoiUrl", "recordUrl", "pdfUrl", "officialWebEdition"],
"properties": {
"repository": { "const": "Zenodo" },
"language": { "enum": ["en", "tr", "de", "es", "ru", "ar"] },
"repositoryLanguage": { "enum": ["eng", "tur", "deu", "spa", "rus", "ara"] },
"version": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" },
"repositoryVersion": { "type": ["string", "null"] },
"doi": { "type": "string", "pattern": "^10\\.5281/zenodo\\.[0-9]+$" },
"conceptDoi": { "type": "string", "pattern": "^10\\.5281/zenodo\\.[0-9]+$" },
"doiUrl": { "type": "string", "format": "uri" },
"conceptDoiUrl": { "type": "string", "format": "uri" },
"recordUrl": { "type": "string", "format": "uri" },
"pdfUrl": { "type": "string", "format": "uri" },
"officialWebEdition": { "type": "string", "format": "uri" }
},
"additionalProperties": false
},
"contentPart": {
"type": "object",
"required": ["canonical", "wordCount", "markdown"],
"properties": {
"canonical": { "type": "string", "format": "uri" },
"wordCount": { "type": "integer", "minimum": 1 },
"markdown": { "type": "string", "minLength": 1 }
}
}
}
}