26 lines
511 B
Markdown
26 lines
511 B
Markdown
# Vosk Speech-to-Text Docker Service
|
|
|
|
## Setup
|
|
|
|
1. Download and extract a Vosk model (already downloading `vosk-model-small-en-us-0.15.zip`):
|
|
|
|
```sh
|
|
unzip model.zip -d model
|
|
mv model/* model/
|
|
```
|
|
|
|
2. Build the Docker image:
|
|
|
|
```sh
|
|
docker build -t vosk-api .
|
|
```
|
|
|
|
3. Run the Docker container (mounting the model directory):
|
|
|
|
```sh
|
|
docker run -p 5000:5000 -v $(pwd)/model:/app/model vosk-api
|
|
```
|
|
|
|
## API Usage
|
|
|
|
POST `/transcribe` with form-data key `audio` (WAV/FLAC/OGG file). Returns JSON with `transcription`. |