memory-eternal 0.18.0 → 0.18.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://anthropic.com/claude-code/plugin.schema.json",
3
3
  "name": "memory-eternal",
4
- "version": "0.18.0",
4
+ "version": "0.18.1",
5
5
  "description": "记忆核心(Memory Eternal):对话结束后自动沉淀知识卡到本地记忆库(~/.dsh/memory-vault),支持检索 / 召回 / 审核中心。",
6
6
  "author": {
7
7
  "name": "EternalNight996",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "memory-eternal",
3
- "version": "0.18.0",
3
+ "version": "0.18.1",
4
4
  "description": "记忆核心(Memory Eternal):对话结束后自动沉淀知识卡到本地记忆库(~/.dsh/memory-vault),支持检索 / 召回 / 审核中心。",
5
5
  "author": {
6
6
  "name": "EternalNight996",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "memory-eternal",
3
- "version": "0.18.0",
3
+ "version": "0.18.1",
4
4
  "description": "记忆核心(Memory Eternal):对话结束后自动沉淀知识卡到本地记忆库(~/.dsh/memory-vault),支持检索 / 召回 / 审核中心。",
5
5
  "author": {
6
6
  "name": "EternalNight996",
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  [![GitHub stars](https://img.shields.io/github/stars/EternalNight996/memory-eternal?style=flat)](https://github.com/EternalNight996/memory-eternal/stargazers)
4
4
  [![npm](https://img.shields.io/npm/v/memory-eternal)](https://www.npmjs.com/package/memory-eternal)
5
- [![release](https://img.shields.io/badge/release-v0.18.0-FF7A45)](https://github.com/EternalNight996/memory-eternal/releases)
5
+ [![release](https://img.shields.io/badge/release-v0.18.1-FF7A45)](https://github.com/EternalNight996/memory-eternal/releases)
6
6
  [![license](https://img.shields.io/badge/license-MIT-blue)](LICENSE)
7
7
 
8
8
  **English (default)** · [简体中文](README.zh-CN.md)
package/README.zh-CN.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  [![GitHub stars](https://img.shields.io/github/stars/EternalNight996/memory-eternal?style=flat)](https://github.com/EternalNight996/memory-eternal/stargazers)
4
4
  [![npm](https://img.shields.io/npm/v/memory-eternal)](https://www.npmjs.com/package/memory-eternal)
5
- [![release](https://img.shields.io/badge/release-v0.18.0-FF7A45)](https://github.com/EternalNight996/memory-eternal/releases)
5
+ [![release](https://img.shields.io/badge/release-v0.18.1-FF7A45)](https://github.com/EternalNight996/memory-eternal/releases)
6
6
  [![license](https://img.shields.io/badge/license-MIT-blue)](LICENSE)
7
7
 
8
8
  [English (default)](README.md) · **简体中文(镜像)**
@@ -2,7 +2,7 @@
2
2
  "name": "memory-eternal",
3
3
  "displayName": "Memory Atlas",
4
4
  "description": "Memory-eternal: open the local Memory Atlas library, review queue and knowledge graph in a Cursor/VS Code webview.",
5
- "version": "0.18.0",
5
+ "version": "0.18.1",
6
6
  "publisher": "EternalNight996",
7
7
  "license": "MIT",
8
8
  "repository": {
@@ -2,7 +2,7 @@
2
2
  "$schema": "urn:dsh-std:community-draft:dsh-plugin:0.15",
3
3
  "id": "memory-eternal-tui",
4
4
  "name": "memory-eternal-tui",
5
- "version": "0.18.0",
5
+ "version": "0.18.1",
6
6
  "manifestVersion": "0.15",
7
7
  "description": "Open Memory Atlas from dsh-TUI: native /audit scene plus browser launcher.",
8
8
  "facets": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "memory-eternal-tui",
3
- "version": "0.18.0",
3
+ "version": "0.18.1",
4
4
  "description": "Memory Atlas for dsh-TUI: /audit scene with reason/severity, batch confirmation and reject reasons.",
5
5
  "type": "module",
6
6
  "main": "main.js",
package/index.js CHANGED
@@ -58,6 +58,8 @@ export const Config = z.object({
58
58
  coreMemoryEnabled: z.boolean().default(true),
59
59
  coreMemoryLimit: z.number().min(1).max(20).default(6),
60
60
  coreMemoryMaxChars: z.number().min(200).max(10000).default(2000),
61
+ // 记忆界面整体布局大小:compact / normal / large(只影响 UI,不影响召回)
62
+ uiScale: z.union([z.const('compact'), z.const('normal'), z.const('large')]).default('normal'),
61
63
  vaultDir: z.string().default(''),
62
64
  dedupThreshold: z.number().min(0).max(1).default(0.62),
63
65
  captureMinChars: z.number().default(200),
@@ -1272,7 +1274,7 @@ export function apply(ctx, config) {
1272
1274
  const cfg = settings.get() ?? {}
1273
1275
  // 只暴露可安全展示/回填的字段
1274
1276
  const safe = {
1275
- autoCapture: cfg.autoCapture, autoRecall: cfg.autoRecall, coreMemoryEnabled: cfg.coreMemoryEnabled, coreMemoryLimit: cfg.coreMemoryLimit, coreMemoryMaxChars: cfg.coreMemoryMaxChars, recallLimit: cfg.recallLimit, recallSummaryLen: cfg.recallSummaryLen, recallIncludeBody: cfg.recallIncludeBody, secretHint: cfg.secretHint || '',
1277
+ autoCapture: cfg.autoCapture, autoRecall: cfg.autoRecall, coreMemoryEnabled: cfg.coreMemoryEnabled, coreMemoryLimit: cfg.coreMemoryLimit, coreMemoryMaxChars: cfg.coreMemoryMaxChars, uiScale: cfg.uiScale, recallLimit: cfg.recallLimit, recallSummaryLen: cfg.recallSummaryLen, recallIncludeBody: cfg.recallIncludeBody, secretHint: cfg.secretHint || '',
1276
1278
  captureMinChars: cfg.captureMinChars, captureCooldownMs: cfg.captureCooldownMs, dedupThreshold: cfg.dedupThreshold, maxCardsPerDay: cfg.maxCardsPerDay,
1277
1279
  distillEnabled: cfg.distillEnabled, dedupByLLM: cfg.dedupByLLM, captureMaxTokens: cfg.captureMaxTokens, recallMinScore: cfg.recallMinScore,
1278
1280
  autoWeb: cfg.autoWeb, autoWebMode: cfg.autoWebMode, webPort: cfg.webPort, webCheckIntervalMs: cfg.webCheckIntervalMs, webMaxRestart: cfg.webMaxRestart, watchdogAutoSpawn: cfg.watchdogAutoSpawn, autoRestartOnDrift: cfg.autoRestartOnDrift, autoMcpSetup: cfg.autoMcpSetup,
@@ -1421,6 +1423,14 @@ export function apply(ctx, config) {
1421
1423
  const cfg0 = settings.get() ?? {}
1422
1424
  if (cfg0.enabled === false) return () => {}
1423
1425
 
1426
+ // (0) issue #53 自动迁移:只修我们自己写过、且指向 Electron 宿主 exe 的旧条目。
1427
+ // 必须在 Electron 宿主里才有旧配置;普通 node 进程/测试不碰真实 home。
1428
+ if (process.versions.electron && process.env.MEMORY_ETERNAL_SKIP_AUTO !== '1') {
1429
+ import('./lib/setup.js')
1430
+ .then((m) => m.repairLegacySetup({ log: (msg) => console.log('[memory-eternal] ' + msg) }))
1431
+ .catch(() => {})
1432
+ }
1433
+
1424
1434
  // (1) MCP 自动挂载:默认关闭;只有用户显式开启才动外部配置。
1425
1435
  if (cfg0.autoMcpSetup === true && process.env.MEMORY_ETERNAL_SKIP_AUTO !== '1') {
1426
1436
  import('./lib/setup.js')
package/lib/api.js CHANGED
@@ -1038,7 +1038,7 @@ export function createApi(deps = {}) {
1038
1038
  const cfg = getSettings() ?? {}
1039
1039
  const env = typeof process !== 'undefined' ? process.env : {}
1040
1040
  const safe = {
1041
- autoCapture: cfg.autoCapture ?? true, autoRecall: cfg.autoRecall ?? true, coreMemoryEnabled: cfg.coreMemoryEnabled ?? true, coreMemoryLimit: cfg.coreMemoryLimit ?? 6, coreMemoryMaxChars: cfg.coreMemoryMaxChars ?? 2000, recallLimit: cfg.recallLimit ?? 5, recallSummaryLen: cfg.recallSummaryLen ?? 130, recallIncludeBody: cfg.recallIncludeBody ?? false, secretHint: cfg.secretHint || '',
1041
+ autoCapture: cfg.autoCapture ?? true, autoRecall: cfg.autoRecall ?? true, coreMemoryEnabled: cfg.coreMemoryEnabled ?? true, coreMemoryLimit: cfg.coreMemoryLimit ?? 6, coreMemoryMaxChars: cfg.coreMemoryMaxChars ?? 2000, uiScale: cfg.uiScale || 'normal', recallLimit: cfg.recallLimit ?? 5, recallSummaryLen: cfg.recallSummaryLen ?? 130, recallIncludeBody: cfg.recallIncludeBody ?? false, secretHint: cfg.secretHint || '',
1042
1042
  captureMinChars: cfg.captureMinChars ?? 200, captureCooldownMs: cfg.captureCooldownMs ?? 300000, dedupThreshold: cfg.dedupThreshold ?? 0.62, maxCardsPerDay: cfg.maxCardsPerDay ?? 60,
1043
1043
  distillEnabled: cfg.distillEnabled ?? true, dedupByLLM: cfg.dedupByLLM ?? true, captureMaxTokens: cfg.captureMaxTokens ?? DEFAULT_CAPTURE_MAX_TOKENS, recallMinScore: cfg.recallMinScore ?? 2,
1044
1044
  autoWeb: cfg.autoWeb ?? env.MEMORY_AUTO_WEB !== '0', autoWebMode: cfg.autoWebMode || 'init', webPort: Number(cfg.webPort) || Number(env.MEMORY_WEB_PORT) || 7999, webCheckIntervalMs: Number(cfg.webCheckIntervalMs) || 5000, webMaxRestart: Number(cfg.webMaxRestart) || 10, watchdogAutoSpawn: cfg.watchdogAutoSpawn ?? env.MEMORY_WATCHDOG === '1', autoRestartOnDrift: cfg.autoRestartOnDrift ?? true, autoMcpSetup: cfg.autoMcpSetup ?? false,