File size: 725 Bytes
a03ca67
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10e198a
a03ca67
b16e331
a03ca67
 
 
 
 
 
1b4ccca
a03ca67
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import streamlit as st
from youtube_transcript_api import YouTubeTranscriptApi
import urllib.parse as urlparse
from pytube import extract

transcript = ""
 

def read_file(_id):
	tx = YouTubeTranscriptApi.get_transcript(_id)
	my_list = []
	for i in tx:
		curr_str = i["text"].replace("\xa0", "").replace("\n", " ")		
		my_list.append(curr_str)
	transcript = " ".join(str(x) for x in my_list)
	st.markdown(transcript)	

st.title('Easily Transcribe YouTube Videos - ChatGPTBots.net')

link = st.text_input('Enter your YouTube video link', 'https://www.youtube.com/watch?v=F6PqxbvOCUI')

if link is not None:
	print(link)
	_id=extract.video_id(link)
	st.video(link)

	st.button('Check Status', on_click=read_file(_id))