TokenizerId

org.llm4s.context.tokens.TokenizerId
See theTokenizerId companion object
@Stable
final case class TokenizerId(name: String)

Identifies a BPE tokenizer vocabulary by its canonical name.

A tokenizer id selects the byte-pair-encoding vocabulary used to count tokens without calling the provider API. Which vocabulary a model uses is its vendor's knowledge: the vendor's module maps model names to ids (OpenAITokenizers in llm4s-openai).

Value parameters

name

Tokenizer vocabulary name as used by tiktoken and related libraries (e.g. "cl100k_base").

Attributes

Companion
object
Source
Tokens.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

Attributes

Inherited from:
Product

Attributes

Inherited from:
Product