encode

fun encode(text: String): IntArray

Encodes a text into token IDs.

Return

Array of token IDs.

Parameters

text

Text to tokenize (UTF-8).