model_support.remote_code

model_support.remote_code

Serve a model’s remote-code classes from an in-tree package.

Functions

Name Description
owned_stem Exact-stem match: a sibling remote module such as modeling_kimi_vl
redirect_dynamic_modules Resolve stems from package whenever transformers loads remote code.

owned_stem

model_support.remote_code.owned_stem(stems, module_path)

Exact-stem match: a sibling remote module such as modeling_kimi_vl must fall through to the original loader.

redirect_dynamic_modules

model_support.remote_code.redirect_dynamic_modules(package, stems)

Resolve stems from package whenever transformers loads remote code.