Skip to content

fix: clarify ForceEndTurn deployment behavior - #788

Open
GregHolmes wants to merge 1 commit into
mainfrom
gh/fix-force-end-turn-followups
Open

GregHolmes wants to merge 1 commit into
mainfrom
gh/fix-force-end-turn-followups

Conversation

@GregHolmes

Copy link
Copy Markdown
Contributor

Summary

  • State that ForceEndTurn is available on hosted deployments, including EU and AU, while self-hosted availability follows the deployed release.
  • Report FORCE_END_TURN_UNSUPPORTED immediately in the Voice Agent example.
  • Link the frozen EOT description patch to deepgram-docs #1202 and correct the Pydantic v1 unfreeze condition.
  • Restore the socket-client grouping in the generated-patch ledger.

Validation

  • python3 -m compileall on both changed examples
  • git diff --check
  • ruff check in a Python 3.12 container

@github-actions

Copy link
Copy Markdown
Contributor

Code Coverage

Package Line Rate Branch Rate Complexity Health
src.deepgram 97% 94% 0 ✔
src.deepgram.agent 100% 100% 0 ✔
src.deepgram.agent.v1 98% 100% 0 ✔
src.deepgram.agent.v1.settings 100% 100% 0 ✔
src.deepgram.agent.v1.settings.think 100% 100% 0 ✔
src.deepgram.agent.v1.settings.think.models 97% 100% 0 ✔
src.deepgram.auth 100% 100% 0 ✔
src.deepgram.auth.v1 100% 100% 0 ✔
src.deepgram.auth.v1.tokens 97% 100% 0 ✔
src.deepgram.core 88% 81% 0 ➖
src.deepgram.errors 100% 100% 0 ✔
src.deepgram.helpers 100% 95% 0 ✔
src.deepgram.listen 100% 100% 0 ✔
src.deepgram.listen.v1 98% 93% 0 ✔
src.deepgram.listen.v1.media 97% 100% 0 ✔
src.deepgram.listen.v2 98% 93% 0 ✔
src.deepgram.manage 100% 100% 0 ✔
src.deepgram.manage.v1 100% 100% 0 ✔
src.deepgram.manage.v1.models 96% 100% 0 ✔
src.deepgram.manage.v1.projects 97% 100% 0 ✔
src.deepgram.manage.v1.projects.billing 100% 100% 0 ✔
src.deepgram.manage.v1.projects.billing.balances 96% 100% 0 ✔
src.deepgram.manage.v1.projects.billing.breakdown 97% 100% 0 ✔
src.deepgram.manage.v1.projects.billing.fields 97% 100% 0 ✔
src.deepgram.manage.v1.projects.billing.purchases 97% 100% 0 ✔
src.deepgram.manage.v1.projects.keys 96% 100% 0 ✔
src.deepgram.manage.v1.projects.members 97% 100% 0 ✔
src.deepgram.manage.v1.projects.members.invites 96% 100% 0 ✔
src.deepgram.manage.v1.projects.members.scopes 96% 100% 0 ✔
src.deepgram.manage.v1.projects.models 96% 100% 0 ✔
src.deepgram.manage.v1.projects.usage 98% 100% 0 ✔
src.deepgram.manage.v1.projects.usage.breakdown 97% 100% 0 ✔
src.deepgram.manage.v1.projects.usage.fields 97% 100% 0 ✔
src.deepgram.read 100% 100% 0 ✔
src.deepgram.read.v1 100% 100% 0 ✔
src.deepgram.read.v1.text 98% 100% 0 ✔
src.deepgram.self_hosted 100% 100% 0 ✔
src.deepgram.self_hosted.v1 100% 100% 0 ✔
src.deepgram.self_hosted.v1.distribution_credentials 96% 100% 0 ✔
src.deepgram.speak 100% 100% 0 ✔
src.deepgram.speak.v1 98% 97% 0 ✔
src.deepgram.speak.v1.audio 91% 80% 0 ✔
src.deepgram.speak.v2 98% 93% 0 ✔
src.deepgram.speak.v2.audio 100% 100% 0 ✔
src.deepgram.voice_agent 100% 100% 0 ✔
src.deepgram.voice_agent.configurations 95% 100% 0 ✔
src.deepgram.voice_agent.variables 95% 100% 0 ✔
Summary 95% (6503 / 6818) 91% (1419 / 1552) 0 ✔

Scope: hand-maintained SDK logic. Fern-generated data models (types/, requests/), package __init__.py files, version.py, and the unused core/http_sse/ scaffolding are excluded — see .coveragerc. Unscoped whole-package coverage is ~70%.

@dg-coreylweathers dg-coreylweathers 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.

What this PR does
Changes the ForceEndTurn examples and the conversational-STT skill file to say the control is available on Deepgram-hosted deployments including EU and AU (self-hosted depends on the release), makes the Voice Agent example fail fast on FORCE_END_TURN_UNSUPPORTED, and edits the manual-patch ledger.

What I checked

  • Is the availability claim true? Yes: the repo's own tests/manual/listen/v2/force_end_turn/main.py passed all four steps with trigger: manual against api.deepgram.com, api.eu.deepgram.com, and api.au.deepgram.com.
  • Is FORCE_END_TURN_UNSUPPORTED real? Yes, it is the Voice Agent warning for a non-Flux listen provider (deepgram-docs schemas.agent.v1.yml:220), and both Warning and Error carry .code/.description.
  • Gates in Docker: mypy clean, ruff clean on changed files, pytest 1034 passed.

Blocking

  • The AGENTS.md/.fernignore hunk for listen_v2eot_threshold.py and requests/deepgram_listen_provider_v2.py is stale: main's AGENTS.md:85 already says Fern emits that description natively as of the 2026-09-23 regen and the files were unfrozen, so main's .fernignore no longer lists them. The branch is also CONFLICTING. Fix: rebase onto main and drop that hunk entirely; keep only the StrictInt unfreeze-condition change.

Should-fix

  • "Self-hosted availability depends on the deployed release" (examples/16:24-25, SKILL.md:94) omits the switch. deepgram-docs says it needs listen_v2_force_end_turn = true under [features] on the 2026-09-15 release or later. Say that.
  • tests/manual/listen/v2/force_end_turn/main.py:24-27,174 and async.py:8,115 still say "gated per deployment" / "not enabled on this deployment"; align them with the new sentence.

Nit: examples/32:94-104, the trailing rejected-check can raise after agent_finished is set; fine if intended, worth a comment.

This branch has not been deployed

No deployments
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