gensim logo

gensim
gensim tagline

Get Expert Help From The Gensim Authors

Consulting in Machine Learning & NLP

• Commercial document similarity engine: ScaleText.ai

Corporate trainings in Python Data Science and Deep Learning

summarization.syntactic_unit – Syntactic Unit class

summarization.syntactic_unit – Syntactic Unit class

This module contains implementation of SyntacticUnit class. It generally used while text cleaning. SyntacticUnit represents printable version of provided text.

class gensim.summarization.syntactic_unit.SyntacticUnit(text, token=None, tag=None)

Bases: object

SyntacticUnit class.

text

str – Input text.

token

str – Tokenized text.

tag

str – Tag of unit, optional.

index

int – Index of sytactic unit in corpus, optional.

score

float – Score of synctatic unit, optional.

Parameters:
  • text (str) – Input text.
  • token (str) – Tokenized text, optional.
  • tag (str) – Tag of unit, optional.