Tokenizer.GetIndexByTokenCountFromEnd メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
オーバーロード
| 名前 | 説明 |
|---|---|
| GetIndexByTokenCountFromEnd(ReadOnlySpan<Char>, Int32, String, Int32, Boolean, Boolean) |
トークンの制限を超えることなく、最大エンコード容量のインデックスを見つけます。 |
| GetIndexByTokenCountFromEnd(String, Int32, String, Int32, Boolean, Boolean) |
トークンの制限を超えることなく、最大エンコード容量のインデックスを見つけます。 |
GetIndexByTokenCountFromEnd(ReadOnlySpan<Char>, Int32, String, Int32, Boolean, Boolean)
- ソース:
- Tokenizer.cs
- ソース:
- Tokenizer.cs
- ソース:
- Tokenizer.cs
トークンの制限を超えることなく、最大エンコード容量のインデックスを見つけます。
public int GetIndexByTokenCountFromEnd(ReadOnlySpan<char> text, int maxTokenCount, out string? normalizedText, out int tokenCount, bool considerPreTokenization = true, bool considerNormalization = true);
member this.GetIndexByTokenCountFromEnd : ReadOnlySpan<char> * int * string * int * bool * bool -> int
Public Function GetIndexByTokenCountFromEnd (text As ReadOnlySpan(Of Char), maxTokenCount As Integer, ByRef normalizedText As String, ByRef tokenCount As Integer, Optional considerPreTokenization As Boolean = true, Optional considerNormalization As Boolean = true) As Integer
パラメーター
- text
- ReadOnlySpan<Char>
エンコードするテキスト。
- maxTokenCount
- Int32
エンコードするトークンの最大数。
- normalizedText
- String
トークナイザーの正規化が有効になっているか、 <paramRef name="considerPreTokenization"></paramRef> が false場合、これは正規化された形式で <paramRef name="text"></paramRef> に設定されます。それ以外の場合、この値は nullに設定されます。
- tokenCount
- Int32
トークン数は、最大トークン数よりも小さくする必要がある生成できます。
- considerPreTokenization
- Boolean
トークン化の前に事前トークン化を検討するかどうかを示します。
- considerNormalization
- Boolean
トークン化の前に正規化を検討するかどうかを示します。
返品
トークンの制限を超えずに処理されたテキスト内の最大エンコード容量のインデックス。 これは、含める最初の文字のインデックスを表します。 トークンが適合しない場合、結果はテキストの長さになります。逆に、すべてのトークンが適合する場合、結果はゼロになります。
適用対象
GetIndexByTokenCountFromEnd(String, Int32, String, Int32, Boolean, Boolean)
- ソース:
- Tokenizer.cs
- ソース:
- Tokenizer.cs
- ソース:
- Tokenizer.cs
トークンの制限を超えることなく、最大エンコード容量のインデックスを見つけます。
public int GetIndexByTokenCountFromEnd(string text, int maxTokenCount, out string? normalizedText, out int tokenCount, bool considerPreTokenization = true, bool considerNormalization = true);
member this.GetIndexByTokenCountFromEnd : string * int * string * int * bool * bool -> int
Public Function GetIndexByTokenCountFromEnd (text As String, maxTokenCount As Integer, ByRef normalizedText As String, ByRef tokenCount As Integer, Optional considerPreTokenization As Boolean = true, Optional considerNormalization As Boolean = true) As Integer
パラメーター
- text
- String
エンコードするテキスト。
- maxTokenCount
- Int32
エンコードするトークンの最大数。
- normalizedText
- String
トークナイザーの正規化が有効になっているか、 <paramRef name="considerPreTokenization"></paramRef> が false場合、これは正規化された形式で <paramRef name="text"></paramRef> に設定されます。それ以外の場合、この値は nullに設定されます。
- tokenCount
- Int32
トークン数は、最大トークン数よりも小さくする必要がある生成できます。
- considerPreTokenization
- Boolean
トークン化の前に事前トークン化を検討するかどうかを示します。
- considerNormalization
- Boolean
トークン化の前に正規化を検討するかどうかを示します。
返品
トークンの制限を超えずに処理されたテキスト内の最大エンコード容量のインデックス。 これは、含める最初の文字のインデックスを表します。 トークンが適合しない場合、結果はテキストの長さになります。逆に、すべてのトークンが適合する場合、結果はゼロになります。