How to take Text Input from a user

Hi @thiago and Developers’ Team of Streamlit,

I just came across your amazing tool and was looking forward to build a small ASR app with huggingface transformers model. What I need is to enter the path to the mp3 or wav file on the local drive and use it afterwards. However, st.text_input doesn’t seem to work, the model reads only the first character and says the file doesn’t exist.

Here’s my code I need to implement:

from asrecognition import ASREngine
import streamlit as st

st.header("Trascribe your Audio")

filePath = st.text_input(label = "Please enter the path to the file" )

asr = ASREngine("ru", model_path="jonatasgrosman/wav2vec2-large-xlsr-53-russian")

transcriptions = asr.transcribe(filePath)

st.write(result.get("transcription"))

Here’s the error I get: