feat: add voice transcription

This commit is contained in:
bladeclara42
2025-07-03 10:02:12 +07:00
parent f047a3c1c2
commit 0fd8170c5b
5 changed files with 53 additions and 7 deletions

View File

@@ -1,8 +1,17 @@
from pydantic import BaseModel
from typing import Optional
# Text-to-Speech Models
class VoiceRequest(BaseModel):
text: str
class VoiceResponse(BaseModel):
voice: str
voice_output: str
# Speech-to-Text Models
class TranscriptionRequest(BaseModel):
audio_file_path: str
target_language: Optional[str] = "id" # Default to English
class TranscriptionResponse(BaseModel):
text: str