Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -65,27 +65,17 @@ def generate_stream(prompt):
|
|
65 |
|
66 |
with gr.Blocks() as demo:
|
67 |
gr.Markdown("## 🧠 OpenVINO Streaming Demo with Gradio Textbox")
|
68 |
-
|
69 |
with gr.Row():
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
with gr.Column(scale=3):
|
81 |
-
with gr.Row():
|
82 |
-
with gr.Column(scale=1):
|
83 |
-
start_btn = gr.Button("開始對話")
|
84 |
-
end_btn = gr.Button("結束對話")
|
85 |
-
#with gr.Column(scale=3):
|
86 |
-
status_box = gr.Textbox(label="狀態", interactive=False)
|
87 |
-
TPS_box = gr.Textbox(label="TPS", interactive=False)
|
88 |
-
textbox_output = gr.Markdown(label="robot answer:", elem_id="scroll_output")
|
89 |
|
90 |
start_btn.click(fn=start_chat, outputs=status_box)
|
91 |
end_btn.click(fn=finish_chat, outputs=status_box)
|
|
|
65 |
|
66 |
with gr.Blocks() as demo:
|
67 |
gr.Markdown("## 🧠 OpenVINO Streaming Demo with Gradio Textbox")
|
|
|
68 |
with gr.Row():
|
69 |
+
with gr.Column():
|
70 |
+
start_btn = gr.Button("開始對話")
|
71 |
+
end_btn = gr.Button("結束對話")
|
72 |
+
status_box = gr.Textbox(label="狀態", interactive=False)
|
73 |
+
PS_box = gr.Textbox(label="TPS", interactive=False)
|
74 |
+
with gr.Row():
|
75 |
+
textbox_input = gr.Textbox(label="Prompt", lines=1, placeholder="Enter prompt here...")
|
76 |
+
button = gr.Button("Submit")
|
77 |
+
|
78 |
+
textbox_output = gr.Markdown(label="robot answer:", elem_id="scroll_output")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
79 |
|
80 |
start_btn.click(fn=start_chat, outputs=status_box)
|
81 |
end_btn.click(fn=finish_chat, outputs=status_box)
|