Skip to content

simple script for downloading Youtube comments without using the Youtube API

License

Notifications You must be signed in to change notification settings

santhoshse7en/utuby

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyPI Version Coverage Status License Documentation Status

utuby

YouTube's API is annoying to work with, and has lots of limitations. utuby is a simple script for downloading Youtube comments without using the Youtube API - No API rate limits. No restrictions. Extremely fast.

Source Link
PyPI: https://pypi.org/project/utuby/
Repository: https://github.com/santhoshse7en/utuby/
Documentation: https://santhoshse7en.github.io/utuby_doc/

Dependencies

  • beautifulsoup4
  • requests
  • lxml
  • cssselect
  • vaderSentiment
  • textblob
  • pandas

Dependencies Installation

Use the package manager pip to install following

pip install -r requirements.txt

A Glance

Download it by clicking the green download button here on Github. You only need to parse specific YouTube URL as argument.

>>> from utuby.utuby import youtube

>>> url = 'https://www.youtube.com/watch?v=xjQFi-HP7po'

>>> youtube = youtube(url)

Directory of youtube class

>>> print(dir(youtube))

ytdir

Examples for Extracting YouTube Channel Name

>>> youtube.channel_name

'Fully'

Examples Calculating Sentiment Scores for extracted YouTube Comments

>>> youtube.final_sentiment_scores

{'neu': 0.769, 'neg': 0.051, 'pos': 0.178, 'compound': 0.0}

Youtube Comments DataFrame

>>> youtube.youtube_comments_df.head()

ytdf

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT