Spaces:
Sleeping
Sleeping
key_moments_html
Browse files
app.py
CHANGED
@@ -635,7 +635,6 @@ def process_youtube_link(password, link):
|
|
635 |
formatted_transcript_json, \
|
636 |
summary, \
|
637 |
key_moments_html, \
|
638 |
-
key_moments, \
|
639 |
mind_map, \
|
640 |
mind_map_html, \
|
641 |
html_content, \
|
@@ -2001,17 +2000,6 @@ HEAD = """
|
|
2001 |
</script>
|
2002 |
"""
|
2003 |
|
2004 |
-
def update_key_moments_section(key_moments):
|
2005 |
-
blocks = []
|
2006 |
-
for moment in key_moments:
|
2007 |
-
with gr.Row() as row:
|
2008 |
-
with gr.Column(scale=1):
|
2009 |
-
gr.Gallery(images=moment['images'], show_label=False)
|
2010 |
-
with gr.Column(scale=2):
|
2011 |
-
gr.Textbox(value=moment['text'], show_label=False, interactive=False)
|
2012 |
-
blocks.append(row)
|
2013 |
-
return blocks
|
2014 |
-
|
2015 |
with gr.Blocks(theme=gr.themes.Base(primary_hue=gr.themes.colors.orange, secondary_hue=gr.themes.colors.amber, text_size = gr.themes.sizes.text_lg), head=HEAD) as demo:
|
2016 |
with gr.Row() as admin:
|
2017 |
password = gr.Textbox(label="Password", type="password", elem_id="password_input", visible=True)
|
@@ -2100,16 +2088,6 @@ with gr.Blocks(theme=gr.themes.Base(primary_hue=gr.themes.colors.orange, seconda
|
|
2100 |
with gr.Tab("ιι΅ζε»"):
|
2101 |
with gr.Row():
|
2102 |
key_moments_html = gr.HTML(value="")
|
2103 |
-
with gr.Tab("Mind Map"):
|
2104 |
-
key_moments_state = gr.State()
|
2105 |
-
update_key_moments_button = gr.Button("ζ΄ζ°ιι΅ζε»")
|
2106 |
-
key_moments_section = gr.Blocks()
|
2107 |
-
|
2108 |
-
update_key_moments_button.click(
|
2109 |
-
fn=update_key_moments_section,
|
2110 |
-
inputs=[],
|
2111 |
-
outputs=key_moments_section
|
2112 |
-
)
|
2113 |
|
2114 |
with gr.Tab("ζεΈεθͺ²"):
|
2115 |
with gr.Row():
|
@@ -2294,7 +2272,6 @@ with gr.Blocks(theme=gr.themes.Base(primary_hue=gr.themes.colors.orange, seconda
|
|
2294 |
df_string_output,
|
2295 |
df_summarise,
|
2296 |
key_moments_html,
|
2297 |
-
key_moments_state,
|
2298 |
mind_map,
|
2299 |
mind_map_html,
|
2300 |
transcript_html,
|
|
|
635 |
formatted_transcript_json, \
|
636 |
summary, \
|
637 |
key_moments_html, \
|
|
|
638 |
mind_map, \
|
639 |
mind_map_html, \
|
640 |
html_content, \
|
|
|
2000 |
</script>
|
2001 |
"""
|
2002 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2003 |
with gr.Blocks(theme=gr.themes.Base(primary_hue=gr.themes.colors.orange, secondary_hue=gr.themes.colors.amber, text_size = gr.themes.sizes.text_lg), head=HEAD) as demo:
|
2004 |
with gr.Row() as admin:
|
2005 |
password = gr.Textbox(label="Password", type="password", elem_id="password_input", visible=True)
|
|
|
2088 |
with gr.Tab("ιι΅ζε»"):
|
2089 |
with gr.Row():
|
2090 |
key_moments_html = gr.HTML(value="")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2091 |
|
2092 |
with gr.Tab("ζεΈεθͺ²"):
|
2093 |
with gr.Row():
|
|
|
2272 |
df_string_output,
|
2273 |
df_summarise,
|
2274 |
key_moments_html,
|
|
|
2275 |
mind_map,
|
2276 |
mind_map_html,
|
2277 |
transcript_html,
|