优化提示词

This commit is contained in:
xunbu
2025-08-23 14:06:26 +08:00
parent cdceccdbed
commit 15748f0f2f
2 changed files with 2 additions and 2 deletions

View File

@@ -49,4 +49,4 @@ Output:
$$1+1=2$$ $$1+1=2$$
\\((c_0,c_1,c_2^2)\\)是一个坐标。""" \\((c_0,c_1,c_2^2)\\)是一个坐标。"""
if config.custom_prompt: if config.custom_prompt:
self.system_prompt += "\n# 重要规则或背景【非常重要】\n" + config.custom_prompt + '\n' self.system_prompt += "\n# Important rules or background\n" + config.custom_prompt + '\n'

View File

@@ -44,7 +44,7 @@ Output
Warning: Never wrap the entire JSON object in quotes to make it a single string. Never wrap the JSON text in ```. Warning: Never wrap the entire JSON object in quotes to make it a single string. Never wrap the JSON text in ```.
""" """
if config.custom_prompt: if config.custom_prompt:
self.system_prompt += "\n# 重要规则或背景【非常重要】\n" + config.custom_prompt + '\n' self.system_prompt += "\n# Important rules or background for segments for translation\n" + config.custom_prompt + '\n'
def _result_handler(self, result: str, origin_prompt: str, logger: Logger): def _result_handler(self, result: str, origin_prompt: str, logger: Logger):
try: try: