Written Comm Analyzer — Sentence Structure

Sajid Rahman
Prod.IO
Published in
1 min readSep 29, 2018

We wanted to explore scoring texts on the basis of sentence structure. We used a python package called Spacy, This is a powerful NLP tool that can be used to do numerous analyses on texts and pre-process it for training deep neural networks on them. We did the following analysis that provided a good sense of the structure of the sentence being analyzed.

  1. Active/Passive Voice: Using spacy’s inbuilt functionalities, we found out if the text is in active or passive voice.
  2. Noun Phrases
  3. Verb Phrases
  4. Stop Words list
  5. Stem Words — get a list of all the unique stem words in the paragraph
  6. Adverb phrases
  7. Syllable count of words used
  8. Sentence Type — Analyze the text and categorize whether the sentence is simple, compound or complex.
  9. Sentence Statistics — Get statistics for a given sentence like word count, character count, voice, sentence type
  10. Paragraph Stats — Get statistics for a paragraph example — average reading words per minute, average speaking words per minute.

Such an analysis helped us to get deeper insights into the text. These parameters can help scoring texts based on the context of use. For example, in some context active voice might be recommended over passive voice, or simple sentences might be better than compound sentences.

--

--