lume-dsh-plugin 0.4.5 → 0.6.0
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.
- package/LICENSE +21 -21
- package/README.md +305 -284
- package/assets/personalities/butler-corpus.jsonl +0 -0
- package/assets/personalities/butler.txt +0 -0
- package/assets/personalities/loli-corpus.jsonl +30 -30
- package/assets/personalities/loli.txt +12 -12
- package/assets/personalities/none-corpus.jsonl +0 -0
- package/assets/personalities/none.txt +0 -0
- package/assets/personalities/senpai-corpus.jsonl +30 -30
- package/assets/personalities/senpai.txt +12 -12
- package/assets/personalities/tsundere-corpus.jsonl +0 -0
- package/assets/personalities/tsundere.txt +0 -0
- package/assets/personalities.json +47 -47
- package/cordis.patch.yml +5 -5
- package/lib/client.js +0 -0
- package/lib/core/card.js +0 -0
- package/lib/core/dialogue-mining.js +0 -0
- package/lib/core/leak-detector.js +0 -0
- package/lib/core/manifest.js +0 -0
- package/lib/core/persona-text.js +0 -0
- package/lib/core/retrieval.js +0 -0
- package/lib/core/sampling.js +0 -0
- package/lib/core/text.js +0 -0
- package/lib/host/boundary.js +0 -0
- package/lib/host/compaction.js +33 -211
- package/lib/host/diag.js +25 -0
- package/lib/host/distill.js +12 -12
- package/lib/host/extraction.js +0 -0
- package/lib/host/identity.js +0 -0
- package/lib/host/injection.js +0 -0
- package/lib/host/personalities.js +0 -0
- package/lib/host/protocol.js +67 -9
- package/lib/host/reflection.js +0 -0
- package/lib/host/registry.js +0 -0
- package/lib/host/rpc.js +0 -0
- package/lib/host/session-runtime.js +3 -0
- package/lib/host/store.js +0 -0
- package/lib/host/thinking.js +40 -40
- package/lib/index.js +166 -41
- package/package.json +112 -120
package/lib/index.js
CHANGED
|
@@ -31,9 +31,10 @@ import { detectLeak } from "./core/leak-detector.js";
|
|
|
31
31
|
import { messageText } from "./core/text.js";
|
|
32
32
|
import { composeBoundary } from "./host/boundary.js";
|
|
33
33
|
import { SessionRuntimeStore } from "./host/session-runtime.js";
|
|
34
|
-
import {
|
|
34
|
+
import { isCompactionCheckpoint } from "./host/compaction.js";
|
|
35
35
|
import { LUME_REFLECTION_SPEC, ReflectionStore, buildReflectionPrompt, parseReflectionScore } from "./host/reflection.js";
|
|
36
|
-
import {
|
|
36
|
+
import { appendLumeLog } from "./host/diag.js";
|
|
37
|
+
import { advancePhase, buildAlignmentCorrection, buildCompactionNotice, buildInteractionDirective, buildLongSessionGuard, buildSessionAnchor, buildTaskPhaseDirective, buildToolFailureNotice, classifyInteraction, isUserAuthored, taskPhaseForMode } from "./host/protocol.js";
|
|
37
38
|
import { REASONING_MODEL_RE, TASK_SIGNAL_RE, selectThinkingProtocol } from "./host/thinking.js";
|
|
38
39
|
/** schemastery → domainTable 形参的桥接(与 identity.ts 同款)。 */
|
|
39
40
|
const recordSchema = zodLike;
|
|
@@ -62,6 +63,10 @@ const LUME_THINKING_ORDER = 1;
|
|
|
62
63
|
const LUME_PERSONA_ORDER = 10000;
|
|
63
64
|
const LUME_BOUNDARY_SECTION = "lume:boundary";
|
|
64
65
|
const LUME_BOUNDARY_ORDER = 10100;
|
|
66
|
+
/** 工具失败提示:走 runtime-context 通道(渲染成对话尾部的一条消息),
|
|
67
|
+
* 不进 system 串——避免会变的内容每步作废前缀缓存。 */
|
|
68
|
+
const LUME_TOOL_NOTICE_CONTEXT = "lume:tool-notice";
|
|
69
|
+
const LUME_TOOL_NOTICE_ORDER = 10150;
|
|
65
70
|
const MAX_SESSIONS = 200;
|
|
66
71
|
const SWITCH_BOUNDARY_TURNS = 2;
|
|
67
72
|
/** Cordis 插件名 */
|
|
@@ -83,7 +88,6 @@ export function apply(ctx, config = {}) {
|
|
|
83
88
|
const extractionRouteOverride = { provider: config.extractionProvider, model: config.extractionModel };
|
|
84
89
|
const distillRouteOverride = { provider: config.distillProvider, model: config.distillModel };
|
|
85
90
|
const reflectionEnabled = config.reflectionEnabled ?? true;
|
|
86
|
-
const compactionTakeover = config.compactionTakeover ?? false;
|
|
87
91
|
const boundaryTurns = config.switchBoundaryTurns ?? SWITCH_BOUNDARY_TURNS;
|
|
88
92
|
const defaultName = builtins[NONE_PERSONA] ? NONE_PERSONA : null;
|
|
89
93
|
const legacyStatePath = join(assetsDir, "persona-state.json");
|
|
@@ -423,19 +427,28 @@ export function apply(ctx, config = {}) {
|
|
|
423
427
|
break;
|
|
424
428
|
}
|
|
425
429
|
case "user/message": {
|
|
430
|
+
// 压缩检查点:宿主把被压缩的历史替换成一条摘要消息,必须与真实
|
|
431
|
+
// 用户消息区分——否则摘要会被当成「用户当前说的话」,污染协议
|
|
432
|
+
// 路由所依赖的 lastQuery 与对话缓冲。这是兜底识别:同一轮里
|
|
433
|
+
// compaction/summary 通常先到且带规模,不要把那条覆盖成无规模的。
|
|
434
|
+
if (isCompactionCheckpoint(event.data)) {
|
|
435
|
+
if (!st.compaction || st.compaction.turnIndex !== st.turnIndex) {
|
|
436
|
+
st.compaction = { turnIndex: st.turnIndex, shadowedItems: 0, tokens: 0 };
|
|
437
|
+
}
|
|
438
|
+
appendLumeLog(`[${sid}] 检测到上下文压缩检查点(第 ${st.turnIndex} 轮)`);
|
|
439
|
+
break;
|
|
440
|
+
}
|
|
441
|
+
// 只有真实用户消息能定义本轮意图。宿主快照(@deepseek-ai/dsh-system-prompt)、
|
|
442
|
+
// 工作区指令(agent-instructions)、技能目录(skill-catalog)都经这条通道投递,
|
|
443
|
+
// 曾被当成用户发言:覆盖真实请求,并把模式从「执行」冲成「问答」。
|
|
444
|
+
if (!isUserAuthored(event.data))
|
|
445
|
+
break;
|
|
426
446
|
const text = messageText(event.data);
|
|
427
447
|
if (text) {
|
|
428
448
|
const normalized = text.trim().replace(/\s+/g, " ").slice(0, 240);
|
|
429
449
|
const explicitCorrection = /不是这个意思|不是我说的|你理解错|答非所问|听不懂|我说的是|我指的是|不对|错了|别这样|重新来/i.test(text);
|
|
430
450
|
const repeatedRequest = normalized.length >= 5 && st.recentUserQueries.includes(normalized);
|
|
431
451
|
st.userText = text;
|
|
432
|
-
st.lastQuery = text;
|
|
433
|
-
st.interactionMode = classifyInteraction(text);
|
|
434
|
-
st.taskPhase = taskPhaseForMode(st.interactionMode);
|
|
435
|
-
st.toolCalls = 0;
|
|
436
|
-
st.toolSuccesses = 0;
|
|
437
|
-
st.toolFailures = 0;
|
|
438
|
-
st.toolUnknown = 0;
|
|
439
452
|
st.alignmentCorrection = explicitCorrection
|
|
440
453
|
? buildAlignmentCorrection("user-correction")
|
|
441
454
|
: repeatedRequest
|
|
@@ -447,6 +460,8 @@ export function apply(ctx, config = {}) {
|
|
|
447
460
|
st.recentTurns.push(`用户: ${text.slice(0, 300)}`);
|
|
448
461
|
if (st.recentTurns.length > 12)
|
|
449
462
|
st.recentTurns.shift();
|
|
463
|
+
// 模式/阶段的冻结统一由 resolveIntent(组装时读会话权威历史)负责,
|
|
464
|
+
// 这里只记账:两处都写会让「同一条消息」被判定为不同轮而反复重算。
|
|
450
465
|
}
|
|
451
466
|
break;
|
|
452
467
|
}
|
|
@@ -463,7 +478,7 @@ export function apply(ctx, config = {}) {
|
|
|
463
478
|
case "tool/call": {
|
|
464
479
|
st.toolCalls++;
|
|
465
480
|
if (st.interactionMode === "execute")
|
|
466
|
-
st.taskPhase = "execute";
|
|
481
|
+
st.taskPhase = advancePhase(st.taskPhase, "execute");
|
|
467
482
|
break;
|
|
468
483
|
}
|
|
469
484
|
case "tool/result": {
|
|
@@ -478,7 +493,17 @@ export function apply(ctx, config = {}) {
|
|
|
478
493
|
else
|
|
479
494
|
st.toolSuccesses++;
|
|
480
495
|
if (st.interactionMode === "execute")
|
|
481
|
-
st.taskPhase = unknownResult || explicitError ? "diagnose" : "verify";
|
|
496
|
+
st.taskPhase = advancePhase(st.taskPhase, unknownResult || explicitError ? "diagnose" : "verify");
|
|
497
|
+
break;
|
|
498
|
+
}
|
|
499
|
+
case "compaction/summary": {
|
|
500
|
+
// 压缩由宿主 preset 在隔离域执行(Lume 无法接管该服务),但事件在
|
|
501
|
+
// 会话总线上可见。记录规模,供下一轮注入「摘要不是完整历史」的重锚。
|
|
502
|
+
const data = event.data;
|
|
503
|
+
const shadowedItems = Array.isArray(data?.shadowedSeqs) ? data.shadowedSeqs.length : 0;
|
|
504
|
+
const tokens = typeof data?.shadowedTokenCount === "number" ? data.shadowedTokenCount : 0;
|
|
505
|
+
st.compaction = { turnIndex: st.turnIndex, shadowedItems, tokens };
|
|
506
|
+
appendLumeLog(`[${sid}] 压缩完成:替换 ${shadowedItems} 项历史(~${tokens} tokens),下一轮注入状态重锚`);
|
|
482
507
|
break;
|
|
483
508
|
}
|
|
484
509
|
case "turn/end": {
|
|
@@ -504,7 +529,7 @@ export function apply(ctx, config = {}) {
|
|
|
504
529
|
? "〔上轮交付复核〕上一轮执行回复没有给出可见的验证证据。本轮若继续处理同一任务,先确认上轮变更是否真实生效,再继续扩大范围。"
|
|
505
530
|
: null;
|
|
506
531
|
if (st.interactionMode === "execute")
|
|
507
|
-
st.taskPhase = st.toolFailures > 0 || st.toolUnknown > 0 ? "diagnose" : claimsVerification ? "deliver" : "verify";
|
|
532
|
+
st.taskPhase = advancePhase(st.taskPhase, st.toolFailures > 0 || st.toolUnknown > 0 ? "diagnose" : claimsVerification ? "deliver" : "verify");
|
|
508
533
|
// 即时对齐只影响当前轮;下一轮重新根据用户消息判断,避免纠偏条款滞留。
|
|
509
534
|
st.alignmentCorrection = null;
|
|
510
535
|
// 风格泄漏检测挂在 turn/end(该事件已被窗口机制验证可靠;assistant/message
|
|
@@ -526,6 +551,11 @@ export function apply(ctx, config = {}) {
|
|
|
526
551
|
break;
|
|
527
552
|
}
|
|
528
553
|
default:
|
|
554
|
+
// 诊断:压缩事件是否经由 session/event 总线投递(宿主按 session
|
|
555
|
+
// 所属上下文收集监听者,隔离域里发出的日志事件可能不经过这里)。
|
|
556
|
+
if (typeof event.type === "string" && /compact/i.test(event.type)) {
|
|
557
|
+
appendLumeLog(`[${sid}] 收到未处理的压缩事件类型 ${event.type}`);
|
|
558
|
+
}
|
|
529
559
|
break;
|
|
530
560
|
}
|
|
531
561
|
}), "lume: session events");
|
|
@@ -628,7 +658,50 @@ export function apply(ctx, config = {}) {
|
|
|
628
658
|
}));
|
|
629
659
|
}, "lume: persona tools");
|
|
630
660
|
// ── 人设五段式注入 + 切换播报 ──
|
|
631
|
-
|
|
661
|
+
/**
|
|
662
|
+
* 权威意图解析:与宿主会话历史对账,而不是只信事件缓存。
|
|
663
|
+
*
|
|
664
|
+
* 事件投递与首次提示词组装存在时序差——实测同一轮的 step 1 仍带上一轮的模式,
|
|
665
|
+
* step 2 才切到本轮分类,系统提示词因此在轮内变化、前缀缓存每步作废。这里直接
|
|
666
|
+
* 读会话投影出的消息(`deriveMessages`,宿主侧带增量缓存),取最后一条真实用户
|
|
667
|
+
* 消息作为本轮意图;messageId 未变时零成本短路,保证一轮内只冻结一次。
|
|
668
|
+
*/
|
|
669
|
+
function resolveIntent(context, st) {
|
|
670
|
+
const session = context?.agent?.session;
|
|
671
|
+
const messages = typeof session?.deriveMessages === "function" ? session.deriveMessages() : [];
|
|
672
|
+
let text = null;
|
|
673
|
+
let messageId = "";
|
|
674
|
+
for (let i = messages.length - 1; i >= 0; i--) {
|
|
675
|
+
const msg = messages[i];
|
|
676
|
+
if (!isUserAuthored(msg))
|
|
677
|
+
continue;
|
|
678
|
+
const candidate = messageText(msg);
|
|
679
|
+
if (!candidate)
|
|
680
|
+
continue;
|
|
681
|
+
text = candidate;
|
|
682
|
+
messageId = String(msg.id ?? "");
|
|
683
|
+
break;
|
|
684
|
+
}
|
|
685
|
+
// 权威会话历史不可用(旧宿主、非标准 session 对象)时退回事件记录的用户文本:
|
|
686
|
+
// 否则意图会永远停在默认的「问答」,比改动前更差。
|
|
687
|
+
if (text === null && st.userText) {
|
|
688
|
+
text = st.userText;
|
|
689
|
+
messageId = `text:${st.userText.slice(0, 120)}`;
|
|
690
|
+
}
|
|
691
|
+
if (text !== null && (st.intent === null || st.intent.messageId !== messageId)) {
|
|
692
|
+
const mode = classifyInteraction(text);
|
|
693
|
+
st.intent = { turnIndex: st.turnIndex, messageId, text };
|
|
694
|
+
st.lastQuery = text;
|
|
695
|
+
st.interactionMode = mode;
|
|
696
|
+
st.taskPhase = taskPhaseForMode(mode);
|
|
697
|
+
st.toolCalls = 0;
|
|
698
|
+
st.toolSuccesses = 0;
|
|
699
|
+
st.toolFailures = 0;
|
|
700
|
+
st.toolUnknown = 0;
|
|
701
|
+
}
|
|
702
|
+
return { text: st.intent?.text ?? st.lastQuery ?? "", mode: st.interactionMode };
|
|
703
|
+
}
|
|
704
|
+
function buildSessionText(sid, context) {
|
|
632
705
|
if (!currentStore)
|
|
633
706
|
return "";
|
|
634
707
|
const st = runtime.get(sid);
|
|
@@ -654,18 +727,49 @@ export function apply(ctx, config = {}) {
|
|
|
654
727
|
: null;
|
|
655
728
|
// 播报改由独立的尾部 section 渲染(LUME_BOUNDARY_SECTION),人设段不再内联
|
|
656
729
|
st.activeBoundary = boundaryText;
|
|
657
|
-
const
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
730
|
+
const memories = personaName ? identity?.getMemory(personaName) ?? [] : [];
|
|
731
|
+
const styleRules = personaName ? identity?.getStyleRules(personaName) ?? [] : [];
|
|
732
|
+
const corpusPins = personaName ? identity?.getCorpusPins(personaName) ?? [] : [];
|
|
733
|
+
const { text: query } = resolveIntent(context, st);
|
|
734
|
+
// 一轮一算:注入段按查询做 top-k 检索,查询或记忆每步抖动会让整段改写,
|
|
735
|
+
// 系统提示词随之在轮内变化(实测一轮产生 28 份),前缀缓存每步作废。
|
|
736
|
+
// 指纹覆盖 persona、查询、记忆/风格/语料与注入配置;人设切换、边界窗口、
|
|
737
|
+
// 记忆写入都会改变指纹而自动失效。
|
|
738
|
+
const last = (list, field) => list.length > 0 ? list[list.length - 1]?.[field] : "";
|
|
739
|
+
const key = [
|
|
740
|
+
String(personaName),
|
|
741
|
+
String(persona?.name ?? ""),
|
|
742
|
+
query,
|
|
743
|
+
String(st.turnIndex),
|
|
744
|
+
String(memories.length),
|
|
745
|
+
String(last(memories, "text")),
|
|
746
|
+
String(styleRules.length),
|
|
747
|
+
String(last(styleRules, "rule")),
|
|
748
|
+
String(corpusPins.length),
|
|
749
|
+
String(last(corpusPins, "assistant")),
|
|
750
|
+
String(boundaryText ?? ""),
|
|
751
|
+
String(sampleCount),
|
|
752
|
+
String(sampleMin),
|
|
753
|
+
String(memoryInject),
|
|
754
|
+
String(styleInject),
|
|
755
|
+
strategy,
|
|
756
|
+
].join("\u0001");
|
|
757
|
+
let text = st.personaCache !== null && st.personaCache.key === key ? st.personaCache.text : null;
|
|
758
|
+
if (text === null) {
|
|
759
|
+
text = buildPersonaSection({
|
|
760
|
+
persona,
|
|
761
|
+
profileName: personaName ? registry.profileNameOf(personaName) : null,
|
|
762
|
+
memories,
|
|
763
|
+
styleRules,
|
|
764
|
+
corpusPins,
|
|
765
|
+
query,
|
|
766
|
+
turnIndex: st.turnIndex,
|
|
767
|
+
sessionKey: sid,
|
|
768
|
+
boundaryText: null,
|
|
769
|
+
config: { sampleCount, sampleMin, memoryInject, styleInject, strategy },
|
|
770
|
+
});
|
|
771
|
+
st.personaCache = { turnIndex: st.turnIndex, key, text };
|
|
772
|
+
}
|
|
669
773
|
st.lastInjected = personaName;
|
|
670
774
|
if (greeting)
|
|
671
775
|
st.switchGreetingPending = false;
|
|
@@ -706,7 +810,7 @@ export function apply(ctx, config = {}) {
|
|
|
706
810
|
order: personaOrder,
|
|
707
811
|
text: (context) => {
|
|
708
812
|
const sid = context.agent?.session?.id ?? context.agent?.id;
|
|
709
|
-
return sid ? buildSessionText(String(sid)) : "";
|
|
813
|
+
return sid ? buildSessionText(String(sid), context) : "";
|
|
710
814
|
},
|
|
711
815
|
}), "lume.persona-section()");
|
|
712
816
|
ctx.effect(() => ctx.systemPrompt.section({
|
|
@@ -725,7 +829,10 @@ export function apply(ctx, config = {}) {
|
|
|
725
829
|
text: (context) => {
|
|
726
830
|
const sid = context.agent?.session?.id ?? context.agent?.id;
|
|
727
831
|
const st = sid ? runtime.get(String(sid)) : null;
|
|
728
|
-
|
|
832
|
+
// 意图取自会话权威历史(resolveIntent),不再读事件缓存里的最新文本:
|
|
833
|
+
// 后者会被注入消息覆盖,且首步可能还带着上一轮的值,导致模式在轮内漂移。
|
|
834
|
+
const intent = st !== null && sid ? resolveIntent(context, st) : null;
|
|
835
|
+
const query = intent?.text ?? "";
|
|
729
836
|
// 已知推理型模型具备计划能力,任务轮只保留变更、验证、归因和复核约束;
|
|
730
837
|
// 路由未知时使用完整版,避免误判造成能力退化。
|
|
731
838
|
const base = selectThinkingProtocol({
|
|
@@ -736,23 +843,41 @@ export function apply(ctx, config = {}) {
|
|
|
736
843
|
// 才能在「不使用人设」的纯任务会话里也生效。
|
|
737
844
|
const correction = st?.protocolCorrection;
|
|
738
845
|
const reflectionHint = reflectionStore?.getFeedback() ?? null;
|
|
739
|
-
const
|
|
846
|
+
const mode = intent?.mode ?? "question";
|
|
847
|
+
const route = buildInteractionDirective(mode);
|
|
740
848
|
const longSession = buildLongSessionGuard(st?.turnIndex ?? 0);
|
|
741
|
-
const anchor = buildSessionAnchor(st?.turnIndex ?? 0,
|
|
849
|
+
const anchor = buildSessionAnchor(st?.turnIndex ?? 0, mode, query, st?.recentTurns ?? []);
|
|
742
850
|
const alignment = st?.alignmentCorrection;
|
|
743
851
|
const postTurnReview = st?.postTurnReview;
|
|
744
852
|
const phase = buildTaskPhaseDirective(st?.taskPhase ?? "answer");
|
|
745
|
-
|
|
746
|
-
|
|
853
|
+
// 工具失败提示已移到 runtime-context 通道(见 lume.tool-notice-context):
|
|
854
|
+
// 它一出现就固定不变,但会变的内容不该待在 system 串里——那会作废前缀缓存。
|
|
855
|
+
// 压缩重锚:宿主的 preset 隔离域负责压缩,Lume 只能观察事件;
|
|
856
|
+
// 在压缩后一轮提醒「摘要不是完整历史」。
|
|
857
|
+
const compactionNotice = st?.compaction ? buildCompactionNotice(st.compaction, st.turnIndex) : null;
|
|
858
|
+
return [base, route, phase, longSession, anchor, alignment, postTurnReview, compactionNotice, correction, reflectionHint].filter(Boolean).join("\n\n");
|
|
747
859
|
},
|
|
748
860
|
}), "lume.thinking-section()");
|
|
749
|
-
//
|
|
750
|
-
//
|
|
751
|
-
//
|
|
752
|
-
//
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
861
|
+
// 工具失败提示走 runtime-context 通道:宿主把它渲染成对话尾部的一条消息,
|
|
862
|
+
// 而不是拼进 system 串。system 串只要变化就会写一条新的 request/header,
|
|
863
|
+
// 既在界面上多出一行「系统提示词」,也让前缀缓存从系统提示词处整段失效。
|
|
864
|
+
// `systemPrompt.context` 是宿主较新版本才有的 API,缺失时静默跳过(旧宿主下
|
|
865
|
+
// 只是失去这条提示,不影响其余功能)。
|
|
866
|
+
ctx.effect(() => {
|
|
867
|
+
if (typeof ctx.systemPrompt?.context !== "function") {
|
|
868
|
+
ctx.logger?.warn?.("lume: 当前宿主不支持 systemPrompt.context,工具失败提示已跳过(不影响其余功能)");
|
|
869
|
+
return;
|
|
870
|
+
}
|
|
871
|
+
return ctx.systemPrompt.context({
|
|
872
|
+
name: LUME_TOOL_NOTICE_CONTEXT,
|
|
873
|
+
order: LUME_TOOL_NOTICE_ORDER,
|
|
874
|
+
text: (context) => {
|
|
875
|
+
const sid = context.agent?.session?.id ?? context.agent?.id;
|
|
876
|
+
const st = sid ? runtime.get(String(sid)) : null;
|
|
877
|
+
if (!st)
|
|
878
|
+
return "";
|
|
879
|
+
return buildToolFailureNotice({ failures: st.toolFailures, unknown: st.toolUnknown }) ?? "";
|
|
880
|
+
},
|
|
881
|
+
});
|
|
882
|
+
}, "lume.tool-notice-context()");
|
|
758
883
|
}
|
package/package.json
CHANGED
|
@@ -1,120 +1,112 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "lume-dsh-plugin",
|
|
3
|
-
"description": "微光 (Lume) — DSH Desktop 增强插件:Codex 风格自适应任务执行协议 + 人设系统(聊天记录蒸馏具名角色、长期记忆、风格纠偏自动捕获)",
|
|
4
|
-
"version": "0.
|
|
5
|
-
"type": "module",
|
|
6
|
-
"main": "lib/index.js",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"default": "./lib/index.js"
|
|
10
|
-
},
|
|
11
|
-
"./client": {
|
|
12
|
-
"default": "./lib/client.js"
|
|
13
|
-
},
|
|
14
|
-
"./package.json": "./package.json"
|
|
15
|
-
},
|
|
16
|
-
"dsh": {
|
|
17
|
-
"bundle": {
|
|
18
|
-
"patch": "./cordis.patch.yml"
|
|
19
|
-
},
|
|
20
|
-
"client": {
|
|
21
|
-
"inject": [
|
|
22
|
-
"@deepseek-ai/dsh-client-connection",
|
|
23
|
-
"@deepseek-ai/dsh-client-locale",
|
|
24
|
-
"@deepseek-ai/dsh-client-runtime",
|
|
25
|
-
"@deepseek-ai/dsh-client-ui-conversation",
|
|
26
|
-
"@deepseek-ai/dsh-client-ui-primitives"
|
|
27
|
-
],
|
|
28
|
-
"external": [
|
|
29
|
-
"react",
|
|
30
|
-
"react/jsx-runtime",
|
|
31
|
-
"@deepseek-ai/dsh-client-ui-primitives"
|
|
32
|
-
],
|
|
33
|
-
"platform": "web",
|
|
34
|
-
"immediately": true
|
|
35
|
-
}
|
|
36
|
-
},
|
|
37
|
-
"license": "MIT",
|
|
38
|
-
"repository": {
|
|
39
|
-
"type": "git",
|
|
40
|
-
"url": "https://github.com/cayan0x/Lume.git"
|
|
41
|
-
},
|
|
42
|
-
"keywords": [
|
|
43
|
-
"dsh-plugin",
|
|
44
|
-
"persona",
|
|
45
|
-
"personality",
|
|
46
|
-
"identity",
|
|
47
|
-
"memory"
|
|
48
|
-
],
|
|
49
|
-
"engines": {
|
|
50
|
-
"node": ">=20"
|
|
51
|
-
},
|
|
52
|
-
"peerDependencies": {
|
|
53
|
-
"@deepseek-ai/cordis": "^4.0.1",
|
|
54
|
-
"@deepseek-ai/dsh-client-ui-primitives": "*",
|
|
55
|
-
"@deepseek-ai/dsh-llm": "*",
|
|
56
|
-
"@deepseek-ai/dsh-storage-domain": "*",
|
|
57
|
-
"@deepseek-ai/dsh-tools": "*",
|
|
58
|
-
"@deepseek-ai/
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
"
|
|
64
|
-
"
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
"@deepseek-ai/
|
|
70
|
-
"@deepseek-ai/dsh-
|
|
71
|
-
"@deepseek-ai/dsh-
|
|
72
|
-
"@deepseek-ai/dsh-
|
|
73
|
-
"@deepseek-ai/dsh-
|
|
74
|
-
"@deepseek-ai/dsh-
|
|
75
|
-
"@deepseek-ai/dsh-storage": "^0.0.1-rc.1",
|
|
76
|
-
"@deepseek-ai/dsh-
|
|
77
|
-
"@deepseek-ai/dsh-
|
|
78
|
-
"@deepseek-ai/
|
|
79
|
-
"@
|
|
80
|
-
"@
|
|
81
|
-
"
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
"
|
|
89
|
-
"
|
|
90
|
-
"assets/personalities
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
"@deepseek-ai/dsh-compaction-basic": {
|
|
114
|
-
"optional": true
|
|
115
|
-
},
|
|
116
|
-
"@deepseek-ai/schemastery": {
|
|
117
|
-
"optional": true
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "lume-dsh-plugin",
|
|
3
|
+
"description": "微光 (Lume) — DSH Desktop 增强插件:Codex 风格自适应任务执行协议 + 人设系统(聊天记录蒸馏具名角色、长期记忆、风格纠偏自动捕获)",
|
|
4
|
+
"version": "0.6.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "lib/index.js",
|
|
7
|
+
"exports": {
|
|
8
|
+
".": {
|
|
9
|
+
"default": "./lib/index.js"
|
|
10
|
+
},
|
|
11
|
+
"./client": {
|
|
12
|
+
"default": "./lib/client.js"
|
|
13
|
+
},
|
|
14
|
+
"./package.json": "./package.json"
|
|
15
|
+
},
|
|
16
|
+
"dsh": {
|
|
17
|
+
"bundle": {
|
|
18
|
+
"patch": "./cordis.patch.yml"
|
|
19
|
+
},
|
|
20
|
+
"client": {
|
|
21
|
+
"inject": [
|
|
22
|
+
"@deepseek-ai/dsh-client-connection",
|
|
23
|
+
"@deepseek-ai/dsh-client-locale",
|
|
24
|
+
"@deepseek-ai/dsh-client-runtime",
|
|
25
|
+
"@deepseek-ai/dsh-client-ui-conversation",
|
|
26
|
+
"@deepseek-ai/dsh-client-ui-primitives"
|
|
27
|
+
],
|
|
28
|
+
"external": [
|
|
29
|
+
"react",
|
|
30
|
+
"react/jsx-runtime",
|
|
31
|
+
"@deepseek-ai/dsh-client-ui-primitives"
|
|
32
|
+
],
|
|
33
|
+
"platform": "web",
|
|
34
|
+
"immediately": true
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"license": "MIT",
|
|
38
|
+
"repository": {
|
|
39
|
+
"type": "git",
|
|
40
|
+
"url": "https://github.com/cayan0x/Lume.git"
|
|
41
|
+
},
|
|
42
|
+
"keywords": [
|
|
43
|
+
"dsh-plugin",
|
|
44
|
+
"persona",
|
|
45
|
+
"personality",
|
|
46
|
+
"identity",
|
|
47
|
+
"memory"
|
|
48
|
+
],
|
|
49
|
+
"engines": {
|
|
50
|
+
"node": ">=20"
|
|
51
|
+
},
|
|
52
|
+
"peerDependencies": {
|
|
53
|
+
"@deepseek-ai/cordis": "^4.0.1",
|
|
54
|
+
"@deepseek-ai/dsh-client-ui-primitives": "*",
|
|
55
|
+
"@deepseek-ai/dsh-llm": "*",
|
|
56
|
+
"@deepseek-ai/dsh-storage-domain": "*",
|
|
57
|
+
"@deepseek-ai/dsh-tools": "*",
|
|
58
|
+
"@deepseek-ai/schemastery": "^3.18.1"
|
|
59
|
+
},
|
|
60
|
+
"scripts": {
|
|
61
|
+
"build": "tsc -p tsconfig.build.json && tsdown",
|
|
62
|
+
"bundle": "tsdown",
|
|
63
|
+
"watch": "tsdown --watch",
|
|
64
|
+
"test": "vitest run"
|
|
65
|
+
},
|
|
66
|
+
"devDependencies": {
|
|
67
|
+
"@deepseek-ai/cordis": "^4.0.1",
|
|
68
|
+
"@deepseek-ai/dsh-agent-default-model": "^0.1.0-rc.6",
|
|
69
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.1.1-rc.2",
|
|
70
|
+
"@deepseek-ai/dsh-llm": "^0.0.1-rc.1",
|
|
71
|
+
"@deepseek-ai/dsh-scope": "^0.0.1-rc.1",
|
|
72
|
+
"@deepseek-ai/dsh-session": "^0.0.1-rc.1",
|
|
73
|
+
"@deepseek-ai/dsh-storage": "^0.0.1-rc.1",
|
|
74
|
+
"@deepseek-ai/dsh-storage-domain": "^0.0.1-rc.1",
|
|
75
|
+
"@deepseek-ai/dsh-storage-json": "^0.0.1-rc.1",
|
|
76
|
+
"@deepseek-ai/dsh-timeout": "^0.0.1-rc.1",
|
|
77
|
+
"@deepseek-ai/dsh-tools": "^0.0.1-rc.1",
|
|
78
|
+
"@deepseek-ai/schemastery": "^3.18.1",
|
|
79
|
+
"@types/node": "^22.20.1",
|
|
80
|
+
"@types/react": "~18.3.1",
|
|
81
|
+
"tsdown": "^0.22.14",
|
|
82
|
+
"typescript": "^5.9.3",
|
|
83
|
+
"vitest": "^3.2.7"
|
|
84
|
+
},
|
|
85
|
+
"files": [
|
|
86
|
+
"lib",
|
|
87
|
+
"cordis.patch.yml",
|
|
88
|
+
"assets/personalities.json",
|
|
89
|
+
"assets/personalities/*.txt",
|
|
90
|
+
"assets/personalities/*.jsonl"
|
|
91
|
+
],
|
|
92
|
+
"peerDependenciesMeta": {
|
|
93
|
+
"@deepseek-ai/cordis": {
|
|
94
|
+
"optional": true
|
|
95
|
+
},
|
|
96
|
+
"@deepseek-ai/dsh-client-ui-primitives": {
|
|
97
|
+
"optional": true
|
|
98
|
+
},
|
|
99
|
+
"@deepseek-ai/dsh-llm": {
|
|
100
|
+
"optional": true
|
|
101
|
+
},
|
|
102
|
+
"@deepseek-ai/dsh-storage-domain": {
|
|
103
|
+
"optional": true
|
|
104
|
+
},
|
|
105
|
+
"@deepseek-ai/dsh-tools": {
|
|
106
|
+
"optional": true
|
|
107
|
+
},
|
|
108
|
+
"@deepseek-ai/schemastery": {
|
|
109
|
+
"optional": true
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|