feat: rewrite voice-assistant in Go

Replace Python voice assistant with Go for smaller container images.
Uses handler-base Go module for NATS, health, telemetry, and all service clients.

- Full pipeline: STT → embed → Milvus → rerank → LLM → TTS
- Base64 audio encode/decode
- Dockerfile: multi-stage golang:1.25-alpine → scratch
- CI: Gitea Actions with lint/test/release/docker/notify
This commit is contained in:
2026-02-19 18:00:58 -05:00
parent e028d078d8
commit 2e66cac1e9
12 changed files with 413 additions and 3258 deletions

View File

@@ -1,9 +1,23 @@
# Voice Assistant - Using handler-base with audio support
ARG BASE_TAG=latest
FROM ghcr.io/billy-davies-2/handler-base:${BASE_TAG}
# Build stage
FROM golang:1.25-alpine AS builder
WORKDIR /app
COPY voice_assistant.py .
RUN apk add --no-cache ca-certificates
CMD ["python", "voice_assistant.py"]
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-w -s" -o /voice-assistant .
# Runtime stage
FROM scratch
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
COPY --from=builder /voice-assistant /voice-assistant
USER 65534:65534
ENTRYPOINT ["/voice-assistant"]