# Vercel 推出 AI Gateway 支援語音轉文字

> 📖 本站完整內容索引（documentation index）：[llms.txt](/llms.txt)

> 原作者：Vercel Developers (@vercel_dev) · 策展與摘要：EasyVibeCoding · 平台：X (Twitter) · 熱度：🔥 · 日期：2026-07-24

> 原始來源：https://x.com/vercel_dev/status/2080343888662077799

## 證據與延伸閱讀

- [Vercel 推出 AI Gateway 支援語音轉文字。](https://vercel.com/changelog/ai-gateway-now-supports-streaming-transcription)

## 中文摘要

Vercel 推出 AI Gateway 支援語音轉文字。

![](https://pub-75d4fe1e4e80421b9ecb1245a7ae0d1a.r2.dev/curated/ace601aadbee721f.jpg)
> 黑色背景的圖片左側顯示白色文字「AI Gateway now supports streaming transcription」，上方有一個白色三角形圖示，右側則有由白色點陣組成的波浪狀動態線條。

**功能與運作方式**
- Vercel AI Gateway 新增串流語音轉文字支援，改變過去必須等待完整音訊檔案才能回傳完整逐字稿的模式。
- 音訊串流輸入的同時，模型會即時回傳逐字稿更新，大幅降低延遲，適合用於即時字幕與語音輸入等應用。
- 此功能目前處於 beta 階段，透過 AI SDK 的 `streamTranscribe` 函式與任何支援串流的轉錄模型搭配使用。

**程式碼範例**
開發人員可以利用以下程式碼將原始 PCM 音訊串流傳送至模型，並在每個轉錄片段抵達時進行列印：

```ts
import { experimental_streamTranscribe as streamTranscribe } from 'ai';

const result = streamTranscribe({
  model: 'openai/gpt-realtime-whisper',
  audio: audioStream, // ReadableStream<Uint8Array | string>
  inputAudioFormat: { type: 'audio/pcm', rate: 24000 },
});

for await (const part of result.fullStream) {
  if (part.type === 'transcript-delta') {
    process.stdout.write(part.delta);
  }
}
```

**實際應用與跨模型支援**
- 具備跨供應商相容性，只需替換模型字串即可切換至 `xai/grok-stt` 或其他支援串流的轉錄模型。
- 串流轉錄能輕鬆為 Agent 增加語音模式，將使用者的語音串流傳送至轉錄模型後，把即時文字傳遞給 Agent 即可運作。
- Agent 本身無須修改，仍舊接收文字，因此相容於任何以文字為基礎的 Agent；若需要 Agent 語音回覆，可搭配語音生成或使用即時語音來實現完整的雙向對話。
- 詳細資訊可參閱 [AI Gateway 串流轉錄說明文件](https://vercel.com/changelog/ai-gateway-now-supports-streaming-transcription)。

## 標籤

STT, 功能更新, 新產品, Vercel
