Exemplo n.º 1
0
    def __init__(self, _id, _type: str, reference_type: str, _value: str,
                 json_path: str, doc) -> None:

        Extractable.__init__(self)
        self.id = _id
        self._type = _type
        self._value = _value
        self.json_path = json_path
        self.reference_type = reference_type
        self.origin_doc = doc
Exemplo n.º 2
0
    def __init__(self,
                 id,
                 json_path: str,
                 attribute: str,
                 extraction_provenances,
                 _document=None) -> None:

        Extractable.__init__(self)
        self.id = id
        self.field = None
        self._destination = json_path + '.' + attribute
        self.extraction_provenances = extraction_provenances  # will be assigned later_provenances
        self._document = _document
        self.doc_id = None
Exemplo n.º 3
0
    def __init__(self,
                 id: int,
                 json_path: str,
                 method: str,
                 start_char: str,
                 end_char: str,
                 confidence,
                 _document,
                 parent_extraction_provenance: int = None) -> None:

        Extractable.__init__(self)
        self.id = id
        self.origin_record = OriginRecord(json_path, start_char, end_char,
                                          _document)
        self.method = method
        self.extraction_confidence = confidence
        self._document = _document
        self._parent_extraction_provenance = parent_extraction_provenance
Exemplo n.º 4
0
 def __init__(self, json_path: str, _value: Dict, _document) -> None:
     Extractable.__init__(self)
     self.json_path = json_path
     self._value = _value
     self._extractions = dict()
     self._document = _document