video_bot_999 / app.py

Commit History

def chat_with_youtube_transcript(youtube_id, thread_id, user_message, chat_history, socratic_mode=False):
3341bca

youngtsai commited on

if thread_id is None or thread_id == "":
c398005

youngtsai commited on

video_id = gr.Textbox(label="video_id")
cdaf4d8

youngtsai commited on

chat_with_youtube_transcript
c5051e3

youngtsai commited on

summary_json = {"summary": str(summary)}
ee689dc

youngtsai commited on

def get_video_id_summary(video_id, df_string, source):
b872b89

youngtsai commited on

elif source == "drive":
f28acdd

youngtsai commited on

get_questions
1643087

youngtsai commited on

updated_transcript_json
2f6be19

youngtsai commited on

# 先取消 Google Drive 的图片
cc41b6c

youngtsai commited on

print("===entry===")
fd44792

youngtsai commited on

screenshot_path = img_file_id
915c4c3

youngtsai commited on

screenshot_blob_name
ce3af6c

youngtsai commited on

is_transcript_exists
fcdfe30

youngtsai commited on

print("===更新逐字稿文件===")
9cd0c68

youngtsai commited on

is_transcript_exists
2814ef1

youngtsai commited on

transcript_text = download_blob_to_string(gcs_client, bucket_name, transcript_blob_name)
617b2b5

youngtsai commited on

updated_transcript_text
6d113f6

youngtsai commited on

print("逐字稿已上传到GCS")
3cc7368

youngtsai commited on

raise gr.Error("test")
642f40d

youngtsai commited on

upload_file_to_gcs_with_json_string
2df824b

youngtsai commited on

transcript = process_transcript_and_screenshots_on_gcs(video_id)
1491bd4

youngtsai commited on

def copy_file_from_drive_to_gcs(drive_service, gcs_client, file_id, bucket_name, gcs_destination_path):
f0d8f54

youngtsai commited on

def copy_file_from_drive_to_gcs(drive_service, gcs_client, file_id, bucket_name, gcs_destination_path):
aaf5d8b

youngtsai commited on

print("GCS folder:{video_id} 已存在")
c3b5949

youngtsai commited on

simple_html_content = gr.HTML(label="Simple Transcript")
4bbcdbc

youngtsai commited on

# 当输入网页链接时触发
848a8d9

youngtsai commited on

with gr.Blocks() as demo:
c997d4e

youngtsai commited on

with gr.Blocks(head=HEAD) as demo:
15e1a1f

youngtsai commited on

with gr.Blocks() as demo:
27bd0db

youngtsai commited on

with gr.Tab("心智圖",elem_id="mind_map_tab"):
7ab5e1e

youngtsai commited on

mind_map = gr.Textbox(container=True, show_copy_button=True, lines=40, elem_id="mind_map_markdown")
369b716

youngtsai commited on

Submit_YouTube_Link
81040e3

youngtsai commited on

youtube_link_btn = gr.Button("Submit")
d476f89

youngtsai commited on

youtube_link_btn = gr.Button("Submit", id="youtube_link_btn")
094d768

youngtsai commited on

youtube_link_btn = gr.Button("Submit")
c352296

youngtsai commited on

https://www.youtube.com/watch?v=lYCugZj-d74&list=PLm778hWdXOZkrfV0px167qaUxvCZJLlzd&index=12
b512528

youngtsai commited on

with gr.Column(scale=4):
0eff37a

youngtsai commited on

youtube_link_btn.click(
28092cb

youngtsai commited on

print(dict(gr.Request().request.query_params))
e3633b7

youngtsai commited on

print(dict(gr.Request.query_params))
f890e74

youngtsai commited on