concrete.linking.ttypes module

Bases: object

A structure that represents the origin of an entity linking annotation.

- sourceId

The “root” of this Link; points to a EntityMention UUID, Entity UUID, etc.

- linkTargetList

A list of LinkTarget objects that this Link contains.

read(iprot)
thrift_spec = (None, (1, 12, 'sourceId', (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), None), (2, 15, 'linkTargetList', (12, (<class 'concrete.linking.ttypes.LinkTarget'>, (None, (1, 4, 'confidence', None, None), (2, 12, 'targetId', (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), None), (3, 11, 'dbId', 'UTF8', None), (4, 11, 'dbName', 'UTF8', None))), False), None))
validate()
write(oprot)
class concrete.linking.ttypes.LinkTarget(confidence=None, targetId=None, dbId=None, dbName=None)

Bases: object

A structure that represents the target of an entity linking annotation.

- confidence

Confidence of this LinkTarget object.

- targetId

A UUID that represents the target of this LinkTarget. This

UUID should exist in the Entity/Situation(Mention)Set that the Linking object is contained in.

  • dbId: A database ID that represents the target of this linking.

This should be used if the target of the linking is not associated with an Entity|Situation(Mention)Set in Concrete, and therefore cannot be linked by a UUID internal to concrete.

If present, other optional field ‘dbName’ should also be populated.
  • dbName: The name of the database that represents the target of this linking.

Together with the ‘dbId’, this can form a pointer to a target that is not represented inside concrete.

Should be populated alongside ‘dbId’.

read(iprot)
thrift_spec = (None, (1, 4, 'confidence', None, None), (2, 12, 'targetId', (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), None), (3, 11, 'dbId', 'UTF8', None), (4, 11, 'dbName', 'UTF8', None))
validate()
write(oprot)
class concrete.linking.ttypes.Linking(metadata=None, linkList=None)

Bases: object

A structure that represents entity linking annotations.

- metadata

Metadata related to this Linking object.

- linkList

A list of Link objects that this Linking object contains.

read(iprot)
thrift_spec = (None, (1, 12, 'metadata', (<class 'concrete.metadata.ttypes.AnnotationMetadata'>, (None, (1, 11, 'tool', 'UTF8', None), (2, 10, 'timestamp', None, None), None, (4, 12, 'digest', (<class 'concrete.metadata.ttypes.Digest'>, (None, (1, 11, 'bytesValue', 'BINARY', None), (2, 10, 'int64Value', None, None), (3, 4, 'doubleValue', None, None), (4, 11, 'stringValue', 'UTF8', None), (5, 15, 'int64List', (10, None, False), None), (6, 15, 'doubleList', (4, None, False), None), (7, 15, 'stringList', (11, 'UTF8', False), None))), None), (5, 12, 'dependencies', (<class 'concrete.metadata.ttypes.TheoryDependencies'>, (None, (1, 15, 'sectionTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (2, 15, 'sentenceTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (3, 15, 'tokenizationTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (4, 15, 'posTagTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (5, 15, 'nerTagTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (6, 15, 'lemmaTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (7, 15, 'langIdTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (8, 15, 'parseTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (9, 15, 'dependencyParseTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (10, 15, 'tokenAnnotationTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (11, 15, 'entityMentionSetTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (12, 15, 'entitySetTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (13, 15, 'situationMentionSetTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (14, 15, 'situationSetTheoryList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None), (15, 15, 'communicationsList', (12, (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), False), None))), None), (6, 8, 'kBest', None, 1))), None), (2, 15, 'linkList', (12, (<class 'concrete.linking.ttypes.Link'>, (None, (1, 12, 'sourceId', (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), None), (2, 15, 'linkTargetList', (12, (<class 'concrete.linking.ttypes.LinkTarget'>, (None, (1, 4, 'confidence', None, None), (2, 12, 'targetId', (<class 'concrete.uuid.ttypes.UUID'>, (None, (1, 11, 'uuidString', 'UTF8', None))), None), (3, 11, 'dbId', 'UTF8', None), (4, 11, 'dbName', 'UTF8', None))), False), None))), False), None))
validate()
write(oprot)