你寫訓練循環,佢管 GPU:AWS SageMaker 推出 serverless training sessions

2026 年 10 月 22 日,美國 AWS 喺自家 blog 宣佈 Amazon SageMaker AI 嘅「serverless 模型自訂」功能擴展,推出「training sessions」(訓練會話)API,並同時達到正式可用(GA)。

核心賣點只有一句:以前你要自訂訓練,就同時要自管 GPU、cluster、分佈式配置;而家你可以自己寫訓練循環(training loop),SageMaker AI 處理 GPU allocation、distributed execution、fault recovery、gradient synchronization 同 checkpoint storage。廠商原話係「You write the training loop, and SageMaker AI runs the infrastructure」。

點樣運作

API 將 forward_backward()、optim_step()、sample() 等操作變成 SageMaker API call,呼叫一個 live、stateful 嘅 GPU session。模型(base model 加 LoRA adapter)喺 GPU 上保持加載,用户決定調用次數,唔使預先寫 config 文件或開 cluster。SDK 用三個 client:ServiceClient 管平台設定(execution role、S3 output、KMS key、VPC),並 instantiate 出 TrainingClient 負責訓練同 checkpoint。

技術範圍:SFT、DPO、RLVR、RLAIF、multi-turn RL 都可以;LoRA 或 full fine-tuning 都可以;多項技術可以串接做連續自訂。

同 cookbook 同 agent

同步推出嘅有「SageMaker AI training sessions cookbook」,提供可執行嘅 SFT 同 RL recipe 作藍圖。Blog 仲提到「model customization agent skills」——你描述 use case,agent 處理資料準備、技術選擇、訓練、評估、部署,並稱可喺 SageMaker Studio、Kiro、Claude Code、Codex、GitHub Copilot 運行。呢段係廠商聲稱,本站未實測。

客户引述

ImagineSoftware 嘅 Rob Gontarek(Data Science SVP)喺公告引述話,佢哋用 training sessions 做醫療 claim denial triage 模型,讚低層 API 俾科學家「fine-grained control」,可以對 accuracy-critical 場景做 RL。

模姐驗嚇貨

呢度嘅賣點真係清晰:抽象分界由「抽走算術」改為「抽走算力」。對開發者而家最大嘅痛點唔係寫唔到 RL loop,而係寫到都要自己搞基建。將呢條線拉低一層,理論上 algorithmic freedom 同運維簡單化可以同時有。

但有三樣嘢要留待審:

第一,呢個係廠商自宣。冇獨立測試、冇第三方跑過嘅 benchmark、冇可對照嘅舊版比較。GA 唔等於是無痛過渡。

第二,stateful session 喺雲端 GPU 上「保持加載」,模型同 LoRA adapter 嘅存放、跨用户隔離(tenant isolation)點做,blog 冇交代具體機制,只係一句「the service handles...」。呢個係私隱同數據治理嘅核心問題,唔該再追。

第三,支持「alignment algorithm published last week」呢句,暗示技術可以即寫即跑。但新 alignment 方法嘅安全風險、是否會產生有害行為,平台層面有冇任何 guardrail 或評估門檻,材料冇提。