Merge pull request #1402 from drahnreb/drahnreb/fix-prompt-formatting
fix: correct parentheses. `system_prompt` was never formatted.
This commit is contained in:
@@ -1195,9 +1195,8 @@ async def mix_kg_vector_query(
|
||||
|
||||
# 5. Construct hybrid prompt
|
||||
sys_prompt = (
|
||||
system_prompt
|
||||
if system_prompt
|
||||
else PROMPTS["mix_rag_response"].format(
|
||||
system_prompt if system_prompt else PROMPTS["mix_rag_response"]
|
||||
).format(
|
||||
kg_context=kg_context
|
||||
if kg_context
|
||||
else "No relevant knowledge graph information found",
|
||||
@@ -1207,7 +1206,6 @@ async def mix_kg_vector_query(
|
||||
response_type=query_param.response_type,
|
||||
history=history_context,
|
||||
)
|
||||
)
|
||||
|
||||
if query_param.only_need_prompt:
|
||||
return sys_prompt
|
||||
|
Reference in New Issue
Block a user