Skip to content

Latest commit

 

History

History

text Similarity

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Python Script to calculate Text Similarity using Cosine Distance

The script will take as input two sentences from user and determine how similar they are. For encoding the text, Count Vectorizer and TFIDF Vectorizer have been used.

Installation

  • You must have Python and Pip installed.

  • Go to the directory of the folder using your command prompt.

  • Type pip install -r requirements.txt. This will download all the dependencies

Run

  • Type python TextSimilarity.py
  • Enter the two sentences
  • See the results generated