Skip to content

Commit cb64336

Browse files
authored
Feat/update prompt (#698)
* feat: update prompt for playground * feat: add promot * feat :fix * feat: add warning * feat: upadte * feat: update
1 parent d210235 commit cb64336

File tree

2 files changed

+4
-7
lines changed

2 files changed

+4
-7
lines changed

src/memos/templates/mos_prompts.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,6 @@
121121
- Brackets MUST be English half-width square brackets `[]`, NEVER use Chinese full-width brackets `【】` or any other symbols.
122122
- **When a sentence draws on an assistant/other-party memory**, mark the role in the sentence (“The assistant suggests…”) and add the corresponding citation at the end per this rule; e.g., “The assistant suggests choosing a midi dress and visiting COS in Guomao. [1:abc123]”
123123
- For preferences, do not mention the source in the response, do not appear `[Explicit preference]`, `[Implicit preference]`, `(Explicit preference)` or `(Implicit preference)` in the response
124-
- In the thinking mode (think), also strictly use the citation format `[i:memId]`,`i` is the order in the "Memories" section below (starting at 1). `memId` is the given short memory ID. The same as the response format.
125124
126125
# Current Date: {date}
127126
@@ -171,8 +170,6 @@
171170
- **OuterMemory[O]**: External information retrieved from the internet and other sources
172171
- Some user queries may be related to OuterMemory[O] content that is NOT about the user's personal information. Do not use such OuterMemory[O] to answer questions about the user themselves.
173172
174-
##warning
175-
- In thinking information (think), do not appear the reference number and id etc. in the response, otherwise it will cause reference error.
176173
"""
177174

178175
MEMOS_PRODUCT_BASE_PROMPT_ZH = """
@@ -233,7 +230,6 @@
233230
- 方括号必须是英文半角方括号`[]`,绝不使用中文全角括号`【】`或任何其他符号。
234231
- **当句子引用助手/其他方记忆时**,在句子中标注角色("助手建议…")并根据此规则在句尾添加相应引用;例如,"助手建议选择中长裙并访问国贸的COS。[1:abc123]"
235232
- 对于偏好,不要在回答中标注来源,不要出现`[显式偏好]`或`[隐式偏好]`或`(显式偏好)`或`(隐式偏好)`的字样
236-
- 在思考模式下(think),也需要严格采用引用格式`[i:memId]`,`i`是下面"记忆"部分中的顺序(从1开始)。`memId`是给定的短记忆ID。与回答要求一致
237233
238234
# 当前日期:{date}
239235
@@ -282,9 +278,6 @@
282278
- **个人记忆[P]**:来自先前交互的用户特定记忆和信息
283279
- **外部记忆[O]**:从互联网和其他来源检索的外部信息
284280
- 某些用户查询可能与外部记忆[O]内容相关,但这些内容并非关于用户的个人信息。不要使用此类外部记忆[O]来回答关于用户自身的问题。
285-
286-
##警告
287-
- 思考内容(think)里面输出不准出现引用的序号以及id等标记,否则会导致引用错误
288281
"""
289282

290283

src/memos/templates/prefer_complete_prompt.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -681,11 +681,15 @@
681681
# Note:
682682
Fact memory are summaries of facts, while preference memory are summaries of user preferences.
683683
Your response must not violate any of the user's preferences, whether explicit or implicit, and briefly explain why you answer this way to avoid conflicts.
684+
#warning
685+
- In thinking content, do not appear the reference number and id [1,2,3]etc. otherwise it will cause reference error.
684686
"""
685687

686688

687689
PREF_INSTRUCTIONS_ZH = """
688690
# 注意:
689691
事实记忆是事实的摘要,而偏好记忆是用户偏好的摘要。
690692
你的回复不得违反用户的任何偏好,无论是显式偏好还是隐式偏好,并简要解释你为什么这样回答以避免冲突。
693+
# 注意
694+
- 在思考内容中,不要出现引用序号和id [1,2,3]等标记,否则会导致引用错误。
691695
"""

0 commit comments

Comments
 (0)