调整语音文件大小限制,超出 10MB 时禁止识别

This commit is contained in:
jxxghp
2026-04-29 18:41:54 +08:00
parent bd5c3d848c
commit 7299733960

View File

@@ -84,7 +84,7 @@ class OpenAIVoiceProvider(VoiceProvider):
if not content:
return None
if len(content) > self.MAX_TRANSCRIBE_BYTES:
raise ValueError("语音文件超过 25MB无法识别")
raise ValueError("语音文件超过 10MB无法识别")
try:
client = self._get_client("stt")