Unverified Commit e41e1715 authored by yunzhoul-nv's avatar yunzhoul-nv Committed by GitHub
Browse files

feat: adds support to pass local tokenizer path (#8128)


Signed-off-by: default avatarYunzhou Liu <232973175+yunzhoul-nv@users.noreply.github.com>
parent 3acdc0f8
...@@ -302,7 +302,7 @@ async def init_llm_worker( ...@@ -302,7 +302,7 @@ async def init_llm_worker(
module_path, class_name = tokenizer_path.rsplit(".", 1) module_path, class_name = tokenizer_path.rsplit(".", 1)
tokenizer_class = getattr(import_module(module_path), class_name) tokenizer_class = getattr(import_module(module_path), class_name)
tokenizer = tokenizer_class.from_pretrained( tokenizer = tokenizer_class.from_pretrained(
arg_map["model"], arg_map.get("tokenizer") or arg_map["model"],
trust_remote_code=arg_map.get("trust_remote_code", False), trust_remote_code=arg_map.get("trust_remote_code", False),
) )
except (ValueError, ImportError, AttributeError) as e: except (ValueError, ImportError, AttributeError) as e:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment