Skip to content

feat: prefer QQ platform asr_refer_text for voice transcription#71

Merged
quick-sort merged 1 commit into
mainfrom
feat/qq-voice-asr-refer-text
Jun 27, 2026
Merged

feat: prefer QQ platform asr_refer_text for voice transcription#71
quick-sort merged 1 commit into
mainfrom
feat/qq-voice-asr-refer-text

Conversation

@hilr

@hilr hilr commented Jun 27, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • QQ 语音消息的 attachment payload 里携带了平台自己的 ASR 结果(asr_refer_text)。现在优先直接使用它,跳过音频下载和 SILK 转码。
  • asr_refer_text 不存在时,回退到原有逻辑(下载音频 + GLM ASR)。
  • 同步更新 CLAUDE.mdGLM_API_KEY 的描述,说明它现在是回退而非唯一转写途径。

参考 openclaw-qqbot 的入站附件处理:QQ 平台在语音事件载荷中提供 asr_refer_textvoice_wav_url,前者可直接作为转录文本,无需本地解码。

Test plan

  • uv run pytest tests/ — 186 passed
  • 发送一条 QQ 语音,确认日志出现 QQ voice: using platform asr_refer_text (N chars)
  • 确认 agent 收到的转写文本正确

🤖 Generated with Claude Code

QQ voice messages carry the platform's own ASR result in the attachment
payload (asr_refer_text). Use it directly — no audio download or SILK
transcoding needed. Falls back to GLM ASR only when the field is absent.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@quick-sort
quick-sort merged commit 648ac27 into main Jun 27, 2026
1 check passed
@quick-sort
quick-sort deleted the feat/qq-voice-asr-refer-text branch June 27, 2026 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants