key | value | description |
---|---|---|
id (required) | box | Extracts all lines in a box. If you define an anchor that’s outside the box borders, then use offset parameters to define a point that’s inside the box borders so that Sensible recognizes the box. |
position | right, left, below, above. default: center of the anchor line’s bounding box | Use this parameter to fine tune box recognition. Defines the starting point for the box recognition relative to the anchor. For example, right specifies starting at the midpoint of the anchor line’s right boundary, and below specifies starting at the midpoint of the anchor line’s bottom boundary. Sensible searches outward from this point until it finds dark pixels signifying the box border. For an example of how to use this parameter, see the following Examples section. |
offsetX | number in inches default: 0 | Searches for a box starting at a point offset from the point defined by the Position parameter. Positive values offset to the right, negative values offset to the left. For an example of how to use this parameter, see the following Examples section. |
offsetY | number in inches default: 0 | Searches for a box starting at a point offset from the point defined by the Position parameter. Positive values offset down the page, negative values offset up the page. For an example of how to use this parameter, see the following Examples section. |
offsetBoxes | object. default: none | Recognize a box offset from the point defined in the Position parameter by a number of contiguous boxes that share borders. For example, use this parameter for tables or grids where borders surround every cell. Contains the following parameters: - direction: The direction to search in (above, below, right, left, relative to the starting box. - number: The number of boxes to offset by.For an example of how to use this parameter, see the following Examples section. |
darknessThreshold | number between 0 and 1. default: 0.9 | The brightness threshold below which to consider a pixel a box boundary. White is 1.0. Configure this parameter for checkboxes with dark backgrounds relative to the surrounding background.If the document has a white background, the default value is 0.9.If the document has dark or mottled background, for example as the result of a scan, then Sensible automatically chooses a default value based on the amount of contrast in the document. For an example of how to use this parameter, see the following Examples section. |
includeAnchor | true, false. default: false | If true, includes anchors lines that are inside the box borders in the method output. Ignores anchor lines that are outside box borders. |
Example document | Download link |
---|
darknessThreshold
parameter.
Config
Example document | Download link |
---|
Example document | Download link |
---|
"direction": "below"
) that’s shared with the next box. Choose a point ( represented as the second green dot) on the bottom border that’s in the middle of the starting box’s border and that’s just inside the next box’s borders.Example document | Download link |
---|
"position": "left"
). Since the point (the green dot) overlaps the box border, Sensible can’t recognize the box.
Config
Example document | Download link |
---|
"position": "right"
, the green dot is far enough inside the borders that Sensible recognizes the box:
Config