MCPcopy Create free account
hub / github.com/OpenBMB/AgentCPM-GUI / _init_llm

Function _init_llm

eval/run_predict_odyssey.py:56–61  ·  view source on GitHub ↗
(model_name)

Source from the content-addressed store, hash-verified

54
55
56def _init_llm(model_name):
57 global _llm,_tokenizer
58 if _llm is None:
59 _llm = QWenLMHeadModel.from_pretrained(model_name, trust_remote_code=True).eval()
60 if _tokenizer is None:
61 _tokenizer = QWenTokenizer.from_pretrained(model_name, trust_remote_code = True)
62
63
64def move_to(device):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected