Skip to content

[Bug]Minimax TTS的API请求格式错误 #7795

@enemywind-zm

Description

@enemywind-zm

What happened / 发生了什么

在使用AstrBot的TTS(文本转语音)功能时,当QQ官方插件处理从云端TTS服务返回的语音消息时,会抛出以下错误:[Core] [ERRO] [v4.23.5] [qqofficial.qqofficial_message_event:656]: 处理语音时出错: file does not start with RIFF id
问题本质:云端TTS服务返回MP3格式的音频文件,但AstrBot的语音处理代码预期接收WAV格式音频,导致格式验证失败。可是MiniMax TTS支持wav格式

Reproduce / 如何复现?

a. 启动AstrBot并确保TTS服务配置正确
b. 触发一条需要语音回复的QQ消息
c. TTS服务调用成功,音频文件被缓存到服务器
d. AstrBot尝试处理该音频文件时抛出上述错误
e. 检查服务器缓存,确认音频文件确实为MP3格式而非WAV格式

AstrBot version, deployment method (e.g., Windows Docker Desktop deployment), provider used, and messaging platform used. / AstrBot 版本、部署方式(如 Windows Docker Desktop 部署)、使用的提供商、使用的消息平台适配器

AstrBot 版本v4.23.5、Ubuntu22.04手动部署、Minimax token plan、QQ官方机器人(websocket)

OS

Linux

Logs / 报错日志

[10:55:32.046] [Core] [INFO] [result_decorate.stage:299]: TTS 请求:一个代表国际最前沿,一个代表国产开源力量。
[10:55:40.153] [Core] [INFO] [result_decorate.stage:301]: TTS 结果: /home/astrbot/AstrBot/data/temp/minimax_tts_api_8542665d-b8e1-483a-9fb9-f2fb9e5c12b6.mp3
[10:55:40.153] [Core] [INFO] [respond.stage:183]: Prepare to send - /DD74A1EA717091E5085E2CF5606E1FFC: [ComponentType.Record]
[10:55:40.154] [Core] [ERRO] [v4.23.5] [qqofficial.qqofficial_message_event:656]: 处理语音时出错: file does not start with RIFF id

Are you willing to submit a PR? / 你愿意提交 PR 吗?

  • Yes!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:platformThe bug / feature is about IM platform adapter, such as QQ, Lark, Telegram, WebChat and so on.bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions