Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -7,66 +7,74 @@ import openai
|
|
| 7 |
import os
|
| 8 |
import random
|
| 9 |
import re
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
# nltk λ°μ΄ν° λ€μ΄λ‘λ (μ΅μ΄ ν λ² μ€ν)
|
| 17 |
-
nltk.download('punkt')
|
| 18 |
-
|
| 19 |
-
# λ‘κΉ
μ€μ
|
| 20 |
-
logging.basicConfig(
|
| 21 |
-
filename='youtube_script_extractor.log',
|
| 22 |
-
level=logging.DEBUG,
|
| 23 |
-
format='%(asctime)s - %(levelname)s - %(message)s'
|
| 24 |
-
)
|
| 25 |
|
| 26 |
def parse_api_response(response):
|
| 27 |
try:
|
| 28 |
if isinstance(response, str):
|
| 29 |
-
response =
|
|
|
|
|
|
|
| 30 |
if not isinstance(response, dict):
|
| 31 |
raise ValueError(f"μμμΉ λͺ»ν μλ΅ νμμ
λλ€. λ°μ λ°μ΄ν° νμ
: {type(response)}")
|
| 32 |
return response
|
| 33 |
except Exception as e:
|
| 34 |
raise ValueError(f"API μλ΅ νμ± μ€ν¨: {str(e)}")
|
| 35 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 36 |
def get_youtube_script(url):
|
| 37 |
logging.info(f"μ€ν¬λ¦½νΈ μΆμΆ μμ: URL = {url}")
|
|
|
|
| 38 |
client = Client("whispersound/YT_Ts_R")
|
|
|
|
| 39 |
try:
|
| 40 |
logging.debug("API νΈμΆ μμ")
|
| 41 |
result = client.predict(youtube_url=url, api_name="/predict")
|
| 42 |
logging.debug("API νΈμΆ μλ£")
|
|
|
|
| 43 |
parsed_result = parse_api_response(result)
|
|
|
|
|
|
|
|
|
|
| 44 |
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
raise ValueError("λ°μ΄ν°λ₯Ό κ°μ Έμ¬ μ μμ΅λλ€.")
|
| 49 |
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
title = data.get("title", "")
|
| 53 |
-
transcription = data.get("transcription", [])
|
| 54 |
-
transcription_as_text = data.get("transcriptionAsText", "")
|
| 55 |
|
| 56 |
logging.info("μ€ν¬λ¦½νΈ μΆμΆ μλ£")
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
"transcription": transcription,
|
| 60 |
-
"transcriptionAsText": transcription_as_text
|
| 61 |
-
})
|
| 62 |
-
return title, script_json
|
| 63 |
except Exception as e:
|
| 64 |
error_msg = f"μ€ν¬λ¦½νΈ μΆμΆ μ€ μ€λ₯ λ°μ: {str(e)}"
|
| 65 |
logging.exception(error_msg)
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
# OpenAI API ν€ μ€μ
|
| 69 |
-
openai.api_key = os.getenv("OPENAI_API_KEY")
|
| 70 |
|
| 71 |
def call_api(prompt, max_tokens, temperature, top_p):
|
| 72 |
try:
|
|
@@ -80,126 +88,146 @@ def call_api(prompt, max_tokens, temperature, top_p):
|
|
| 80 |
return response['choices'][0]['message']['content']
|
| 81 |
except Exception as e:
|
| 82 |
logging.exception("LLM API νΈμΆ μ€ μ€λ₯ λ°μ")
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
def extract_video_id(url):
|
| 86 |
-
parsed_url = urllib.parse.urlparse(url)
|
| 87 |
-
if parsed_url.hostname in ('www.youtube.com', 'youtube.com'):
|
| 88 |
-
query_params = urllib.parse.parse_qs(parsed_url.query)
|
| 89 |
-
return query_params.get('v', [None])[0]
|
| 90 |
-
elif parsed_url.hostname == 'youtu.be':
|
| 91 |
-
return parsed_url.path[1:]
|
| 92 |
-
else:
|
| 93 |
-
return None
|
| 94 |
|
| 95 |
def summarize_section(section_text):
|
| 96 |
-
prompt = f"""
|
|
|
|
|
|
|
|
|
|
|
|
|
| 97 |
|
|
|
|
| 98 |
{section_text}
|
| 99 |
-
|
| 100 |
-
μμ½μ νκ΅μ΄λ‘ κ°κ²°νκ² μμ±ν΄ μ£ΌμΈμ.
|
| 101 |
"""
|
| 102 |
-
return call_api(prompt, max_tokens=
|
| 103 |
-
|
| 104 |
-
def
|
| 105 |
-
|
| 106 |
-
|
| 107 |
-
|
| 108 |
-
|
| 109 |
-
|
| 110 |
-
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
| 114 |
-
|
| 115 |
-
|
| 116 |
-
|
| 117 |
-
|
| 118 |
-
|
| 119 |
-
|
| 120 |
-
|
| 121 |
-
|
| 122 |
-
|
| 123 |
-
|
| 124 |
-
|
| 125 |
-
|
| 126 |
-
|
| 127 |
-
|
| 128 |
-
|
| 129 |
-
|
| 130 |
-
|
| 131 |
-
|
| 132 |
-
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
|
| 136 |
-
|
| 137 |
-
|
| 138 |
-
|
| 139 |
-
|
| 140 |
-
|
| 141 |
-
|
| 142 |
-
|
| 143 |
-
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
|
| 147 |
-
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
return
|
| 159 |
|
| 160 |
with gr.Blocks() as demo:
|
| 161 |
gr.Markdown("## YouTube μ€ν¬λ¦½νΈ μΆμΆ λ° μμ½ λꡬ")
|
|
|
|
| 162 |
youtube_url_input = gr.Textbox(label="YouTube URL μ
λ ₯")
|
| 163 |
analyze_button = gr.Button("λΆμνκΈ°")
|
| 164 |
script_output = gr.HTML(label="μ€ν¬λ¦½νΈ")
|
| 165 |
-
|
| 166 |
-
|
|
|
|
|
|
|
| 167 |
|
| 168 |
def extract_and_cache(url, cache):
|
| 169 |
-
if url == cache
|
| 170 |
-
return cache["title"], cache
|
| 171 |
-
|
| 172 |
-
|
| 173 |
-
|
| 174 |
-
|
| 175 |
-
|
| 176 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 177 |
return script_html
|
| 178 |
|
| 179 |
-
def
|
| 180 |
-
|
| 181 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 182 |
try:
|
| 183 |
-
|
| 184 |
-
|
| 185 |
-
|
| 186 |
-
|
| 187 |
-
|
| 188 |
-
|
| 189 |
-
|
| 190 |
-
return generate_summary(sections, cache["url"])
|
| 191 |
except Exception as e:
|
| 192 |
-
|
| 193 |
-
|
|
|
|
| 194 |
|
| 195 |
analyze_button.click(
|
| 196 |
-
|
| 197 |
-
inputs=[youtube_url_input, cached_data],
|
| 198 |
-
outputs=[script_output, cached_data]
|
| 199 |
-
).then(
|
| 200 |
-
update_summary,
|
| 201 |
-
inputs=cached_data,
|
| 202 |
-
outputs=summary_output
|
| 203 |
)
|
| 204 |
|
| 205 |
-
demo.launch(share=True)
|
|
|
|
| 7 |
import os
|
| 8 |
import random
|
| 9 |
import re
|
| 10 |
+
|
| 11 |
+
logging.basicConfig(filename='youtube_script_extractor.log', level=logging.DEBUG,
|
| 12 |
+
format='%(asctime)s - %(levelname)s - %(message)s')
|
| 13 |
+
|
| 14 |
+
openai.api_key = os.getenv("OPENAI_API_KEY")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15 |
|
| 16 |
def parse_api_response(response):
|
| 17 |
try:
|
| 18 |
if isinstance(response, str):
|
| 19 |
+
response = json.loads(response)
|
| 20 |
+
if isinstance(response, list) and len(response) > 0:
|
| 21 |
+
response = response[0]
|
| 22 |
if not isinstance(response, dict):
|
| 23 |
raise ValueError(f"μμμΉ λͺ»ν μλ΅ νμμ
λλ€. λ°μ λ°μ΄ν° νμ
: {type(response)}")
|
| 24 |
return response
|
| 25 |
except Exception as e:
|
| 26 |
raise ValueError(f"API μλ΅ νμ± μ€ν¨: {str(e)}")
|
| 27 |
|
| 28 |
+
def split_sentences(text):
|
| 29 |
+
sentences = re.split(r"(λλ€|μμ|ꡬλ|ν΄μ|κ΅°μ|κ² μ΄μ|μμ€|ν΄λΌ|μμ|μμ|λ°μ|λμ|μΈμ|μ΄μ|κ²μ|ꡬμ|κ³ μ|λμ|νμ£ )(?![\w])", text)
|
| 30 |
+
combined_sentences = []
|
| 31 |
+
current_sentence = ""
|
| 32 |
+
for i in range(0, len(sentences), 2):
|
| 33 |
+
if i + 1 < len(sentences):
|
| 34 |
+
sentence = sentences[i] + sentences[i + 1]
|
| 35 |
+
else:
|
| 36 |
+
sentence = sentences[i]
|
| 37 |
+
if len(current_sentence) + len(sentence) > 100:
|
| 38 |
+
combined_sentences.append(current_sentence.strip())
|
| 39 |
+
current_sentence = sentence.strip()
|
| 40 |
+
else:
|
| 41 |
+
current_sentence += sentence
|
| 42 |
+
if sentence.endswith(('.', '?', '!')):
|
| 43 |
+
combined_sentences.append(current_sentence.strip())
|
| 44 |
+
current_sentence = ""
|
| 45 |
+
if current_sentence:
|
| 46 |
+
combined_sentences.append(current_sentence.strip())
|
| 47 |
+
return combined_sentences
|
| 48 |
+
|
| 49 |
def get_youtube_script(url):
|
| 50 |
logging.info(f"μ€ν¬λ¦½νΈ μΆμΆ μμ: URL = {url}")
|
| 51 |
+
|
| 52 |
client = Client("whispersound/YT_Ts_R")
|
| 53 |
+
|
| 54 |
try:
|
| 55 |
logging.debug("API νΈμΆ μμ")
|
| 56 |
result = client.predict(youtube_url=url, api_name="/predict")
|
| 57 |
logging.debug("API νΈμΆ μλ£")
|
| 58 |
+
|
| 59 |
parsed_result = parse_api_response(result)
|
| 60 |
+
|
| 61 |
+
if 'data' not in parsed_result or not parsed_result['data']:
|
| 62 |
+
raise ValueError("API μλ΅μ μ ν¨ν λ°μ΄ν°κ° μμ΅λλ€.")
|
| 63 |
|
| 64 |
+
title = parsed_result["data"][0].get("title", "μ λͺ© μμ")
|
| 65 |
+
transcription_text = parsed_result["data"][0].get("transcriptionAsText", "")
|
| 66 |
+
sections = parsed_result["data"][0].get("sections", [])
|
|
|
|
| 67 |
|
| 68 |
+
if not transcription_text:
|
| 69 |
+
raise ValueError("μΆμΆλ μ€ν¬λ¦½νΈκ° μμ΅λλ€.")
|
|
|
|
|
|
|
|
|
|
| 70 |
|
| 71 |
logging.info("μ€ν¬λ¦½νΈ μΆμΆ μλ£")
|
| 72 |
+
return title, transcription_text, sections
|
| 73 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
| 74 |
except Exception as e:
|
| 75 |
error_msg = f"μ€ν¬λ¦½νΈ μΆμΆ μ€ μ€λ₯ λ°μ: {str(e)}"
|
| 76 |
logging.exception(error_msg)
|
| 77 |
+
raise
|
|
|
|
|
|
|
|
|
|
| 78 |
|
| 79 |
def call_api(prompt, max_tokens, temperature, top_p):
|
| 80 |
try:
|
|
|
|
| 88 |
return response['choices'][0]['message']['content']
|
| 89 |
except Exception as e:
|
| 90 |
logging.exception("LLM API νΈμΆ μ€ μ€λ₯ λ°μ")
|
| 91 |
+
raise
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 92 |
|
| 93 |
def summarize_section(section_text):
|
| 94 |
+
prompt = f"""
|
| 95 |
+
λ€μ μ νλΈ λλ³Έ μΉμ
μ ν΅μ¬ λ΄μ©μ κ°κ²°νκ² μμ½νμΈμ:
|
| 96 |
+
1. νκΈλ‘ μμ±νμΈμ.
|
| 97 |
+
2. μ£Όμ λ
Όμ κ³Ό μ€μν μΈλΆμ¬νμ ν¬ν¨νμΈμ.
|
| 98 |
+
3. μμ½μ 2-3λ¬Έμ₯μΌλ‘ μ ννμΈμ.
|
| 99 |
|
| 100 |
+
μΉμ
λ΄μ©:
|
| 101 |
{section_text}
|
|
|
|
|
|
|
| 102 |
"""
|
| 103 |
+
return call_api(prompt, max_tokens=150, temperature=0.3, top_p=0.9)
|
| 104 |
+
|
| 105 |
+
def format_time(seconds):
|
| 106 |
+
minutes, seconds = divmod(seconds, 60)
|
| 107 |
+
hours, minutes = divmod(minutes, 60)
|
| 108 |
+
return f"{int(hours):02d}:{int(minutes):02d}:{int(seconds):02d}"
|
| 109 |
+
|
| 110 |
+
def generate_timeline_summary(sections):
|
| 111 |
+
combined_sections = "\n\n".join([f"{format_time(section['start_time'])}: {section['text']}" for section in sections])
|
| 112 |
+
|
| 113 |
+
prompt = f"""
|
| 114 |
+
λ€μμ μ νλΈ μμμ νμλΌμΈκ³Ό κ° μΉμ
μ λ΄μ©μ
λλ€. μ΄λ₯Ό λ°νμΌλ‘ νμλΌμΈ μμ½μ μμ±ν΄μ£ΌμΈμ:
|
| 115 |
+
|
| 116 |
+
1. κ° μΉμ
μ μμ μκ°μ μ μ§νλ©΄μ ν΅μ¬ λ΄μ©μ κ°κ²°νκ² μμ½νμΈμ.
|
| 117 |
+
2. μμ½μ νκΈλ‘ μμ±νμΈμ.
|
| 118 |
+
3. κ° μΉμ
μ μμ½μ 1-2λ¬Έμ₯μΌλ‘ μ ννμΈμ.
|
| 119 |
+
4. μ 체 λ§₯λ½μ κ³ λ €νμ¬ μμ½νλ, κ° μΉμ
μ κ³ μ ν λ΄μ©μ λμΉμ§ λ§μΈμ.
|
| 120 |
+
5. μΆλ ₯ νμμ λ€μκ³Ό κ°μ΄ μ μ§νμΈμ:
|
| 121 |
+
[μμ μκ°] μΉμ
μμ½
|
| 122 |
+
|
| 123 |
+
μΉμ
λ΄μ©:
|
| 124 |
+
{combined_sections}
|
| 125 |
+
"""
|
| 126 |
+
|
| 127 |
+
response = call_api(prompt, max_tokens=1000, temperature=0.3, top_p=0.9)
|
| 128 |
+
|
| 129 |
+
# μλ΅μ μ€ λ¨μλ‘ λΆλ¦¬νκ³ κ° μ€μ HTML νμμΌλ‘ λ³ν
|
| 130 |
+
timeline_html = "<br>".join(response.split('\n'))
|
| 131 |
+
|
| 132 |
+
return f"""
|
| 133 |
+
<h3>νμλΌμΈ μμ½:</h3>
|
| 134 |
+
<div style="white-space: pre-wrap; max-height: 400px; overflow-y: auto; border: 1px solid #ccc; padding: 10px;">
|
| 135 |
+
{timeline_html}
|
| 136 |
+
</div>
|
| 137 |
+
"""
|
| 138 |
+
|
| 139 |
+
def summarize_text(text):
|
| 140 |
+
prompt = f"""
|
| 141 |
+
1. λ€μ μ£Όμ΄μ§λ μ νλΈ λλ³Έμ ν΅μ¬ μ£Όμ μ λͺ¨λ μ£Όμ λ΄μ©μ μμΈνκ² μμ½νλΌ
|
| 142 |
+
2. λ°λμ νκΈλ‘ μμ±νλΌ
|
| 143 |
+
3. μμ½λ¬Έλ§μΌλ‘λ μμμ μ§μ μμ²ν κ²κ³Ό λμΌν μμ€μΌλ‘ λ΄μ©μ μ΄ν΄ν μ μλλ‘ μμΈν μμ±
|
| 144 |
+
4. κΈμ λ무 μμΆνκ±°λ ν¨μΆνμ§ λ§κ³ , μ€μν λ΄μ©κ³Ό μΈλΆμ¬νμ λͺ¨λ ν¬ν¨
|
| 145 |
+
5. λ°λμ λλ³Έμ νλ¦κ³Ό λ
Όλ¦¬ ꡬ쑰λ₯Ό μ μ§
|
| 146 |
+
6. λ°λμ μκ° μμλ μ¬κ±΄μ μ κ° κ³Όμ μ λͺ
ννκ² λ°μ
|
| 147 |
+
7. λ±μ₯μΈλ¬Ό, μ₯μ, μ¬κ±΄ λ± μ€μν μμλ₯Ό μ ννκ² μμ±
|
| 148 |
+
8. λλ³Έμμ μ λ¬νλ κ°μ μ΄λ λΆμκΈ°λ ν¬ν¨
|
| 149 |
+
9. λ°λμ κΈ°μ μ μ©μ΄λ μ λ¬Έ μ©μ΄κ° μμ κ²½μ°, μ΄λ₯Ό μ ννκ² μ¬μ©
|
| 150 |
+
10. λλ³Έμ λͺ©μ μ΄λ μλλ₯Ό νμ
νκ³ , μ΄λ₯Ό μμ½μ λ°λμ λ°μ
|
| 151 |
+
11. μ 체κΈμ 보κ³
|
| 152 |
+
|
| 153 |
+
---
|
| 154 |
+
|
| 155 |
+
μ΄ ν둬ννΈκ° λμμ΄ λμκΈΈ λ°λλλ€.
|
| 156 |
+
\n\n
|
| 157 |
+
{text}"""
|
| 158 |
+
|
| 159 |
+
return call_api(prompt, max_tokens=10000, temperature=0.3, top_p=0.9)
|
| 160 |
|
| 161 |
with gr.Blocks() as demo:
|
| 162 |
gr.Markdown("## YouTube μ€ν¬λ¦½νΈ μΆμΆ λ° μμ½ λꡬ")
|
| 163 |
+
|
| 164 |
youtube_url_input = gr.Textbox(label="YouTube URL μ
λ ₯")
|
| 165 |
analyze_button = gr.Button("λΆμνκΈ°")
|
| 166 |
script_output = gr.HTML(label="μ€ν¬λ¦½νΈ")
|
| 167 |
+
timeline_output = gr.HTML(label="νμλΌμΈ μμ½")
|
| 168 |
+
summary_output = gr.HTML(label="μ 체 μμ½")
|
| 169 |
+
|
| 170 |
+
cached_data = gr.State({"url": "", "title": "", "script": "", "sections": []})
|
| 171 |
|
| 172 |
def extract_and_cache(url, cache):
|
| 173 |
+
if url == cache["url"]:
|
| 174 |
+
return cache["title"], cache["script"], cache["sections"], cache
|
| 175 |
+
|
| 176 |
+
try:
|
| 177 |
+
title, script, sections = get_youtube_script(url)
|
| 178 |
+
new_cache = {"url": url, "title": title, "script": script, "sections": sections}
|
| 179 |
+
return title, script, sections, new_cache
|
| 180 |
+
except Exception as e:
|
| 181 |
+
logging.exception("λ°μ΄ν° μΆμΆ μ€ μ€λ₯ λ°μ")
|
| 182 |
+
raise gr.Error(f"μ€ν¬λ¦½νΈ μΆμΆ μ€ν¨: {str(e)}")
|
| 183 |
+
|
| 184 |
+
def display_script(title, script):
|
| 185 |
+
formatted_script = "\n".join(split_sentences(script))
|
| 186 |
+
script_html = f"""<h2 style='font-size:24px;'>{title}</h2>
|
| 187 |
+
<details>
|
| 188 |
+
<summary><h3>μλ¬Έ μ€ν¬λ¦½νΈ (ν΄λ¦νμ¬ νΌμΉκΈ°)</h3></summary>
|
| 189 |
+
<div style="white-space: pre-wrap;">{formatted_script}</div>
|
| 190 |
+
</details>"""
|
| 191 |
return script_html
|
| 192 |
|
| 193 |
+
def display_timeline(sections):
|
| 194 |
+
timeline_summary = generate_timeline_summary(sections)
|
| 195 |
+
timeline_html = f"""
|
| 196 |
+
<h3>νμλΌμΈ μμ½:</h3>
|
| 197 |
+
<div style="white-space: pre-wrap; max-height: 400px; overflow-y: auto; border: 1px solid #ccc; padding: 10px;">
|
| 198 |
+
{timeline_summary}
|
| 199 |
+
</div>
|
| 200 |
+
"""
|
| 201 |
+
return timeline_html
|
| 202 |
+
|
| 203 |
+
def generate_summary(script):
|
| 204 |
+
summary = summarize_text(script)
|
| 205 |
+
summary_html = f"""
|
| 206 |
+
<h3>μ 체 μμ½:</h3>
|
| 207 |
+
<div style="white-space: pre-wrap; max-height: 400px; overflow-y: auto; border: 1px solid #ccc; padding: 10px;">
|
| 208 |
+
{summary}
|
| 209 |
+
</div>
|
| 210 |
+
"""
|
| 211 |
+
return summary_html
|
| 212 |
+
|
| 213 |
+
def analyze(url, cache):
|
| 214 |
try:
|
| 215 |
+
title, script, sections, new_cache = extract_and_cache(url, cache)
|
| 216 |
+
script_html = display_script(title, script)
|
| 217 |
+
timeline_html = generate_timeline_summary(sections)
|
| 218 |
+
summary_html = generate_summary(script)
|
| 219 |
+
return script_html, timeline_html, summary_html, new_cache
|
| 220 |
+
except gr.Error as e:
|
| 221 |
+
return str(e), "", "", cache
|
|
|
|
| 222 |
except Exception as e:
|
| 223 |
+
error_msg = f"μ²λ¦¬ μ€ μ€λ₯ λ°μ: {str(e)}"
|
| 224 |
+
logging.exception(error_msg)
|
| 225 |
+
return error_msg, "", "", cache
|
| 226 |
|
| 227 |
analyze_button.click(
|
| 228 |
+
analyze,
|
| 229 |
+
inputs=[youtube_url_input, cached_data],
|
| 230 |
+
outputs=[script_output, timeline_output, summary_output, cached_data]
|
|
|
|
|
|
|
|
|
|
|
|
|
| 231 |
)
|
| 232 |
|
| 233 |
+
demo.launch(share=True)
|