concrete.summarization package¶
-
class
concrete.summarization.ttypes.
SummarizationCapability
(type=None, lang=None)¶ Bases:
object
Attributes:- type- lang-
read
(iprot)¶
-
validate
()¶
-
write
(oprot)¶
-
-
class
concrete.summarization.ttypes.
SummarizationRequest
(queryTerms=None, maximumTokens=None, maximumCharacters=None, sourceType=None, sourceIds=None, sourceCommunication=None)¶ Bases:
object
A request to summarize which specifies the length of the desiredsummary and the text data to be summarized.Either set sourceCommunication or sourceType and sourceIds.Attributes:- queryTerms: Terms or features pertinent to the query.Can be empty, meaning summarize all source material withno a priori beliefs about what is important to summarize.- maximumTokens: Limit on how long the returned summary can be in tokens.- maximumCharacters: Limit on how long the returned summary can be in characters.- sourceType: How to interpret the ids in sourceIds.May be null is sourceIds is null, otherwise must be populated.- sourceIds: A list of concrete object ids which serve as the materialto summarize.- sourceCommunication: Alternative to sourceIds+sourceType: provide a Communicationof text to summarize.-
read
(iprot)¶
-
validate
()¶
-
write
(oprot)¶
-
-
class
concrete.summarization.ttypes.
Summary
(summaryCommunication=None, concepts=None)¶ Bases:
object
A shortened version of some text, possibly with some conceptsannotated as justifications for why particular pieces of thesummary were kept.Attributes:- summaryCommunication: Contains the text of the generated summary.- concepts: Concepts mentioned in the summary which are believed to beinteresting and/or worth highlighting.-
read
(iprot)¶
-
validate
()¶
-
write
(oprot)¶
-
-
class
concrete.summarization.ttypes.
SummaryConcept
(tokens=None, concept=None, confidence=1, utility=1)¶ Bases:
object
A mention of a concept described in a summary which is thoughtto be informative. Concepts might be named entities, facts, orevents which were determined to be salient in the text beingsummarized.Attributes:- tokens: Location in summaryCommunication of this concept- concept: Short description of the concept being evoked, e.g. “kbrel:bornIn” or “related:ACME_Corp”- confidence: How confident is the system that this concept was evoked by this mention, in [0,1]- utility: How informative/important it is that this concept be included in the summary (non-negative).-
read
(iprot)¶
-
validate
()¶
-
write
(oprot)¶
-