Krittaprot commited on
Commit
9107744
1 Parent(s): 53f107e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -237,9 +237,10 @@ def create_sentiment_analysis_chart(data):
237
 
238
  def process_youtube_comments(youtube_link, max_comments, stop_words):
239
  # Process the YouTube link and generate the word cloud, summary, and sentiment analysis
240
-
 
241
  # Pull comments from the YouTube Video
242
- comments_df = comments_collector(video_link=youtube_link, max_comments=max_comments)
243
  # Analyze
244
  analysis_dict = comments_analyzer(comments_df)
245
  long_text = analysis_dict['blended_comments']
 
237
 
238
  def process_youtube_comments(youtube_link, max_comments, stop_words):
239
  # Process the YouTube link and generate the word cloud, summary, and sentiment analysis
240
+ video_id = extract_youtube_video_id(youtube_link)
241
+
242
  # Pull comments from the YouTube Video
243
+ comments_df = comments_collector(video_link=video_id, max_comments=max_comments)
244
  # Analyze
245
  analysis_dict = comments_analyzer(comments_df)
246
  long_text = analysis_dict['blended_comments']