We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 67a55c1 commit ef995baCopy full SHA for ef995ba
xllm/core/framework/dit_model_loader.cpp
@@ -174,6 +174,15 @@ bool DiTFolderLoader::load_tokenizer_args(
174
JsonReader tokenizer_reader;
175
const std::string tokenizer_args_file_path =
176
model_weights_path_ + "/tokenizer_config.json";
177
+
178
+ // check if tokenizer.json exists, if exists, set the tokenizer type to fast
179
+ const std::string tokenizer_json_path =
180
+ model_weights_path + "/tokenizer.json";
181
+ if (std::filesystem::exists(tokenizer_json_path)) {
182
+ tokenizer_args_.tokenizer_type() = "fast";
183
+ tokenizer_args_.vocab_file() = tokenizer_json_path;
184
+ }
185
186
if (!std::filesystem::exists(tokenizer_args_file_path)) {
187
return true;
188
}
0 commit comments