FastAPI wrapper for Faster-Whisper
1.1.0- add v2 router with simple text response
- add asyncio lock for queening requests
- default router are deprecated
1.0.0/transcriberouter
- Python3.8 +
- 1.4GB for docker image
- 500MB+ RAM for docker
-
Set variables. Create
.envfile with variables:MODEL_SIZE="tiny" PORT="8080"
-
Run container Simply use
docker-composefor run containerdocker-compose up -d
-
Wait for some time while whisper model are downloading.
- http://127.0.0.1:8080/v2/transcribe - post audio endpoint
- http://127.0.0.1:8080/transcribe - deprecated - post audio endpoint
- http://127.0.0.1:8080/health - healthcheck endpoint
- http://127.0.0.1:8080/docs - fastapi auto documentation
curl -X 'POST' \
'http://127.0.0.1:8080/v2/transcribe' \
-H 'accept: application/json' \
-H 'Content-Type: multipart/form-data' \
-F 'audio=@voice.ogg;type=video/ogg'"transcribed text"