MCPcopy
hub / github.com/yangjianxin1/Firefly / register_template

Function register_template

component/template.py:19–28  ·  view source on GitHub ↗
(template_name, system_format, user_format, assistant_format, system, stop_word=None)

Source from the content-addressed store, hash-verified

17
18
19def register_template(template_name, system_format, user_format, assistant_format, system, stop_word=None):
20 template_dict[template_name] = Template(
21 template_name=template_name,
22 system_format=system_format,
23 user_format=user_format,
24 assistant_format=assistant_format,
25 system=system,
26 stop_word=stop_word,
27 # stop_token_id=stop_token_id
28 )
29
30
31# 注册template

Callers 1

template.pyFile · 0.85

Calls 1

TemplateClass · 0.85

Tested by

no test coverage detected