2 instantiations of LruCache
Microsoft.ML.Tokenizers (2)
12 references to LruCache
Microsoft.ML.Tokenizers (12)
Model\TiktokenTokenizer.cs (11)
29private readonly LruCache<(int Id, int TokenIndex, int TokenLength)[]> _cache;
46internal TiktokenTokenizer(string vocabFilePath, PreTokenizer? preTokenizer, IReadOnlyDictionary<string, int>? specialTokens = null, Normalizer? normalizer = null, int cacheSize = LruCache<int[]>.DefaultCacheSize) :
61internal TiktokenTokenizer(Stream vocabStream, PreTokenizer? preTokenizer, IReadOnlyDictionary<string, int>? specialTokens = null, Normalizer? normalizer = null, int cacheSize = LruCache<int[]>.DefaultCacheSize) :
83int cacheSize = LruCache<int[]>.DefaultCacheSize)
1243LruCache<int[]>.DefaultCacheSize);
1260int cacheSize = LruCache<int[]>.DefaultCacheSize)
1277int cacheSize = LruCache<int[]>.DefaultCacheSize)
1295int cacheSize = LruCache<int[]>.DefaultCacheSize,
1324int cacheSize = LruCache<int[]>.DefaultCacheSize,
1349int cacheSize = LruCache<int[]>.DefaultCacheSize,
1388int cacheSize = LruCache<int[]>.DefaultCacheSize,