mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-13 02:41:50 +08:00
feat: Implement core memory management with knowledge graph and evolution tracking
- Added core-memory.js and core-memory-graph.js for managing core memory views and visualizations. - Introduced functions for viewing knowledge graphs and evolution history of memories. - Implemented modal dialogs for creating, editing, and viewing memory details. - Developed core-memory.ts for backend operations including list, import, export, and summary generation. - Integrated Zod for parameter validation in core memory operations. - Enhanced UI with dynamic rendering of memory cards and detailed views.
This commit is contained in:
@@ -29,6 +29,7 @@ const i18n = {
|
||||
'nav.history': 'History',
|
||||
'nav.memory': 'Memory',
|
||||
'nav.contextMemory': 'Context',
|
||||
'nav.coreMemory': 'Core Memory',
|
||||
'nav.promptHistory': 'Prompts',
|
||||
|
||||
// Sidebar - Sessions section
|
||||
@@ -287,6 +288,30 @@ const i18n = {
|
||||
'codexlens.indexSuccess': 'Index created successfully',
|
||||
'codexlens.indexFailed': 'Indexing failed',
|
||||
|
||||
// Index Manager
|
||||
'index.manager': 'Index Manager',
|
||||
'index.projects': 'Projects',
|
||||
'index.totalSize': 'Total Size',
|
||||
'index.vectorIndexes': 'Vector',
|
||||
'index.ftsIndexes': 'FTS',
|
||||
'index.projectId': 'Project ID',
|
||||
'index.size': 'Size',
|
||||
'index.type': 'Type',
|
||||
'index.lastModified': 'Modified',
|
||||
'index.vector': 'Vector',
|
||||
'index.fts': 'FTS',
|
||||
'index.noIndexes': 'No indexes yet',
|
||||
'index.notConfigured': 'Not configured',
|
||||
'index.initCurrent': 'Init Current Project',
|
||||
'index.cleanAll': 'Clean All',
|
||||
'index.cleanProject': 'Clean Index',
|
||||
'index.cleanProjectConfirm': 'Clean index for',
|
||||
'index.cleaning': 'Cleaning index...',
|
||||
'index.cleanSuccess': 'Index cleaned successfully',
|
||||
'index.cleanFailed': 'Clean failed',
|
||||
'index.cleanAllConfirm': 'Are you sure you want to clean ALL indexes? This cannot be undone.',
|
||||
'index.cleanAllSuccess': 'All indexes cleaned',
|
||||
|
||||
// Semantic Search Configuration
|
||||
'semantic.settings': 'Semantic Search Settings',
|
||||
'semantic.testSearch': 'Test Semantic Search',
|
||||
@@ -294,7 +319,19 @@ const i18n = {
|
||||
'semantic.runSearch': 'Run Semantic Search',
|
||||
'semantic.close': 'Close',
|
||||
|
||||
'cli.settings': 'CLI Execution Settings',
|
||||
'cli.settings': 'Settings',
|
||||
|
||||
// Language Settings
|
||||
'lang.settings': 'Response Language',
|
||||
'lang.settingsDesc': 'Configure Claude response language preference',
|
||||
'lang.chinese': 'Chinese Response',
|
||||
'lang.chineseDesc': 'Enable Chinese response guidelines in global CLAUDE.md',
|
||||
'lang.enabled': 'Enabled',
|
||||
'lang.disabled': 'Disabled',
|
||||
'lang.enableSuccess': 'Chinese response enabled',
|
||||
'lang.disableSuccess': 'Chinese response disabled',
|
||||
'lang.enableFailed': 'Failed to enable Chinese response',
|
||||
'lang.disableFailed': 'Failed to disable Chinese response',
|
||||
'cli.promptFormat': 'Prompt Format',
|
||||
'cli.promptFormatDesc': 'Format for multi-turn conversation concatenation',
|
||||
'cli.storageBackend': 'Storage Backend',
|
||||
@@ -1060,15 +1097,17 @@ const i18n = {
|
||||
'graph.searchProcessDesc': 'Visualize how search queries flow through the system',
|
||||
'graph.searchProcessTitle': 'Search Pipeline',
|
||||
'graph.resultsFound': 'results found',
|
||||
'graph.coreMemory': 'Core Memory',
|
||||
'graph.dataSourceSwitched': 'Data source switched',
|
||||
'graph.type': 'Type',
|
||||
'graph.line': 'Line',
|
||||
'graph.path': 'Path',
|
||||
'graph.depth': 'Depth',
|
||||
'graph.exports': 'Exports',
|
||||
'graph.imports': 'Imports',
|
||||
'graph.references': 'References',
|
||||
'graph.symbolType': 'Symbol Type',
|
||||
'graph.path': 'Path',
|
||||
'graph.line': 'Line',
|
||||
'graph.imports': 'imports',
|
||||
'graph.exports': 'exports',
|
||||
'graph.references': 'references',
|
||||
'graph.affectedSymbols': 'Affected Symbols',
|
||||
'graph.depth': 'Depth',
|
||||
|
||||
// CLI Sync (used in claude-manager.js)
|
||||
'claude.cliSync': 'CLI Auto-Sync',
|
||||
@@ -1131,6 +1170,56 @@ const i18n = {
|
||||
'common.saveFailed': 'Failed to save',
|
||||
'common.unknownError': 'Unknown error',
|
||||
'common.exception': 'Exception',
|
||||
|
||||
// Core Memory
|
||||
'title.coreMemory': 'Core Memory',
|
||||
'coreMemory.createNew': 'Create Memory',
|
||||
'coreMemory.showArchived': 'Show Archived',
|
||||
'coreMemory.showActive': 'Show Active',
|
||||
'coreMemory.totalMemories': 'Total Memories',
|
||||
'coreMemory.noMemories': 'No memories found',
|
||||
'coreMemory.noArchivedMemories': 'No archived memories',
|
||||
'coreMemory.content': 'Content',
|
||||
'coreMemory.contentPlaceholder': 'Enter strategic context, insights, or important information...',
|
||||
'coreMemory.contentRequired': 'Content is required',
|
||||
'coreMemory.summary': 'Summary',
|
||||
'coreMemory.summaryPlaceholder': 'Optional: Brief summary of this memory...',
|
||||
'coreMemory.metadata': 'Metadata',
|
||||
'coreMemory.invalidMetadata': 'Invalid JSON metadata',
|
||||
'coreMemory.rawOutput': 'Raw Output',
|
||||
'coreMemory.created': 'Memory created successfully',
|
||||
'coreMemory.updated': 'Memory updated successfully',
|
||||
'coreMemory.archived': 'Memory archived successfully',
|
||||
'coreMemory.unarchived': 'Memory unarchived successfully',
|
||||
'coreMemory.deleted': 'Memory deleted successfully',
|
||||
'coreMemory.confirmArchive': 'Archive this memory?',
|
||||
'coreMemory.confirmDelete': 'Permanently delete this memory?',
|
||||
'coreMemory.fetchError': 'Failed to fetch memories',
|
||||
'coreMemory.saveError': 'Failed to save memory',
|
||||
'coreMemory.archiveError': 'Failed to archive memory',
|
||||
'coreMemory.unarchiveError': 'Failed to unarchive memory',
|
||||
'coreMemory.deleteError': 'Failed to delete memory',
|
||||
'coreMemory.edit': 'Edit Memory',
|
||||
'coreMemory.unarchive': 'Unarchive',
|
||||
'coreMemory.generateSummary': 'Generate Summary',
|
||||
'coreMemory.generatingSummary': 'Generating summary...',
|
||||
'coreMemory.summaryGenerated': 'Summary generated successfully',
|
||||
'coreMemory.summaryError': 'Failed to generate summary',
|
||||
'coreMemory.knowledgeGraph': 'Knowledge Graph',
|
||||
'coreMemory.graph': 'Graph',
|
||||
'coreMemory.entities': 'Entities',
|
||||
'coreMemory.noEntities': 'No entities found',
|
||||
'coreMemory.relationships': 'Relationships',
|
||||
'coreMemory.noRelationships': 'No relationships found',
|
||||
'coreMemory.graphError': 'Failed to load knowledge graph',
|
||||
'coreMemory.evolution': 'Evolution',
|
||||
'coreMemory.evolutionHistory': 'Evolution History',
|
||||
'coreMemory.noHistory': 'No evolution history',
|
||||
'coreMemory.noReason': 'No reason provided',
|
||||
'coreMemory.current': 'Current',
|
||||
'coreMemory.evolutionError': 'Failed to load evolution history',
|
||||
'coreMemory.created': 'Created',
|
||||
'coreMemory.updated': 'Updated',
|
||||
},
|
||||
|
||||
zh: {
|
||||
@@ -1154,6 +1243,7 @@ const i18n = {
|
||||
'nav.history': '历史',
|
||||
'nav.memory': '记忆',
|
||||
'nav.contextMemory': '活动',
|
||||
'nav.coreMemory': '核心记忆',
|
||||
'nav.promptHistory': '洞察',
|
||||
|
||||
// Sidebar - Sessions section
|
||||
@@ -1412,6 +1502,30 @@ const i18n = {
|
||||
'codexlens.indexSuccess': '索引创建成功',
|
||||
'codexlens.indexFailed': '索引失败',
|
||||
|
||||
// 索引管理器
|
||||
'index.manager': '索引管理器',
|
||||
'index.projects': '项目数',
|
||||
'index.totalSize': '总大小',
|
||||
'index.vectorIndexes': '向量',
|
||||
'index.ftsIndexes': '全文',
|
||||
'index.projectId': '项目 ID',
|
||||
'index.size': '大小',
|
||||
'index.type': '类型',
|
||||
'index.lastModified': '修改时间',
|
||||
'index.vector': '向量',
|
||||
'index.fts': '全文',
|
||||
'index.noIndexes': '暂无索引',
|
||||
'index.notConfigured': '未配置',
|
||||
'index.initCurrent': '索引当前项目',
|
||||
'index.cleanAll': '清理全部',
|
||||
'index.cleanProject': '清理索引',
|
||||
'index.cleanProjectConfirm': '清理索引:',
|
||||
'index.cleaning': '清理索引中...',
|
||||
'index.cleanSuccess': '索引清理成功',
|
||||
'index.cleanFailed': '清理失败',
|
||||
'index.cleanAllConfirm': '确定要清理所有索引吗?此操作无法撤销。',
|
||||
'index.cleanAllSuccess': '所有索引已清理',
|
||||
|
||||
// Semantic Search 配置
|
||||
'semantic.settings': '语义搜索设置',
|
||||
'semantic.testSearch': '测试语义搜索',
|
||||
@@ -1419,7 +1533,19 @@ const i18n = {
|
||||
'semantic.runSearch': '运行语义搜索',
|
||||
'semantic.close': '关闭',
|
||||
|
||||
'cli.settings': 'CLI 调用设置',
|
||||
'cli.settings': '设置',
|
||||
|
||||
// 语言设置
|
||||
'lang.settings': '回复语言',
|
||||
'lang.settingsDesc': '配置 Claude 回复语言偏好',
|
||||
'lang.chinese': '中文回复',
|
||||
'lang.chineseDesc': '在全局 CLAUDE.md 中启用中文回复准则',
|
||||
'lang.enabled': '已启用',
|
||||
'lang.disabled': '已禁用',
|
||||
'lang.enableSuccess': '中文回复已启用',
|
||||
'lang.disableSuccess': '中文回复已禁用',
|
||||
'lang.enableFailed': '启用中文回复失败',
|
||||
'lang.disableFailed': '禁用中文回复失败',
|
||||
'cli.promptFormat': '提示词格式',
|
||||
'cli.promptFormatDesc': '多轮对话拼接格式',
|
||||
'cli.storageBackend': '存储后端',
|
||||
@@ -2163,6 +2289,8 @@ const i18n = {
|
||||
'graph.searchProcessDesc': '可视化搜索查询在系统中的流转过程',
|
||||
'graph.searchProcessTitle': '搜索管道',
|
||||
'graph.resultsFound': '个结果',
|
||||
'graph.coreMemory': '核心记忆',
|
||||
'graph.dataSourceSwitched': '数据源已切换',
|
||||
'graph.type': '类型',
|
||||
'graph.line': '行号',
|
||||
'graph.path': '路径',
|
||||
@@ -2265,6 +2393,56 @@ const i18n = {
|
||||
'common.saveFailed': '保存失败',
|
||||
'common.unknownError': '未知错误',
|
||||
'common.exception': '异常',
|
||||
|
||||
// Core Memory
|
||||
'title.coreMemory': '核心记忆',
|
||||
'coreMemory.createNew': '创建记忆',
|
||||
'coreMemory.showArchived': '显示已归档',
|
||||
'coreMemory.showActive': '显示活动',
|
||||
'coreMemory.totalMemories': '总记忆数',
|
||||
'coreMemory.noMemories': '未找到记忆',
|
||||
'coreMemory.noArchivedMemories': '没有已归档的记忆',
|
||||
'coreMemory.content': '内容',
|
||||
'coreMemory.contentPlaceholder': '输入战略性上下文、见解或重要信息...',
|
||||
'coreMemory.contentRequired': '内容为必填项',
|
||||
'coreMemory.summary': '摘要',
|
||||
'coreMemory.summaryPlaceholder': '可选:此记忆的简要摘要...',
|
||||
'coreMemory.metadata': '元数据',
|
||||
'coreMemory.invalidMetadata': '无效的 JSON 元数据',
|
||||
'coreMemory.rawOutput': '原始输出',
|
||||
'coreMemory.created': '记忆创建成功',
|
||||
'coreMemory.updated': '记忆更新成功',
|
||||
'coreMemory.archived': '记忆已归档',
|
||||
'coreMemory.unarchived': '记忆已取消归档',
|
||||
'coreMemory.deleted': '记忆已删除',
|
||||
'coreMemory.confirmArchive': '归档此记忆?',
|
||||
'coreMemory.confirmDelete': '永久删除此记忆?',
|
||||
'coreMemory.fetchError': '获取记忆失败',
|
||||
'coreMemory.saveError': '保存记忆失败',
|
||||
'coreMemory.archiveError': '归档记忆失败',
|
||||
'coreMemory.unarchiveError': '取消归档失败',
|
||||
'coreMemory.deleteError': '删除记忆失败',
|
||||
'coreMemory.edit': '编辑记忆',
|
||||
'coreMemory.unarchive': '取消归档',
|
||||
'coreMemory.generateSummary': '生成摘要',
|
||||
'coreMemory.generatingSummary': '正在生成摘要...',
|
||||
'coreMemory.summaryGenerated': '摘要生成成功',
|
||||
'coreMemory.summaryError': '生成摘要失败',
|
||||
'coreMemory.knowledgeGraph': '知识图谱',
|
||||
'coreMemory.graph': '图谱',
|
||||
'coreMemory.entities': '实体',
|
||||
'coreMemory.noEntities': '未找到实体',
|
||||
'coreMemory.relationships': '关系',
|
||||
'coreMemory.noRelationships': '未找到关系',
|
||||
'coreMemory.graphError': '加载知识图谱失败',
|
||||
'coreMemory.evolution': '演化',
|
||||
'coreMemory.evolutionHistory': '演化历史',
|
||||
'coreMemory.noHistory': '无演化历史',
|
||||
'coreMemory.noReason': '未提供原因',
|
||||
'coreMemory.current': '当前',
|
||||
'coreMemory.evolutionError': '加载演化历史失败',
|
||||
'coreMemory.created': '创建时间',
|
||||
'coreMemory.updated': '更新时间',
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user