mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-02 13:18:18 +00:00
Fix system prompt to make openai reasoning models md format response
This commit is contained in:
@@ -181,9 +181,10 @@ def llm_thread(
|
||||
]
|
||||
if len(system_messages) > 0:
|
||||
first_system_message_index, first_system_message = system_messages[0]
|
||||
first_system_message_content = first_system_message["content"]
|
||||
formatted_messages[first_system_message_index][
|
||||
"content"
|
||||
] = f"{first_system_message} Formatting re-enabled"
|
||||
] = f"{first_system_message_content}\nFormatting re-enabled"
|
||||
elif is_twitter_reasoning_model(model_name, api_base_url):
|
||||
reasoning_effort = "high" if deepthought else "low"
|
||||
model_kwargs["reasoning_effort"] = reasoning_effort
|
||||
|
||||
Reference in New Issue
Block a user