Daily Tech Briefing
AI 科技速览
每天 5 分钟内学习 AI。获取最新的人工智能新闻,理解其重要性,并学习如何将其应用于您的工作。
Together AI · 2026/7/29 00:00:00

Configuring Dedicated Model Inference
AI 中文解读
Together AI这次搞了个大新闻,他们重新定义了AI模型部署的"流量控制"方式。最吸引人的地方在于,系统不再按固定比例分配请求,而是根据每个服务实例的实时处理能力动态调节,还支持A/B测试和零停机更新。
打个比方,这就像餐厅不再按"每桌固定上几道菜"的规矩来,而是哪个厨师手上活少就多派单给他,哪个厨师还在备菜就少安排,这样上菜更快、厨房也不会乱。技术上,他们把复杂的模型服务拆成三个部件:对外固定的"门牌号"、负责干活的"服务组",以及定义干活方式的"配方"。每次流量进来,系统自动按各服务组当前能接的活儿量来分配,等忙完的组多了就自动多接单,闲下来就少接,全程不用人工干预。
对普通用户来说,以后用AI应用会更少遇到"服务器繁忙"的提示,高峰期也不会卡顿。对企业开发者而言,部署新模型、测试不同版本的效果变得像发个指令一样简单,成本还能大幅降低。简单说,AI服务变得更聪明、更省钱了。
SummaryDedicated Model Inference on the Together AI platform consists of three parts: the endpoint (a stable name you or your clients call), deployments (specific model + hardware combinations running replicas behind it), and configs (recipes for how a model runs). A capacity-aware traffic split ties these three entities together. This architecture enables various other features such as rollouts, A/B tests, shadow experiments, zero-downtime changes possible. Below we'll show how capacity-aware routing works against a live endpoint with measured traffic.How the resource model worksA config is a recipe that specifies the engine, the GPU type and count as well as the parallelism and optimization profile (throughput, latency, balanced). Configs are immutable and every config has an ID like cr_... . Your deployment always points at exactly the config that was tested.A deployment binds one model (at a specific revision) to one config, gives it an autoscaling policy, and runs replicas. Deployments are disposable on purpose and creating and destroying should be considered routine.An endpoint is a fixed identity: a qualified name (<project_slug>/<endpoint_name>) that your applications pass as the model parameter in the ordinary inference API. The endpoint has a traffic split which is used to determine request routing over its deployments.One easy way to understand this is by referring to the ID, every ID in the system tells you what it is by prefix, which makes logs and scripts self-documenting: proj_ (project), ml_ (model), cr_ (config revision), endpoint_, dep_ (deployment), rol_ (rollout).Every advanced operation in the platform is just "add a deployment, and assign it a traffic routing weight" An A/B test is deployments with cohort assignments. A shadow experiment is a deployment at weight zero receiving mirrored traffic. Stopping a deployment is bounding min and max replicas to 0/0.Weight based traffic splitThe traffic split is a list of {deployment_id, weight} entries where a weight is per ready replica**.** The router computes each deployment's effective capacity as weight × ready_replicas and routes proportionally to this capacity.Walk through the diagram above: both deployments have weight 1 but deployment A has 1 ready replica (capacity 1), deployment B has 3 (capacity 3), so traffic follows a 25%/75% split. Equal weights mean equal per-replica load, not equal traffic share.We designed it this way because it makes routing and scaling the same conversation:Autoscaling composes for free. When deployment A scales from 1 replica to 3, its capacity triples and it automatically absorbs proportionally more traffic. With naive percentages, a deployment pinned at "25%" would saturate when scaled down and be idle when scaled up.Per-replica load is what you control. Weight 1 vs weight 2 says "each replica of B should work twice as hard as each replica of A"Replicas that aren't ready don't count. A deployment mid-cold-start, or degraded to 0 ready replicas, contributes zero capacity, so traffic flows to what can actually serve.Weights are positive numbers with no sum constraint so 0.7/0.3 and 700/300 describe identical routing. If you want fixed traffic shares regardless of replica count you can setup A/B experiment cohorts which allow for integer percents that sum to 100%.Setting a split is one PATCH with a field mask:
tg beta endpoints update $DEPLOYMENT_A --traffic-weight 1
tg beta endpoints update $DEPLOYMENT_B --traffic-weight 1
# take a deployment out of rotation without scaling it down
tg beta endpoints update $DEPLOYMENT_B --traffic-weight 0
⚠️ Important
A brand-new deployment will not get any traffic until it appears in the endpoint's traffic split. If you create an endpoint and a deployment and have it `READY`, send a request, and get back a `routing_error` it is probably because the traffic split is not specified and the router hasn’t yet been told that this deployment should receive traffic. The CLI's `
分享
阅读原文 ↗