中文版正在随流水线自动整理,稍后刷新即可;可先阅读下方英文原文。
本文由 AI图鉴自动抓取并翻译,版权归原作者所有;如需查看原文请点下方链接。
Ollama现在支持语音模型,从Gradium的Phonon开始。 以五种语言和几十个声音大声读出文字,随其生成而流传,结束
中文版正在随流水线自动整理,稍后刷新即可;可先阅读下方英文原文。
本文由 AI图鉴自动抓取并翻译,版权归原作者所有;如需查看原文请点下方链接。
Speech models in Ollama
October 24, 2026
Ollama can now turn text into speech. The first speech model is Phonon, a family of small, state-of-the-art text-to-speech models from Gradium. Speech models are now available for macOS, with Windows and Linux support coming soon.
ollama run phonon "Hello from Ollama."
Performance on Apple Silicon
On Apple Silicon, Ollama is accelerated by MLX, Apple’s machine learning framework, for state-of-the-art throughput. On a MacBook Pro with M5 Max, Ollama was 35% faster than the next fastest engine, Gradium’s own runtime.
Ollama’s implementation is just as accurate, matching the word error rate of the reference implementation in Hugging Face Transformers:
Voices
Choose a voice with --voice, or voice in the API:
ollama run phonon --voice Hadley "Hello from Ollama."
The voices come from Gradium’s voice catalog. ollama show phonon lists them all.
Languages
phonon is released under Apache 2.0. The 40M models are released under CC BY-NC 4.0, which limits them to noncommercial use.
Read replies aloud
Pipe a chat model’s reply into Phonon. Text is spoken as it arrives, so the reply starts playing after its first sentence:
ollama run gemma4 --hidethinking "Tell me a fun fact about owls in two sentences." | ollama run phonon
Run ollama run phonon with no text to type lines at a prompt, or redirect the output to save a WAV file:
ollama run phonon "Save this to a file." > speech.wav
API
Phonon works with the OpenAI-compatible /v1/audio/speech endpoint, so existing code that uses the OpenAI SDK only needs a new base URL.
curl http://localhost:11434/v1/audio/speech \
-H "Content-Type: application/json" \
-d '{
"model": "phonon",
"voice": "Zoey",
"input": "Hello from Ollama."
}' --output speech.wavfrom openai import OpenAI
client = OpenAI(base_url="http://localhost:11434/v1", api_key="ollama")
with client.audio.speech.with_streaming_response.create(
model="phonon",
voice="Zoey",
input="Hello from Ollama.",
response_format="wav",
) as response:
response.stream_to_file("speech.wav")import fs from "node:fs"
import OpenAI from "openai"
const openai = new OpenAI({ baseURL: "http://localhost:11434/v1", apiKey: "ollama" })
const response = await openai.audio.speech.create({
model: "phonon",
voice: "Zoey",
input: "Hello from Ollama.",
response_format: "wav",
})
fs.writeFileSync("speech.wav", Buffer.from(await response.arrayBuffer()))
The response streams while the audio is generated, so it can play right away:
curl -sN http://localhost:11434/v1/audio/speech \
-H "Content-Type: application/json" \
-d '{"model": "phonon", "input": "Playback starts right away."}' \
| ffplay -nodisp -autoexit -loglevel error -
Audio is 24 kHz mono, returned as WAV by default or as raw 16-bit samples with "response_format": "pcm".
Get started
Speech models run on Apple Silicon Macs. Download Ollama 0.40.11 or later, then pull Phonon:
ollama pull phonon
For more information, see:
Auto-fetched and translated by AI Atlas. All rights belong to the original author.
字节跳动推出的AI大模型家族,包括视频生成、语音视觉、通用语言模型等
ElevenLabsAI文本转语音,支持包含中文在内的29种语言
Ollama本地运行Llama和其他大语言模型
OpenBMB清华团队支持发起的大规模预训练语言模型库与相关工具
标题、摘要与正文均来自该信源的公开页面,版权归原作者所有;本站自动聚合与翻译,仅作出处跳转。