Expand description
Stateful detokenizer: token IDs → text.
Three correctness concerns it handles:
- Per-token decoding via the map’s encoder (byte_level / metaspace / identity).
- Byte-fallback range — IDs in
[byte_fallback_start, byte_fallback_end]are decoded as raw bytes. - Partial multi-byte sequences across frame boundaries — buffered between calls when
partial: true.
Structs§
- Detokenize
Options - Options for
Detokenizer::render. - Detokenizer
- Stateful detokenizer.