例如,我想要给CHATGPT一个身份设定:以一个老师的身份,温馨亲切的口气回答问题。
在openai的文档里,可以在"role": "system", "content":中设置。
但是看了大神您的动作,不知道该怎么设置呢。或者能否告知该如何设置?或者辛苦添加一个身份设定的选项?
openai.ChatCompletion.create(
model="gpt-3.5-turbo",
messages=[
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Who won the world series in 2020?"},
{"role": "assistant", "content": "The Los Angeles Dodgers won the World Series in 2020."},
{"role": "user", "content": "Where was it played?"}
]
)
抱歉,最近比较忙,我有空研究下,你试过语言引导吗,和这个差别大吗