Spaces:
Sleeping
Sleeping
print(html_content)
Browse files
app.py
CHANGED
@@ -62,8 +62,11 @@ def process_youtube_link(link):
|
|
62 |
video_id = link.split("=")[-1]
|
63 |
transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=['zh-TW'])
|
64 |
# 基于逐字稿生成其他所需的输出
|
65 |
-
questions =
|
66 |
-
df_summarise =
|
|
|
|
|
|
|
67 |
|
68 |
formatted_transcript = []
|
69 |
for entry in transcript:
|
@@ -79,6 +82,9 @@ def process_youtube_link(link):
|
|
79 |
formatted_transcript.append(line)
|
80 |
|
81 |
html_content = format_transcript_to_html(formatted_transcript)
|
|
|
|
|
|
|
82 |
|
83 |
# 确保返回与 UI 组件预期匹配的输出
|
84 |
return questions[0] if len(questions) > 0 else "", \
|
|
|
62 |
video_id = link.split("=")[-1]
|
63 |
transcript = YouTubeTranscriptApi.get_transcript(video_id, languages=['zh-TW'])
|
64 |
# 基于逐字稿生成其他所需的输出
|
65 |
+
questions = [1,2,3]
|
66 |
+
df_summarise = "..."
|
67 |
+
|
68 |
+
# questions = generate_questions(transcript)
|
69 |
+
# df_summarise = generate_df_summarise(transcript)
|
70 |
|
71 |
formatted_transcript = []
|
72 |
for entry in transcript:
|
|
|
82 |
formatted_transcript.append(line)
|
83 |
|
84 |
html_content = format_transcript_to_html(formatted_transcript)
|
85 |
+
print("=====html_content=====")
|
86 |
+
print(html_content)
|
87 |
+
print("=====html_content=====")
|
88 |
|
89 |
# 确保返回与 UI 组件预期匹配的输出
|
90 |
return questions[0] if len(questions) > 0 else "", \
|