Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -32,14 +32,13 @@ except Exception as e:
|
|
32 |
print("Continuing with limited functionality...")
|
33 |
|
34 |
# ----------------------- Global Variables ----------------------- #
|
35 |
-
# VOICE_CHOICES ์ ์ (TTS๊ฐ ์ด๊ธฐํ๋์ง ์๋๋ผ๋ ๊ธฐ๋ณธ๊ฐ ์ ๊ณต)
|
36 |
VOICE_CHOICES = {
|
37 |
'๐บ๐ธ Female (Default)': 'af',
|
38 |
'๐บ๐ธ Bella': 'af_bella',
|
39 |
'๐บ๐ธ Sarah': 'af_sarah',
|
40 |
'๐บ๐ธ Nicole': 'af_nicole'
|
41 |
}
|
42 |
-
TTS_ENABLED = False #
|
43 |
|
44 |
# ----------------------- Model and Tokenizer Initialization ----------------------- #
|
45 |
model_name = "deepseek-ai/DeepSeek-R1-Distill-Llama-8B"
|
@@ -393,6 +392,7 @@ css = """
|
|
393 |
color: #ffffff !important;
|
394 |
border: 1px solid #555555 !important;
|
395 |
}
|
|
|
396 |
footer {
|
397 |
text-align: center;
|
398 |
padding: 1rem 0;
|
@@ -405,7 +405,8 @@ footer {
|
|
405 |
with gr.Blocks(title="AI Search Assistant", css=css) as demo:
|
406 |
chat_history = gr.State([])
|
407 |
|
408 |
-
|
|
|
409 |
gr.Markdown("# ๐ AI Search Assistant")
|
410 |
gr.Markdown("### Powered by DeepSeek & Real-time Web Results with Voice")
|
411 |
|
@@ -430,7 +431,7 @@ with gr.Blocks(title="AI Search Assistant", css=css) as demo:
|
|
430 |
with gr.Column(elem_classes="answer-box"):
|
431 |
answer_output = gr.Markdown()
|
432 |
audio_output = gr.Audio(label="Voice Response")
|
433 |
-
with gr.Accordion("Chat History", open=False):
|
434 |
chat_history_display = gr.Chatbot(elem_classes="chat-history")
|
435 |
with gr.Column(scale=1):
|
436 |
with gr.Column():
|
|
|
32 |
print("Continuing with limited functionality...")
|
33 |
|
34 |
# ----------------------- Global Variables ----------------------- #
|
|
|
35 |
VOICE_CHOICES = {
|
36 |
'๐บ๐ธ Female (Default)': 'af',
|
37 |
'๐บ๐ธ Bella': 'af_bella',
|
38 |
'๐บ๐ธ Sarah': 'af_sarah',
|
39 |
'๐บ๐ธ Nicole': 'af_nicole'
|
40 |
}
|
41 |
+
TTS_ENABLED = False # ๊ธฐ๋ณธ์ ์ผ๋ก TTS ๋ชจ๋ ์ด๊ธฐํ ์คํจ ์ ๋นํ์ฑํ
|
42 |
|
43 |
# ----------------------- Model and Tokenizer Initialization ----------------------- #
|
44 |
model_name = "deepseek-ai/DeepSeek-R1-Distill-Llama-8B"
|
|
|
392 |
color: #ffffff !important;
|
393 |
border: 1px solid #555555 !important;
|
394 |
}
|
395 |
+
|
396 |
footer {
|
397 |
text-align: center;
|
398 |
padding: 1rem 0;
|
|
|
405 |
with gr.Blocks(title="AI Search Assistant", css=css) as demo:
|
406 |
chat_history = gr.State([])
|
407 |
|
408 |
+
# 'id' ์ธ์ ๋์ 'elem_id' ์ฌ์ฉ
|
409 |
+
with gr.Column(elem_id="header"):
|
410 |
gr.Markdown("# ๐ AI Search Assistant")
|
411 |
gr.Markdown("### Powered by DeepSeek & Real-time Web Results with Voice")
|
412 |
|
|
|
431 |
with gr.Column(elem_classes="answer-box"):
|
432 |
answer_output = gr.Markdown()
|
433 |
audio_output = gr.Audio(label="Voice Response")
|
434 |
+
with gr.Accordion("Chat History", open=False, elem_classes="accordion"):
|
435 |
chat_history_display = gr.Chatbot(elem_classes="chat-history")
|
436 |
with gr.Column(scale=1):
|
437 |
with gr.Column():
|