TalkingBot/ingestion/tests/fixtures/textract-layout.json

46 lines
6.7 KiB
JSON

{
"JobStatus": "SUCCEEDED",
"Blocks": [
{ "Id": "h1", "BlockType": "LAYOUT_HEADER", "Page": 1, "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.5, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["lh1"] }] },
{ "Id": "lh1", "BlockType": "LINE", "Page": 1, "Text": "Weekly Digest", "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "pn1", "BlockType": "LAYOUT_PAGE_NUMBER", "Page": 1, "Geometry": { "BoundingBox": { "Top": 0.02, "Left": 0.8, "Width": 0.1, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["lp1"] }] },
{ "Id": "lp1", "BlockType": "LINE", "Page": 1, "Text": "12", "Geometry": { "BoundingBox": { "Top": 0.02, "Left": 0.8, "Width": 0.1, "Height": 0.02 } } },
{ "Id": "t1", "BlockType": "LAYOUT_TEXT", "Page": 1, "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.1, "Width": 0.7, "Height": 0.4 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["l1", "l2", "l3", "l4", "p1foot"] }] },
{ "Id": "l1", "BlockType": "LINE", "Page": 1, "Text": "Edition Banner", "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "l2", "BlockType": "LINE", "Page": 1, "Text": "This is an exam-", "Geometry": { "BoundingBox": { "Top": 0.14, "Left": 0.1, "Width": 0.5, "Height": 0.02 } } },
{ "Id": "l3", "BlockType": "LINE", "Page": 1, "Text": "ple of a sentence that wraps.", "Geometry": { "BoundingBox": { "Top": 0.17, "Left": 0.1, "Width": 0.6, "Height": 0.02 } } },
{ "Id": "l4", "BlockType": "LINE", "Page": 1, "Text": "Next paragraph starts here.", "Geometry": { "BoundingBox": { "Top": 0.22, "Left": 0.1, "Width": 0.5, "Height": 0.02 } } },
{ "Id": "f1", "BlockType": "LAYOUT_FOOTER", "Page": 1, "Geometry": { "BoundingBox": { "Top": 0.95, "Left": 0.1, "Width": 0.4, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["lf1"] }] },
{ "Id": "lf1", "BlockType": "LINE", "Page": 1, "Text": "Confidential", "Geometry": { "BoundingBox": { "Top": 0.95, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "p1foot", "BlockType": "LINE", "Page": 1, "Text": "Printed Footer", "Geometry": { "BoundingBox": { "Top": 0.9, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "c1", "BlockType": "LINE", "Page": 2, "Text": "Edition Banner", "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.05, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "c2", "BlockType": "LINE", "Page": 2, "Text": "Left column sentence.", "Geometry": { "BoundingBox": { "Top": 0.2, "Left": 0.05, "Width": 0.35, "Height": 0.02 } } },
{ "Id": "c3", "BlockType": "LINE", "Page": 2, "Text": "Right column sentence.", "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.55, "Width": 0.35, "Height": 0.02 } } },
{ "Id": "c4", "BlockType": "LINE", "Page": 2, "Text": "iv", "Geometry": { "BoundingBox": { "Top": 0.9, "Left": 0.55, "Width": 0.1, "Height": 0.02 } } },
{ "Id": "c5", "BlockType": "LINE", "Page": 2, "Text": "Printed Footer", "Geometry": { "BoundingBox": { "Top": 0.96, "Left": 0.55, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "h3", "BlockType": "LAYOUT_HEADER", "Page": 3, "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.4, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["lh3"] }] },
{ "Id": "lh3", "BlockType": "LINE", "Page": 3, "Text": "Weekly Digest", "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "t3", "BlockType": "LAYOUT_TEXT", "Page": 3, "Geometry": { "BoundingBox": { "Top": 0.08, "Left": 0.1, "Width": 0.7, "Height": 0.1 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["b3", "body3"] }] },
{ "Id": "b3", "BlockType": "LINE", "Page": 3, "Text": "Edition Banner", "Geometry": { "BoundingBox": { "Top": 0.08, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "body3", "BlockType": "LINE", "Page": 3, "Text": "A table follows this sentence.", "Geometry": { "BoundingBox": { "Top": 0.12, "Left": 0.1, "Width": 0.5, "Height": 0.02 } } },
{ "Id": "tb", "BlockType": "LAYOUT_TABLE", "Page": 3, "Geometry": { "BoundingBox": { "Top": 0.2, "Left": 0.1, "Width": 0.6, "Height": 0.1 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["tr1", "tr2"] }] },
{ "Id": "tr1", "BlockType": "LINE", "Page": 3, "Text": "Name Age", "Geometry": { "BoundingBox": { "Top": 0.2, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "tr2", "BlockType": "LINE", "Page": 3, "Text": "Ada 36", "Geometry": { "BoundingBox": { "Top": 0.24, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "ls", "BlockType": "LAYOUT_LIST", "Page": 3, "Geometry": { "BoundingBox": { "Top": 0.4, "Left": 0.1, "Width": 0.5, "Height": 0.1 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["li1", "li2"] }] },
{ "Id": "li1", "BlockType": "LINE", "Page": 3, "Text": "Item one", "Geometry": { "BoundingBox": { "Top": 0.4, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "li2", "BlockType": "LINE", "Page": 3, "Text": "Item two", "Geometry": { "BoundingBox": { "Top": 0.44, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "foot3", "BlockType": "LAYOUT_TEXT", "Page": 3, "Geometry": { "BoundingBox": { "Top": 0.96, "Left": 0.1, "Width": 0.4, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["p3foot"] }] },
{ "Id": "p3foot", "BlockType": "LINE", "Page": 3, "Text": "Printed Footer", "Geometry": { "BoundingBox": { "Top": 0.94, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } },
{ "Id": "h4", "BlockType": "LAYOUT_HEADER", "Page": 4, "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.4, "Height": 0.02 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["lh4"] }] },
{ "Id": "lh4", "BlockType": "LINE", "Page": 4, "Text": "Weekly Digest", "Geometry": { "BoundingBox": { "Top": 0.01, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "t4", "BlockType": "LAYOUT_TEXT", "Page": 4, "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.1, "Width": 0.7, "Height": 0.2 } }, "Relationships": [{ "Type": "CHILD", "Ids": ["b4", "w4", "end4", "p4foot"] }] },
{ "Id": "b4", "BlockType": "LINE", "Page": 4, "Text": "Edition Banner", "Geometry": { "BoundingBox": { "Top": 0.1, "Left": 0.1, "Width": 0.4, "Height": 0.02 } } },
{ "Id": "w4", "BlockType": "LINE", "Page": 4, "Text": "The well-known path continues.", "Geometry": { "BoundingBox": { "Top": 0.16, "Left": 0.1, "Width": 0.5, "Height": 0.02 } } },
{ "Id": "end4", "BlockType": "LINE", "Page": 4, "Text": "Final words and a \uFB01ligature.", "Geometry": { "BoundingBox": { "Top": 0.2, "Left": 0.1, "Width": 0.5, "Height": 0.02 } } },
{ "Id": "p4foot", "BlockType": "LINE", "Page": 4, "Text": "Printed Footer", "Geometry": { "BoundingBox": { "Top": 0.94, "Left": 0.1, "Width": 0.3, "Height": 0.02 } } }
]
}