pycognaize.document.field.field.Field
- class Field(name, value='', tags=None, field_id=None, group_key=None, confidence=-1.0, group_name=None, classification_labels=None, mapping=None)[source]
Bases:
object
Base class for all Field types
- Parameters:
name (
str
)value (
str
)tags (
Optional
[List
[BoxTag
]])field_id (
Optional
[str
])group_key (
Optional
[str
])confidence (
Optional
[float
])group_name (
Optional
[str
])classification_labels (
Optional
[ClassificationLabels
])mapping (
Optional
[List
[Dict
[str
,str
]]])
Methods
Use raw dictionary in order to recreate the Field python object
Return a dictionary representing the field object
Attributes
classes
classification_labels
confidence
field_id
group_key
group_name
mapping
name
raw_value
tags
value
- abstract classmethod construct_from_raw(raw, pages, html=None, labels=None)[source]
Use raw dictionary in order to recreate the Field python object
- Parameters:
raw (
dict
)pages (
Dict
[int
,Page
])html (
Optional
[HTML
])labels (
ClassificationLabels
)
- Return type: