Skip to content

Commit e0773ec

Browse files
seonglaexenova
andauthored
docs: streaming description from @xenova's suggestion
Co-authored-by: Joshua Lochner <admin@xenova.com>
1 parent d226461 commit e0773ec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/source/pipelines.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ It adds depth and richness without being overpowering its taste buds alone
150150

151151
### Streaming
152152

153-
Some pipelines such as `text-generation` or whisper `speech-to-text` models support streaming output. For example, when using a chat model like `Qwen2.5-Coder-0.5B-Instruct`, you can specify a callback function that will be called with each generated token text.
153+
Some pipelines such as `text-generation` or `automatic-speech-recognition` support streaming output. This is achieved using the `TextStreamer` class. For example, when using a chat model like `Qwen2.5-Coder-0.5B-Instruct`, you can specify a callback function that will be called with each generated token text (if unset, new tokens will be printed to the console).
154154

155155
```js
156156
import { pipeline, TextStreamer } from "@huggingface/transformers";

0 commit comments

Comments
 (0)