Out-of-the-box NLP functionalities for your project using Transformers Library!
This article was published as a part of the Data Science Blogathon.
Introduction
In this tutorial, you will learn how you can integrate common Natural Language Processing (NLP) functionalities into your application with minimal effort. We will be doing this using the ‘transformers‘ library provided by Hugging Face.
1. First, Install the transformers library.
# Install the library !pip install transformers
2. Next, import the necessary functions.
# Necessary imports from transformers import pipeline
3. Irrespective of the task that we want to perform using this library, we have to first create a pipeline object which will intake other parameters and give an appropriate output. The required model weights will be downloaded the first time when the code is run.
Sentiment Analysis
Here is an example of how you can easily