Skip to content

ENG-87567 docs: document audio transcription batches#277

Merged
rishabh-bhargava merged 1 commit into
mainfrom
rishabh/eng-87567-batch-audio-docs
May 11, 2026
Merged

ENG-87567 docs: document audio transcription batches#277
rishabh-bhargava merged 1 commit into
mainfrom
rishabh/eng-87567-batch-audio-docs

Conversation

@rishabh-bhargava
Copy link
Copy Markdown
Contributor

@rishabh-bhargava rishabh-bhargava commented May 11, 2026

Summary

Surfaces the audio-batch contract in the API reference. The Batch API has supported /v1/audio/transcriptions and /v1/audio/translations for a while, but the spec only documented /v1/chat/completions, leaving customers to reverse-engineer the JSONL input shape (the ENG-87557 customer hit exactly this dead end).

What changed

  • CreateBatchRequest.endpoint is now constrained to an enum of the three supported values, with an inline description listing each.
  • Two new x-codeSamples on POST /batches showing audio batch creation (Python + cURL). The Python sample's leading comment documents the JSONL line shape, including the per-line "method": "FILE" field required for audio dispatch today.

Coordination

  • Linear: ENG-87567 (this PR) and ENG-87568 (service fix to auto-detect multipart for audio endpoints, assigned to @abakhturin).
  • Companion Mintlify PR: togethercomputer/mintlify-docs#824 — narrative changes to docs/inference/batch/tutorial.mdx and overview.mdx. Reference page reference/batch-create.mdx auto-syncs from this spec via .github/workflows/sync-openapi-spec-to-docs.yml, so no manual edit needed there.
  • If ENG-87568 ships before this is reviewed, the method: "FILE" line in the Python sample's leading comment becomes obsolete and I'll simplify.

Test plan

  • Targeted edits only — verified the diff doesn't include unrelated yamlfmt drift from main
  • yamlfmt -dry -conf .yamlfmt openapi.yaml shows no new formatting issues attributable to this change (CI uses -dry, non-blocking)
  • Visual check in API ref preview that the enum dropdown and two new code-sample tabs render as expected

🤖 Generated with Claude Code

Adds an enum on CreateBatchRequest.endpoint covering all three supported
values (chat completions plus audio transcriptions and translations) and
two x-codeSamples (Python + cURL) demonstrating audio batch creation.
The Python sample includes the per-line JSONL shape with `"method": "FILE"`,
which is required for audio batches today.

Surfaces the audio batch contract that previously only existed in code.
Coordinates with ENG-87568 (service fix to drop the method:"FILE"
requirement) — if that lands first the JSONL example here will be
simplified.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 11, 2026

✱ Stainless preview builds for togetherai

This PR will update the togetherai SDKs with the following commit messages.

go

fix(types): convert endpoint to enum in batch new params

openapi

feat(api): add endpoint enum with audio transcriptions/translations to batches

python

fix(types): constrain endpoint parameter to literals in batches

terraform

chore(internal): regenerate SDK with no functional changes

typescript

fix(types): restrict endpoint to specific values in batches create
togetherai-openapi studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅

⚠️ togetherai-go studio · code

Your SDK build had a failure in the test CI job, which is a regression from the base state.
generate ✅build ⏭️lint ✅test ❗

go get github.com/stainless-sdks/togetherai-go@24f44d8b31359e5c2d0792f7baf244731e2acbba
⚠️ togetherai-python studio · code

Your SDK build had at least one "warning" diagnostic.
generate ⚠️build ✅lint ✅test ⏭️

pip install https://pkg.stainless.com/s/togetherai-python/cc61be030cc95d6a3d8e262ec47f7ceacfd2eb75/together-2.12.0-py3-none-any.whl
⚠️ togetherai-typescript studio · code

Your SDK build had at least one "warning" diagnostic.
generate ⚠️build ✅lint ✅test ✅

npm install https://pkg.stainless.com/s/togetherai-typescript/c65be590b14e2da807110160e6d87f07b7c5ff55/dist.tar.gz
togetherai-terraform studio · code

Your SDK build had at least one "note" diagnostic.
generate ✅lint ✅test ✅


This comment is auto-generated by GitHub Actions and is automatically kept up to date as you push.
If you push custom code to the preview branch, re-run this workflow to update the comment.
Last updated: 2026-05-11 21:16:45 UTC

@rishabh-bhargava rishabh-bhargava merged commit 309621e into main May 11, 2026
6 checks passed
@rishabh-bhargava rishabh-bhargava deleted the rishabh/eng-87567-batch-audio-docs branch May 11, 2026 21:14
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