From bd075d5b3d5b5cac9c4017e55f16482bfc2e683b Mon Sep 17 00:00:00 2001 From: krasi Date: Wed, 13 May 2026 00:28:28 +0200 Subject: [PATCH 1/4] =?UTF-8?q?feat(tts):=20Phase=2010C=20=E2=80=94=20TTS?= =?UTF-8?q?=20generation=20via=20OpenRouter=20/audio/speech?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add generate_tts LangGraph tool + node (features/audio/) - service.py: POST to openrouter /audio/speech with gpt-4o-mini-tts, upload mp3 to Supabase Storage, return 7-day signed URL - tool.py: extract text arg from supervisor tool_call, call service, return ToolMessage with markdown audio link - schemas.py: AudioGenerateResult Pydantic model - Wire generate_tts into supervisor + orchestrator - supervisor.py: bind generate_tts tool, add TTS section to system prompt, detect text-format tool calls (DeepSeek compat) and convert to structured - orchestrator.py: add generate_tts node, conditional edge from supervisor - Config: tts_model=openai/gpt-4o-mini-tts-2025-12-15, tts_voice, audio_bucket - State: add pending_audio field for cross-turn save confirmation (Phase 10D) - Emit Generating audio... SSE tool_use event from chat service - Frontend: inline