https://github.com/d-ashesss/whisper-service
gRPC service for self-hosted OpenAI Whisper ASR.
https://github.com/d-ashesss/whisper-service
asr grpc openai service whisper
Last synced: 3 months ago
JSON representation
gRPC service for self-hosted OpenAI Whisper ASR.
- Host: GitHub
- URL: https://github.com/d-ashesss/whisper-service
- Owner: d-ashesss
- License: mit
- Created: 2023-05-31T19:00:58.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-16T22:23:51.000Z (about 3 years ago)
- Last Synced: 2025-05-22T01:37:46.597Z (about 1 year ago)
- Topics: asr, grpc, openai, service, whisper
- Language: Go
- Homepage:
- Size: 21.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Whisper Service
[](https://github.com/d-ashesss/whisper-service/actions)
[](https://goreportcard.com/report/github.com/d-ashesss/whisper-service)
[](https://opensource.org/licenses/MIT)
[](https://github.com/d-ashesss/whisper-service/blob/main/go.mod)
[](https://github.com/d-ashesss/whisper-service/tags)
[](https://github.com/d-ashesss/whisper-service)
gRPC service for a self-hosted [openai/whisper](https://github.com/openai/whisper).
## Running with Docker
To get and run the service from Docker Hub:
```shell
docker pull ashesss/openai-whisper-service:latest
docker run -p 8080:8080 ashesss/openai-whisper-service:latest
```
### GPU
To utilize the GPU for the service, first make sure that nvidia plugin for docker is installed then start ther container with GPU support:
```shell
docker run -p 8080:8080 --gpus all ashesss/openai-whisper-service:latest
```
### Model Cache
ASR models will be downloaded for each new container, if you want to cache them on persistent volume, mount it as follows:
```shell
docker run -p 8080:8080 -v /path/to/cached/models:/root/.cache/whisper ashesss/openai-whisper-service:latest
```
## Basic Usage
With Go you can simply import client from this repo:
```go
import whisperpb "github.com/d-ashesss/whisper-service/proto"
func main() {
conn, _ := grpc.Dial("localhost:8080", grpc.WithTransportCredentials(insecure.NewCredentials()))
c := whisperpb.NewWhisperServiceClient(conn)
stream, err := c.Transcribe(context.Background())
...
}
```
For other languages use [whisper.proto](https://github.com/d-ashesss/whisper-service/blob/main/proto/whisper.proto) file to generate gRPC client.