dsh-context-compression-improved 0.10.1 → 0.10.2

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.
Files changed (262) hide show
  1. package/README.md +15 -110
  2. package/README.zh.md +14 -104
  3. package/THIRD_PARTY_NOTICES.md +25 -7
  4. package/{packages/selector/dsh.plugin.json → dsh.plugin.json} +1 -1
  5. package/{packages/selector/lib → lib}/client.js +73 -12
  6. package/package.json +125 -112
  7. package/screenshots.json +3 -6
  8. package/.agents/plans/improve/checklist.md +0 -32
  9. package/.agents/plans/improve/findings.md +0 -102
  10. package/.agents/plans/improve/spec.md +0 -53
  11. package/.agents/plans/improve/tasks.md +0 -70
  12. package/.gitattributes +0 -2
  13. package/.githooks/pre-push +0 -37
  14. package/.github/workflows/ci.yml +0 -39
  15. package/CHANGELOG.de.md +0 -580
  16. package/CHANGELOG.es.md +0 -588
  17. package/CHANGELOG.fr.md +0 -576
  18. package/CHANGELOG.it.md +0 -577
  19. package/CHANGELOG.ja.md +0 -261
  20. package/CHANGELOG.ko.md +0 -254
  21. package/CHANGELOG.md +0 -544
  22. package/CHANGELOG.ru.md +0 -554
  23. package/CHANGELOG.zh.md +0 -238
  24. package/CONTRIBUTING.md +0 -22
  25. package/README.de.md +0 -96
  26. package/README.es.md +0 -96
  27. package/README.fr.md +0 -96
  28. package/README.it.md +0 -96
  29. package/README.ja.md +0 -102
  30. package/README.ko.md +0 -102
  31. package/README.ru.md +0 -96
  32. package/SECURITY.md +0 -18
  33. package/assets/board.png +0 -0
  34. package/assets/context.png +0 -0
  35. package/docs/assets/context-compression-selector-profiles.jpg +0 -0
  36. package/docs/assets/context-compression-selector-settings.png +0 -0
  37. package/docs/compat-0.1.5-report.md +0 -77
  38. package/docs/installation.de.md +0 -104
  39. package/docs/installation.es.md +0 -104
  40. package/docs/installation.fr.md +0 -104
  41. package/docs/installation.it.md +0 -104
  42. package/docs/installation.ja.md +0 -78
  43. package/docs/installation.ko.md +0 -78
  44. package/docs/installation.md +0 -103
  45. package/docs/installation.ru.md +0 -104
  46. package/docs/installation.zh.md +0 -100
  47. package/docs/repair-log.md +0 -657
  48. package/eslint.config.js +0 -30
  49. package/packages/selector/LICENSE +0 -21
  50. package/packages/selector/README.md +0 -26
  51. package/packages/selector/README.zh.md +0 -24
  52. package/packages/selector/THIRD_PARTY_NOTICES.md +0 -32
  53. package/packages/selector/docs/history-tool-call-working-set-spec.md +0 -112
  54. package/packages/selector/docs/native-tool-result-selector-spec.md +0 -34
  55. package/packages/selector/docs/subagent-cache-reuse-spec.md +0 -46
  56. package/packages/selector/lib/style.css +0 -350
  57. package/packages/selector/package.json +0 -178
  58. package/packages/selector/screenshots.json +0 -3
  59. package/packages/selector/src/client/CompressionProfileControls.tsx +0 -293
  60. package/packages/selector/src/client/CompressionProfileSelector.module.css +0 -199
  61. package/packages/selector/src/client/CompressionProfileSelector.tsx +0 -85
  62. package/packages/selector/src/client/CustomPolicyEditor.tsx +0 -216
  63. package/packages/selector/src/client/EstimatorControls.tsx +0 -277
  64. package/packages/selector/src/client/bridge-scope.ts +0 -125
  65. package/packages/selector/src/client/decode.ts +0 -57
  66. package/packages/selector/src/client/index.ts +0 -424
  67. package/packages/selector/src/client/locales/de.ts +0 -158
  68. package/packages/selector/src/client/locales/es.ts +0 -158
  69. package/packages/selector/src/client/locales/fr.ts +0 -158
  70. package/packages/selector/src/client/locales/it.ts +0 -158
  71. package/packages/selector/src/client/locales/ja.ts +0 -158
  72. package/packages/selector/src/client/locales/ko.ts +0 -158
  73. package/packages/selector/src/client/locales/ru.ts +0 -158
  74. package/packages/selector/src/client/locales.ts +0 -316
  75. package/packages/selector/src/client/monitor-fab.ts +0 -419
  76. package/packages/selector/src/client/preset-options.ts +0 -88
  77. package/packages/selector/src/client/savings-card.tsx +0 -269
  78. package/packages/selector/src/client/scope-face.ts +0 -24
  79. package/packages/selector/src/client/settings-section.tsx +0 -140
  80. package/packages/selector/src/compat/host-generation.ts +0 -96
  81. package/packages/selector/src/compat/llm-messages.ts +0 -50
  82. package/packages/selector/src/compat/settings-lease.ts +0 -108
  83. package/packages/selector/src/compat/tool-result.ts +0 -91
  84. package/packages/selector/src/css-modules.d.ts +0 -6
  85. package/packages/selector/src/deepseek-v4-tokenizer.ts +0 -205
  86. package/packages/selector/src/estimator-catalog.ts +0 -104
  87. package/packages/selector/src/index.ts +0 -890
  88. package/packages/selector/src/invariant.ts +0 -113
  89. package/packages/selector/src/preset-overlay.ts +0 -749
  90. package/packages/selector/src/profiles.ts +0 -431
  91. package/packages/selector/src/pruner/content.ts +0 -198
  92. package/packages/selector/src/pruner/session.ts +0 -97
  93. package/packages/selector/src/pruner/state.ts +0 -61
  94. package/packages/selector/src/pruner/tuning.ts +0 -23
  95. package/packages/selector/src/pruner/types.ts +0 -78
  96. package/packages/selector/src/pruner.ts +0 -2914
  97. package/packages/selector/src/runtime/adaptive-cost.ts +0 -205
  98. package/packages/selector/src/runtime/audit.ts +0 -320
  99. package/packages/selector/src/runtime/config.ts +0 -756
  100. package/packages/selector/src/runtime/custom-policy.ts +0 -278
  101. package/packages/selector/src/runtime/deepseek-official-pricing.ts +0 -298
  102. package/packages/selector/src/runtime/deepseek-v4-vision-tokens.ts +0 -254
  103. package/packages/selector/src/runtime/display-prefs.ts +0 -98
  104. package/packages/selector/src/runtime/measurement.ts +0 -444
  105. package/packages/selector/src/runtime/monitor.ts +0 -310
  106. package/packages/selector/src/runtime/panel-command.ts +0 -213
  107. package/packages/selector/src/runtime/reducers.ts +0 -1754
  108. package/packages/selector/src/runtime/retrieve.ts +0 -503
  109. package/packages/selector/src/runtime/savings-integral.ts +0 -117
  110. package/packages/selector/src/runtime/savings-projection.ts +0 -229
  111. package/packages/selector/src/runtime/savings-verify.ts +0 -446
  112. package/packages/selector/src/runtime/savings.ts +0 -526
  113. package/packages/selector/src/runtime/session-events.ts +0 -30
  114. package/packages/selector/src/runtime/session-file-decode.ts +0 -523
  115. package/packages/selector/src/runtime/stats-backfill.ts +0 -541
  116. package/packages/selector/src/runtime/stats-db.ts +0 -492
  117. package/packages/selector/src/runtime/stats-schema.ts +0 -123
  118. package/packages/selector/src/runtime/stats-sync.ts +0 -307
  119. package/packages/selector/src/runtime/summary-command.ts +0 -127
  120. package/packages/selector/src/runtime/tail-trim.ts +0 -176
  121. package/packages/selector/src/runtime/token-count.ts +0 -72
  122. package/packages/selector/src/runtime/tokenpilot/advisor-prompt.ts +0 -233
  123. package/packages/selector/src/runtime/tokenpilot/advisor-state.ts +0 -204
  124. package/packages/selector/src/runtime/tokenpilot/advisor.ts +0 -419
  125. package/packages/selector/src/runtime/tokenpilot/benefit.ts +0 -200
  126. package/packages/selector/src/runtime/tokenpilot/dedup.ts +0 -81
  127. package/packages/selector/src/runtime/tokenpilot/estimator.ts +0 -151
  128. package/packages/selector/src/runtime/tokenpilot/intent-fold.ts +0 -53
  129. package/packages/selector/src/runtime/tokenpilot/intent-gate.ts +0 -65
  130. package/packages/selector/src/runtime/tokenpilot/intent-input-mask.ts +0 -125
  131. package/packages/selector/src/runtime/tokenpilot/intent-range.ts +0 -37
  132. package/packages/selector/src/runtime/tokenpilot/locator.ts +0 -128
  133. package/packages/selector/src/runtime/tokenpilot/read-state.ts +0 -98
  134. package/packages/selector/src/runtime/tokenpilot/sidechannel.ts +0 -303
  135. package/packages/selector/src/runtime/toolclass.ts +0 -103
  136. package/packages/selector/src/runtime/types.ts +0 -365
  137. package/packages/selector/src/runtime/value.ts +0 -48
  138. package/packages/selector/src/settings-bridge.ts +0 -175
  139. package/packages/selector/tests/advisor-report.host.spec.ts +0 -223
  140. package/packages/selector/tests/auto-compact.client.spec.tsx +0 -214
  141. package/packages/selector/tests/built/client-artifact.spec.ts +0 -56
  142. package/packages/selector/tests/cache-prefix-audit.spec.ts +0 -123
  143. package/packages/selector/tests/code-skeleton.client.spec.ts +0 -98
  144. package/packages/selector/tests/compat/compat-narrow-waist.spec.ts +0 -150
  145. package/packages/selector/tests/custom-contract.client.spec.ts +0 -226
  146. package/packages/selector/tests/estimator-catalog.spec.ts +0 -70
  147. package/packages/selector/tests/estimator-channel.client.spec.tsx +0 -253
  148. package/packages/selector/tests/estimator-route-registration.host.spec.ts +0 -202
  149. package/packages/selector/tests/helpers/legacy-namespace.ts +0 -35
  150. package/packages/selector/tests/helpers/legacy-settings/index.ts +0 -15
  151. package/packages/selector/tests/helpers/legacy-settings/legacy/provider.d.ts +0 -41
  152. package/packages/selector/tests/helpers/legacy-settings/legacy/provider.js +0 -647
  153. package/packages/selector/tests/helpers/legacy-settings/legacy/redact.js +0 -78
  154. package/packages/selector/tests/helpers/legacy-settings/legacy/util-values.js +0 -234
  155. package/packages/selector/tests/host-preset-overlay.host.spec.ts +0 -204
  156. package/packages/selector/tests/monitor-fab.client.spec.ts +0 -220
  157. package/packages/selector/tests/preset-options-write.client.spec.ts +0 -192
  158. package/packages/selector/tests/preset-overlay-loader.e2e.host.spec.ts +0 -200
  159. package/packages/selector/tests/preset-overlay.host.spec.ts +0 -246
  160. package/packages/selector/tests/profiles.client.spec.tsx +0 -436
  161. package/packages/selector/tests/public/package-contract.client.spec.ts +0 -86
  162. package/packages/selector/tests/runtime/adaptive-cost.spec.ts +0 -167
  163. package/packages/selector/tests/runtime/advice-never-withholds.host.spec.ts +0 -230
  164. package/packages/selector/tests/runtime/advisor-invariant.spec.ts +0 -272
  165. package/packages/selector/tests/runtime/advisor.spec.ts +0 -226
  166. package/packages/selector/tests/runtime/audit.spec.ts +0 -275
  167. package/packages/selector/tests/runtime/auto-compact-config.spec.ts +0 -523
  168. package/packages/selector/tests/runtime/char-basis.spec.ts +0 -30
  169. package/packages/selector/tests/runtime/code-skeleton.spec.ts +0 -152
  170. package/packages/selector/tests/runtime/deepseek-official-pricing.spec.ts +0 -186
  171. package/packages/selector/tests/runtime/deepseek-v4-tokenizer.spec.ts +0 -122
  172. package/packages/selector/tests/runtime/deepseek-v4-vision-tokens.spec.ts +0 -122
  173. package/packages/selector/tests/runtime/deprecated-preset-options.spec.ts +0 -96
  174. package/packages/selector/tests/runtime/fixtures/profile-baseline.json +0 -273
  175. package/packages/selector/tests/runtime/fixtures/session-v4-dump.jsonl +0 -46
  176. package/packages/selector/tests/runtime/fixtures/tokenizer-golden.json +0 -106
  177. package/packages/selector/tests/runtime/fixtures/vision-golden.json +0 -459
  178. package/packages/selector/tests/runtime/frequency-longstrings.spec.ts +0 -74
  179. package/packages/selector/tests/runtime/fresh-gate.spec.ts +0 -43
  180. package/packages/selector/tests/runtime/html-reducer.spec.ts +0 -212
  181. package/packages/selector/tests/runtime/intent-gate.spec.ts +0 -62
  182. package/packages/selector/tests/runtime/intent-summary.spec.ts +0 -156
  183. package/packages/selector/tests/runtime/jsonl-reducer.spec.ts +0 -79
  184. package/packages/selector/tests/runtime/line-mapping.spec.ts +0 -153
  185. package/packages/selector/tests/runtime/monitor.spec.ts +0 -354
  186. package/packages/selector/tests/runtime/panel-command.spec.ts +0 -101
  187. package/packages/selector/tests/runtime/prose-reducers.spec.ts +0 -133
  188. package/packages/selector/tests/runtime/public/public-runtime.spec.ts +0 -2781
  189. package/packages/selector/tests/runtime/read-input-cap.spec.ts +0 -33
  190. package/packages/selector/tests/runtime/savings-accounting.spec.ts +0 -291
  191. package/packages/selector/tests/runtime/savings-integral.spec.ts +0 -169
  192. package/packages/selector/tests/runtime/savings-projection.spec.ts +0 -89
  193. package/packages/selector/tests/runtime/savings-verify.spec.ts +0 -226
  194. package/packages/selector/tests/runtime/savings.spec.ts +0 -139
  195. package/packages/selector/tests/runtime/search-reducer.spec.ts +0 -110
  196. package/packages/selector/tests/runtime/session-events.spec.ts +0 -27
  197. package/packages/selector/tests/runtime/session-file-decode.spec.ts +0 -281
  198. package/packages/selector/tests/runtime/settings-unwrap.spec.ts +0 -58
  199. package/packages/selector/tests/runtime/sidechannel.spec.ts +0 -241
  200. package/packages/selector/tests/runtime/stats-backfill-scheduler.spec.ts +0 -167
  201. package/packages/selector/tests/runtime/stats-backfill.spec.ts +0 -348
  202. package/packages/selector/tests/runtime/stats-db.spec.ts +0 -361
  203. package/packages/selector/tests/runtime/stats-privacy.spec.ts +0 -55
  204. package/packages/selector/tests/runtime/stats-sync.spec.ts +0 -278
  205. package/packages/selector/tests/runtime/summary-command.spec.ts +0 -154
  206. package/packages/selector/tests/runtime/toc-and-bundled.spec.ts +0 -159
  207. package/packages/selector/tests/runtime/tokenizer-golden.spec.ts +0 -53
  208. package/packages/selector/tests/runtime/tokenpilot/benefit.spec.ts +0 -217
  209. package/packages/selector/tests/runtime/tokenpilot/dedup.spec.ts +0 -52
  210. package/packages/selector/tests/runtime/tokenpilot/estimator.spec.ts +0 -79
  211. package/packages/selector/tests/runtime/tokenpilot/locator.spec.ts +0 -76
  212. package/packages/selector/tests/runtime/tokenpilot/profile-baseline.spec.ts +0 -119
  213. package/packages/selector/tests/runtime/tokenpilot/read-state.spec.ts +0 -82
  214. package/packages/selector/tests/runtime/toolclass.spec.ts +0 -156
  215. package/packages/selector/tests/runtime/value.spec.ts +0 -23
  216. package/packages/selector/tests/savings-sessions.client.spec.tsx +0 -140
  217. package/packages/selector/tests/settings-seat.client.spec.ts +0 -215
  218. package/packages/selector/tests/standing-generation.host.spec.ts +0 -724
  219. package/packages/selector/tests/subagent-cache-reuse.host.spec.ts +0 -269
  220. package/packages/selector/tests/support/cache-prefix-audit.ts +0 -105
  221. package/packages/selector/tests/support/mock-adapter.ts +0 -37
  222. package/packages/selector/tests/support/ui-primitives.tsx +0 -34
  223. package/packages/selector/tsconfig.json +0 -11
  224. package/packages/selector/tsdown.client.config.ts +0 -102
  225. package/packages/selector/tsdown.config.ts +0 -20
  226. package/pnpm-workspace.yaml +0 -76
  227. package/scripts/capture-profile-baseline.mjs +0 -42
  228. package/scripts/cell-browser-e2e.mjs +0 -354
  229. package/scripts/generate-tokenizer-fixtures.py +0 -81
  230. package/scripts/generate-vision-fixtures.py +0 -208
  231. package/scripts/hosts.mjs +0 -78
  232. package/scripts/packed-components-smoke.mjs +0 -763
  233. package/scripts/packed-install-e2e.mjs +0 -1346
  234. package/scripts/sync-hosts.mjs +0 -174
  235. package/scripts/toolclass-corpus-replay.mjs +0 -281
  236. package/scripts/verify-release.mjs +0 -338
  237. package/tests/TEST_INVENTORY.md +0 -41
  238. package/tsconfig.base.json +0 -18
  239. package/tsconfig.json +0 -7
  240. package/tsconfig.tests.json +0 -15
  241. package/vitest.built.config.ts +0 -9
  242. package/vitest.config.ts +0 -54
  243. /package/{packages/selector/assets → assets}/deepseek-v4/LICENSE.DeepSeek-V4-Pro.txt +0 -0
  244. /package/{packages/selector/assets → assets}/deepseek-v4/manifest.json +0 -0
  245. /package/{packages/selector/assets → assets}/deepseek-v4/tokenizer.json +0 -0
  246. /package/{packages/selector/assets → assets}/deepseek-v4/tokenizer_config.json +0 -0
  247. /package/{packages/selector/assets → assets}/deepseek-v4-vision-exp/LICENSE.DeepSeek-V4-Flash-Vision-Exp.txt +0 -0
  248. /package/{packages/selector/assets → assets}/deepseek-v4-vision-exp/manifest.json +0 -0
  249. /package/{packages/selector/assets → assets}/deepseek-v4-vision-exp/tokenizer.json +0 -0
  250. /package/{packages/selector/assets → assets}/deepseek-v4-vision-exp/tokenizer_config.json +0 -0
  251. /package/{packages/selector/cordis.patch.yml → cordis.patch.yml} +0 -0
  252. /package/{packages/selector/lib → lib}/client.d.ts +0 -0
  253. /package/{packages/selector/lib → lib}/index.d.ts +0 -0
  254. /package/{packages/selector/lib → lib}/index.js +0 -0
  255. /package/{packages/selector/lib → lib}/invariant.d.ts +0 -0
  256. /package/{packages/selector/lib → lib}/invariant.js +0 -0
  257. /package/{packages/selector/lib → lib}/profiles.d.ts +0 -0
  258. /package/{packages/selector/lib → lib}/pruner.d.ts +0 -0
  259. /package/{packages/selector/lib → lib}/pruner.js +0 -0
  260. /package/{packages/selector/lib → lib}/savings-integral.js +0 -0
  261. /package/{packages/selector/lib → lib}/tail-trim.js +0 -0
  262. /package/{packages/selector/lib → lib}/tool-result.js +0 -0
package/eslint.config.js DELETED
@@ -1,30 +0,0 @@
1
- import js from '@eslint/js'
2
- import globals from 'globals'
3
- import tseslint from 'typescript-eslint'
4
-
5
- export default tseslint.config(
6
- {
7
- ignores: ['**/node_modules/**', '**/lib/**', '**/dist/**', '**/coverage/**', 'docs/**'],
8
- },
9
- js.configs.recommended,
10
- ...tseslint.configs.recommended,
11
- {
12
- files: ['packages/**/*.{ts,tsx}', 'scripts/**/*.{js,mjs}', 'eslint.config.js'],
13
- languageOptions: {
14
- globals: { ...globals.browser, ...globals.node },
15
- },
16
- rules: {
17
- '@typescript-eslint/no-unused-vars': ['error', {
18
- argsIgnorePattern: '^_',
19
- varsIgnorePattern: '^_',
20
- caughtErrorsIgnorePattern: '^_',
21
- destructuredArrayIgnorePattern: '^_',
22
- }],
23
- },
24
- },
25
- {
26
- // Terminal normalization intentionally matches ANSI/BEL control characters.
27
- files: ['packages/selector/src/runtime/reducers.ts'],
28
- rules: { 'no-control-regex': 'off' },
29
- },
30
- )
@@ -1,21 +0,0 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 WilliamShi666
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
@@ -1,26 +0,0 @@
1
- # dsh-context-compression-improved
2
-
3
- The installable Product Bundle for the unofficial community DeepSeek Harness context-compression selector.
4
-
5
- **0.1.0 highlights:** DeepSeek V4 Flash Vision's official tokenizer is included; users can choose the model-driven Auto Compact threshold; standard profile watermarks and compression parameters follow that choice.
6
-
7
- ```sh
8
- ```sh
9
- dsh plugin --profile web add dsh-context-compression-improved@dsh-0.1.5
10
- # DSH 0.1.2 line:
11
- # dsh plugin --profile web add dsh-context-compression-improved@dsh-0.1.2
12
- dsh --profile web --dump-config
13
- ```
14
- dsh --profile web --dump-config
15
- ```
16
-
17
- This one command installs the single `dsh-context-compression-improved` package: the compression
18
- runtime, the Host settings, the Web UI and the reversible preset overlay all ship in it.
19
- The Bundle contributes Host settings, the Web UI, and a reversible preset overlay. All presets
20
- except the exact built-in `minimal` id receive the compression stack; switching non-Minimal
21
- presets preserves the saved selector settings. Minimal pauses plugin compression without
22
- deleting the setting.
23
-
24
- Verified compatibility: DeepSeek Harness `dsh-v0.1.1-rc.2` and `dsh-v0.1.2-alpha.5`, Node `^22.19.0 || >=24`. No Harness core patch is required.
25
-
26
- See the [full README](https://github.com/WilliamShi666/dsh-context-compression-improved#readme) for profiles, defaults, audit evidence, Adaptive/cache limitations, upgrade/removal, and security guidance. This package is not affiliated with or endorsed by DeepSeek.
@@ -1,24 +0,0 @@
1
- # dsh-context-compression-improved
2
-
3
- 这是可直接安装的非官方社区 DeepSeek Harness 上下文压缩选择器 Product Bundle。
4
-
5
- **0.1.0 更新:**已加入 DeepSeek V4 Flash 视觉模型的官方 tokenizer;用户可选择模型驱动 Auto Compact 的触发阈值;标准 Profile 的水位与压缩参数会随该选择联动。
6
-
7
- ```sh
8
- ```sh
9
- dsh plugin --profile web add dsh-context-compression-improved@dsh-0.1.5
10
- # DSH 0.1.2 line:
11
- # dsh plugin --profile web add dsh-context-compression-improved@dsh-0.1.2
12
- dsh --profile web --dump-config
13
- ```
14
- dsh --profile web --dump-config
15
- ```
16
-
17
- 这一条命令安装单一的 `dsh-context-compression-improved` 包:压缩运行时、Host 设置、Web UI
18
- 与可逆 preset overlay 全部包含在其中。除 id 精确等于内置 `minimal` 的 preset 外,
19
- 其他 preset 都会获得压缩能力;非 Minimal preset 之间切换时已保存设置保持不变。
20
- Minimal 只暂停插件压缩,不删除设置。
21
-
22
- 已验证兼容 DeepSeek Harness `dsh-v0.1.1-rc.2` 与 `dsh-v0.1.2-alpha.5`,Node `^22.19.0 || >=24`。不需要修改 Harness 核心。
23
-
24
- Profile、默认值、审计证据、Adaptive/cache 限制、升级/卸载与安全说明见[完整 README](https://github.com/WilliamShi666/dsh-context-compression-improved#readme)。本包与 DeepSeek 无隶属或背书关系。
@@ -1,32 +0,0 @@
1
- # Third-party notices
2
-
3
- Portions of this package are adapted from the MIT-licensed DeepSeek Harness, verified against `dsh-v0.1.1-rc.2` (`b150a551b8d465e31e418e1b2eaf5e79bbb7d28e`).
4
-
5
- ## DeepSeek Harness MIT notice
6
-
7
- Copyright (c) 2026 DeepSeek
8
-
9
- Permission is hereby granted, free of charge, to any person obtaining a copy
10
- of this software and associated documentation files (the "Software"), to deal
11
- in the Software without restriction, including without limitation the rights
12
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13
- copies of the Software, and to permit persons to whom the Software is
14
- furnished to do so, subject to the following conditions:
15
-
16
- The above copyright notice and this permission notice shall be included in all
17
- copies or substantial portions of the Software.
18
-
19
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25
- SOFTWARE.
26
-
27
- This package carries the official DeepSeek tokenizer assets, with their exact license and
28
- provenance manifests, under `assets/`.
29
-
30
- This package depends on `js-yaml` under MIT; its production dependency `argparse` is licensed under Python-2.0. Their NPM packages carry the dependency license texts.
31
-
32
- This is an unofficial community package and is not endorsed by DeepSeek.
@@ -1,112 +0,0 @@
1
- # History / microcompact:按 agent 工具调用保护近期工作集
2
-
3
- 状态:提案,尚未实现
4
-
5
- ## 目标与边界
6
-
7
- 将插件的 History / microcompact 从“保护最近若干个 Harness turn 加一个 token 尾窗”改为“超过该 Profile 的 History 触发阈值后,保护最近 10 次已完成的 agent 工具调用”。这是一项面向所有插件 Profile 的策略变更,不是只为 Balanced 调整。
8
-
9
- 所有实现只修改本仓库的 runtime、selector UI、配置、审计、测试和 npm Bundle。不得修改 DeepSeek Harness 核心、会话事件格式、内置压缩器、provider 或 DSH UI。插件继续只消费现有公开的 `tool/call`、`tool/result` 和 Session surface API。
10
-
11
- 此前发现的 `deepseek-official` tokenizer route alias 是独立的插件内兼容性修复:需回填到本仓库的 `measurement.ts` 并测试,但不属于本 History 策略改动。
12
-
13
- ## 现有问题
14
-
15
- 当前 History 用外层 `turn` 保护近期内容。一个 turn 通常是一次用户消息驱动的 agent 处理周期,不是一次工具调用:一次“探索代码库”的用户请求可以在同一 turn 内产生几十个 Bash、Read、Grep 或 Web 调用。这样它们会被整体保护,即使其中大部分已经很旧;反过来,连续输入几条没有工具输出的用户消息也会推进保护窗口。
16
-
17
- 用户消息不是 History 的可替换对象,保护它们的外层 turn 对 History 没有实际约束意义。现有的 `historyKeepRecentTokens` 也会让“近期保护”取决于个别结果的大小,而不是 agent 最近实际使用过的工具交互数量。
18
-
19
- ## 统一语义
20
-
21
- ### 触发条件不变
22
-
23
- 每个 Profile 仍使用自己的 History gate、`historyTriggerTokens` 和 `historyMinReclaimTokens`。当且仅当:
24
-
25
- 1. 运行到了插件的 `pressure` 阶段;
26
- 2. Profile 的 History gate 允许执行;
27
- 3. 所有活动工具结果的精确 token 总数严格大于该 Profile 的 `historyTriggerTokens`;
28
-
29
- History 才会规划 microcompact。Fresh、Aggregate、Native 和 TailTrim 的各自 trigger/reducer 不因这条规则而变。
30
-
31
- ### 两部分近期工作集
32
-
33
- 一条可计数记录是一个仍在活动 surface 中、能按 `callId` 与 agent 发出的 `tool/call` 配对的 `tool/result`。计数顺序使用该调用在活动会话 surface 中的原始发生顺序,不能使用外层 turn,也不能使用之后压缩替换事件的 seq。
34
-
35
- - 精确保护最新 10 条已完成调用;不足 10 条时全部保护。
36
- - 用户消息、assistant 文本、`turn/start`、`turn/end`、`step/start`、`step/end` 都不计数,也不因它们的数量改变选择结果。
37
- - 尚未产生 `tool/result` 的未完成调用不占槽位,也不是压缩候选。
38
- - `context_compression_retrieve` 也算一次 agent 工具调用并占一个槽位,以保证“最后十次调用完全不动”的字面语义;但它本身继续永远不可被 History 重写。
39
- - 已经是 History 占位符的结果继续占槽位,但不能再次被 History 重写。
40
-
41
- 在调用数量保护之外,保留一个 `64000` token 的工具结果尾窗。从最新活动 `tool/result` 向较早结果逐条累计精确 token;每一条先加入保护集、再判断累计值是否已达到或超过 `64000`。因此,刚好使累计值跨过 `64000` 的那一条也受保护。这个尾窗同样不包含用户消息或 assistant 文本。
42
-
43
- 最终保护集是“最近 10 次调用保护集”和“最近 `64000` token 工具结果尾窗”的并集。排除它后,History 由旧到新选择安全结果,沿用现有可恢复占位符/富结果 reducer。达到 `max(historyMinReclaimTokens, totalTokens - historyTriggerTokens)` 后停止;若最终无法达到最小回收量,则整个 History 批次不提交。精确 tokenizer 不可用、结果形态不安全或 recovery tool 缺失时继续 fail-open。
44
-
45
- 删除 `historyKeepRecentTurns`,保留并将标准 Profile 的 `historyKeepRecentTokens` 统一为 `64000`。近期工作集因此同时保证最近工具交互数量和最近工具结果的内容规模。
46
-
47
- ## 各 Profile 的计划与初始参数
48
-
49
- 首版只替换“保护集的计算方法”,保留现有各 Profile 的触发和回收数值。这样可以先验证工作集语义,而不把“何时触发”“保留什么”“一次回收多少”三个变量同时改变。下表中的“建议首版”是待实现值;“后续调参”只有在带真实工具输出的可重复测试证明需要时才进行。
50
-
51
- | Profile | 当前/建议 History gate | 首版 trigger / 最小回收 | 近期保护 | 后续调参方向 |
52
- | --- | --- | --- | --- | --- |
53
- | `off` | disabled | 不触发 | 10 次调用 + `64000` token;无运行效果 | 无;保持关闭。 |
54
- | `native` | disabled | 不触发;Native 头-中-尾裁剪仍独立 | 10 次调用 + `64000` token;无运行效果 | 无;不得把 History 偷偷加入 Native。 |
55
- | `balanced` | `routine` | `500000 / 96000` tokens,保持不变 | 最近 10 次调用 + `64000` token 尾窗 | 作为基线。若保护集导致频繁无法达到 96k 回收,再只评估提高 trigger 或降低 min-reclaim 之一。 |
56
- | `cache-strict` | `capacity-pressure` | `600000 / 128000` tokens,保持不变;路由上下文利用率至少 `70%` | 最近 10 次调用 + `64000` token 尾窗 | 不降低 trigger;它以稳定已发送前缀为优先。只在已确认容量压力时改写。 |
57
- | `savings` | `routine` | `400000 / 128000` tokens | 最近 10 次调用 + `64000` token 尾窗 | 将 trigger 从 `450000` 提前到 `400000`,以更早回收旧工具结果;首版保留 `128000` 最小回收量,避免用一次很小的前缀改写交换缓存损失。 |
58
- | `adaptive` | `adaptive`,容量压力可覆盖 | `500000 / 96000` tokens,保持不变 | 最近 10 次调用 + `64000` token 尾窗 | 先让现有成本判断评估新的候选批次;没有连续官方 usage/价格证据时不调低门槛。 |
59
- | `custom` | `enabled + prefixPolicy` 决定 routine 或 capacity-pressure | 保留用户的 trigger/min-reclaim | 默认 10 次调用 + `64000` token 尾窗 | Custom v3 允许用户显式改两个保护值;默认/重置值为 10 与 `64000`。 |
60
-
61
- TailTrim 不属于 History / microcompact,但它目前复用 History 的近期保护 helper。为避免同一 helper 同时拥有两套语义,TailTrim 也使用同一个“最近 N 次工具调用 + token 尾窗”保护集;它的独立 trigger、完整工具组条件和 reducer 不变。
62
-
63
- ## 参数与配置改动
64
-
65
- 近期保护参数为:
66
-
67
- ```ts
68
- historyKeepRecentToolCalls: number
69
- historyKeepRecentTokens: number
70
- ```
71
-
72
- 前者是非负安全整数;标准 Profile 都解析为 `10`,它不是 token 数,不受 `tokens` / `context-percent` 单位切换影响。后者保留现有 token 尾窗语义,标准 Profile 都解析为 `64000`。即使 `off`、`native` 的 History 被禁用,解析后的策略结构仍完整一致。
73
-
74
- Custom 升为版本 3:
75
-
76
- ```ts
77
- history: {
78
- enabled: boolean
79
- trigger: number
80
- keepRecentToolCalls: number
81
- keepRecentTokens: number
82
- minReclaim: number
83
- }
84
- ```
85
-
86
- Custom 编辑器显示“保护近期工具调用数”和“保护近期工具结果尾窗”,默认值分别为 10 与 `64000`。保留 Custom 的可编辑性:标准 Profile 固定这些默认值,只有明确选择 Custom 的用户可以改变它们。若产品决定“Custom 也必须固定为这些值”,可在实现前删去两个输入框;其余算法不受影响。
87
-
88
- 已有 Custom v1/v2 设置继续可读:插件将它们规范化为 v3,将 `keepRecentToolCalls` 设为 10,并将用户原有的 `keepRecent` 原样迁移为 `keepRecentTokens`。下一次用户保存 Custom 时写回 v3。部署配置中使用已删除的 `historyKeepRecentTurns` 则在插件加载时明确报错,提示改用 `historyKeepRecentToolCalls`;`historyKeepRecentTokens` 继续受支持。
89
-
90
- ## 审计与可观测性
91
-
92
- `policy-frozen` 和 `policy-resolved` 记录新字段。History rewrite 仍记录 `component: "history"`、`stage: "pressure"`、History mode、reducer、精确 token 前后值和回收量。
93
-
94
- 为解释选择器结果,History 审计增加有限元数据:配置的保护调用数、尾窗 token 预算、活动已完成调用总数、实际受保护结果数。不得记录工具文本、工具参数、用户消息、call id 或 prompt。无需新增 DSH Session event 或修改 DSH 核心审计 schema。
95
-
96
- ## 验证计划
97
-
98
- 每个 History-enabled Profile 至少覆盖一次独立测试;不得只用 Balanced 证明实现。
99
-
100
- 1. 一个用户 turn 内连续完成至少 16 次调用并越过 trigger:最近 10 次总计约 `30000` token,继续向前累计到 `64000` token 的第 11 至第 15 次也不变;第 16 次(从最新向旧数)成为可选候选。
101
- 2. 将同一批调用切分到任意多个用户 turn:受保护和可压缩集合完全相同;只添加用户消息的 turn 不改变结果。
102
- 3. 包含并行调用、错误结果、富结果、已替换占位符和 `context_compression_retrieve`,验证计数顺序与不可重写规则。
103
- 4. `off` 和 `native` 即使工具输出很大也不执行 History;Native 仍按自己的逻辑运行。
104
- 5. Balanced、Savings 的 routine gate 在各自 trigger 之上执行;Cache Strict 只有确认容量压力时执行;Adaptive 在成本证据不足时跳过、容量压力时仍可执行;Custom 同时覆盖 routine 与 capacity-pressure。
105
- 6. 十条或更少调用、未达到 `64000` token 尾窗但所有调用都仍在尾窗内、精确 tokenizer 不可用、无安全候选或达不到最小回收量时,History 只留下可解释的跳过审计,不产生部分重写。
106
- 7. Custom v1/v2 规范化、v3 校验、浏览器输入、中文/英文文案、运行时公共测试、packed smoke、构建和 clean-install 发布验证均使用新字段。
107
-
108
- ## 风险与取舍
109
-
110
- 最近十条结果或 `64000` token 尾窗可能很大,导致旧结果不足以回收最小 token 数;此时跳过是对工作集保证的正确结果,而不是压缩器失效。Savings 的更激进候选参数必须先用同一任务的 token、缓存和结果可用性数据验证。
111
-
112
- 这会改变旧 Custom 文档的实际保留行为。将其统一为 10 次调用是可预测的迁移,但不等价于任何旧 turn/token 数。发布说明必须明确指出 Custom v3 和该语义变化。
@@ -1,34 +0,0 @@
1
- # 原生工具结果压缩接管规格
2
-
3
- ## 范围
4
-
5
- 本规格只约束选择器 Bundle 的工具结果压缩。不得修改 DeepSeek Harness 核心、内置 pruner、会话事件格式或 DSH UI。
6
-
7
- ## 机制
8
-
9
- 适用的 Harness preset 在插件的可逆 overlay 中移除 `@deepseek-ai/dsh-compaction-tool-result-pruner`,并以选择器 runtime 的同名 `toolResultPruner` 服务替换它。Harness 的 compaction-basic 继续调用这个公开服务;选择器据冻结的 Profile 决定允许哪一种 reducer。因此同一 Session 不会同时运行核心头尾裁剪和选择器 reducer。
10
-
11
- ## Profile 规则
12
-
13
- | Profile | 选择器原生风格头—中间—尾 reducer | 其他选择器路径 |
14
- | --- | --- | --- |
15
- | `native` | 允许 | Fresh、Aggregate、History、TailTrim 均关闭 |
16
- | `balanced` | 禁止 | 按 Balanced policy 运行 |
17
- | `cache-strict` | 禁止 | 按 Cache Strict policy 运行 |
18
- | `savings` | 禁止 | 按 Savings policy 运行 |
19
- | `adaptive` | 禁止 | 按 Adaptive policy 运行 |
20
- | `custom` | 禁止 | 只运行 Custom 明确启用的路径 |
21
- | `off` | 禁止 | 不运行选择器工具结果压缩 |
22
-
23
- 这里的“禁止”同时排除两条路径:overlay 已移除核心 `@deepseek-ai/dsh-compaction-tool-result-pruner`,解析后的 `nativeToolResultEnabled` 也为 `false`。因此不会生成 `component: "native-tool-result"` 的选择器 rewrite。`native-auto-compact` 是 Harness/模型独立机制,不受本规格控制。
24
-
25
- ## 会话冻结
26
-
27
- 选择器首次观察 Session 时冻结 Profile 与 Custom 文档。之后修改全局设置只能影响新 Session,不能让已经采用 Balanced、Savings、Cache Strict、Adaptive 或 Custom 的 Session 在中途重新启用头—中间—尾裁剪。
28
-
29
- ## 验收
30
-
31
- 1. `resolvePolicy()` 对 `balanced`、`cache-strict`、`savings`、`adaptive`、`custom` 返回 `nativeToolResultEnabled: false`,对 `native` 返回 `true`。
32
- 2. 插件 runtime 的 pressure pass 仅在 `nativeToolResultEnabled` 为 `true` 时计划 `native-tool-result` rewrite。
33
- 3. preset overlay 测试证明生成 composition 中没有核心 pruner,只有选择器 runtime 的同名服务。
34
- 4. 所有源代码改动限定在本仓库;不修改 Harness worktree。
@@ -1,46 +0,0 @@
1
- # Parent and child agent cache-prefix audit
2
-
3
- ## Scope
4
-
5
- This reference characterizes when DeepSeek Harness parent and child requests can present an identical prompt prefix to DeepSeek's automatic context cache. It does not add an explicit cache key, cache breakpoint, cache identifier, or client-side KV cache.
6
-
7
- The selector plugin owns settings registration and UI only. It has no hook into agent request construction, subagent session creation, or LLM serialization, so this work must not add runtime request behavior to the plugin or modify Harness core.
8
-
9
- ## Three separate questions
10
-
11
- Context inheritance asks whether a child session receives parent session events. A fork copies the parent event prefix through the last completed turn; a spawn starts without parent messages. The child metadata records the parent session and, for a fork, the seed length.
12
-
13
- Harness cache control asks whether Harness supplies a DeepSeek cache key or breakpoint across requests or sessions. The DeepSeek adapter serializes ordinary Chat Completions input and reads official usage fields; it supplies no explicit cache control.
14
-
15
- Server cache reuse asks whether byte-identical request prefixes can hit DeepSeek's automatic context cache. This is best-effort server behavior and is confirmed only when official response usage reports a positive `prompt_cache_hit_tokens` value. Latency and price are not evidence.
16
-
17
- ## Reuse characterization
18
-
19
- The test-only audit representation is versioned and canonical. Object keys are sorted recursively, while arrays retain their model-visible order. A SHA-256 fingerprint is computed over UTF-8 JSON containing the provider, model, system prompt, tool schemas, and inherited messages.
20
-
21
- A child is reusable only when it is a fork, declares parent-context inheritance, and its provider, model, system prompt, tools, and inherited messages equal the parent's stable envelope. Spawn mode, a changed persona or system prompt, changed tool schema or order, changed provider or model route, and changed history are rejected. The audit never repairs or concatenates mismatched contexts.
22
-
23
- The characterization does not guarantee that two independently assembled HTTP bodies have the same byte prefix: JSON property order and the child-only continuation still belong to the DeepSeek adapter. The live test captures the actual immutable agent-loop request options and compares the stable inherited envelope before allowing a cache-reuse claim.
24
-
25
- ## Safe evidence record
26
-
27
- An evidence event may contain only the audit version, prefix fingerprint, estimated shared-prefix tokens, parent and child session identifiers, mode, eligibility or reason, cache-read tokens, cache-miss tokens, observed prompt tokens, and confirmation status. It must not contain prompts, messages, tool arguments or results, tool schemas, permissions, environment values, credentials, or secrets.
28
-
29
- Usage is internally consistent only when `cacheReadTokens + cacheMissTokens` equals the observed prompt-token total. A positive cache-read count confirms a natural cache hit for that request. Missing or zero cache-read usage yields `unconfirmed`, never a claimed miss caused by Harness.
30
-
31
- ## TDD acceptance criteria
32
-
33
- The RED test imports an absent test-support module and defines the required behavior before implementation. The GREEN implementation remains under `tests/support` and exports no product runtime API.
34
-
35
- - Fork accepts an identical completed-turn prefix and produces the same fingerprint for parent and child views.
36
- - Spawn is ineligible because it does not inherit parent messages.
37
- - Persona, tool schema or order, provider, model, and history mismatches are ineligible.
38
- - Safe evidence records contain only the allowlisted fields and never contain representative secret or tool-result content.
39
- - Usage projection accepts hit plus miss equaling the prompt total and rejects inconsistent totals.
40
- - The existing selector runtime source remains unchanged, so disabling or omitting the plugin cannot affect agent requests.
41
- - A key-gated host-side live DeepSeek E2E test uses an isolated in-memory context and task-local `DSH_HOME`; it reports only sanitized usage evidence.
42
- - Existing fork, spawn, request-reconstruction, DeepSeek usage-projection, selector-plugin tests, the full build, and `git diff --check` pass.
43
-
44
- ## Operational boundaries
45
-
46
- Tests do not connect to the active web profile, start or restart a Harness service, deploy code, or write session logs outside the isolated test environment. The test-only implementation adds no product runtime API and does not alter active profile settings or service state.
@@ -1,350 +0,0 @@
1
- .WcpPCW_settingsSection {
2
- max-width: 720px;
3
- color: var(--dsw-alias-label-primary);
4
- flex-direction: column;
5
- gap: 12px;
6
- display: flex;
7
- }
8
-
9
- .WcpPCW_settingsTitle {
10
- color: var(--dsw-alias-label-primary);
11
- margin: 0;
12
- font-size: 16px;
13
- font-weight: 500;
14
- line-height: 24px;
15
- }
16
-
17
- .WcpPCW_settingsDescription {
18
- color: var(--dsw-alias-label-tertiary);
19
- margin: 0;
20
- font-size: 14px;
21
- line-height: 22px;
22
- }
23
-
24
- .WcpPCW_root {
25
- width: 100%;
26
- }
27
-
28
- .WcpPCW_profileGrid {
29
- grid-template-columns: repeat(2, minmax(0, 1fr));
30
- gap: 10px;
31
- display: grid;
32
- }
33
-
34
- .WcpPCW_profileCard {
35
- border: 1px solid var(--dsw-alias-border-l2);
36
- min-height: 112px;
37
- color: var(--dsw-alias-label-primary);
38
- cursor: pointer;
39
- text-align: left;
40
- background: none;
41
- border-radius: 10px;
42
- flex-direction: column;
43
- gap: 8px;
44
- padding: 14px;
45
- display: flex;
46
- }
47
-
48
- .WcpPCW_profileCard:hover:not(:disabled) {
49
- background: var(--dsw-alias-interactive-bg-hover);
50
- }
51
-
52
- .WcpPCW_profileCard[aria-pressed="true"] {
53
- border-color: var(--dsw-alias-label-primary);
54
- }
55
-
56
- .WcpPCW_profileCard:active:not(:disabled) {
57
- transform: scale(.99);
58
- }
59
-
60
- .WcpPCW_profileCard:disabled {
61
- cursor: default;
62
- opacity: .6;
63
- }
64
-
65
- .WcpPCW_profileCard:focus-visible {
66
- outline-offset: 2px;
67
- outline: 2px solid;
68
- }
69
-
70
- .WcpPCW_profileCardTop {
71
- align-items: center;
72
- gap: 8px;
73
- display: flex;
74
- }
75
-
76
- .WcpPCW_profileCardTitle {
77
- font-size: 14px;
78
- font-weight: 500;
79
- line-height: 20px;
80
- }
81
-
82
- .WcpPCW_profileCurrent {
83
- background: var(--dsw-alias-label-primary);
84
- color: var(--dsw-alias-bg-base);
85
- border-radius: 999px;
86
- padding: 1px 6px;
87
- font-size: 10px;
88
- line-height: 14px;
89
- }
90
-
91
- .WcpPCW_profileCardDetail {
92
- color: var(--dsw-alias-label-secondary);
93
- font-size: 12px;
94
- line-height: 18px;
95
- }
96
-
97
- .WcpPCW_button {
98
- border: 1px solid var(--dsw-alias-border-l2);
99
- width: 100%;
100
- min-height: 34px;
101
- color: var(--dsw-alias-label-primary);
102
- cursor: pointer;
103
- text-align: left;
104
- background: none;
105
- border-radius: 10px;
106
- align-items: center;
107
- gap: 8px;
108
- padding: 6px 8px;
109
- display: flex;
110
- }
111
-
112
- .WcpPCW_button:hover {
113
- background: var(--dsw-alias-interactive-bg-hover);
114
- }
115
-
116
- .WcpPCW_button:disabled {
117
- cursor: default;
118
- opacity: .6;
119
- }
120
-
121
- .WcpPCW_copy {
122
- flex: 1;
123
- min-width: 0;
124
- }
125
-
126
- .WcpPCW_label {
127
- color: var(--dsw-alias-label-tertiary);
128
- font-size: 11px;
129
- line-height: 14px;
130
- }
131
-
132
- .WcpPCW_value {
133
- text-overflow: ellipsis;
134
- white-space: nowrap;
135
- font-size: 13px;
136
- line-height: 17px;
137
- overflow: hidden;
138
- }
139
-
140
- .WcpPCW_chevron {
141
- color: var(--dsw-alias-label-secondary);
142
- flex: none;
143
- }
144
-
145
- .WcpPCW_menuCopy {
146
- flex-direction: column;
147
- gap: 2px;
148
- min-width: 220px;
149
- display: flex;
150
- }
151
-
152
- .WcpPCW_menuTitle {
153
- font-size: 13px;
154
- line-height: 17px;
155
- }
156
-
157
- .WcpPCW_menuDetail {
158
- white-space: normal;
159
- max-width: 290px;
160
- color: var(--dsw-alias-label-tertiary);
161
- font-size: 11px;
162
- line-height: 15px;
163
- }
164
-
165
- .WcpPCW_error {
166
- color: var(--dsw-alias-state-error-primary);
167
- padding: 4px 8px 0;
168
- font-size: 11px;
169
- line-height: 15px;
170
- }
171
-
172
- .WcpPCW_unavailable {
173
- color: var(--dsw-alias-label-tertiary);
174
- padding: 4px 8px 0;
175
- font-size: 11px;
176
- line-height: 15px;
177
- }
178
-
179
- .WcpPCW_settingsHint {
180
- color: var(--dsw-alias-label-secondary);
181
- padding: 4px 8px 0;
182
- font-size: 11px;
183
- line-height: 15px;
184
- }
185
-
186
- .WcpPCW_pricing {
187
- color: var(--dsw-alias-label-tertiary);
188
- padding: 4px 8px 0;
189
- font-size: 11px;
190
- line-height: 15px;
191
- }
192
-
193
- .WcpPCW_custom {
194
- border-top: 1px solid var(--dsw-alias-border-l2);
195
- margin-top: 16px;
196
- padding: 16px 0 0;
197
- }
198
-
199
- .WcpPCW_customTitle {
200
- margin: 0 0 6px;
201
- font-size: 13px;
202
- line-height: 17px;
203
- }
204
-
205
- .WcpPCW_customNote {
206
- color: var(--dsw-alias-label-tertiary);
207
- margin: 4px 0;
208
- font-size: 11px;
209
- line-height: 15px;
210
- }
211
-
212
- .WcpPCW_stage {
213
- border: 0;
214
- border-top: 1px solid var(--dsw-alias-border-l2);
215
- margin: 12px 0 0;
216
- padding: 12px 0 0;
217
- }
218
-
219
- .WcpPCW_stageToggle {
220
- align-items: center;
221
- gap: 6px;
222
- font-size: 12px;
223
- line-height: 16px;
224
- display: inline-flex;
225
- }
226
-
227
- .WcpPCW_fieldGrid {
228
- grid-template-columns: 1fr;
229
- gap: 8px;
230
- display: grid;
231
- }
232
-
233
- .WcpPCW_field {
234
- min-width: 0;
235
- color: var(--dsw-alias-label-secondary);
236
- flex-direction: column;
237
- gap: 4px;
238
- margin-top: 8px;
239
- font-size: 11px;
240
- line-height: 15px;
241
- display: flex;
242
- }
243
-
244
- .WcpPCW_field input, .WcpPCW_field select {
245
- box-sizing: border-box;
246
- border: 1px solid var(--dsw-alias-border-l2);
247
- background: var(--dsw-alias-bg-base);
248
- width: 100%;
249
- min-width: 0;
250
- min-height: 30px;
251
- color: var(--dsw-alias-label-primary);
252
- border-radius: 7px;
253
- padding: 4px 6px;
254
- }
255
-
256
- .WcpPCW_field input:focus-visible, .WcpPCW_field select:focus-visible, .WcpPCW_actions button:focus-visible {
257
- outline-offset: 2px;
258
- outline: 2px solid;
259
- }
260
-
261
- .WcpPCW_actions {
262
- flex-wrap: wrap;
263
- gap: 8px;
264
- margin-top: 10px;
265
- display: flex;
266
- }
267
-
268
- .WcpPCW_actions button {
269
- border: 1px solid var(--dsw-alias-border-l2);
270
- min-height: 30px;
271
- color: var(--dsw-alias-label-primary);
272
- background: none;
273
- border-radius: 7px;
274
- padding: 4px 8px;
275
- }
276
-
277
- .WcpPCW_actions button:active:not(:disabled) {
278
- transform: scale(.98);
279
- }
280
-
281
- .WcpPCW_actions button:disabled {
282
- opacity: .6;
283
- }
284
-
285
- @media (width <= 560px) {
286
- .WcpPCW_profileGrid {
287
- grid-template-columns: 1fr;
288
- }
289
- }
290
-
291
- .WcpPCW_autoCompact {
292
- border: 1px solid #80808059;
293
- border-radius: 8px;
294
- margin-top: 24px;
295
- padding: 16px;
296
- }
297
-
298
- .WcpPCW_autoCompactTitle {
299
- margin: 0 0 8px;
300
- font-size: 15px;
301
- font-weight: 600;
302
- }
303
-
304
- .WcpPCW_autoCompactRisk {
305
- opacity: .9;
306
- margin: 8px 0 0;
307
- font-size: 12px;
308
- }
309
-
310
- .WcpPCW_savingsCard {
311
- border: 1px solid #ffffff1a;
312
- border-radius: 8px;
313
- flex-direction: column;
314
- gap: 4px;
315
- margin-top: 14px;
316
- padding: 10px 12px;
317
- display: flex;
318
- }
319
-
320
- .WcpPCW_savingsRow {
321
- justify-content: space-between;
322
- align-items: baseline;
323
- gap: 12px;
324
- display: flex;
325
- }
326
-
327
- .WcpPCW_savingsNetPositive strong {
328
- color: #30d158;
329
- }
330
-
331
- .WcpPCW_savingsNetNegative strong {
332
- color: #ff9f0a;
333
- }
334
-
335
- .WcpPCW_savingsMuted {
336
- opacity: .66;
337
- font-size: .92em;
338
- }
339
-
340
- .WcpPCW_savingsBreakdown {
341
- border-top: 1px solid #ffffff14;
342
- margin-top: 4px;
343
- padding-top: 4px;
344
- }
345
-
346
- .WcpPCW_savingsNote {
347
- opacity: .5;
348
- margin-top: 4px;
349
- font-size: .85em;
350
- }