1- // Manual /dream skill — runs the memory consolidation prompt interactively.
2- // Extracted from the KAIROS feature gate so it's available unconditionally
3- // whenever auto-memory is enabled.
1+ // 手动 /dream 技能 — 交互式运行记忆整合提示词。
2+ // 从 KAIROS 功能门控中提取,只要启用了自动记忆功能即可无条件使用。
43
54import { getAutoMemPath , isAutoMemoryEnabled } from '../../memdir/paths.js'
65import { buildConsolidationPrompt } from '../../services/autoDream/consolidationPrompt.js'
@@ -9,33 +8,33 @@ import { getOriginalCwd } from '../../bootstrap/state.js'
98import { getProjectDir } from '../../utils/sessionStorage.js'
109import { registerBundledSkill } from '../bundledSkills.js'
1110
12- const DREAM_PROMPT_PREFIX = `# Dream: Memory Consolidation (manual run)
11+ const DREAM_PROMPT_PREFIX = `# Dream: 记忆整合(手动运行)
1312
14- You are performing a manual dream — a reflective pass over your memory files. Unlike the automatic background dream, this run has full tool permissions and the user is watching. Synthesize what you've learned recently into durable, well-organized memories so that future sessions can orient quickly.
13+ 你正在执行一次手动 dream — 对你的记忆文件进行回顾性整理。与自动后台 dream 不同,本次运行拥有完整的工具权限,且用户正在观看。将最近学到的内容整合为持久、有条理的记忆,以便未来的会话能够快速定位。
1514
1615`
1716
1817export function registerDreamSkill ( ) : void {
1918 registerBundledSkill ( {
2019 name : 'dream' ,
2120 description :
22- 'Manually trigger memory consolidation — review, organize, and prune your auto-memory files. ' ,
21+ '手动触发记忆整合 — 审查、整理和清理你的自动记忆文件。 ' ,
2322 whenToUse :
24- 'Use when the user says /dream or wants to manually consolidate memories, organize memory files, or clean up stale entries. ' ,
23+ '当用户说 /dream 或希望手动整合记忆、整理记忆文件或清理过时条目时使用。 ' ,
2524 userInvocable : true ,
2625 isEnabled : ( ) => isAutoMemoryEnabled ( ) ,
2726 async getPromptForCommand ( args ) {
2827 const memoryRoot = getAutoMemPath ( )
2928 const transcriptDir = getProjectDir ( getOriginalCwd ( ) )
3029
31- // Stamp the consolidation lock optimistically (same as the KAIROS path).
30+ // 乐观地标记整合锁定(与 KAIROS 路径相同)。
3231 await recordConsolidation ( )
3332
3433 const basePrompt = buildConsolidationPrompt ( memoryRoot , transcriptDir , '' )
3534 let prompt = DREAM_PROMPT_PREFIX + basePrompt
3635
3736 if ( args ) {
38- prompt += `\n\n## Additional context from user \n\n${ args } `
37+ prompt += `\n\n## 用户提供的额外上下文 \n\n${ args } `
3938 }
4039
4140 return [ { type : 'text' , text : prompt } ]
0 commit comments