Aye10032
commited on
Commit
·
460b909
1
Parent(s):
060411c
修改提示词
Browse files
pages/AcademicTranslate.py
CHANGED
@@ -39,7 +39,9 @@ def ac_translate(original_text: str, is_en2zh: bool):
|
|
39 |
if is_en2zh:
|
40 |
_prompt = ChatPromptTemplate.from_messages(
|
41 |
[
|
42 |
-
SystemMessage(content="
|
|
|
|
|
43 |
("human", "这是你需要翻译的句子:\n{original_text}\n\n注意你的回答只需要给出翻译后的英文文本,不要包含其他东西")
|
44 |
]
|
45 |
)
|
|
|
39 |
if is_en2zh:
|
40 |
_prompt = ChatPromptTemplate.from_messages(
|
41 |
[
|
42 |
+
SystemMessage(content="你的任务是将用户给出的英文文本翻译为**语句通顺的**中文,同时务必注意不能漏翻或错翻。"
|
43 |
+
"对于专有名词或公式等,若没有合适的译文可以保留原本英文文本不做翻译。"
|
44 |
+
"对于原句子中被markdown代码块或latex公式包裹的内容,不做改动原样返回。"),
|
45 |
("human", "这是你需要翻译的句子:\n{original_text}\n\n注意你的回答只需要给出翻译后的英文文本,不要包含其他东西")
|
46 |
]
|
47 |
)
|