Skip to content

feat: add STT transcript echo toggle - #54257

Closed
devatnull wants to merge 2 commits into
NousResearch:mainfrom
devatnull:feat/stt-transcript-echo-toggle
Closed

feat: add STT transcript echo toggle#54257
devatnull wants to merge 2 commits into
NousResearch:mainfrom
devatnull:feat/stt-transcript-echo-toggle

Conversation

@devatnull

@devatnull devatnull commented Jun 28, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add stt.echo_transcripts config to keep voice-message STT enabled while suppressing the user-facing 🎙️ transcript echo
  • preserve current behavior by defaulting the new flag to true
  • gate both fresh voice-message and queued voice-interrupt transcript echo paths

Test Plan

  • scripts/run_tests.sh tests/gateway/test_stt_transcript_echo_config.py tests/test_gateway_streaming_nested_config.py

Copilot AI review requested due to automatic review settings June 28, 2026 13:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new configuration toggle to control whether inbound voice-message STT transcripts are echoed back to the user, while keeping STT transcription available to the agent. This fits into the gateway’s STT pipeline and Hermes’ config defaults by making transcript echo configurable without changing the default UX.

Changes:

  • Add stt.echo_transcripts (config.yaml default) / stt_echo_transcripts (GatewayConfig field + top-level override) to control transcript echo behavior, defaulting to true for backward compatibility.
  • Gate transcript echo in the fresh voice-message STT path and one queued/dequeue transcription path via GatewayRunner._should_echo_stt_transcripts().
  • Add focused unit tests for config precedence/defaults and for the runner helper behavior.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
tests/gateway/test_stt_transcript_echo_config.py Adds tests for default behavior, nested-vs-top-level precedence, and runner gating helper.
hermes_cli/config.py Introduces the new stt.echo_transcripts default in the user-facing default config.
gateway/run.py Adds _should_echo_stt_transcripts() and uses it to gate transcript echo in two STT echo call sites.
gateway/config.py Extends GatewayConfig with stt_echo_transcripts, supports parsing from stt.echo_transcripts, and includes it in to_dict().

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread gateway/run.py
Comment on lines +11743 to +11745
def _should_echo_stt_transcripts(self) -> bool:
"""Return whether inbound voice/STT transcripts should be echoed to chat."""
return bool(getattr(self.config, "stt_echo_transcripts", True))
@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have comp/gateway Gateway runner, session dispatch, delivery comp/cli CLI entry point, hermes_cli/, setup wizard tool/tts Text-to-speech and transcription sweeper:risk-message-delivery Sweeper risk: may drop, duplicate, misroute, or suppress messages labels Jun 28, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

This was generated by AI during triage.

Related (competing config feature, not a duplicate): this is part of a saturated STT-transcript-echo-toggle cluster. Notably #46910 adds the exact same stt.echo_transcripts key but defaults it to false, while this PR defaults to true. Other variants: #53038 (stt.echo, default true), #50867 (gateway.echo_voice_transcripts), #53313 (gated opt-in), #13727 (stt.send_transcription + /stt). Flagging for a maintainer to pick a single config key/default before any of these land.

@tonydwb tonydwb left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review Summary

Verdict: LGTM

Adds a configurable STT transcript echo toggle (stt_echo_transcripts). Defaults to True for backwards compatibility. The gate is applied at all transcript echo points (fresh messages, voice interrupts, queued messages). Test verifies the config wiring and uses a source-level assertion to confirm all echo sends are gated.

Reviewed by Hermes Agent

@devatnull

Copy link
Copy Markdown
Contributor Author

Closing this old branch so we can rebuild the Hermes changes cleanly from current main and reopen smaller fresh PRs.

@devatnull devatnull closed this Jul 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/cli CLI entry point, hermes_cli/, setup wizard comp/gateway Gateway runner, session dispatch, delivery P3 Low — cosmetic, nice to have sweeper:risk-message-delivery Sweeper risk: may drop, duplicate, misroute, or suppress messages 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