Revert "Use local Whisper compose stack"

This reverts commit 5f833e84a6.
This commit is contained in:
William Valentin
2026-02-13 23:28:49 -08:00
parent 8fa2a6de9d
commit 4f3810ba4c
3 changed files with 30 additions and 49 deletions
+8 -8
View File
@@ -7,8 +7,7 @@
telegram:
bot_token: ${FLYNN_TELEGRAM_TOKEN}
allowed_chat_ids: [-1003673132186]
require_mention: false
allowed_chat_ids: [] # Add your Telegram chat ID
server:
tailscale_only: true
@@ -168,9 +167,10 @@ hooks:
# --host 0.0.0.0 --port 8080 --convert --language en \
# --inference-path /v1/audio/transcriptions
#
audio:
enabled: true
provider:
type: custom
endpoint: "http://whisper-server:8080/v1/audio/transcriptions"
model: "whisper-1"
# audio:
# enabled: true
# provider:
# type: custom # openai, groq, ollama, llamacpp, custom
# endpoint: "http://localhost:18801/v1/audio/transcriptions"
# api_key: "${WHISPER_API_KEY}" # Optional Bearer token
# model: "whisper-1" # Model name (default: whisper-1)
+20 -33
View File
@@ -1,5 +1,3 @@
version: '3.9'
services:
flynn:
build: .
@@ -31,39 +29,28 @@ services:
timeout: 5s
start_period: 15s
retries: 3
depends_on:
whisper-server:
condition: service_healthy
networks:
- flynn-net
# Optional: Whisper server for audio transcription
whisper-server:
image: ghcr.io/ggml-org/whisper.cpp:main
container_name: whisper-server
restart: unless-stopped
ports:
- "18801:8080"
command: >
whisper-server
--model /app/models/ggml-base.en.bin
--host 0.0.0.0
--port 8080
--convert
--language en
--inference-path /v1/audio/transcriptions
volumes:
- ./whisper-models:/app/models:ro
healthcheck:
test: ["CMD-SHELL", "curl", "-f", "http://localhost:8080/"]
interval: 30s
timeout: 5s
start_period: 15s
retries: 3
networks:
- flynn-net
# Uncomment and adjust as needed for voice message support
# whisper-server:
# image: ghcr.io/ggml-org/whisper.cpp:main
# container_name: whisper-server
# restart: unless-stopped
# ports:
# - "18801:8080"
# command: whisper-server
# --model /app/models/ggml-base.en.bin
# --host 0.0.0.0
# --port 8080
# --convert
# --language en
# --inference-path /v1/audio/transcriptions
# healthcheck:
# test: ["CMD-SHELL", "curl", "-f", "http://localhost:8080/"]
# interval: 30s
# timeout: 5s
# start_period: 15s
# retries: 3
volumes:
flynn-data:
networks:
flynn-net:
+2 -8
View File
@@ -56,10 +56,7 @@ export class SessionStore {
const stmt = this.db.prepare(
'INSERT INTO messages (session_id, role, content, metadata) VALUES (?, ?, ?, ?)',
);
const contentString = typeof message.content === 'string'
? message.content
: JSON.stringify(message.content);
stmt.run(sessionId, message.role, contentString, metadata ? JSON.stringify(metadata) : null);
stmt.run(sessionId, message.role, message.content, metadata ? JSON.stringify(metadata) : null);
}
getMessages(sessionId: string): Message[] {
@@ -87,10 +84,7 @@ export class SessionStore {
'INSERT INTO messages (session_id, role, content, metadata) VALUES (?, ?, ?, ?)',
);
for (const msg of messages) {
const contentString = typeof msg.content === 'string'
? msg.content
: JSON.stringify(msg.content);
insert.run(sessionId, msg.role, contentString, null);
insert.run(sessionId, msg.role, msg.content, null);
}
});
transaction();