1 instantiation of SymbolPair
Microsoft.ML.Tokenizers (1)
Model\CodeGenTokenizer.cs (1)
1716
SymbolPair pair =
new
(left, right, rank, symbols[left].pieceSpan.Length + symbols[right].pieceSpan.Length);
14 references to SymbolPair
Microsoft.ML.Tokenizers (14)
Model\CodeGenTokenizer.cs (14)
382
PriorityQueue<
SymbolPair
> agenda = new(textSpanToEncode.Length);
422
private void EncodeInternal(string? text, scoped ReadOnlySpan<char> textSpan, List<EncodedToken> tokens, bool addPrefixSpace, int offset, PriorityQueue<
SymbolPair
> agenda)
622
PriorityQueue<
SymbolPair
> agenda = new(textSpanToEncode.Length);
834
PriorityQueue<
SymbolPair
> agenda = new(textSpanToEncode.Length);
971
PriorityQueue<
SymbolPair
> agenda = new(textSpanToEncode.Length);
1101
private int EncodeToIdsInternal(string? text, scoped ReadOnlySpan<char> textSpan, IList<int>? accumulatedIds, PriorityQueue<
SymbolPair
> agenda, out int charsConsumed, int maxTokens)
1165
private int EncodeToIdsFromEndInternal(string? text, scoped ReadOnlySpan<char> textSpan, IList<int>? accumulatedIds, PriorityQueue<
SymbolPair
> agenda, out int textIndex, int maxTokens)
1616
private List<EncodedToken> EncodeToTokens(Span<char> text, Span<int> mapping, ReadOnlySpan<char> originalText, PriorityQueue<
SymbolPair
> agenda)
1652
SymbolPair
top = agenda.Dequeue();
1716
SymbolPair
pair = new(left, right, rank, symbols[left].pieceSpan.Length + symbols[right].pieceSpan.Length);
1820
private struct SymbolPair : IEquatable<
SymbolPair
>, IComparable<
SymbolPair
>
1835
public int CompareTo(
SymbolPair
other)
1855
public bool Equals(
SymbolPair
other) => Left == other.Left && Score == other.Score;