@deepseek-ai/dsh-client-ui-plan 0.0.1-rc.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/LICENSE +28 -0
- package/README.i18n.yaml +6 -0
- package/README.md +25 -0
- package/README.zh.md +25 -0
- package/lib/client.js +138 -0
- package/lib/index.js +13 -0
- package/lib/invariant.js +24 -0
- package/lib/types/client/PlanModeControl.d.ts +11 -0
- package/lib/types/client/index.d.ts +25 -0
- package/lib/types/client/locales.d.ts +18 -0
- package/lib/types/index.d.ts +11 -0
- package/lib/types/invariant.d.ts +16 -0
- package/package.json +80 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
BSD 3-Clause License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026, DeepSeek
|
|
4
|
+
|
|
5
|
+
Redistribution and use in source and binary forms, with or without
|
|
6
|
+
modification, are permitted provided that the following conditions are met:
|
|
7
|
+
|
|
8
|
+
1. Redistributions of source code must retain the above copyright notice, this
|
|
9
|
+
list of conditions and the following disclaimer.
|
|
10
|
+
|
|
11
|
+
2. Redistributions in binary form must reproduce the above copyright notice,
|
|
12
|
+
this list of conditions and the following disclaimer in the documentation
|
|
13
|
+
and/or other materials provided with the distribution.
|
|
14
|
+
|
|
15
|
+
3. Neither the name of the copyright holder nor the names of its
|
|
16
|
+
contributors may be used to endorse or promote products derived from
|
|
17
|
+
this software without specific prior written permission.
|
|
18
|
+
|
|
19
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
20
|
+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
21
|
+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
22
|
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
23
|
+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
24
|
+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
25
|
+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
26
|
+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
27
|
+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
28
|
+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
package/README.i18n.yaml
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Bilingual-pair consistency record (docs/i18n/README.md): the git blob hash of each
|
|
2
|
+
# side as of the last confirmed-consistent state. Both languages carry equal authority;
|
|
3
|
+
# after editing either side, bring the other along and re-record with:
|
|
4
|
+
# pnpm run verify-translation-pairing --write packages/client/ui-plan/README.md
|
|
5
|
+
README.md: fcc4fbab4fbe1a8cc27119366b21ef55c669ba30
|
|
6
|
+
README.zh.md: f512d40568058ef061c6f262eadb20acda78cb64
|
package/README.md
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# @deepseek-ai/dsh-client-ui-plan
|
|
2
|
+
|
|
3
|
+
English | [中文](README.zh.md)
|
|
4
|
+
|
|
5
|
+
Plan-mode status chip, a pure browser surface plugin. The browser half occupies the conversation-declared `conversation.input.plan` single seat (to the right of the access-mode control); the node half is an empty apply (the roster row). Plan behavior itself — the `/plan` command, the boundary-or-idle-committed `plan/mode` state, the `plan` projection unit, and the policy section — is owned by [`@deepseek-ai/dsh-plan-mode`](../../plan/plan-mode/README.md), composed independently on the host roster.
|
|
6
|
+
|
|
7
|
+
Plan mode is entered through the `/plan` command path: users can choose Plan from the composer's `+` Command menu or type `/plan`, while this package renders no inactive plan control. While the host-computed `plan` projection's effective target is plan mode (`pending ? !active : active` — a folded host value, not client optimism, so an arriving frame corrects the chip either way), the seat renders the warn-colored "Plan ×" status button, which executes `/plan off` through `command.execute`; otherwise the seat stays empty — a host without plan-mode (or a Draft with no session) shows nothing. While plan mode is the effective target, the composer textarea's placeholder switches to the plan-task hint — "describe your task to generate plan", localized through ui-conversation's `conversation` locale namespace (the `placeholder.plan` / `hint.plan` keys) and shared verbatim with the claimed `/plan` command hint (rendered by the composer from the same projection; owner-supplied placeholders win).
|
|
8
|
+
|
|
9
|
+
The chip carries the accessible description "Plan mode on, press to turn off". Admission failures (`matched: false`, business errors, transport faults) surface as an inline error and the chip stays until the projection confirms the exit.
|
|
10
|
+
|
|
11
|
+
The model exits plan mode through the stable `exit_plan_mode` tool; its plan review uses the composed Web question channel.
|
|
12
|
+
|
|
13
|
+
## Model Experience
|
|
14
|
+
|
|
15
|
+
Indirectly, through the `/plan off` command line the chip dispatches: `@deepseek-ai/dsh-plan-mode` owns the model-visible policy section, the exit-tool schema, and the logged state that line drives, while this package only renders the projection and sends what a user could equally type.
|
|
16
|
+
|
|
17
|
+
#### KV Cache effect
|
|
18
|
+
|
|
19
|
+
Entering or leaving plan mode changes the active `plan:policy` system-prompt section and therefore the request prefix; the chip itself adds no prompt content.
|
|
20
|
+
|
|
21
|
+
## Known Limitations and Deferred Work
|
|
22
|
+
|
|
23
|
+
- **Plan mode is guidance, not an execution sandbox** — deployments that require enforced read-only planning must compose the independent sandbox and approval policies.
|
|
24
|
+
- **The chip belongs to the default composer** — a pending whole-composer interaction such as plan review temporarily replaces the InputBar and its chip.
|
|
25
|
+
- **No inactive plan control** — entry uses the shared Command source; a session with the capability but inactive mode shows no plan affordance in the tool row.
|
package/README.zh.md
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# @deepseek-ai/dsh-client-ui-plan
|
|
2
|
+
|
|
3
|
+
[English](README.md) | 中文
|
|
4
|
+
|
|
5
|
+
Plan mode 状态徽章,纯浏览器 surface 插件。浏览器侧占用会话声明的 `conversation.input.plan` 单实例 seat(位于 access 模式控件右侧);node 侧是空 apply(roster 行)。plan 行为本身——`/plan` 命令、边界或空闲即时提交的 `plan/mode` 状态、`plan` 投影单元与 policy 段——归 [`@deepseek-ai/dsh-plan-mode`](../../plan/plan-mode/README.md) 所有,由 host roster 独立组合。
|
|
6
|
+
|
|
7
|
+
plan mode 经 `/plan` 命令路径进入:用户可以从 composer 的 `+` Command 菜单选择 Plan,也可以输入 `/plan`,而本包不渲染未激活态 plan 控件。当 host 计算的 `plan` 投影有效目标为 plan mode 时(`pending ? !active : active`——折叠的 host 值而非客户端乐观态,帧到达即自动纠正),座位渲染 warn 色的 "Plan ×" 状态按钮,该按钮经 `command.execute` 执行 `/plan off`;否则座位保持为空——未组合 plan-mode 的 host(或尚无会话的 Draft)不显示任何内容。plan mode 为有效目标期间,composer 文本框的 placeholder 切换为 plan 任务提示——"describe your task to generate plan"(中文「描述你的任务以生成计划」),经 ui-conversation 的 `conversation` locale 命名空间(`placeholder.plan` / `hint.plan` 键)本地化,并与已认领 `/plan` 命令的提示逐字共用同一份文案(由 composer 从同一投影渲染;owner 提供的 placeholder 优先)。
|
|
8
|
+
|
|
9
|
+
chip 携带无障碍描述 "Plan mode on, press to turn off"。准入失败(`matched: false`、业务错误、传输故障)以内联错误呈现,chip 保持显示直至投影确认退出。
|
|
10
|
+
|
|
11
|
+
模型通过稳定的 `exit_plan_mode` 工具退出 plan mode;其 plan 评审走已组合的 Web question 通道。
|
|
12
|
+
|
|
13
|
+
## 模型体验
|
|
14
|
+
|
|
15
|
+
间接地,通过 chip 派发的 `/plan off` 命令行:`@deepseek-ai/dsh-plan-mode` 拥有该命令行驱动的模型可见 policy 段、退出工具 schema 与已记录状态,本包只渲染投影并发送用户同样可以手敲的内容。
|
|
16
|
+
|
|
17
|
+
#### KV Cache 影响
|
|
18
|
+
|
|
19
|
+
进入或离开 plan mode 会改变活跃的 `plan:policy` 系统提示词段,因此改变请求前缀;chip 本身不添加任何提示词内容。
|
|
20
|
+
|
|
21
|
+
## 已知局限与延后工作
|
|
22
|
+
|
|
23
|
+
- **Plan mode 是引导而非执行沙箱**:需要强制只读规划的部署必须组合独立的沙箱与审批策略。
|
|
24
|
+
- **chip 属于默认编辑器**:待处理的整编辑器交互(如 plan 评审)会临时取代 InputBar 及其 chip。
|
|
25
|
+
- **无未激活态 plan 控件**——入口使用共享 Command source;有能力但 mode 未激活的会话在工具行不显示 plan 入口。
|
package/lib/client.js
ADDED
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
window.__ModuleLoader__.load({
|
|
2
|
+
id: "@deepseek-ai/dsh-client-ui-plan",
|
|
3
|
+
factory: (require) => {
|
|
4
|
+
var module = { exports: {} };
|
|
5
|
+
var exports = module.exports;
|
|
6
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
7
|
+
let react_jsx_runtime = require("react/jsx-runtime");
|
|
8
|
+
let react = require("react");
|
|
9
|
+
let _deepseek_ai_dsh_client_ui_primitives = require("@deepseek-ai/dsh-client-ui-primitives");
|
|
10
|
+
//#region \0dsh-css:/home/runner/work/deepseek-harness/deepseek-harness/packages/client/ui-plan/src/client/PlanModeControl.module.css.mjs
|
|
11
|
+
const css = ".rS3zOq_wrap{align-items:center;gap:6px;display:inline-flex}.rS3zOq_chip{background:var(--dsw-alias-state-warn-tertiary);min-width:34px;color:var(--dsw-alias-state-warn-label);cursor:pointer;border:none;border-radius:999px;align-items:center;gap:4px;padding:2px 8px;font-size:13px;font-weight:500;line-height:20px;display:inline-flex}.rS3zOq_chip:hover:not(:disabled){color:var(--dsw-alias-state-warn-primary)}.rS3zOq_chip:focus-visible{outline:2px solid var(--dsw-alias-state-warn-label);outline-offset:2px}.rS3zOq_chip:disabled{opacity:.6;cursor:default}.rS3zOq_close{color:currentColor;align-items:center;display:inline-flex}.rS3zOq_error{color:var(--dsw-alias-state-error-primary);font-size:12px;line-height:18px}";
|
|
12
|
+
const tagId = "@deepseek-ai/dsh-client-ui-plan/PlanModeControl.module.css";
|
|
13
|
+
if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId) + "]") === null) {
|
|
14
|
+
const tag = document.createElement("style");
|
|
15
|
+
tag.dataset.plugin = "@deepseek-ai/dsh-client-ui-plan";
|
|
16
|
+
tag.dataset.pluginCss = tagId;
|
|
17
|
+
tag.textContent = css;
|
|
18
|
+
document.head.appendChild(tag);
|
|
19
|
+
}
|
|
20
|
+
var PlanModeControl_module_css_default = {
|
|
21
|
+
"chip": "rS3zOq_chip",
|
|
22
|
+
"wrap": "rS3zOq_wrap",
|
|
23
|
+
"close": "rS3zOq_close",
|
|
24
|
+
"error": "rS3zOq_error"
|
|
25
|
+
};
|
|
26
|
+
//#endregion
|
|
27
|
+
//#region lib/types/client/PlanModeControl.js
|
|
28
|
+
/**
|
|
29
|
+
* Plan-mode status over the host-computed `plan` projection. The chip renders
|
|
30
|
+
* only while the effective target is plan mode (`pending ? !active : active`
|
|
31
|
+
* — a folded host value, not client optimism) and executes /plan off.
|
|
32
|
+
*/
|
|
33
|
+
function PlanChip({ useProjection, locked, exitPlanMode, t }) {
|
|
34
|
+
const plan = useProjection("plan");
|
|
35
|
+
const [leaving, setLeaving] = (0, react.useState)(false);
|
|
36
|
+
const [error, setError] = (0, react.useState)(null);
|
|
37
|
+
const aliveRef = (0, react.useRef)(true);
|
|
38
|
+
(0, react.useEffect)(() => {
|
|
39
|
+
aliveRef.current = true;
|
|
40
|
+
return () => {
|
|
41
|
+
aliveRef.current = false;
|
|
42
|
+
};
|
|
43
|
+
}, []);
|
|
44
|
+
if (plan === void 0) return null;
|
|
45
|
+
if (!(plan.pending ? !plan.active : plan.active)) return null;
|
|
46
|
+
const off = () => {
|
|
47
|
+
setLeaving(true);
|
|
48
|
+
setError(null);
|
|
49
|
+
exitPlanMode().then((failure) => {
|
|
50
|
+
if (!aliveRef.current) return;
|
|
51
|
+
setLeaving(false);
|
|
52
|
+
setError(failure);
|
|
53
|
+
}, (reason) => {
|
|
54
|
+
if (!aliveRef.current) return;
|
|
55
|
+
setLeaving(false);
|
|
56
|
+
setError(reason instanceof Error ? reason.message : String(reason));
|
|
57
|
+
});
|
|
58
|
+
};
|
|
59
|
+
return (0, react_jsx_runtime.jsxs)("span", {
|
|
60
|
+
className: PlanModeControl_module_css_default.wrap,
|
|
61
|
+
children: [(0, react_jsx_runtime.jsxs)("button", {
|
|
62
|
+
type: "button",
|
|
63
|
+
className: PlanModeControl_module_css_default.chip,
|
|
64
|
+
"aria-label": t("chip.on.aria"),
|
|
65
|
+
title: t("chip.on.title"),
|
|
66
|
+
disabled: locked || leaving,
|
|
67
|
+
onClick: off,
|
|
68
|
+
children: ["Plan", (0, react_jsx_runtime.jsx)("span", {
|
|
69
|
+
className: PlanModeControl_module_css_default.close,
|
|
70
|
+
"aria-hidden": true,
|
|
71
|
+
children: (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.IconCloseFill14, { size: 12 })
|
|
72
|
+
})]
|
|
73
|
+
}), error !== null && (0, react_jsx_runtime.jsx)("span", {
|
|
74
|
+
className: PlanModeControl_module_css_default.error,
|
|
75
|
+
role: "status",
|
|
76
|
+
title: error,
|
|
77
|
+
children: "failed to exit plan mode"
|
|
78
|
+
})]
|
|
79
|
+
});
|
|
80
|
+
}
|
|
81
|
+
//#endregion
|
|
82
|
+
//#region lib/types/client/locales.js
|
|
83
|
+
/** `plan` namespace dictionaries (the composer plan chip's copy). */
|
|
84
|
+
/** Simplified Chinese dictionary (the key-set source of truth). */
|
|
85
|
+
const zh = {
|
|
86
|
+
"chip.on.aria": "plan mode 已开启,按下关闭",
|
|
87
|
+
"chip.on.title": "plan mode 已开启 — 点击关闭(/plan off)",
|
|
88
|
+
"chip.off.aria": "plan mode 已关闭,按下开启",
|
|
89
|
+
"chip.off.title": "plan mode 已关闭 — 点击开启(/plan)"
|
|
90
|
+
};
|
|
91
|
+
/** English dictionary, checked complete against the zh key set. */
|
|
92
|
+
const en = {
|
|
93
|
+
"chip.on.aria": "Plan mode on, press to turn off",
|
|
94
|
+
"chip.on.title": "Plan mode on — click to turn off (/plan off)",
|
|
95
|
+
"chip.off.aria": "Plan mode off, press to turn on",
|
|
96
|
+
"chip.off.title": "Plan mode off — click to turn on (/plan)"
|
|
97
|
+
};
|
|
98
|
+
//#endregion
|
|
99
|
+
//#region lib/types/client/index.js
|
|
100
|
+
/** Dictionary namespace owned by this plugin. */
|
|
101
|
+
const NS = "plan";
|
|
102
|
+
/** Required services: the seat's slot registry, transport, and locale registry. */
|
|
103
|
+
const inject = [
|
|
104
|
+
"slots",
|
|
105
|
+
"connection",
|
|
106
|
+
"locale"
|
|
107
|
+
];
|
|
108
|
+
/**
|
|
109
|
+
* Client plugin body: register the plan chip over the command channel.
|
|
110
|
+
* @param ctx - client root context.
|
|
111
|
+
*/
|
|
112
|
+
function apply(ctx) {
|
|
113
|
+
ctx.effect(() => ctx.locale.register(NS, {
|
|
114
|
+
zh,
|
|
115
|
+
en
|
|
116
|
+
}), "ui-plan: dictionaries");
|
|
117
|
+
ctx.slots.inject("conversation.input.plan", () => ctx.slots.register({
|
|
118
|
+
name: "conversation.input.plan",
|
|
119
|
+
locale: NS,
|
|
120
|
+
inject: (sessionId) => ({ exitPlanMode: async () => {
|
|
121
|
+
const { result } = await ctx.get("connection").api.commands.execute({
|
|
122
|
+
sessionId,
|
|
123
|
+
line: "/plan off"
|
|
124
|
+
});
|
|
125
|
+
if (!result.ok) return `${result.error.message} (${result.error.code})`;
|
|
126
|
+
if (!result.value.matched) return "unknown command: /plan off";
|
|
127
|
+
return null;
|
|
128
|
+
} })
|
|
129
|
+
}, PlanChip));
|
|
130
|
+
}
|
|
131
|
+
//#endregion
|
|
132
|
+
exports.apply = apply;
|
|
133
|
+
exports.inject = inject;
|
|
134
|
+
return module.exports;
|
|
135
|
+
}
|
|
136
|
+
});
|
|
137
|
+
|
|
138
|
+
//# sourceMappingURL=client.js.map
|
package/lib/index.js
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
//#region lib/types/index.js
|
|
2
|
+
/**
|
|
3
|
+
* Plan control plugin, node half. Pure UI plugin: the empty apply exists so
|
|
4
|
+
* the plugin appears in the host cordis.yml / Loader; the browser half ships
|
|
5
|
+
* via exports["./client"], discovered through the package.json dsh.client
|
|
6
|
+
* declaration. Plan behavior itself (the /plan command, the plan projection
|
|
7
|
+
* unit, the policy section) is owned by `@deepseek-ai/dsh-plan-mode`,
|
|
8
|
+
* composed independently on the host roster.
|
|
9
|
+
*/
|
|
10
|
+
/** Host plugin body — no host-side behavior for this surface plugin. */
|
|
11
|
+
function apply() {}
|
|
12
|
+
//#endregion
|
|
13
|
+
export { apply };
|
package/lib/invariant.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
//#region lib/types/invariant.js
|
|
2
|
+
/**
|
|
3
|
+
* Package-owned invariant companion for `@deepseek-ai/dsh-client-ui-plan`.
|
|
4
|
+
* @module @deepseek-ai/dsh-client-ui-plan/invariant
|
|
5
|
+
*/
|
|
6
|
+
const PACKAGE_NAME = "@deepseek-ai/dsh-client-ui-plan";
|
|
7
|
+
/** Cordis companion plugin name. */
|
|
8
|
+
const name = "client-ui-plan-invariant";
|
|
9
|
+
/** Service required before the companion can reserve package ownership. */
|
|
10
|
+
const inject = ["invariants"];
|
|
11
|
+
/**
|
|
12
|
+
* No runtime invariant: plan state and boundary ownership are
|
|
13
|
+
* audited by dsh-plan-mode, while the control is a slot effect whose
|
|
14
|
+
* declaration, registration, and teardown are exercised by this package.
|
|
15
|
+
*/
|
|
16
|
+
const install = () => {};
|
|
17
|
+
/**
|
|
18
|
+
* Register this package's invariant companion.
|
|
19
|
+
* @param ctx - Cordis context carrying the invariant service.
|
|
20
|
+
* @returns The installed registration's disposer after setup succeeds.
|
|
21
|
+
*/
|
|
22
|
+
const apply = (ctx) => Promise.resolve(ctx.invariants.register(PACKAGE_NAME, install));
|
|
23
|
+
//#endregion
|
|
24
|
+
export { apply, inject, name };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { InjectFace, PropsLocale, PropsRuntime } from '@deepseek-ai/dsh-client-ui-slots';
|
|
2
|
+
import type { PlanChipInjected } from './index.ts';
|
|
3
|
+
/** Full plan-seat component props: runtime share (standard kit + locked owner prop) & injected share & the locale seat. */
|
|
4
|
+
export type PlanChipProps = PropsRuntime<'conversation.input.plan'> & InjectFace<PlanChipInjected> & PropsLocale<'plan'>;
|
|
5
|
+
/**
|
|
6
|
+
* Plan-mode status over the host-computed `plan` projection. The chip renders
|
|
7
|
+
* only while the effective target is plan mode (`pending ? !active : active`
|
|
8
|
+
* — a folded host value, not client optimism) and executes /plan off.
|
|
9
|
+
*/
|
|
10
|
+
export declare function PlanChip({ useProjection, locked, exitPlanMode, t }: PlanChipProps): import("react").JSX.Element | null;
|
|
11
|
+
//# sourceMappingURL=PlanModeControl.d.ts.map
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { ClientContext } from '@deepseek-ai/dsh-client-runtime/client';
|
|
2
|
+
import { type PlanKey } from './locales.ts';
|
|
3
|
+
export type { PlanKey } from './locales.ts';
|
|
4
|
+
declare module '@deepseek-ai/dsh-client-ui-slots' {
|
|
5
|
+
interface LocaleNamespaceMap {
|
|
6
|
+
/** The composer plan chip's copy. */
|
|
7
|
+
plan: PlanKey;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
/** Injected business face of the composer plan seat. */
|
|
11
|
+
export interface PlanChipInjected {
|
|
12
|
+
/**
|
|
13
|
+
* Leave plan mode by executing /plan off.
|
|
14
|
+
* @returns null on admitted execution; a user-visible failure line otherwise.
|
|
15
|
+
*/
|
|
16
|
+
exitPlanMode: () => Promise<string | null>;
|
|
17
|
+
}
|
|
18
|
+
/** Required services: the seat's slot registry, transport, and locale registry. */
|
|
19
|
+
export declare const inject: string[];
|
|
20
|
+
/**
|
|
21
|
+
* Client plugin body: register the plan chip over the command channel.
|
|
22
|
+
* @param ctx - client root context.
|
|
23
|
+
*/
|
|
24
|
+
export declare function apply(ctx: ClientContext): void;
|
|
25
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/** `plan` namespace dictionaries (the composer plan chip's copy). */
|
|
2
|
+
/** Simplified Chinese dictionary (the key-set source of truth). */
|
|
3
|
+
export declare const zh: {
|
|
4
|
+
'chip.on.aria': string;
|
|
5
|
+
'chip.on.title': string;
|
|
6
|
+
'chip.off.aria': string;
|
|
7
|
+
'chip.off.title': string;
|
|
8
|
+
};
|
|
9
|
+
/** The plan namespace key union. */
|
|
10
|
+
export type PlanKey = keyof typeof zh;
|
|
11
|
+
/** English dictionary, checked complete against the zh key set. */
|
|
12
|
+
export declare const en: {
|
|
13
|
+
'chip.on.aria': string;
|
|
14
|
+
'chip.on.title': string;
|
|
15
|
+
'chip.off.aria': string;
|
|
16
|
+
'chip.off.title': string;
|
|
17
|
+
};
|
|
18
|
+
//# sourceMappingURL=locales.d.ts.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Plan control plugin, node half. Pure UI plugin: the empty apply exists so
|
|
3
|
+
* the plugin appears in the host cordis.yml / Loader; the browser half ships
|
|
4
|
+
* via exports["./client"], discovered through the package.json dsh.client
|
|
5
|
+
* declaration. Plan behavior itself (the /plan command, the plan projection
|
|
6
|
+
* unit, the policy section) is owned by `@deepseek-ai/dsh-plan-mode`,
|
|
7
|
+
* composed independently on the host roster.
|
|
8
|
+
*/
|
|
9
|
+
/** Host plugin body — no host-side behavior for this surface plugin. */
|
|
10
|
+
export declare function apply(): void;
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Package-owned invariant companion for `@deepseek-ai/dsh-client-ui-plan`.
|
|
3
|
+
* @module @deepseek-ai/dsh-client-ui-plan/invariant
|
|
4
|
+
*/
|
|
5
|
+
import type { Context } from '@deepseek-ai/cordis';
|
|
6
|
+
/** Cordis companion plugin name. */
|
|
7
|
+
export declare const name = "client-ui-plan-invariant";
|
|
8
|
+
/** Service required before the companion can reserve package ownership. */
|
|
9
|
+
export declare const inject: string[];
|
|
10
|
+
/**
|
|
11
|
+
* Register this package's invariant companion.
|
|
12
|
+
* @param ctx - Cordis context carrying the invariant service.
|
|
13
|
+
* @returns The installed registration's disposer after setup succeeds.
|
|
14
|
+
*/
|
|
15
|
+
export declare const apply: (ctx: Context) => Promise<() => void>;
|
|
16
|
+
//# sourceMappingURL=invariant.d.ts.map
|
package/package.json
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@deepseek-ai/dsh-client-ui-plan",
|
|
3
|
+
"description": "Plan-mode composer control: the conversation.input.plan seat over the plan projection and the /plan command channel",
|
|
4
|
+
"version": "0.0.1-rc.1",
|
|
5
|
+
"publishConfig": {
|
|
6
|
+
"access": "restricted"
|
|
7
|
+
},
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/deepseek-ai/deepseek-harness.git",
|
|
11
|
+
"directory": "packages/client/ui-plan"
|
|
12
|
+
},
|
|
13
|
+
"type": "module",
|
|
14
|
+
"main": "lib/index.js",
|
|
15
|
+
"types": "lib/types/index.d.ts",
|
|
16
|
+
"exports": {
|
|
17
|
+
".": {
|
|
18
|
+
"types": "./lib/types/index.d.ts",
|
|
19
|
+
"default": "./lib/index.js"
|
|
20
|
+
},
|
|
21
|
+
"./invariant": {
|
|
22
|
+
"types": "./lib/types/invariant.d.ts",
|
|
23
|
+
"default": "./lib/invariant.js"
|
|
24
|
+
},
|
|
25
|
+
"./client": {
|
|
26
|
+
"types": "./lib/types/client/index.d.ts",
|
|
27
|
+
"default": "./lib/client.js"
|
|
28
|
+
},
|
|
29
|
+
"./src/*": "./src/*",
|
|
30
|
+
"./package.json": "./package.json"
|
|
31
|
+
},
|
|
32
|
+
"dsh": {
|
|
33
|
+
"client": {
|
|
34
|
+
"inject": [
|
|
35
|
+
"@deepseek-ai/dsh-client-connection",
|
|
36
|
+
"@deepseek-ai/dsh-client-locale",
|
|
37
|
+
"@deepseek-ai/dsh-client-ui-conversation"
|
|
38
|
+
],
|
|
39
|
+
"platform": "web"
|
|
40
|
+
}
|
|
41
|
+
},
|
|
42
|
+
"license": "BSD-3-Clause",
|
|
43
|
+
"peerDependencies": {
|
|
44
|
+
"react": "^18.2.0",
|
|
45
|
+
"@deepseek-ai/dsh-client-connection": "^0.0.1-rc.1",
|
|
46
|
+
"@deepseek-ai/dsh-client-locale": "^0.0.1-rc.1",
|
|
47
|
+
"@deepseek-ai/dsh-client-runtime": "^0.0.1-rc.1",
|
|
48
|
+
"@deepseek-ai/dsh-client-ui-conversation": "^0.0.1-rc.1",
|
|
49
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.0.1-rc.1",
|
|
50
|
+
"@deepseek-ai/dsh-invariants": "^0.0.1-rc.1",
|
|
51
|
+
"@deepseek-ai/dsh-plan-mode": "^0.0.1-rc.1",
|
|
52
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.0.1-rc.1",
|
|
53
|
+
"@deepseek-ai/cordis": "^4.0.1-rc.1"
|
|
54
|
+
},
|
|
55
|
+
"devDependencies": {
|
|
56
|
+
"@types/react": "~18.3.1",
|
|
57
|
+
"react": "^18.2.0",
|
|
58
|
+
"@deepseek-ai/dsh-client-locale": "^0.0.1-rc.1",
|
|
59
|
+
"@deepseek-ai/dsh-client-runtime": "^0.0.1-rc.1",
|
|
60
|
+
"@deepseek-ai/dsh-client-test-runtime": "^0.0.1-rc.1",
|
|
61
|
+
"@deepseek-ai/dsh-client-ui-primitives": "^0.0.1-rc.1",
|
|
62
|
+
"@deepseek-ai/dsh-client-connection": "^0.0.1-rc.1",
|
|
63
|
+
"@deepseek-ai/dsh-client-ui-conversation": "^0.0.1-rc.1",
|
|
64
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.0.1-rc.1",
|
|
65
|
+
"@deepseek-ai/dsh-client-web-react": "^0.0.1-rc.1",
|
|
66
|
+
"@deepseek-ai/dsh-invariants": "^0.0.1-rc.1",
|
|
67
|
+
"@deepseek-ai/dsh-plan-mode": "^0.0.1-rc.1",
|
|
68
|
+
"@deepseek-ai/cordis": "^4.0.1-rc.1"
|
|
69
|
+
},
|
|
70
|
+
"files": [
|
|
71
|
+
"lib/index.js",
|
|
72
|
+
"lib/invariant.js",
|
|
73
|
+
"lib/client.js",
|
|
74
|
+
"lib/types/**/*.d.ts"
|
|
75
|
+
],
|
|
76
|
+
"scripts": {
|
|
77
|
+
"bundle": "tsdown",
|
|
78
|
+
"watch": "tsdown --watch"
|
|
79
|
+
}
|
|
80
|
+
}
|