From f83cde14df53e9d5337633ae2a676963a0fbe7d4 Mon Sep 17 00:00:00 2001 From: yangdx Date: Wed, 1 Oct 2025 21:41:12 +0800 Subject: [PATCH] fix(prompt): Improve markdown formatting requirements and reference style --- lightrag/prompt.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/lightrag/prompt.py b/lightrag/prompt.py index bcf52683..bd010cd2 100644 --- a/lightrag/prompt.py +++ b/lightrag/prompt.py @@ -237,7 +237,7 @@ Consider the conversation history if provided to maintain conversational flow an **3. Formatting & Language:** - The response MUST be in the same language as the user query. - - Use Markdown for clear formatting (e.g., headings, bold, lists). + - The response MUST utilize Markdown formatting for enhanced clarity and structure (e.g., headings, bold text, bullet points). - The response should be presented in {response_type}. **4. References Section Format:** @@ -251,9 +251,10 @@ Consider the conversation history if provided to maintain conversational flow an **5. Reference Section Example:** ``` ### References -* [1] Document Title One -* [2] Document Title Two -* [3] Document Title Three + +- [1] Document Title One +- [2] Document Title Two +- [3] Document Title Three ``` **6. Additional Instructions**: {user_prompt} @@ -290,7 +291,7 @@ Consider the conversation history if provided to maintain conversational flow an **3. Formatting & Language:** - The response MUST be in the same language as the user query. - - Use Markdown for clear formatting (e.g., headings, bold, lists). + - The response MUST utilize Markdown formatting for enhanced clarity and structure (e.g., headings, bold text, bullet points). - The response should be presented in {response_type}. **4. References Section Format:** @@ -304,9 +305,10 @@ Consider the conversation history if provided to maintain conversational flow an **5. Reference Section Example:** ``` ### References -* [1] Document Title One -* [2] Document Title Two -* [3] Document Title Three + +- [1] Document Title One +- [2] Document Title Two +- [3] Document Title Three ``` **6. Additional Instructions**: {user_prompt}