add a simple python fastapi server to serve whisper models for speech-to-text and piper for text-to-speech

This commit is contained in:
milan
2026-04-08 23:54:48 +02:00
parent 1895e1ec66
commit 5def79b4ca
13 changed files with 193 additions and 0 deletions
+19
View File
@@ -0,0 +1,19 @@
FROM python:3.14.4-slim AS builder
WORKDIR /app
COPY pyproject.toml requirements.txt ./
COPY src src
RUN pip wheel --no-cache-dir --no-deps --wheel-dir wheels .
FROM python:3.14.4-slim AS runner
COPY --from=builder /app/wheels /wheels
RUN pip install --no-cache /wheels/* && rm -rf /wheels
RUN apt update
RUN apt -y install ffmpeg
WORKDIR /app
EXPOSE 8000
CMD ["uvicorn", "audio_server:app", "--host", "0.0.0.0", "--port", "8000"]