UNPKG

gpt-tokenizer

Version:

A pure JavaScript implementation of a BPE tokenizer (Encoder/Decoder) for GPT-2 / GPT-3 / GPT-4 and other OpenAI models

4 lines (3 loc) 215 B
import type { RawBytePairRanks } from '../BytePairEncodingCore.js'; import type { EncodingParams } from '../modelParams.js'; export declare function O200KBase(bytePairRankDecoder: RawBytePairRanks): EncodingParams;