Skip to content

Commit

Permalink
feat(model): Fix chatgpt message format bug (eosphoros-ai#1028)
Browse files Browse the repository at this point in the history
  • Loading branch information
fangyinc authored and Hopshine committed Sep 10, 2024
1 parent 652062e commit 21a1734
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion dbgpt/model/proxy/llms/chatgpt.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,8 @@ def _build_request(model: ProxyModel, params):

messages: List[ModelMessage] = params["messages"]

history = __convert_2_gpt_messages(messages)
# history = __convert_2_gpt_messages(messages)
history = ModelMessage.to_openai_messages(messages)
payloads = {
"temperature": params.get("temperature"),
"max_tokens": params.get("max_new_tokens"),
Expand Down

0 comments on commit 21a1734

Please sign in to comment.