Gemma 4 audio with MLX

Gemma 4 audio with MLX

Gemma 4 音频与 MLX

https://ift.tt/HlhJCXM

感谢来自 Rahim Nathwani 的一个提示,以下是在 macOS 上使用 10.28 GB 的 Gemma 4 E2B 模型、MLX 和 mlx-vlm,对音频文件进行转录的 uv run 配方:

uv run –python 3.13 –with mlx_vlm –with torchvision –with gradio \
mlx_vlm.generate \
–model google/gemma-4-e2b-it \
–audio file.wav \
–prompt “Transcribe this audio” \
–max-tokens 500 \
–temperature 1.0

我在这个 14 秒的 .wav 文件上进行了尝试,并得到以下输出:

这段前面这是一个快速的语音备忘。我想用 MLX VLM 来试试看。只是想看看它是否能被 Gemma 转录,以及这会如何工作。

(那本应是“这就在这里……”以及“… 它有多好用”但我能理解它为什么把它误解为“前面”和“它如何工作”)

标签:uv、mlx、ai、gemma、llms、speech-to-text、python、generative_ai

HI-FI 新闻

来自 Simon Willison 的 Web 日志 https://ift.tt/es8cxt3

2026 年 4 月 13 日 02:05 AM

April 13, 2026 at 02:05AM