IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).

Python class

TokenIds

TokenIds​

max.pipelines.modeling.types.TokenIds

source

Token ids decoded or encoded by a tokenizer: an array, a sequence, or a single id, matching the shape of the request that produced them.

alias of ndarray[tuple[Any, …], dtype[integer[Any]]] | Sequence[int] | int