File tree 1 file changed +2
-2
lines changed
src/benchmarks/Tiktoken.Benchmarks
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ public async Task GlobalSetup()
41
41
42
42
[ Benchmark ]
43
43
[ BenchmarkCategory ( "Encode" ) ]
44
- public IReadOnlyCollection < int > MicrosoftMLTokenizerV1_0_0_Encode ( ) => _microsoftMlTiktoken . EncodeToIds ( Data ) ;
44
+ public IReadOnlyCollection < int > MicrosoftMLTokenizerV1_0_0_Encode ( ) => _microsoftMlTiktoken . EncodeToIds ( Data . AsSpan ( ) ) ;
45
45
46
46
[ Benchmark ]
47
47
[ BenchmarkCategory ( "Encode" ) ]
@@ -62,7 +62,7 @@ public async Task GlobalSetup()
62
62
63
63
[ Benchmark ]
64
64
[ BenchmarkCategory ( "CountTokens" ) ]
65
- public int MicrosoftMLTokenizerV1_0_0_ ( ) => _microsoftMlTiktoken . CountTokens ( Data ) ;
65
+ public int MicrosoftMLTokenizerV1_0_0_ ( ) => _microsoftMlTiktoken . CountTokens ( Data . AsSpan ( ) ) ;
66
66
67
67
[ Benchmark ]
68
68
[ BenchmarkCategory ( "CountTokens" ) ]
You can’t perform that action at this time.
0 commit comments