2 overrides of TryMapIdToToken
Microsoft.ML.Tokenizers (2)
Model\SentencePieceBpeModel.cs (1)
65
public override bool
TryMapIdToToken
(int id, out string? token) => _vocabReverse.TryGetValue(id, out token);
Model\SentencePieceUnigramModel.cs (1)
427
public override bool
TryMapIdToToken
(int id, out string? token)
8 references to TryMapIdToToken
Microsoft.ML.Tokenizers (8)
Model\SentencePieceBaseModel.cs (8)
236
else if (!TryDecodeAsSpecialToken(this, current, considerSpecialTokens, ref sb) &&
TryMapIdToToken
(current, out string? token))
241
else if (!TryDecodeAsSpecialToken(this, current, considerSpecialTokens, ref sb) &&
TryMapIdToToken
(current, out string? token))
289
if (!TryDecodeAsSpecialToken(this, current, considerSpecialTokens, ref sb) &&
TryMapIdToToken
(current, out string? token))
406
model.
TryMapIdToToken
(id, out token);
480
if (!isSpecialToken &&
TryMapIdToToken
(current, out string? token))
501
if (!isSpecialToken &&
TryMapIdToToken
(current, out string? token))
578
if (!isSpecialToken &&
TryMapIdToToken
(current, out string? token))
647
model.
TryMapIdToToken
(id, out specialToken);