dsh-plugin-deck-studio 0.2.4 → 0.2.6

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,212 +0,0 @@
1
- # Productization plan (Deckline · DSH image-deck plugin)
2
-
3
- 简体中文 · [English](productization.en.md)
4
-
5
- > Goal: turn "a DSH plugin that works on Yuna's machine" into a product that **anyone can install in
6
- > 5 minutes, configure with their own decks and image key, and start using**.
7
- >
8
- > This document is the full plan + current-state inventory + phased acceptance. Execution is tracked in
9
- > `docs/feedback.md` (F-54…F-57) and `tasks.md` (P27).
10
-
11
- ## 1. Product shape and positioning
12
-
13
- - **Shape**: a DSH (DeepSeek Harness) **bundle plugin** + a dedicated profile (`deckline`).
14
- Not a standalone app; DSH owns chat / models / permissions, Deckline owns the "full-page image deck"
15
- workbench.
16
- - **One-liner**: turn "who is this for, what is the point, how do slides get made" into a traceable
17
- pipeline — discuss in chat → script / intent / governance documents → per-page image prompt →
18
- one-page renders + revisions → export / handoff.
19
- - **Non-goals**: no HTML deck renderer (separate project); no default batch rendering of a whole deck;
20
- never modify the user's deck source directory.
21
- - **Target users**: consultants / trainers / internal communicators / content creators who already use
22
- DSH or are willing to install it.
23
-
24
- ## 2. Current state (available / gaps)
25
-
26
- | Capability | Current state | Productization gap |
27
- |---|---|---|
28
- | DSH plugin form | ✅ bundle + preset + client panel | Package metadata is clean (MIT / direct name / no personal paths, see §10) |
29
- | Installation | ✅ three ways: npm direct name / git subdirectory / local clone (`docs/install.md`) | npm not published yet (owner action) |
30
- | Configuration | ✅ profile patch + `cordis.example.yml` + env conventions (personal paths all moved to the local patch) | Team-shared config templates (Phase 3) |
31
- | Image key | ✅ `apiKeyEnv` / `apiKeyFile`; UI only shows whether a key is configured | Docs + clearer guidance in the Settings panel |
32
- | Styles | ✅ add style (paste/upload/drag) + 8 presets | Presets ship with the plugin + one-click import (done) |
33
- | Data | ✅ `.deck/` fully gitignored, source decks read-only | "where is data / how to back up / how to migrate" docs |
34
- | Verification | ✅ smoke 46 + harness gate + 16-scenario agent eval + real-machine Playwright checks | CI / public fixtures (Phase 1) |
35
- | Docs | ✅ README (zh/en) + install / styles / sample-deck docs (zh/en) + compatibility matrix | productization English, contributing guide, screenshots (Phase 2) |
36
-
37
- ## 3. Phased plan (recommended cadence)
38
-
39
- ### Phase 0 · Installable (v0.1, 1–2 days)
40
-
41
- - [x] Plugin package metadata: `repository` / `homepage` / `keywords` / `peerDependencies`;
42
- - [x] Default config template: `plugin/deck-studio/cordis.example.yml` (decks / projectsRoot / render nodes);
43
- - [x] Install docs `docs/install.md` (npm / git / local, key config, troubleshooting);
44
- - [x] README made public-facing (intro / 5-minute install / config / adding a design / styles);
45
- - [x] Preset styles ship with the plugin: `seeds/styles/*.json` + `seeds/samples/*.jpg` + "+ Import preset styles";
46
- - [x] Adding a design supports paste / drag / file picker; existing styles can take more samples;
47
- - [x] Image key: Settings panel shows nodes + "key configured" + missing-key hints;
48
- - [x] Moved personal config from the **plugin default patch** into the profile patch (distributable defaults) — migrated and verified via `--dump-config`.
49
-
50
- **Acceptance**: a clean machine (macOS/Linux, Node `^22.19` or `≥24` + pnpm + DSH) following the README
51
- can: start → create a deck → create a style (paste an image) → see key status in Settings → run one render
52
- in fake mode.
53
-
54
- ### Phase 1 · Distributable (v0.1.0, ready; release awaits the owner)
55
-
56
- - [x] **License: MIT** (owner decision, 2026-10-21) — `LICENSE` in the repo, package metadata aligned;
57
- - [x] **Direct package name**: `dsh-plugin-deck-studio`, no org / scope; `private: false`;
58
- - [x] **Public scope** (owner decision): plugin + public docs + preset designs (seeds) + 1 sample deck + 1 sample logo;
59
- → `scripts/build-public-bundle.mjs` produces a **whitelisted clean directory** (no internal ledgers / client
60
- names / personal paths / git history);
61
- - [x] Sample logo: `assets/logo/deckline-logo.svg|png` + mark; referenced at the top of README;
62
- - [x] Sample deck: `samples/deckline-intro/` (10-page Deckline product handbook source + paste-ready
63
- walkthrough in `docs/sample-deck.md`);
64
- - [x] Privacy scan: plugin code sanitized (all client names / personal paths / key names replaced), the
65
- bundler has a built-in forbidden-word scan;
66
- - [x] `CHANGELOG.md` + v0.1.0;
67
- - [ ] **Publish the repository**: `gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push`
68
- (after owner confirmation; do not push the development repo — its history contains internal process docs and client information);
69
- - [ ] `npm publish dsh-plugin-deck-studio` (npm account + 2FA required);
70
- - [ ] Add 3 real screenshots/GIF at the top of README (before going public);
71
- - [ ] GitHub Actions:
72
- - `ci.yml`: `node --check` + smoke (`plugin/deck-studio/verify/smoke.mjs`) + commit message lint;
73
- - `release.yml`: `npm publish` on tag (via `NPM_TOKEN` secret);
74
- - [x] Version compatibility: `peerDependencies` / `engines.dsh` declare `0.1.7–0.2.x`; `docs/compat.md`
75
- records two regression batches (0.1.7-rc.2 / 0.2.1-rc.2).
76
-
77
- ### Phase 2 · Easy onboarding (v0.3, 1 week)
78
-
79
- - [ ] First-run wizard: when there are no decks, guide through "new deck / import preset styles / configure key";
80
- - [ ] "New Deck" form can pick a preset style (currently free-text only);
81
- - [ ] Style library page: preview / search / tags (business, fancy, Japanese…), apply to a new deck in one click;
82
- - [ ] Data management: visualize the `.deck` location, backup/export button (zip);
83
- - [ ] i18n: Chinese + English (DSH itself supports multiple languages) — public docs are bilingual; UI strings pending;
84
- - [ ] Error reporting: actionable render failure reasons (key / quota / model name / size).
85
-
86
- ### Phase 3 · Collaborative (v0.4+)
87
-
88
- - [ ] Multi-user / team-shared profile config templates (keys never shared);
89
- - [ ] Style-pack marketplace (community contributes `seeds/styles`, PRs validated for schema + samples);
90
- - [ ] Render cost estimation / usage stats (per node);
91
- - [ ] Deck source adapters for more directory conventions (currently scans `outputs/full/final`, `outputs/final`, `pages`, `images`, `exports`).
92
-
93
- ### Phase 4 · Optional (on demand)
94
-
95
- - Desktop build (DSH desktop already exists), Docker image, SaaS hosting;
96
- - Object storage / image CDN integration (renders go straight to a CDN);
97
- - HTML deck renderer (separate project, not in this repository).
98
-
99
- ## 4. How the Git repo goes public (concrete steps)
100
-
101
- > Owner decision: **public scope = plugin + public docs + preset designs + 1 sample deck + 1 sample logo**.
102
- > The current development repo's git history contains internal ledgers (feedback / tasks / client names /
103
- > personal paths) and **must not be pushed directly**. Generate a clean whitelisted directory, then create
104
- > a new public repository from it.
105
-
106
- ```sh
107
- # 1) Generate the clean directory (whitelist + privacy scan; output in dist/public, gitignored)
108
- node scripts/build-public-bundle.mjs
109
- # ✔ whitelist + privacy scan pass (see script output), no /Users/ paths, no client names, no keys
110
-
111
- # 2) Create the public repo (after owner confirmation; account yuna78)
112
- gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push
113
-
114
- # 3) Fill in repo metadata: About = "DSH image deck workbench plugin",
115
- # Topics = deepseek-harness, dsh-plugin, image-deck, presentation, deck
116
- # 4) Tag / release
117
- cd dist/public && git tag v0.1.0 && git push origin v0.1.0
118
- gh release create v0.1.0 --notes "First public release: install via dsh plugin add dsh-plugin-deck-studio"
119
-
120
- # 5) npm publish (Phase 1)
121
- cd plugin/deck-studio
122
- npm publish --access public # npm account + 2FA required
123
- ```
124
-
125
- **Public bundle contents (whitelist)**:
126
-
127
- - `README.md` / `LICENSE` / `CHANGELOG.md`;
128
- - `docs/`: `productization.md` + `productization.en.md`, `install.md` + `install.en.md`, `styles.md` + `styles.en.md`,
129
- `sample-deck.md` + `sample-deck.en.md`, `compat.md`;
130
- - `plugin/deck-studio/`: the plugin itself (host + client + ui + lib + seeds preset styles/samples + verify smoke);
131
- - `samples/deckline-intro/`: sample deck source (README / intent / script);
132
- - `assets/logo/`: sample logo (svg + png).
133
-
134
- **Not public**: `CURRENT.md` / `HANDOVER.md` / `tasks.md` / `docs/feedback.md` / `docs/architecture.md` /
135
- `docs/adr/` / `docs/research/` / `fixtures/` (contain local references to client material) / `.deck/` (runtime
136
- data) / git history.
137
-
138
- **Cleanup already done**:
139
-
140
- 1. Personal paths in `cordis.patch.yml` → profile patch; the repo carries a generic bundle patch + `cordis.example.yml`;
141
- 2. Plugin `package.json`: `private: false`, MIT, direct package name, repository / homepage / peerDependencies;
142
- 3. Plugin code sanitized: client names, personal paths and env var names in `client.js` / `lib/config.js` /
143
- `lib/deck-workspace.js` / `lib/render-nodes.js` / `lib/source-adapter.js` / `lib/tools.js` / `verify/smoke.mjs`
144
- replaced with generic examples;
145
- 4. The bundler has a built-in forbidden-word scan (client names / `/Users/` / `sk-` / private key names); a hit
146
- aborts the build.
147
-
148
- ## 5. Install and distribution matrix
149
-
150
- | Method | Command | For |
151
- |---|---|---|
152
- | npm | `dsh plugin --profile deckline add dsh-plugin-deck-studio` | Regular users (after publish) |
153
- | Git | `dsh plugin --profile deckline add "github:yuna78/dsh-deck-studio#path:/plugin/deck-studio"` | People tracking main |
154
- | Local clone | `dsh plugin --profile deckline add "$PWD/plugin/deck-studio"` | Developers / customization |
155
-
156
- All three land in `~/.dsh/profiles/deckline/`; after installing, users only edit the **profile patch**
157
- (decks / projectsRoot / render nodes) and never the plugin package — that boundary is what makes
158
- "anyone can install it" true.
159
-
160
- ## 6. Configuration conventions (image key)
161
-
162
- - Configuration exists in exactly two places: the **profile patch** (structure) and **env vars / key files** (credentials);
163
- - The structure only holds `apiKeyEnv` (variable name) or `apiKeyFile` (local path), **never a plaintext key**;
164
- - The workbench Settings panel only shows the `keyConfigured` boolean + source name;
165
- - Multiple nodes supported (primary / backup / different models), each with its own key;
166
- - Missing key: fake mode still runs the full flow; real mode reports where to configure it.
167
-
168
- ## 7. Style ecosystem (the productization differentiator)
169
-
170
- - **Preset bundle ships with the plugin**: `plugin/deck-studio/seeds/styles/<ABBR>.json` (definitions with
171
- `styleBrief` + `baselineBriefs`) + `seeds/samples/<ABBR>-0{1,2,3}.jpg` (3 baseline samples);
172
- - **One-click import**: Designs page "+ Import preset styles", existing abbreviations are skipped (idempotent);
173
- - **Add your own**: paste/upload/drag in the UI; or drop images into `designs/<ABBR>/`;
174
- - **Contribute**: a PR adds one JSON + 3 baseline samples (schema: abbr / name / description / constraints /
175
- reference / styleBrief / baselineBriefs);
176
- - Known limitation: samples illustrate a style, not guarantee verbatim reproduction of their text (a general
177
- image-model limitation); for exact text, overlay HTML/Mermaid text afterwards.
178
-
179
- ## 8. Risks and boundaries
180
-
181
- | Risk | Description | Mitigation |
182
- |---|---|---|
183
- | DSH plugin API changes | The plugin depends on the DSH version | Declared peer range + CI smoke + compatibility docs |
184
- | Credential leakage | Users paste a key into the patch | Docs stress apiKeyEnv / apiKeyFile; Settings never echoes keys |
185
- | Runaway render cost | Users batch-render everything | Named batches / whole-deck renders are allowed (per-page revisions, single-page retries); no one-click button, to avoid accidents |
186
- | Client data | Deck sources may be sensitive | Sources read-only, output local under `.deck`, repo carries no data; export packages sanitized |
187
- | Model quality | Garbled text, broken layouts | Style prompt constraints + "little text, English" advice + post-edit overlays |
188
-
189
- ## 9. Milestones (suggested)
190
-
191
- - **M1 (this week)**: Phase 0 complete + 8 preset styles imported and usable locally;
192
- - **M2 (next week)**: repository public + v0.1.0 release + 2 external users install successfully;
193
- - **M3 (within two weeks)**: npm publish + CI + first-run wizard;
194
- - **M4 (one month)**: style library page + bilingual UI + community style packs.
195
-
196
- ## 10. Decisions made (2026-10-21)
197
-
198
- | # | Decision | Outcome | Implementation |
199
- |---|---|---|---|
200
- | 1 | License | **MIT** | `LICENSE` + package.json `license: MIT` |
201
- | 2 | Package name | **Direct, no org**: `dsh-plugin-deck-studio` | package.json `name` / `private: false` |
202
- | 3 | Public scope | Plugin + docs + preset designs + **1 sample deck** + **1 sample logo** | `scripts/build-public-bundle.mjs` whitelist; no internal ledgers or history |
203
- | 4 | Brand | **Deckline** confirmed (repo name stays `dsh-deck-studio`) | README / UI / logo |
204
- | 5 | Public account | GitHub `yuna78`; repo `yuna78/dsh-deck-studio` (public) | `gh repo create` + push after owner confirmation |
205
-
206
- **Two actions still waiting on the owner**:
207
-
208
- 1. Confirm going public: run `node scripts/build-public-bundle.mjs`, then
209
- `gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push`;
210
- 2. npm publish: `cd plugin/deck-studio && npm publish --access public` (needs npm login + 2FA).
211
-
212
- CI / release / screenshots come in the iterations after this round.
@@ -1,193 +0,0 @@
1
- # 产品化计划(Deckline · DSH image deck 插件)
2
-
3
- 简体中文 · [English](productization.en.md)
4
-
5
- > 目标:把现在这个「在 Yuna 机器上跑通的 DSH 插件」变成**任何人在自己机器上 5 分钟内装好、
6
- > 配好自己的 deck 和生图 key、开始用**的产品。
7
- >
8
- > 本文是完整计划 + 现状盘点 + 分阶段验收。执行登记见 `docs/feedback.md` F-54…F-57、`tasks.md` P27。
9
-
10
- ## 1. 产品形态与定位
11
-
12
- - **形态**:DSH(DeepSeek Harness)的 **bundle 插件** + 一个专用 profile(`deckline`)。
13
- 不是独立 App;DSH 负责 chat / 模型 / 权限,Deckline 负责「整页图片 deck」的工作台。
14
- - **一句话**:把「讲给谁、讲什么、怎么出图」变成一条可追踪的产线——
15
- Chat 里讨论 → script / intent / 治理文档 → 逐页 image prompt → 单页出图 + 版本 → 导出 / 交接。
16
- - **不做什么**:不做 HTML deck 渲染器(另立项目);不默认批量出整套图;不改用户 deck 源目录。
17
- - **目标用户**:咨询 / 培训 / 内部汇报 / 内容创作者,已经有 DSH 或愿意装 DSH 的人。
18
-
19
- ## 2. 现状盘点(已具备 / 缺口)
20
-
21
- | 能力 | 现状 | 产品化缺口 |
22
- |---|---|---|
23
- | DSH 插件形态 | ✅ bundle + preset + 客户端面板 | 包元数据已整理(MIT / 直发名 / 无个人路径,见 §10) |
24
- | 安装 | ✅ npm 直发包名 / git 子目录 / 本地 clone 三种方式(`docs/install.md`) | npm 尚未发布(负责人执行) |
25
- | 配置 | ✅ profile patch + `cordis.example.yml` + env 口径(个人路径已全部下沉到本机 patch) | 团队共享配置模板(Phase 3) |
26
- | 生图 key | ✅ `apiKeyEnv` / `apiKeyFile`,界面只显示是否配置 | 缺文档 + 设置面板更明确的引导 |
27
- | 风格 | ✅ 添加风格(贴图/上传/拖拽/粘贴)+ 8 个预设 | 预设需要随插件分发 + 一键导入(已做) |
28
- | 数据 | ✅ `.deck/` 全部 gitignore,源 deck 只读 | 缺「数据在哪 / 怎么备份 / 怎么迁移」说明 |
29
- | 验证 | ✅ smoke 46 项 + harness 门禁 + Agent 评估 16 场景 + 真机 Playwright 验证 | CI / 公开 fixture(Phase 1) |
30
- | 文档 | ✅ README(中/英)+ 安装 / 风格目录 / 示例 deck 文档(中/英)+ 兼容矩阵 | productization 英译、贡献指南、截图(Phase 2) |
31
-
32
- ## 3. 分阶段计划(建议按此节奏)
33
-
34
- ### Phase 0 · 可安装(v0.1,1–2 天)
35
-
36
- - [x] 插件包元数据:加 `repository` / `homepage` / `keywords` / `peerDependencies`(`private: true` + `UNLICENSED` 暂留防误发,license 拍板后改);
37
- - [x] 默认配置模板:`plugin/deck-studio/cordis.example.yml`(decks / projectsRoot / render 节点);
38
- - [x] 安装文档 `docs/install.md`(npm / git / 本地 三种方式 + key 配置 + 排障);
39
- - [x] README 对外化(产品介绍 / 5 分钟安装 / 配置 / 加 design / 风格);
40
- - [x] 预设风格随插件分发:`seeds/styles/*.json` + `seeds/samples/*.jpg` + 「+ 导入预设风格」;
41
- - [x] 添加 design 支持贴图 / 拖拽 / 选文件;已有风格可继续加样张;
42
- - [x] 生图 key:工作台设置面板显示节点 + 「key 是否配置」+ 缺 key 提示;
43
- - [x] 把当前机器上的个人配置从**插件默认 patch** 挪到 profile patch(保证默认包可分发)——已迁移并用 `--dump-config` 验证。
44
-
45
- **验收**:一台干净机器(macOS/Linux,Node `^22.19` 或 `≥24` + pnpm + DSH)按 README 走完能:启动 → 建 deck →
46
- 建风格(贴图)→ 设置里看到 key 状态 →(fake 模式)走完一次出图。
47
-
48
- ### Phase 1 · 可分发(v0.1.0,已就绪,待负责人执行发布)
49
-
50
- - [x] **许可证:MIT**(负责人 2026-10-21 拍板)——`LICENSE` 已落仓库,包元数据同步;
51
- - [x] **包名直发**:`dsh-plugin-deck-studio`,无 org / scope;`private: false`;
52
- - [x] **公开范围**(负责人拍板):插件 + 对外 docs + 预设 design(seeds)+ 1 个 sample deck + 1 个 sample logo;
53
- → 用 `scripts/build-public-bundle.mjs` 生成**白名单干净目录**(不含内部台账 / 客户名 / 个人路径 / git 历史);
54
- - [x] sample logo:`assets/logo/deckline-logo.svg|png` + mark;README 顶部已引用;
55
- - [x] sample deck:`samples/deckline-intro/`(Deckline 产品说明手册 10 页源 + 可粘贴跑通流程文案 `docs/sample-deck.md`);
56
- - [x] 隐私扫描:插件代码已脱敏(客户名 / 个人路径 / key 名全部换掉),打包脚本内置禁用词扫描;
57
- - [x] `CHANGELOG.md` + v0.1.0;
58
- - [ ] **仓库公开**:`gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push`
59
- (需负责人确认后执行;不要推当前开发仓库——它的 git 历史含内部过程文档与客户信息);
60
- - [ ] `npm publish dsh-plugin-deck-studio`(需 npm 账号 + 2FA);
61
- - [ ] README 顶部补 3 张真机截图/GIF(公开前);
62
- - [ ] GitHub Actions:
63
- - `ci.yml`:`node --check` + smoke(`plugin/deck-studio/verify/smoke.mjs`)+ 提交信息规范;
64
- - `release.yml`:tag 时 `npm publish`(用 `NPM_TOKEN` secret);
65
- - [x] 版本兼容:`peerDependencies` / `engines.dsh` 声明 `0.1.7–0.2.x`;`docs/compat.md` 记录 0.1.7-rc.2 / 0.2.1-rc.2 两批回归。
66
-
67
- ### Phase 2 · 好上手(v0.3,1 周)
68
-
69
- - [ ] 首次启动向导:无 deck 时引导「新建 deck / 导入预设风格 / 配 key」三步;
70
- - [ ] 「新建 Deck」表单支持从预设风格里选(现在只能手填风格);
71
- - [ ] 风格库页面:预览 / 搜索 / 标签(商务、fancy、日系…),一键套用到新 deck;
72
- - [ ] 数据管理:`.deck` 位置可视化、备份/导出按钮(zip);
73
- - [ ] i18n:中文 + English(DSH 本身支持多语言)——公开文档已中英双语,UI 文案待做;
74
- - [ ] 错误上报:出图失败给出可操作原因(key / 配额 / 模型名 / 尺寸)。
75
-
76
- ### Phase 3 · 可协作(v0.4+)
77
-
78
- - [ ] 多用户 / 团队共享 profile 配置模板(不共享 key);
79
- - [ ] 风格包 marketplace(社区贡献 `seeds/styles`,PR 校验 schema + 样张);
80
- - [ ] 出图成本估算 / 用量统计(按节点);
81
- - [ ] Deck 源适配更多目录约定(现在扫描 `outputs/full/final`、`outputs/final`、`pages`、`images`、`exports`)。
82
-
83
- ### Phase 4 · 可选(视需求)
84
-
85
- - 桌面版(DSH desktop 已有)、Docker 镜像、SaaS 托管;
86
- - 与对象存储 / 图床集成(出图直接进 CDN);
87
- - HTML deck 渲染器(独立项目,不在本仓库)。
88
-
89
- ## 4. Git 如何公开(具体步骤)
90
-
91
- > 负责人已拍板:**公开范围 = 插件 + 对外 docs + 预设 design + 1 个 sample deck + 1 个 sample logo**。
92
- > 当前开发仓库的 git 历史含内部台账(feedback / tasks / 客户名 / 个人路径),**不能直接 push**。
93
- > 用白名单脚本生成干净目录,再创建一个新的公开仓库。
94
-
95
- ```sh
96
- # 1) 生成干净目录(白名单 + 隐私扫描;产物在 dist/public,已 gitignore)
97
- node scripts/build-public-bundle.mjs
98
- # ✔ 白名单 + 隐私扫描通过(以脚本输出为准),无 /Users/ 个人路径、无客户名、无 key
99
-
100
- # 2) 建公开仓库(负责人确认后执行;账号 yuna78)
101
- gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push
102
-
103
- # 3) 补仓库元信息:About = "DSH image deck workbench plugin",
104
- # Topics = deepseek-harness, dsh-plugin, image-deck, presentation, deck
105
- # 4) 打 tag / 发 Release
106
- cd dist/public && git tag v0.1.0 && git push origin v0.1.0
107
- gh release create v0.1.0 --notes "First public release: install via dsh plugin add dsh-plugin-deck-studio"
108
-
109
- # 5) npm 发布(Phase 1)
110
- cd plugin/deck-studio
111
- npm publish --access public # 需要 npm 账号 + 2FA
112
- ```
113
-
114
- **公开包内容(白名单)**:
115
-
116
- - `README.md` / `LICENSE` / `CHANGELOG.md`;
117
- - `docs/`:`productization.md`、`install.md` + `install.en.md`、`styles.md` + `styles.en.md`、`sample-deck.md` + `sample-deck.en.md`、`compat.md`;
118
- - `plugin/deck-studio/`:插件本体(宿主 + 客户端 + ui + lib + seeds 预设风格/样张 + verify smoke);
119
- - `samples/deckline-intro/`:示例 deck 源(README / intent / script);
120
- - `assets/logo/`:sample logo(svg + png)。
121
-
122
- **不公开**:`CURRENT.md` / `HANDOVER.md` / `tasks.md` / `docs/feedback.md` / `docs/architecture.md` /
123
- `docs/adr/` / `docs/research/` / `fixtures/`(含客户材料的本地源引用)/ `.deck/`(运行数据)/ git 历史。
124
-
125
- **已完成的清理**:
126
-
127
- 1. `cordis.patch.yml` 个人路径 → profile patch;仓库里是通用 bundle patch + `cordis.example.yml`;
128
- 2. 插件 `package.json`:`private: false`、MIT、直发包名、repository / homepage / peerDependencies;
129
- 3. 插件代码脱敏:`client.js` / `lib/config.js` / `lib/deck-workspace.js` / `lib/render-nodes.js` /
130
- `lib/source-adapter.js` / `lib/tools.js` / `verify/smoke.mjs` 里的客户名、个人路径、环境变量名全部替换为通用示例;
131
- 4. 白名单脚本内置禁用词扫描(客户名 / `/Users/` / `sk-` / 私有 key 名),命中即中止打包。
132
-
133
- ## 5. 安装与分发矩阵
134
-
135
- | 方式 | 命令 | 适合 |
136
- |---|---|---|
137
- | npm | `dsh plugin --profile deckline add dsh-plugin-deck-studio` | 普通用户(发布后) |
138
- | Git | `dsh plugin --profile deckline add "github:yuna78/dsh-deck-studio#path:/plugin/deck-studio"` | 想跟 main 的人 |
139
- | 本地 clone | `dsh plugin --profile deckline add "$PWD/plugin/deck-studio"` | 开发者 / 定制 |
140
-
141
- 三种方式都落在 `~/.dsh/profiles/deckline/`;安装后用户只需要改 **profile patch**(decks / projectsRoot / render 节点),
142
- 不需要动插件包本身——这是「任何人可安装」的关键边界。
143
-
144
- ## 6. 配置口径(生图 key)
145
-
146
- - 配置只存在于两处:**profile patch**(结构)与 **环境变量 / key 文件**(凭证);
147
- - 结构里只写 `apiKeyEnv`(变量名)或 `apiKeyFile`(本机路径),**永远不写 key 明文**;
148
- - 工作台设置面板只显示 `keyConfigured` 布尔 + 来源名;
149
- - 支持多节点(主 / 备用 / 不同模型),每节点独立 key;
150
- - 缺 key 时:fake 模式仍可走通流程;real 模式报错信息直接给出配置位置。
151
-
152
- ## 7. 风格生态(本产品化差异点)
153
-
154
- - **预设包随插件分发**:`plugin/deck-studio/seeds/styles/<ABBR>.json`(定义,含 `styleBrief` + `baselineBriefs`)
155
- + `seeds/samples/<ABBR>-0{1,2,3}.jpg`(3 张基线样张);
156
- - **一键导入**:Designs 页「+ 导入预设风格」,已存在的缩写自动跳过(幂等);
157
- - **自己加**:界面里贴图/上传/拖拽;或把图片放到 `designs/<ABBR>/`;
158
- - **贡献**:PR 新增一个 JSON + 3 张基线样张即可(schema:abbr / name / description / constraints / reference / styleBrief / baselineBriefs);
159
- - 已知限制:样张是风格示意,不保证能逐字复刻其中的文字(图像模型通病);要精确文字用 HTML/Mermaid 叠字。
160
-
161
- ## 8. 风险与边界
162
-
163
- | 风险 | 说明 | 对策 |
164
- |---|---|---|
165
- | DSH 插件 API 变动 | 插件依赖 DSH 版本 | 声明 peer 范围 + CI 跑 smoke + 版本豁免文档 |
166
- | 凭证泄漏 | 用户误把 key 写进 patch | 文档强调 apiKeyEnv / apiKeyFile;设置面板不回显 |
167
- | 出图成本失控 | 用户批量出图 | 允许点名批量 / 整套(逐页留痕、失败单页重出);不做一键按钮,避免误触 |
168
- | 客户数据 | deck 源可能含敏感内容 | 源只读、产物本地 `.deck`、仓库不含数据;导出交接包脱敏 |
169
- | 模型质量 | 文字糊、版式跑 | 风格 prompt 约束 + 「文字少而英文」建议 + 后期叠字 |
170
-
171
- ## 9. 里程碑(建议时间)
172
-
173
- - **M1(本周)**:Phase 0 完成 + 本机导入 8 个预设风格可用;
174
- - **M2(下周)**:仓库公开 + v0.1.0 Release + 2 位外部用户装通;
175
- - **M3(两周内)**:npm 发布 + CI + 首次启动向导;
176
- - **M4(一个月)**:风格库页面 + UI 双语 + 社区风格包。
177
-
178
- ## 10. 已拍板(2026-10-21)
179
-
180
- | # | 决策 | 结论 | 落地 |
181
- |---|---|---|---|
182
- | 1 | License | **MIT** | `LICENSE` + package.json `license: MIT` |
183
- | 2 | 包名 | **直发,无 org**:`dsh-plugin-deck-studio` | package.json `name` / `private: false` |
184
- | 3 | 公开范围 | 插件 + docs + 预设 design + **1 个 sample deck** + **1 个 sample logo** | `scripts/build-public-bundle.mjs` 白名单;不含内部台账与历史 |
185
- | 4 | 品牌 | **Deckline** 最终确认(仓库名仍 `dsh-deck-studio`) | README / UI / logo |
186
- | 5 | 公开账号 | GitHub `yuna78`;仓库 `yuna78/dsh-deck-studio`(public) | 待负责人确认后 `gh repo create` + push |
187
-
188
- **还等负责人执行的 2 个动作**:
189
-
190
- 1. 确认公开:跑 `node scripts/build-public-bundle.mjs` 后 `gh repo create yuna78/dsh-deck-studio --public --source dist/public --remote origin --push`;
191
- 2. npm 发布:`cd plugin/deck-studio && npm publish --access public`(需登录 npm + 2FA)。
192
-
193
- 之后 CI / Release / 截图由本轮之后的迭代补。