Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,8 +10,10 @@ from audio import analyze_audio # 从 audio.py 导入
|
|
| 10 |
|
| 11 |
|
| 12 |
def process_input(file, text, selected_lang):
|
| 13 |
-
print("[DEBUG]
|
| 14 |
-
print("[DEBUG]
|
|
|
|
|
|
|
| 15 |
|
| 16 |
# 输入优先级: 文件 > 文本
|
| 17 |
if file:
|
|
@@ -92,6 +94,7 @@ with gr.Blocks(theme=gr.themes.Default(spacing_size="sm")) as app:
|
|
| 92 |
inputs=[file_input, text_input, lang_dropdown], # ✅ 必须包含 lang_dropdown
|
| 93 |
outputs=output,
|
| 94 |
api_name="analyze"
|
|
|
|
| 95 |
)
|
| 96 |
|
| 97 |
|
|
|
|
| 10 |
|
| 11 |
|
| 12 |
def process_input(file, text, selected_lang):
|
| 13 |
+
print("[DEBUG] 🟢 Analyze 按钮被点击")
|
| 14 |
+
print(f"[DEBUG] file: {file}")
|
| 15 |
+
print(f"[DEBUG] text: {text[:50]}")
|
| 16 |
+
print(f"[DEBUG] lang: {selected_lang}")
|
| 17 |
|
| 18 |
# 输入优先级: 文件 > 文本
|
| 19 |
if file:
|
|
|
|
| 94 |
inputs=[file_input, text_input, lang_dropdown], # ✅ 必须包含 lang_dropdown
|
| 95 |
outputs=output,
|
| 96 |
api_name="analyze"
|
| 97 |
+
show_progress="full"
|
| 98 |
)
|
| 99 |
|
| 100 |
|