Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
hhaAndroid committed Jun 21, 2024
1 parent 95827b0 commit fe877c1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion xtuner/dataset/map_fns/template_map_fn.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ def template_map_fn(example, template):
if system != '' and system is not None:
system = template.SYSTEM.format(system=system)
input_text = system + input_text

single_turn_conversation['input'] = input_text

if template.get('SUFFIX', None):
Expand Down
2 changes: 1 addition & 1 deletion xtuner/utils/templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
SEP='\n',
STOP_WORDS=['<eoa>']),
internlm2_chat=dict(
SYSTEM='<|im_start|>system\n{system}\n',
SYSTEM='<|im_start|>system\n{system}<|im_end|>\n',
INSTRUCTION=('<|im_start|>user\n{input}<|im_end|>\n'
'<|im_start|>assistant\n'),
SUFFIX='<|im_end|>',
Expand Down

0 comments on commit fe877c1

Please sign in to comment.