-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathissue.schema.json
131 lines (131 loc) · 5.28 KB
/
issue.schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
{
"$schema": "http://json-schema.org/draft-06/schema#",
"$id": "https://impresso.github.io/impresso-schemas/json/newspaper/issue.schema.json",
"description": "Logical representation of the contents of a newspaper issue.",
"title": "Newspaper Issue",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Canonical ID of the newspaper issue (e.g. GDL-1900-01-02-a)"
},
"cdt": {
"type": "string",
"description": "Creation date timestamp (of the JSON file)."
},
"i": {
"type": "array",
"items": {
"type": "object",
"description": "A content item (e.g. article, advertisement, etc.)",
"properties": {
"m": {
"description": "Metadata about the content item.",
"$ref": "#/definitions/metadata"
},
"c": {
"type": "array",
"description": "Coordinates of image-region corresponding to the content-item depending on its type (if `tp == image`).",
"minItems":4,
"items": {
"type": "integer"
}
}
},
"required": ["m"]
},
"description": "The content items contained in the newspaper issue."
},
"s": {
"description": "The text style as defined in the OCR output. \nEach style consists of:\n - a name (`id`)\n - a type-face (`f`)\n - a font-size (`fs`)\n - a color (`rgb`).",
"type": "array",
"items": {
"type": "object",
"properties": {
"rgb": {
"type": "array",
"description": "Color of the text (in RGB).",
"items": {
"type": "integer"
},
"minItems": 3
},
"f": {
"type": "string",
"description": "Font name"
},
"fs": {
"type": "number",
"description": "Font size"
},
"id": {
"type": "integer",
"description": "Local ID of the style"
}
},
"required": ["id"]
}
},
"pp": {
"type": "array",
"description": "Canonical IDs of pages in the issue, without file extension (e.g. GDL-1900-01-02-a-p0004).",
"items": {
"type": "string"
}
},
"n": {
"type": "string",
"description": "Notes."
},
"ar": {
"type": "string",
"description": "Access rights. Three possible situations are defined:\n1. open public: access without NDA, user could redistribute (as defined per Terms of Use)\n2. open private: access without an NDA, user cannot redistribute (private/academic use only)\n3. closed : accessible only upon signing an NDA, user cannot redistribute",
"enum": ["open_public", "open_private", "closed"]
},
"iiif_manifest_uri": {
"type": "string",
"description": "URI for the issue's manifest in the IIIF Presentation API, if the corresponding IIIF server has one."
}
},
"required": ["id", "cdt", "i", "pp", "ar"],
"definitions":{
"metadata": {
"type":"object",
"properties": {
"id": {
"type": "string",
"description": "Content item ID (e.g. `GDL-1900-01-02-a-i0001`)."
},
"l": {
"type": "string",
"description": "Language of the content item."
},
"pp": {
"type": "array",
"items": {
"type": "integer"
},
"description": "Page numbers over which the content item spans."
},
"t": {
"type": "string",
"description": "Title of the content item."
},
"tp": {
"type": "string",
"description": "Type of the content item.",
"enum": ["article", "ad", "image", "table", "death_notice", "weather", "page"]
},
"iiif_link": {
"type": "string",
"description": "IIIF image link, depending on content item type (if `tp == image`). Should follow the format: '{scheme}://{server}/{prefix}/{identifier}/info.json'."
},
"ro": {
"type": "integer",
"description": "Reading order index of the content item, for the table of contents view on the interface. If not defined, the CI number (after 'i' in the ID) should be used."
}
},
"required": ["id","pp", "tp"]
}
}
}