dsh-plugin-prompt-tool 0.6.2 → 0.7.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.
- package/README.md +11 -9
- package/engine/anchor-match.mjs +38 -12
- package/engine/anchor-turn.mjs +68 -0
- package/engine/classify-task.mjs +35 -0
- package/engine/code-presentation.mjs +103 -0
- package/engine/compositions/library/anchor-turn.yml +10 -0
- package/engine/compositions/library/bootstrap-filesystem.yml +1 -1
- package/engine/compositions/library/code-presentation.yml +8 -0
- package/engine/compositions/library/command-goal.yml +11 -0
- package/engine/compositions/library/compaction.yml +1 -1
- package/engine/compositions/library/context-gate.yml +1 -2
- package/engine/compositions/library/cot-drip.yml +11 -0
- package/engine/compositions/library/custom-bash.yml +1 -1
- package/engine/compositions/library/delegation.yml +11 -7
- package/engine/compositions/library/deliberation-gate.yml +11 -0
- package/engine/compositions/library/persistent-shell.yml +25 -2
- package/engine/compositions/library/persona.yml +6 -2
- package/engine/compositions/library/planning.yml +1 -1
- package/engine/compositions/library/prompt-config-engine.yml +1 -1
- package/engine/compositions/library/run-code-env.yml +1 -1
- package/engine/compositions/library/skill-filesystem.yml +1 -1
- package/engine/compositions/library/skill-search.yml +1 -1
- package/engine/compositions/library/str-replace-editor.yml +2 -2
- package/engine/compositions/library/tool-ask-user.yml +1 -1
- package/engine/compositions/library/tool-bash.yml +1 -1
- package/engine/compositions/library/tool-bootstrap.yml +1 -3
- package/engine/compositions/library/tool-config-engine.yml +9 -0
- package/engine/compositions/library/tool-filter.yml +3 -7
- package/engine/compositions/library/tool-fs-search.yml +1 -1
- package/engine/compositions/library/tool-fs.yml +1 -1
- package/engine/compositions/library/tool-goal.yml +1 -9
- package/engine/compositions/library/tool-jobs.yml +1 -1
- package/engine/compositions/library/tool-pwsh.yml +1 -1
- package/engine/compositions/library/tool-todo.yml +1 -1
- package/engine/compositions/library/tool-web.yml +2 -2
- package/engine/compositions/source/local/code-presentation.yml +8 -0
- package/engine/compositions/source/local/context-gate.yml +0 -1
- package/engine/compositions/source/local/str-replace-editor.yml +10 -0
- package/engine/compositions/source/local/tool-bootstrap.yml +1 -3
- package/engine/compositions/source/local/tool-config-engine.yml +9 -0
- package/engine/compositions/source/local/tool-filter.yml +8 -0
- package/engine/cot-drip.mjs +137 -0
- package/engine/custom-bash.mjs +73 -21
- package/engine/deliberation-gate.mjs +127 -0
- package/engine/layers.mjs +223 -198
- package/engine/run-code-env.mjs +8 -2
- package/engine/schema.mjs +1 -1
- package/engine/strategies.mjs +25 -14
- package/engine/tool-bootstrap.mjs +185 -59
- package/engine/tool-config-engine.mjs +390 -0
- package/lib/client.js +3840 -2311
- package/lib/client.js.map +1 -1
- package/lib/index.d.mts +186 -101
- package/lib/index.mjs +1012 -413
- package/lib/preset-core.d.mts +1 -1
- package/lib/preset-core.mjs +29 -3
- package/lib/{prompt-configs-BgFw_bFf.mjs → prompt-configs-BnQKRHVb.mjs} +211 -136
- package/lib/prompt-configs-CN0sJTUL.d.mts +193 -0
- package/package.json +121 -105
- package/preset/anchored/preset.yml +262 -308
- package/preset/creative/preset.yml +34 -32
- package/preset/custom/preset.yml +0 -1
- package/preset/liangshen/preset.yml +53 -50
- package/preset/minimal/preset.yml +18 -17
- package/preset/ptc/preset.yml +35 -33
- package/preset/standard/preset.yml +34 -32
- package/templates/10-pre-step.yml +18 -15
- package/templates/14-first-turn-anchor.yml +13 -13
- package/templates/15-guide-auto.yml +13 -13
- package/templates/16-custom-fallback.yml +19 -18
- package/templates/18-placeholder-env-facts.yml +13 -2
- package/templates/30-runtime-context.yml +3 -0
- package/templates/40-agent-request.yml +9 -9
- package/templates/60-tool-pipeline.yml +9 -8
- package/templates/tools/10-shell-command.yml +20 -0
- package/templates/tools/20-http-fetch.yml +24 -0
- package/templates/tools/30-fs-read.yml +20 -0
- package/templates/tools/40-delegate-character.yml +15 -0
- package/templates/tools/50-delegate-worldbook.yml +15 -0
- package/templates/tools/60-delegate-session-var.yml +15 -0
- package/templates/tools/70-delegate-worldbook-upsert.yml +36 -0
- package/lib/prompt-configs-B4vH09wx.d.mts +0 -100
- package/templates/11-merged-a.yml +0 -11
- package/templates/13-anchor.yml +0 -19
- package/templates/17-instruction-hint.yml +0 -23
- package/templates/19-placeholder-skill-catalog.yml +0 -19
- package/templates/31-runtime-context-placeholder.yml +0 -18
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
//#region src/shared/engine-params.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* 引擎行为参数契约(单一来源)。
|
|
4
|
+
*
|
|
5
|
+
* 这是「可配置引擎参数」的类型唯一权威:所有消费引擎参数的接口(RuntimeOptions /
|
|
6
|
+
* BuildCordisOptions / WritePresetOptions)从这里派生,不再各自手写一遍字段
|
|
7
|
+
* (此前 5 处重复声明导致同字段签名漂移,如 maxDepth / usePtcMode)。
|
|
8
|
+
*
|
|
9
|
+
* 分层约定:
|
|
10
|
+
* - 本文件 = 引擎参数「契约层」(类型):参数桥/模板/UI 可配置的键与类型;
|
|
11
|
+
* - ENGINE_PARAM_KEYS = 引擎参数「运行时键唯一权威」(数组字面量);EngineParams
|
|
12
|
+
* 接口与它双向相等断言(漏改任一侧 typecheck 报错),PARAM_KEYS 从这里派生;
|
|
13
|
+
* - 模型段 ↔ 扁平键的存储翻译唯二入口:loadPresetSpec 展平 / savePresetParams 迁移。
|
|
14
|
+
*
|
|
15
|
+
* 全部字段可选:缺省 = 模板 preset.yml params / 引擎默认,符合「一切皆可自定义」。
|
|
16
|
+
*/
|
|
17
|
+
interface EngineParams {
|
|
18
|
+
/** 首轮近距离锚定:首条真实用户消息后追加一次性首句锚点。 */
|
|
19
|
+
firstTurnAnchor?: boolean;
|
|
20
|
+
/** 自定义锚点文本;firstTurnCustom=true 时固定使用。 */
|
|
21
|
+
firstTurnText?: string;
|
|
22
|
+
/** 自定义锚点开关:true 固定使用 firstTurnText;false 按任务自动选择。 */
|
|
23
|
+
firstTurnCustom?: boolean;
|
|
24
|
+
/** 自定义每轮引导文本;guideCustom=true 时固定使用。 */
|
|
25
|
+
guideText?: string;
|
|
26
|
+
/** 自定义每轮引导开关:true 固定使用 guideText;false 按任务自动选择。 */
|
|
27
|
+
guideCustom?: boolean;
|
|
28
|
+
/** 每轮引导独立开关;undefined = 兼容旧行为:跟随 firstTurnAnchor(关锚定 = 关引导)。 */
|
|
29
|
+
guideEnabled?: boolean;
|
|
30
|
+
/** 锚定确认后注入 preset.md;关闭时仍保留工具引导,但不生成 prompt-injector 提示词配置内容。 */
|
|
31
|
+
injectPrompt?: boolean;
|
|
32
|
+
/** 模型路由 provider;与模型名同时非空时给 subagent/subagent_fork 行加 agentOptions(主对话直派子代理与委派子代理通用)。 */
|
|
33
|
+
modelProvider?: string;
|
|
34
|
+
/** 模型名;与 provider 同时非空时生效。 */
|
|
35
|
+
modelName?: string;
|
|
36
|
+
/** 子代理固定模型路由 provider(agentOptions 注入 tool-subagent)。 */
|
|
37
|
+
subagentModelProvider?: string;
|
|
38
|
+
/** 子代理固定模型名。 */
|
|
39
|
+
subagentModelName?: string;
|
|
40
|
+
/** 主对话思维程度(agent-request patch reasoningEffort;''=不设置,官方档位 off/low/high/max)。 */
|
|
41
|
+
modelReasoningEffort?: string;
|
|
42
|
+
/** 主对话采样温度(agent-request patch temperature;''=不设置)。 */
|
|
43
|
+
modelTemperature?: string;
|
|
44
|
+
/** 主对话输出上限(agent-request patch maxTokens;''=不设置)。 */
|
|
45
|
+
modelMaxTokens?: string;
|
|
46
|
+
/** 子代理思维程度(agent-request patch,audience=subagent;''=不设置)。 */
|
|
47
|
+
subagentReasoningEffort?: string;
|
|
48
|
+
/** 子代理采样温度(agent-request patch,audience=subagent;''=不设置)。 */
|
|
49
|
+
subagentTemperature?: string;
|
|
50
|
+
/** 子代理输出上限(agent-request patch,audience=subagent;''=不设置)。 */
|
|
51
|
+
subagentMaxTokens?: string;
|
|
52
|
+
/** 委派工具集白名单(toolFilter.allow;支持数组或逗号/空格分隔字符串)。 */
|
|
53
|
+
toolFilterAllow?: string[] | string;
|
|
54
|
+
/** 委派工具集黑名单(toolFilter.deny)。 */
|
|
55
|
+
toolFilterDeny?: string[] | string;
|
|
56
|
+
/** 委派递归深度上限(0 禁止委派 / provider-managed / 正整数;YAML 字符串标量兼容)。 */
|
|
57
|
+
maxDepth?: number | 'provider-managed' | string;
|
|
58
|
+
/** 注入 kind 白名单(context-gate allowKinds;数组或逗号分隔字符串)。 */
|
|
59
|
+
allowKinds?: string[] | string;
|
|
60
|
+
/** custom-fallback 锚定词(prompt-injector params.firstTurnWord)。 */
|
|
61
|
+
firstTurnWord?: string;
|
|
62
|
+
/** 首轮输出封顶(bootstrapMaxTokens);0 或未设置 = 本项目默认无封顶。 */
|
|
63
|
+
bootstrapMaxTokens?: number;
|
|
64
|
+
/** 使用 PTC 模式;undefined = 模板/引擎默认(false,opt-in)。 */
|
|
65
|
+
usePtcMode?: boolean | undefined;
|
|
66
|
+
/** 门控晋升:首段 reasoning minimal-like + 工具调用才晋升(tool-bootstrap 参数桥扁平键)。 */
|
|
67
|
+
promoteGate?: boolean;
|
|
68
|
+
/** 无工具首响应 / 首轮 turn/end 即晋升。 */
|
|
69
|
+
promoteAfterFirstResponse?: boolean;
|
|
70
|
+
/** 门控回退:步数达上限强制晋升(默认 4)。 */
|
|
71
|
+
maxPromoteSteps?: number;
|
|
72
|
+
/** 首轮工具窄化集(覆盖行默认 [bash, str_replace_editor];必须非空)。 */
|
|
73
|
+
bootstrapTools?: string[] | string;
|
|
74
|
+
/** 压缩后恢复工具集(模型中途继续工作的核心工具)。 */
|
|
75
|
+
compactionTools?: string[] | string;
|
|
76
|
+
/** phase-1 提示词段只留 persona。 */
|
|
77
|
+
personaSectionsOnly?: boolean;
|
|
78
|
+
/** 晋升后 persona 附加工作目录行。 */
|
|
79
|
+
workspaceLine?: boolean;
|
|
80
|
+
/** context-gate phase-1 消息源白名单(空 = 不启用)。 */
|
|
81
|
+
messageSources?: string[] | string;
|
|
82
|
+
/** 晋升后延迟注入的 source kind。 */
|
|
83
|
+
deferredSources?: string[] | string;
|
|
84
|
+
/** 延迟注入宽限步数。 */
|
|
85
|
+
deferredGraceSteps?: number;
|
|
86
|
+
/** 晋升后 agent-instructions 全文 → 一次性 hint。 */
|
|
87
|
+
instructionHint?: boolean;
|
|
88
|
+
/** phase-1 persona 追加的首次调用指令行。 */
|
|
89
|
+
phase1FirstCallInstruction?: string;
|
|
90
|
+
/** 渐进披露阶段定义 [{ name, tools }];声明即激活多级阶段窄化。 */
|
|
91
|
+
stages?: Array<{
|
|
92
|
+
name: string;
|
|
93
|
+
tools: string[];
|
|
94
|
+
}>;
|
|
95
|
+
/** 阶段预放档数(默认 1)。 */
|
|
96
|
+
stagePreUnlock?: number;
|
|
97
|
+
/** 阶段推进工具名(默认 phase_advance)。 */
|
|
98
|
+
stageAdvanceTool?: string;
|
|
99
|
+
/** 阶段推进工具描述。 */
|
|
100
|
+
stageAdvanceDescription?: string;
|
|
101
|
+
/** 阶段状态 section 模板({{stage}}/{{stageName}}/{{unlocked}}/{{total}};空 = 不注入)。 */
|
|
102
|
+
stageSectionTemplate?: string;
|
|
103
|
+
/** 子代理也启用主对话工具过滤。 */
|
|
104
|
+
toolFilterSubagents?: boolean;
|
|
105
|
+
/** str-replace-editor 最大输出字符数(参数桥默认官方值 16000;UI 无专卡,高级参数 JSON 可编辑)。 */
|
|
106
|
+
strReplaceEditorMaxOutputChars?: number;
|
|
107
|
+
/** 前置锚定轮(anchor-turn 行):用户首条真实消息前 prepend 合成锚定轮;false = 行挂载但禁用。 */
|
|
108
|
+
anchorTurn?: boolean;
|
|
109
|
+
/** 前置锚定轮自定义锚定文本(空 = 引擎默认 "This round is a test…")。 */
|
|
110
|
+
anchorTurnText?: string;
|
|
111
|
+
/** 轨迹深度门(deliberation-gate 行):首工具调用前流式深思 < 下限时 deny 一次;false = 行挂载但禁用。 */
|
|
112
|
+
deliberationGate?: boolean;
|
|
113
|
+
/** 轨迹深度门深思下限(字符数;默认 400)。 */
|
|
114
|
+
deliberationMinChars?: number;
|
|
115
|
+
/** 轨迹深度门每轮最大 deny 次数(默认 1)。 */
|
|
116
|
+
deliberationMaxGatesPerTurn?: number;
|
|
117
|
+
/** 深思维持节拍(cot-drip 行):每 N 次工具结果滴入一条 "We…" 重申;false = 行挂载但禁用。 */
|
|
118
|
+
cotDrip?: boolean;
|
|
119
|
+
/** 深思维持节拍间隔(工具结果数;默认 4;0 = 禁用滴入)。 */
|
|
120
|
+
cotDripEvery?: number;
|
|
121
|
+
/** 深思维持节拍每轮最大提醒条数(默认 1)。 */
|
|
122
|
+
cotDripMaxPerTurn?: number;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* 引擎行为参数键唯一权威(数组字面量 = 运行时事实)。
|
|
126
|
+
* 与 EngineParams 接口双向相等断言:新增参数必须同时改接口与列表,漏改任一侧
|
|
127
|
+
* typecheck 失败(防历史事故:PARAM_KEYS 漏 25 键混入 variables.yml 污染注入)。
|
|
128
|
+
*/
|
|
129
|
+
declare const ENGINE_PARAM_KEYS: readonly ["firstTurnAnchor", "firstTurnText", "firstTurnCustom", "guideText", "guideCustom", "guideEnabled", "injectPrompt", "modelProvider", "modelName", "subagentModelProvider", "subagentModelName", "modelReasoningEffort", "modelTemperature", "modelMaxTokens", "subagentReasoningEffort", "subagentTemperature", "subagentMaxTokens", "toolFilterAllow", "toolFilterDeny", "maxDepth", "allowKinds", "firstTurnWord", "bootstrapMaxTokens", "usePtcMode", "promoteGate", "promoteAfterFirstResponse", "maxPromoteSteps", "bootstrapTools", "compactionTools", "personaSectionsOnly", "workspaceLine", "phase1FirstCallInstruction", "messageSources", "deferredSources", "deferredGraceSteps", "instructionHint", "stages", "stagePreUnlock", "stageAdvanceTool", "stageAdvanceDescription", "stageSectionTemplate", "toolFilterSubagents", "strReplaceEditorMaxOutputChars", "anchorTurn", "anchorTurnText", "deliberationGate", "deliberationMinChars", "deliberationMaxGatesPerTurn", "cotDrip", "cotDripEvery", "cotDripMaxPerTurn"];
|
|
130
|
+
/**
|
|
131
|
+
* writePreset.runtimeOf 实际透传进运行时 params 的引擎参数子集。
|
|
132
|
+
* RuntimeOptions(装配态)与 WritePresetOptions(写入态)都从这里派生,
|
|
133
|
+
* 防止「加参数只改一处、writePreset 忘透传」的静默漂移(如 stageAdvanceDescription 历史事故)。
|
|
134
|
+
*/
|
|
135
|
+
type PresetWriterParams = Pick<EngineParams, 'firstTurnAnchor' | 'firstTurnText' | 'firstTurnCustom' | 'guideText' | 'guideCustom' | 'guideEnabled' | 'injectPrompt' | 'modelProvider' | 'modelName' | 'subagentModelProvider' | 'subagentModelName' | 'modelReasoningEffort' | 'modelTemperature' | 'modelMaxTokens' | 'subagentReasoningEffort' | 'subagentTemperature' | 'subagentMaxTokens' | 'toolFilterAllow' | 'toolFilterDeny' | 'maxDepth' | 'allowKinds' | 'firstTurnWord' | 'bootstrapMaxTokens' | 'usePtcMode' | 'anchorTurn' | 'anchorTurnText' | 'deliberationGate' | 'deliberationMinChars' | 'deliberationMaxGatesPerTurn' | 'cotDrip' | 'cotDripEvery' | 'cotDripMaxPerTurn'>;
|
|
136
|
+
/** writePreset.runtimeOf 实际透传键(与 PresetWriterParams 双向相等断言,防 Pick 漏键)。 */
|
|
137
|
+
declare const WRITER_PARAM_KEYS: readonly ["firstTurnAnchor", "firstTurnText", "firstTurnCustom", "guideText", "guideCustom", "guideEnabled", "injectPrompt", "modelProvider", "modelName", "subagentModelProvider", "subagentModelName", "modelReasoningEffort", "modelTemperature", "modelMaxTokens", "subagentReasoningEffort", "subagentTemperature", "subagentMaxTokens", "toolFilterAllow", "toolFilterDeny", "maxDepth", "allowKinds", "firstTurnWord", "bootstrapMaxTokens", "usePtcMode", "anchorTurn", "anchorTurnText", "deliberationGate", "deliberationMinChars", "deliberationMaxGatesPerTurn", "cotDrip", "cotDripEvery", "cotDripMaxPerTurn"];
|
|
138
|
+
//#endregion
|
|
139
|
+
//#region src/host/prompt-configs.d.ts
|
|
140
|
+
interface PromptConfigSpec {
|
|
141
|
+
id: string;
|
|
142
|
+
name?: string;
|
|
143
|
+
enabled?: boolean;
|
|
144
|
+
strategy?: string;
|
|
145
|
+
layer?: string;
|
|
146
|
+
configKind?: 'ordered' | 'anchor';
|
|
147
|
+
order?: number;
|
|
148
|
+
role?: 'user' | 'assistant';
|
|
149
|
+
group?: string;
|
|
150
|
+
exclusive?: boolean;
|
|
151
|
+
position?: 'after-user' | 'before-all' | 'after-all';
|
|
152
|
+
dedupe?: 'session' | 'batch' | 'none';
|
|
153
|
+
promotion?: 'none' | 'main' | 'include-subagents';
|
|
154
|
+
/** 消息受众:缺省(省略/null)= 公用(主会话+子代理);main=仅主会话;subagent=仅子代理。 */
|
|
155
|
+
audience?: 'main' | 'subagent' | null;
|
|
156
|
+
modelScope?: 'all' | 'pro' | 'flash';
|
|
157
|
+
sourceKind?: string;
|
|
158
|
+
form?: string;
|
|
159
|
+
summary?: string;
|
|
160
|
+
identity?: {
|
|
161
|
+
field: 'plugin' | 'kind';
|
|
162
|
+
value: string;
|
|
163
|
+
};
|
|
164
|
+
text?: string;
|
|
165
|
+
/** 单条提示词配置的多段文本:注入为一条消息的多个 text 内容块。 */
|
|
166
|
+
texts?: string[];
|
|
167
|
+
/** 同位置多条提示词配置的插入方式:separate=先后插入独立消息(默认);merged=拼接为一条消息。 */
|
|
168
|
+
mergeMode?: 'separate' | 'merged';
|
|
169
|
+
templateFile?: string;
|
|
170
|
+
fill?: string;
|
|
171
|
+
variables?: Record<string, string>;
|
|
172
|
+
params?: Record<string, unknown>;
|
|
173
|
+
}
|
|
174
|
+
interface PromptConfigFile {
|
|
175
|
+
/** 模块文件夹内文件名(数字前缀决定引擎执行顺序)。 */
|
|
176
|
+
file: string;
|
|
177
|
+
/** yml 文件内容。 */
|
|
178
|
+
content: string;
|
|
179
|
+
}
|
|
180
|
+
/**
|
|
181
|
+
* buildCordis 兼容层的运行时选项(生产路径为 writePreset + preset.yml 数据驱动)。
|
|
182
|
+
* 引擎参数契约单一来源见 shared/engine-params.ts(EngineParams),此处直接复用,
|
|
183
|
+
* 不再逐字段手写(此前与 RuntimeOptions / WritePresetOptions 三处重复导致签名漂移)。
|
|
184
|
+
*/
|
|
185
|
+
type BuildCordisOptions = EngineParams;
|
|
186
|
+
/** 把任意提示词配置 spec 渲染为独立提示词配置模块 yml(全部字段开放可配置)。 */
|
|
187
|
+
declare function renderPromptConfigYaml(spec: PromptConfigSpec): string;
|
|
188
|
+
/** 多源提示词配置合并:同名 id 后者覆盖(保留默认提示词配置位置),新 id 追加在末尾。 */
|
|
189
|
+
declare function mergePromptConfigs(...sources: Array<PromptConfigSpec[] | undefined>): PromptConfigSpec[];
|
|
190
|
+
/** 从用户提示词配置目录加载 yml/json 提示词配置(文件名排序;内容必须能解析)。 */
|
|
191
|
+
declare function loadPromptConfigFiles(dir: string): PromptConfigSpec[];
|
|
192
|
+
//#endregion
|
|
193
|
+
export { mergePromptConfigs as a, PresetWriterParams as c, loadPromptConfigFiles as i, WRITER_PARAM_KEYS as l, PromptConfigFile as n, renderPromptConfigYaml as o, PromptConfigSpec as r, ENGINE_PARAM_KEYS as s, BuildCordisOptions as t };
|
package/package.json
CHANGED
|
@@ -1,105 +1,121 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "dsh-plugin-prompt-tool",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "DSH 插件:提示词工具,规范模型的思维链与回答内容,提供 Web UI 编辑 preset.md 与 AGENTS.md,并按 skills 目录注册可开关技能。",
|
|
5
|
-
"license": "MIT",
|
|
6
|
-
"repository": {
|
|
7
|
-
"type": "git",
|
|
8
|
-
"url": "git+https://github.com/Czerror/dsh-plugin-prompt-tool.git"
|
|
9
|
-
},
|
|
10
|
-
"type": "module",
|
|
11
|
-
"main": "lib/index.mjs",
|
|
12
|
-
"types": "lib/index.d.mts",
|
|
13
|
-
"exports": {
|
|
14
|
-
".": {
|
|
15
|
-
"types": "./lib/index.d.mts",
|
|
16
|
-
"default": "./lib/index.mjs"
|
|
17
|
-
},
|
|
18
|
-
"./client": "./lib/client.js",
|
|
19
|
-
"./package.json": "./package.json"
|
|
20
|
-
},
|
|
21
|
-
"engines": {
|
|
22
|
-
"node": ">=20"
|
|
23
|
-
},
|
|
24
|
-
"dsh": {
|
|
25
|
-
"bundle": {
|
|
26
|
-
"patch": "./cordis.patch.yml",
|
|
27
|
-
"requires": [
|
|
28
|
-
"@deepseek-ai/dsh-web-app"
|
|
29
|
-
]
|
|
30
|
-
},
|
|
31
|
-
"client": {
|
|
32
|
-
"inject": [
|
|
33
|
-
"@deepseek-ai/dsh-client-
|
|
34
|
-
"@deepseek-ai/dsh-client-
|
|
35
|
-
"@deepseek-ai/dsh-client-ui-settings"
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
"@deepseek-ai/
|
|
48
|
-
"@deepseek-ai/dsh-
|
|
49
|
-
"@deepseek-ai/dsh-
|
|
50
|
-
"@deepseek-ai/dsh-
|
|
51
|
-
"@deepseek-ai/dsh-
|
|
52
|
-
"@deepseek-ai/dsh-
|
|
53
|
-
"@deepseek-ai/
|
|
54
|
-
"
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
"@deepseek-ai/
|
|
58
|
-
"@deepseek-ai/dsh-
|
|
59
|
-
"@deepseek-ai/dsh-
|
|
60
|
-
"@deepseek-ai/dsh-
|
|
61
|
-
"@deepseek-ai/dsh-
|
|
62
|
-
"@deepseek-ai/dsh-
|
|
63
|
-
"@deepseek-ai/dsh-
|
|
64
|
-
"@deepseek-ai/
|
|
65
|
-
"
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
"@deepseek-ai/
|
|
69
|
-
"@deepseek-ai/dsh-
|
|
70
|
-
"@
|
|
71
|
-
"@
|
|
72
|
-
"@
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"
|
|
79
|
-
"
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
"
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
89
|
-
"
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
"
|
|
93
|
-
"
|
|
94
|
-
"
|
|
95
|
-
"
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
"
|
|
104
|
-
|
|
105
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "dsh-plugin-prompt-tool",
|
|
3
|
+
"version": "0.7.1",
|
|
4
|
+
"description": "DSH 插件:提示词工具,规范模型的思维链与回答内容,提供 Web UI 编辑 preset.md 与 AGENTS.md,并按 skills 目录注册可开关技能。",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "git+https://github.com/Czerror/dsh-plugin-prompt-tool.git"
|
|
9
|
+
},
|
|
10
|
+
"type": "module",
|
|
11
|
+
"main": "lib/index.mjs",
|
|
12
|
+
"types": "lib/index.d.mts",
|
|
13
|
+
"exports": {
|
|
14
|
+
".": {
|
|
15
|
+
"types": "./lib/index.d.mts",
|
|
16
|
+
"default": "./lib/index.mjs"
|
|
17
|
+
},
|
|
18
|
+
"./client": "./lib/client.js",
|
|
19
|
+
"./package.json": "./package.json"
|
|
20
|
+
},
|
|
21
|
+
"engines": {
|
|
22
|
+
"node": ">=20"
|
|
23
|
+
},
|
|
24
|
+
"dsh": {
|
|
25
|
+
"bundle": {
|
|
26
|
+
"patch": "./cordis.patch.yml",
|
|
27
|
+
"requires": [
|
|
28
|
+
"@deepseek-ai/dsh-web-app"
|
|
29
|
+
]
|
|
30
|
+
},
|
|
31
|
+
"client": {
|
|
32
|
+
"inject": [
|
|
33
|
+
"@deepseek-ai/dsh-client-connection",
|
|
34
|
+
"@deepseek-ai/dsh-client-ui-settings",
|
|
35
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins",
|
|
36
|
+
"@deepseek-ai/dsh-client-ui-renderer",
|
|
37
|
+
"@deepseek-ai/dsh-client-ui-layout",
|
|
38
|
+
"@deepseek-ai/dsh-client-ui-sidebar",
|
|
39
|
+
"@deepseek-ai/dsh-client-ui-workspace",
|
|
40
|
+
"@deepseek-ai/dsh-api-remotes",
|
|
41
|
+
"@deepseek-ai/dsh-api-session-controller"
|
|
42
|
+
],
|
|
43
|
+
"platform": "web"
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"peerDependencies": {
|
|
47
|
+
"@deepseek-ai/cordis": "^4.0.1",
|
|
48
|
+
"@deepseek-ai/dsh-api-remotes": "^0.1.2-alpha.2",
|
|
49
|
+
"@deepseek-ai/dsh-api-session-controller": "^0.1.2-alpha.2",
|
|
50
|
+
"@deepseek-ai/dsh-client-connection": "^0.1.2-alpha.2",
|
|
51
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.1.2-alpha.2",
|
|
52
|
+
"@deepseek-ai/dsh-client-ui-settings": "^0.1.2-alpha.2",
|
|
53
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins": "^0.1.2-alpha.2",
|
|
54
|
+
"@deepseek-ai/dsh-client-ui-layout": "^0.1.2-alpha.2",
|
|
55
|
+
"@deepseek-ai/dsh-client-ui-sidebar": "^0.1.2-alpha.2",
|
|
56
|
+
"@deepseek-ai/dsh-client-ui-renderer": "^0.1.2-alpha.2",
|
|
57
|
+
"@deepseek-ai/dsh-client-ui-workspace": "^0.1.2-alpha.2",
|
|
58
|
+
"@deepseek-ai/dsh-commands": "^0.1.2-alpha.2",
|
|
59
|
+
"@deepseek-ai/dsh-host-webserver": "^0.1.2-alpha.2",
|
|
60
|
+
"@deepseek-ai/dsh-settings": "^0.1.2-alpha.2",
|
|
61
|
+
"@deepseek-ai/dsh-skill": "^0.1.2-alpha.2",
|
|
62
|
+
"@deepseek-ai/dsh-system-prompt": "^0.1.2-alpha.2",
|
|
63
|
+
"@deepseek-ai/dsh-tools": "^0.1.2-alpha.2",
|
|
64
|
+
"@deepseek-ai/schemastery": "^3.18.1",
|
|
65
|
+
"react": "^18.2.0"
|
|
66
|
+
},
|
|
67
|
+
"devDependencies": {
|
|
68
|
+
"@deepseek-ai/cordis": "^4.0.1",
|
|
69
|
+
"@deepseek-ai/dsh-api-remotes": "^0.1.2-alpha.2",
|
|
70
|
+
"@deepseek-ai/dsh-api-session-controller": "^0.1.2-alpha.2",
|
|
71
|
+
"@deepseek-ai/dsh-client-connection": "^0.1.2-alpha.2",
|
|
72
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.1.2-alpha.2",
|
|
73
|
+
"@deepseek-ai/dsh-client-ui-settings": "^0.1.2-alpha.2",
|
|
74
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins": "^0.1.2-alpha.2",
|
|
75
|
+
"@deepseek-ai/dsh-client-ui-layout": "^0.1.2-alpha.2",
|
|
76
|
+
"@deepseek-ai/dsh-client-ui-sidebar": "^0.1.2-alpha.2",
|
|
77
|
+
"@deepseek-ai/dsh-client-ui-renderer": "^0.1.2-alpha.2",
|
|
78
|
+
"@deepseek-ai/dsh-client-ui-workspace": "^0.1.2-alpha.2",
|
|
79
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.1.2-alpha.2",
|
|
80
|
+
"@deepseek-ai/dsh-commands": "^0.1.2-alpha.2",
|
|
81
|
+
"@deepseek-ai/dsh-host-webserver": "^0.1.2-alpha.2",
|
|
82
|
+
"@deepseek-ai/dsh-scope": "^0.1.2-alpha.2",
|
|
83
|
+
"@deepseek-ai/dsh-settings": "^0.1.2-alpha.2",
|
|
84
|
+
"@deepseek-ai/dsh-skill": "^0.1.2-alpha.2",
|
|
85
|
+
"@deepseek-ai/dsh-tools": "^0.1.2-alpha.2",
|
|
86
|
+
"@types/node": "^26.2.0",
|
|
87
|
+
"@types/react": "~18.3.1",
|
|
88
|
+
"@types/react-dom": "^18.3.0",
|
|
89
|
+
"clsx": "^2.1.1",
|
|
90
|
+
"lightningcss": "^1.32.0",
|
|
91
|
+
"oxlint": "^1.78.0",
|
|
92
|
+
"react": "^18.3.1",
|
|
93
|
+
"react-dom": "^18.3.1",
|
|
94
|
+
"tsdown": "^0.22.2",
|
|
95
|
+
"typescript": "^5.9.2"
|
|
96
|
+
},
|
|
97
|
+
"files": [
|
|
98
|
+
"lib",
|
|
99
|
+
"engine",
|
|
100
|
+
"cordis.patch.yml",
|
|
101
|
+
"LICENSE",
|
|
102
|
+
"preset",
|
|
103
|
+
"templates",
|
|
104
|
+
"skills",
|
|
105
|
+
"README.md"
|
|
106
|
+
],
|
|
107
|
+
"scripts": {
|
|
108
|
+
"build": "tsdown",
|
|
109
|
+
"prepare": "tsdown",
|
|
110
|
+
"typecheck": "tsc -p tsconfig.json --noEmit && tsc -p tsconfig.client.json --noEmit",
|
|
111
|
+
"lint": "oxlint src test tsdown.config.ts",
|
|
112
|
+
"test": "pnpm build && node --test \"test/**/*.test.mjs\"",
|
|
113
|
+
"link:profile": "node scripts/link-profile.mjs",
|
|
114
|
+
"sync:anchored": "node scripts/sync-anchored.mjs",
|
|
115
|
+
"sync:yaml": "node scripts/sync-yaml-vendor.mjs",
|
|
116
|
+
"rebuild:composition": "node scripts/rebuild-composition.mjs"
|
|
117
|
+
},
|
|
118
|
+
"dependencies": {
|
|
119
|
+
"yaml": "^2.9.0"
|
|
120
|
+
}
|
|
121
|
+
}
|