Skip to content

fix(voice): accept string dtype settings - #4794

Closed
Hughhhhcoder wants to merge 1 commit into
openai:mainfrom
Hughhhhcoder:codex/openai-agents-voice-dtype
Closed

fix(voice): accept string dtype settings#4794
Hughhhhcoder wants to merge 1 commit into
openai:mainfrom
Hughhhhcoder:codex/openai-agents-voice-dtype

Conversation

@Hughhhhcoder

Copy link
Copy Markdown
Contributor

Summary

  • normalize TTS output dtypes with NumPy before selecting the supported int16/float32 conversions
  • accept JSON/dictionary string spellings such as "int16" and "float32"
  • preserve UserError("Invalid output dtype") for unsupported or invalid dtypes

Fixes #4777

Validation

  • .venv/bin/pytest -q tests/voice/test_pipeline.py (58 passed)
  • .venv/bin/ruff check src/agents/voice/result.py tests/voice/test_pipeline.py
  • .venv/bin/ruff format --check src/agents/voice/result.py tests/voice/test_pipeline.py
  • .venv/bin/pyright --project pyrightconfig.json src/agents/voice/result.py tests/voice/test_pipeline.py
  • git diff --check

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Aug 31, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-08-31T07:13:56.358070Z 65d5cd3 Manual request
🔒 Security Review Completed 2026-08-31T07:16:05.304058Z 65d5cd3 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Hughhhhcoder

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep them coming!

Reviewed commit: 65d5cd3cf6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@chatgpt-codex-connector

Copy link
Copy Markdown

Security review completed. No security issues were found in this pull request.

Reviewed commit: 65d5cd3cf6

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

@Hughhhhcoder

Copy link
Copy Markdown
Contributor Author

Closing in favor of #4778, which predates this PR and covers the same dtype normalization behavior with broader regression coverage. Thanks to @ErenAta16 for the careful side-by-side comparison.

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.

VoicePipeline rejects string dtype spellings in TTS settings ("dtype": "float32" raises UserError: Invalid output dtype)

1 participant