feat(volcengine): 接入 Seed-TTS 2.0 与极速 ASR - #1
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Important
📝 变更描述 / Description
为火山引擎渠道新增两个固定公开模型:
doubao-seed-tts-2.0与doubao-seed-asr-flash。TTS 使用 V3 HTTP Chunked 协议并流式透传 MP3、Opus 或 PCM;ASR 使用录音文件极速版并支持json、text、verbose_json。实现同时覆盖新旧鉴权格式、渠道默认音色映射、服务端固定资源 ID、输入边界校验、首字节前重试与流中断退款语义。计费按火山实际字符数/音频时长结算,缺失 usage 时采用受控回退;不硬编码价格,也不会在未配置倍率时免费调用。日志仅记录审计字段,不记录凭据、音频或完整合成文本。
本实现参考社区 PR QuantumNous#4710、QuantumNous#3330 的方向后按当前 rc22 结构重写,没有直接 cherry-pick。现有火山方舟聊天、图像与 V1 TTS 路由保持不变。
🚀 变更类型 / Type of change
🔗 关联任务 / Related Issue
✅ 提交前检查项 / Checklist
📸 运行证明 / Proof of Work
go test ./...:通过bun run typecheck:通过oxlint:通过bun run build:通过docker build --network=host -t new-api:volc-speech-v1-test .:通过sha256:3ed1209417c127a705cd07c7ebba1155c0bc65742ca3dff30efd5e812e7337f0git diff --cached --check:通过