Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import streamlit as st
|
2 |
from transformers import pipeline
|
|
|
3 |
|
4 |
pipe=pipeline(model="vennify/t5-base-grammar-correction")
|
5 |
st.title("Grammatical Error Checker")
|
@@ -7,4 +8,8 @@ text=st.text_area('Enter some text:')
|
|
7 |
|
8 |
if text:
|
9 |
out=pipe(text)
|
10 |
-
st.json(out)
|
|
|
|
|
|
|
|
|
|
1 |
import streamlit as st
|
2 |
from transformers import pipeline
|
3 |
+
from audio_recorder_streamlit import audio_recorder
|
4 |
|
5 |
pipe=pipeline(model="vennify/t5-base-grammar-correction")
|
6 |
st.title("Grammatical Error Checker")
|
|
|
8 |
|
9 |
if text:
|
10 |
out=pipe(text)
|
11 |
+
st.json(out)
|
12 |
+
|
13 |
+
audio_bytes = audio_recorder(pause_threshold=2.0, sample_rate=41_000, recording_color="#e8b62c", neutral_color="#6aa36f", icon_name="user", icon_size="6x")
|
14 |
+
if audio_bytes:
|
15 |
+
st.audio(audio_bytes, format="audio/wav")
|