ms-swift icon indicating copy to clipboard operation
ms-swift copied to clipboard

react模板放在system和user的区别?

Open nauyiahc opened this issue 1 year ago • 1 comments

我发现qwen的原生agent的react是放在了user上,而swift官方提供的ms_agent的react放在了system中,这两者有何区别,或者哪种更好?

Qwen:

<|im_start|>system
You are a helpful assistant.<|im_end|>
<|im_start|>user
Answer the following questions as best you can. You have access to the following APIs

ms_agent

<|im_start|>system
Answer the following questions as best you can. You have access to the following APIs:

nauyiahc avatar May 30 '24 07:05 nauyiahc

或者说,我如果用ms_agent的格式去训练,那么就不能额外的添加系统指令了吧,会影响推理效果,比如将ms_agent的system改成如下:

<|im_start|>system
You are a helpful assistant.

Answer the following questions as best you can. You have access to the following APIs

nauyiahc avatar May 30 '24 07:05 nauyiahc

一般放在system中更好的 参考:https://swift.readthedocs.io/zh-cn/latest/LLM/Agent%E5%BE%AE%E8%B0%83%E6%9C%80%E4%BD%B3%E5%AE%9E%E8%B7%B5.html

tastelikefeet avatar Aug 28 '24 05:08 tastelikefeet