Spaces:
Sleeping
Sleeping
Merge branch 'main' of https://huggingface.co/spaces/EntrepreneurFirst/FitnessEquation
Browse files- Modules/Speech2Text/transcribe.py +6 -0
- requirements.txt +2 -0
Modules/Speech2Text/transcribe.py
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import whisper
|
2 |
+
|
3 |
+
def transcribe(audio_path):
|
4 |
+
model = whisper.load_model("base")
|
5 |
+
result = model.transcribe(audio_path)
|
6 |
+
return result.text
|
requirements.txt
CHANGED
@@ -4,3 +4,5 @@ langchain-core
|
|
4 |
langchain-mistralai
|
5 |
pandas
|
6 |
langchain-community
|
|
|
|
|
|
4 |
langchain-mistralai
|
5 |
pandas
|
6 |
langchain-community
|
7 |
+
st_audiorec
|
8 |
+
openai-whisper
|