Skip to content

fix(gateway): echo Telegram voice transcripts - #30544

Closed
mtorto2 wants to merge 1 commit into
NousResearch:mainfrom
mtorto2:fix/telegram-voice-transcript-echo
Closed

fix(gateway): echo Telegram voice transcripts#30544
mtorto2 wants to merge 1 commit into
NousResearch:mainfrom
mtorto2:fix/telegram-voice-transcript-echo

Conversation

@mtorto2

@mtorto2 mtorto2 commented May 22, 2026

Copy link
Copy Markdown

Summary

  • capture successful Telegram voice STT transcripts as structured per-session metadata
  • prefix final non-streamed Telegram voice replies with the user-visible transcript audit block
  • keep audio file attachments unchanged and guard against duplicate transcript prefixes

Test Plan

  • python -m pytest tests/gateway/test_stt_config.py tests/gateway/test_telegram_audio_vs_voice.py -q
  • python -m py_compile gateway/run.py

@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have comp/gateway Gateway runner, session dispatch, delivery tool/tts Text-to-speech and transcription platform/telegram Telegram bot adapter duplicate This issue or pull request already exists labels May 22, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Duplicate of #13727 (and #22123, #25196). Fourth independent implementation of the STT transcript echo feature. The original PR #13727 with stt.send_transcription config is the canonical one.

@AxDSan

AxDSan commented May 23, 2026

Copy link
Copy Markdown
Contributor

Hey @mtorto2, appreciate the effort on STT transcript echoing. Unfortunately this is the fourth implementation of the same feature — original is #13727. Closing as duplicate. The config approach in #13727 (stt.send_transcription) is the canonical path.

@teknium1

Copy link
Copy Markdown
Contributor

This is an automated hermes-sweeper review. The voice/STT transcript echo behavior from this PR is now implemented on main.

Evidence:

  • gateway/run.py:8481 calls _enrich_message_with_transcription(...), receives _successful_transcripts, and sends each successful transcript back through the platform adapter as a 🎙️ transcript echo before the agent flow continues.
  • gateway/run.py:12664 documents the helper’s tuple contract: (enriched_text, successful_transcripts), with raw transcript strings returned specifically so callers can echo them to the user.
  • gateway/run.py:12701 collects successful STT transcripts while also preserving the transcript in the model-visible voice-message wrapper.
  • gateway/run.py:12790 and gateway/run.py:16080 cover queued/active-run voice messages too, echoing transcripts when a voice note arrives while the agent is busy.
  • gateway/run.py:8443 keeps Telegram/audio file attachments out of the STT path while preserving MessageType.VOICE for transcription.
  • The implementing commit is d55304c39f204dd8b9e23f3bb681cc2f3472dc56 (fix(gateway): transcribe voice messages during active agent runs), included in v2026.6.19.

The prior duplicate discussion linking #13727/#22123/#25196 was useful context; this PR’s requested transcript-echo outcome is covered by the implementation now present on main.

@teknium1 teknium1 closed this Jun 21, 2026
@teknium1 teknium1 added the sweeper:implemented-on-main Sweeper: behavior already present on current main label Jun 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/gateway Gateway runner, session dispatch, delivery duplicate This issue or pull request already exists P3 Low — cosmetic, nice to have platform/telegram Telegram bot adapter sweeper:implemented-on-main Sweeper: behavior already present on current main tool/tts Text-to-speech and transcription type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants