TLDRocket
Sign in

Announcing Together Python SDK v2.0

Together AI

Together AI just shipped a rebuilt Python SDK, version 2.0, as a release candidate. It's fully retyped and rebuilt off their OpenAPI spec, and old code will need some tweaks to keep running.

Based on reporting by Together AI — read the original for the full story.

Summary, retelling and take written by AI under human oversight; images are AI-generated illustrations. How we work · Report an error

Together AI is replacing its Python SDK from the ground up, and the new version 2.0 release candidate is out now. Instead of the hand-maintained client that's powered v1 since the early days, this one is generated straight from Together's OpenAPI spec using a tool called Stainless. That means the SDK now mirrors the actual API surface much more closely, which should cut down on the weird inconsistencies that crop up when a wrapper library drifts from what the backend actually does.

The headline change for developers is typing. Together says it's bringing "TypeScript-like" type safety to Python, with typed parameters, typed responses, and helpers for things like chat messages and eval configs. Pair that with a switch from requests to httpx under the hood, and Together claims roughly 20 milliseconds shaved off average request time, plus better timeout and connection handling. It also plays nice with uv, the newer, faster Python package installer that's been gaining ground fast this year.

Not everything moves over cleanly, though. Together published a full migration guide because there are real breaking changes here. Positional arguments are gone — everything's keyword-only now. The old TogetherException grab-bag has been replaced with a proper error hierarchy: APIStatusError plus specific classes for 400s, 401s, 429s, and so on, which is a much saner way to handle failures than catching one giant exception and guessing. Batches, Files, and Endpoints all got renamed methods too — create_batch is now just create, client.files.retrieve_content is gone in favor of a streaming content() call, and Evals has moved from client.evaluation to client.evals with strongly typed parameter objects instead of loose dictionaries.

The good news is that if your app is mostly just calling chat completions, generating embeddings, or doing basic image generation, Together says those endpoints are essentially drop-in compatible — little to no code changes needed. The rougher edges show up in Files, Batches, Endpoints, and Code Interpreter, where method names and response shapes have shifted enough that you'll want to read the parity matrix Together built to sort easy migrations from the medium-effort ones.

This release also quietly introduces things that never existed in v1 at all: a beta Instant Clusters API, raw response and streaming helpers for debugging, and full session management for Code Interpreter. Together's plan is that all future feature work lands in v2 first, with v1 eventually shifting into maintenance mode and then deprecation — so this RC is less a side option and more a preview of where the whole SDK is headed.

My take — AI-written commentary, not fact-checked reporting

Rebuilding an SDK off an OpenAPI spec is the boring, correct move, and I'll take boring-and-correct over clever-and-brittle any day — this is the kind of infra housekeeping that gets ignored until it saves someone's production job at 2am. My only gripe is the classic RC dance: shipping beta cluster APIs alongside a 'stable-ish' typed client tells you Together wants developer trust and bleeding-edge hype in the same release, and those two goals don't always shake hands.

Read more about this at: Together AI

Related stories

The daily briefing

Every AI story that matters, in your inbox by 8am.

TLDRocket reads all relevant sources, removes duplicate coverage, and summarises the day in two minutes. Follow companies and topics for alerts, or get the briefing in Slack. Free, no spam, unsubscribe anytime.