Commit ·
4f8f2e4
1
Parent(s): a621d2a
Feat: added state to hold selected quote
Browse files
app.py
CHANGED
|
@@ -90,7 +90,7 @@ with gr.Blocks() as demo:
|
|
| 90 |
rand_btn.click(fn=select_quote,inputs=[],outputs=quote)
|
| 91 |
|
| 92 |
with gr.Row():
|
| 93 |
-
|
| 94 |
|
| 95 |
out_1 = gr.HighlightedText(
|
| 96 |
label="WhisperDiff",
|
|
@@ -106,6 +106,6 @@ with gr.Blocks() as demo:
|
|
| 106 |
color_map={"+": "green", "-": "blue"}
|
| 107 |
)
|
| 108 |
btn = gr.Button("Run")
|
| 109 |
-
btn.click(fn=transcribe, inputs=
|
| 110 |
|
| 111 |
demo.launch()
|
|
|
|
| 90 |
rand_btn.click(fn=select_quote,inputs=[],outputs=quote)
|
| 91 |
|
| 92 |
with gr.Row():
|
| 93 |
+
mf_input = gr.Audio(sources='microphone',type="filepath"),
|
| 94 |
|
| 95 |
out_1 = gr.HighlightedText(
|
| 96 |
label="WhisperDiff",
|
|
|
|
| 106 |
color_map={"+": "green", "-": "blue"}
|
| 107 |
)
|
| 108 |
btn = gr.Button("Run")
|
| 109 |
+
btn.click(fn=transcribe, inputs=[mf_input,selected_quote], outputs=[out_1, out_2])
|
| 110 |
|
| 111 |
demo.launch()
|