Bill of Lading V1
Sample Code:
- class BillOfLadingV1(raw_prediction)
Bill of Lading API version 1 inference prediction.
- static get_endpoint_info(klass)
Retrives the endpoint information for an Inference.
Should never retrieve info for CustomV1, as a custom endpoint should be created to use CustomV1.
- Parameters:
klass (
Type
[Inference
]) – product subclass to access endpoint information.- Return type:
Dict
[str
,str
]
- endpoint_name: Optional[str] = 'bill_of_lading'
Name of the endpoint.
- endpoint_version: Optional[str] = '1'
Version of the endpoint.
- is_rotation_applied: Optional[bool]
Whether the document has had any rotation applied to it.
- page_id: Optional[int]
Optional page id for page-level predictions.
-
pages:
List
[Page
[BillOfLadingV1Document
]] Page-level prediction(s).
-
prediction:
BillOfLadingV1Document
Document-level prediction.
- product: Product
Name and version of a given product, as sent back by the API.
- class BillOfLadingV1Document(raw_prediction, page_id=None)
Bill of Lading API version 1.1 document data.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
-
bill_of_lading_number:
StringField
A unique identifier assigned to a Bill of Lading document.
-
carrier:
BillOfLadingV1Carrier
The shipping company responsible for transporting the goods.
-
carrier_items:
List
[BillOfLadingV1CarrierItem
] The goods being shipped.
-
consignee:
BillOfLadingV1Consignee
The party to whom the goods are being shipped.
-
notify_party:
BillOfLadingV1NotifyParty
The party to be notified of the arrival of the goods.
-
place_of_delivery:
StringField
The place where the goods are to be delivered.
-
port_of_discharge:
StringField
The port where the goods are unloaded from the vessel.
-
port_of_loading:
StringField
The port where the goods are loaded onto the vessel.
-
shipper:
BillOfLadingV1Shipper
The party responsible for shipping the goods.
- class BillOfLadingV1Shipper(raw_prediction, page_id=None)
The party responsible for shipping the goods.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
- to_field_list()
Output the object in a format suitable for inclusion in an rST field list.
- Return type:
str
-
address:
Optional
[str
] The address of the shipper.
- bounding_box: Optional[Quadrilateral]
A right rectangle containing the word in the document.
- confidence: float
The confidence score.
-
email:
Optional
[str
] The email of the shipper.
-
name:
Optional
[str
] The name of the shipper.
-
page_n:
int
The document page on which the information was found.
-
phone:
Optional
[str
] The phone number of the shipper.
- polygon: Polygon
A polygon containing the word in the document.
- class BillOfLadingV1Consignee(raw_prediction, page_id=None)
The party to whom the goods are being shipped.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
- to_field_list()
Output the object in a format suitable for inclusion in an rST field list.
- Return type:
str
-
address:
Optional
[str
] The address of the consignee.
- bounding_box: Optional[Quadrilateral]
A right rectangle containing the word in the document.
- confidence: float
The confidence score.
-
email:
Optional
[str
] The email of the shipper.
-
name:
Optional
[str
] The name of the consignee.
-
page_n:
int
The document page on which the information was found.
-
phone:
Optional
[str
] The phone number of the consignee.
- polygon: Polygon
A polygon containing the word in the document.
- class BillOfLadingV1NotifyParty(raw_prediction, page_id=None)
The party to be notified of the arrival of the goods.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
- to_field_list()
Output the object in a format suitable for inclusion in an rST field list.
- Return type:
str
-
address:
Optional
[str
] The address of the notify party.
- bounding_box: Optional[Quadrilateral]
A right rectangle containing the word in the document.
- confidence: float
The confidence score.
-
email:
Optional
[str
] The email of the shipper.
-
name:
Optional
[str
] The name of the notify party.
-
page_n:
int
The document page on which the information was found.
-
phone:
Optional
[str
] The phone number of the notify party.
- polygon: Polygon
A polygon containing the word in the document.
- class BillOfLadingV1Carrier(raw_prediction, page_id=None)
The shipping company responsible for transporting the goods.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
- to_field_list()
Output the object in a format suitable for inclusion in an rST field list.
- Return type:
str
- bounding_box: Optional[Quadrilateral]
A right rectangle containing the word in the document.
- confidence: float
The confidence score.
-
name:
Optional
[str
] The name of the carrier.
-
page_n:
int
The document page on which the information was found.
- polygon: Polygon
A polygon containing the word in the document.
-
professional_number:
Optional
[str
] The professional number of the carrier.
-
scac:
Optional
[str
] The Standard Carrier Alpha Code (SCAC) of the carrier.
- class BillOfLadingV1CarrierItem(raw_prediction, page_id=None)
The goods being shipped.
- Parameters:
raw_prediction (Dict[str, Any]) –
page_id (Optional[int]) –
- to_table_line()
Output in a format suitable for inclusion in an rST table.
- Return type:
str
- bounding_box: Optional[Quadrilateral]
A right rectangle containing the word in the document.
- confidence: float
The confidence score.
-
description:
Optional
[str
] A description of the item.
-
gross_weight:
Optional
[float
] The gross weight of the item.
-
measurement:
Optional
[float
] The measurement of the item.
-
measurement_unit:
Optional
[str
] The unit of measurement for the measurement.
-
page_n:
int
The document page on which the information was found.
- polygon: Polygon
A polygon containing the word in the document.
-
quantity:
Optional
[float
] The quantity of the item being shipped.
-
weight_unit:
Optional
[str
] The unit of measurement for weights.