@tarquinen/opencode-dcp 3.1.12 → 3.1.14

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 (106) hide show
  1. package/README.md +14 -9
  2. package/dist/index.js +105 -39
  3. package/dist/index.js.map +1 -1
  4. package/dist/lib/commands/context.d.ts +15 -0
  5. package/dist/lib/commands/context.d.ts.map +1 -1
  6. package/dist/lib/commands/help.d.ts +1 -0
  7. package/dist/lib/commands/help.d.ts.map +1 -1
  8. package/dist/lib/commands/manual.d.ts +1 -1
  9. package/dist/lib/commands/manual.d.ts.map +1 -1
  10. package/dist/lib/commands/stats.d.ts +10 -0
  11. package/dist/lib/commands/stats.d.ts.map +1 -1
  12. package/dist/lib/compress/pipeline.d.ts.map +1 -1
  13. package/dist/lib/hooks.d.ts.map +1 -1
  14. package/dist/lib/state/persistence.d.ts +3 -0
  15. package/dist/lib/state/persistence.d.ts.map +1 -1
  16. package/dist/lib/state/state.d.ts +1 -0
  17. package/dist/lib/state/state.d.ts.map +1 -1
  18. package/dist/lib/tui/commands.d.ts +3 -0
  19. package/dist/lib/tui/commands.d.ts.map +1 -0
  20. package/dist/lib/tui/data.d.ts +14 -0
  21. package/dist/lib/tui/data.d.ts.map +1 -0
  22. package/dist/lib/tui/dialogs.d.ts +30 -0
  23. package/dist/lib/tui/dialogs.d.ts.map +1 -0
  24. package/dist/lib/tui/format.d.ts +4 -0
  25. package/dist/lib/tui/format.d.ts.map +1 -0
  26. package/dist/lib/tui/modals.d.ts +10 -0
  27. package/dist/lib/tui/modals.d.ts.map +1 -0
  28. package/dist/lib/tui/types.d.ts +15 -0
  29. package/dist/lib/tui/types.d.ts.map +1 -0
  30. package/dist/lib/tui/ui.d.ts +48 -0
  31. package/dist/lib/tui/ui.d.ts.map +1 -0
  32. package/dist/tui.d.ts +7 -0
  33. package/dist/tui.d.ts.map +1 -0
  34. package/lib/auth.ts +37 -0
  35. package/lib/commands/compression-targets.ts +137 -0
  36. package/lib/commands/context.ts +305 -0
  37. package/lib/commands/decompress.ts +275 -0
  38. package/lib/commands/help.ts +76 -0
  39. package/lib/commands/index.ts +11 -0
  40. package/lib/commands/manual.ts +127 -0
  41. package/lib/commands/recompress.ts +224 -0
  42. package/lib/commands/stats.ts +159 -0
  43. package/lib/commands/sweep.ts +268 -0
  44. package/lib/compress/index.ts +3 -0
  45. package/lib/compress/message-utils.ts +250 -0
  46. package/lib/compress/message.ts +145 -0
  47. package/lib/compress/pipeline.ts +108 -0
  48. package/lib/compress/protected-content.ts +208 -0
  49. package/lib/compress/range-utils.ts +308 -0
  50. package/lib/compress/range.ts +192 -0
  51. package/lib/compress/search.ts +267 -0
  52. package/lib/compress/state.ts +268 -0
  53. package/lib/compress/timing.ts +77 -0
  54. package/lib/compress/types.ts +108 -0
  55. package/lib/compress-permission.ts +25 -0
  56. package/lib/config.ts +1007 -0
  57. package/lib/hooks.ts +375 -0
  58. package/lib/host-permissions.ts +101 -0
  59. package/lib/logger.ts +226 -0
  60. package/lib/message-ids.ts +172 -0
  61. package/lib/messages/index.ts +8 -0
  62. package/lib/messages/inject/inject.ts +215 -0
  63. package/lib/messages/inject/subagent-results.ts +82 -0
  64. package/lib/messages/inject/utils.ts +374 -0
  65. package/lib/messages/priority.ts +102 -0
  66. package/lib/messages/prune.ts +233 -0
  67. package/lib/messages/query.ts +72 -0
  68. package/lib/messages/reasoning-strip.ts +40 -0
  69. package/lib/messages/shape.ts +50 -0
  70. package/lib/messages/sync.ts +124 -0
  71. package/lib/messages/utils.ts +185 -0
  72. package/lib/prompts/compress-message.ts +43 -0
  73. package/lib/prompts/compress-range.ts +60 -0
  74. package/lib/prompts/context-limit-nudge.ts +18 -0
  75. package/lib/prompts/extensions/nudge.ts +43 -0
  76. package/lib/prompts/extensions/system.ts +32 -0
  77. package/lib/prompts/extensions/tool.ts +35 -0
  78. package/lib/prompts/index.ts +29 -0
  79. package/lib/prompts/iteration-nudge.ts +6 -0
  80. package/lib/prompts/store.ts +467 -0
  81. package/lib/prompts/system.ts +33 -0
  82. package/lib/prompts/turn-nudge.ts +10 -0
  83. package/lib/protected-patterns.ts +128 -0
  84. package/lib/state/index.ts +4 -0
  85. package/lib/state/persistence.ts +305 -0
  86. package/lib/state/state.ts +208 -0
  87. package/lib/state/tool-cache.ts +98 -0
  88. package/lib/state/types.ts +111 -0
  89. package/lib/state/utils.ts +345 -0
  90. package/lib/strategies/deduplication.ts +127 -0
  91. package/lib/strategies/index.ts +2 -0
  92. package/lib/strategies/purge-errors.ts +88 -0
  93. package/lib/subagents/subagent-results.ts +74 -0
  94. package/lib/token-utils.ts +164 -0
  95. package/lib/tui/commands.ts +31 -0
  96. package/lib/tui/data.ts +73 -0
  97. package/lib/tui/dialogs.tsx +235 -0
  98. package/lib/tui/format.ts +25 -0
  99. package/lib/tui/modals.tsx +92 -0
  100. package/lib/tui/types.ts +16 -0
  101. package/lib/tui/ui.tsx +219 -0
  102. package/lib/ui/notification.ts +347 -0
  103. package/lib/ui/utils.ts +304 -0
  104. package/lib/update.ts +185 -0
  105. package/package.json +21 -5
  106. package/tui.tsx +26 -0
package/README.md CHANGED
@@ -17,6 +17,17 @@ opencode plugin @tarquinen/opencode-dcp@latest --global
17
17
 
18
18
  This installs the package and adds it to your global OpenCode config.
19
19
 
20
+ ## Project Status
21
+
22
+ Development on DCP has slowed because most new context-management work has moved to [Sleev](https://sleev.ai) and the `sleev` CLI. Sleev is a local proxy for Claude Code, Codex, and OpenCode that builds on DCP's core ideas with newer context-management features and will work with any harness/client.
23
+
24
+ DCP remains available for OpenCode plugin users, but new features are landing in Sleev first. If you are starting fresh, we recommend trying Sleev:
25
+
26
+ ```bash
27
+ npm i -g sleev
28
+ sleev
29
+ ```
30
+
20
31
  ## How It Works
21
32
 
22
33
  DCP reduces context size through a compress tool and automatic cleanup. Your session history is never modified — DCP replaces pruned content with placeholders before sending requests to your LLM.
@@ -176,16 +187,10 @@ Each level overrides the previous, so project settings take priority over global
176
187
 
177
188
  ### Commands
178
189
 
179
- DCP provides a `/dcp` slash command:
190
+ DCP provides a TUI panel and one prompt-producing slash command:
180
191
 
181
- - `/dcp` — Shows available DCP commands
182
- - `/dcp context` — Shows a breakdown of your current session's token usage by category (system, user, assistant, tools, etc.) and how much has been saved through pruning.
183
- - `/dcp stats` — Shows cumulative pruning statistics across all sessions.
184
- - `/dcp sweep` — Prunes all tools since the last user message. Accepts an optional count: `/dcp sweep 10` prunes the last 10 tools. Respects `commands.protectedTools`.
185
- - `/dcp manual [on|off]` — Toggle manual mode or set explicit state. When on, the AI will not autonomously use context management tools.
186
- - `/dcp compress [focus]` — Trigger a single compress tool execution. Optional focus text directs what content to compress, following the active `compress.mode`.
187
- - `/dcp decompress <n>` — Restore a specific active compression by ID (for example `/dcp decompress 2`). Running without an argument shows available compression IDs, token sizes, and topics.
188
- - `/dcp recompress <n>` — Re-apply a user-decompressed compression by ID (for example `/dcp recompress 2`). Running without an argument shows recompressible IDs, token sizes, and topics.
192
+ - `/dcp` — Opens the DCP panel with context, stats, and manual-mode controls.
193
+ - `/dcp-compress [focus]` — Asks the model to run one compression pass. Optional focus text directs what content to compress, following the active `compress.mode`.
189
194
 
190
195
  ### Prompt Overrides
191
196
 
package/dist/index.js CHANGED
@@ -2387,6 +2387,8 @@ var SoftIssue = class extends Error {
2387
2387
  this.kind = kind;
2388
2388
  this.messageId = messageId;
2389
2389
  }
2390
+ kind;
2391
+ messageId;
2390
2392
  };
2391
2393
  function validateArgs(args) {
2392
2394
  if (typeof args.topic !== "string" || args.topic.trim().length === 0) {
@@ -2851,6 +2853,7 @@ async function saveSessionState(sessionState, logger, sessionName) {
2851
2853
  }
2852
2854
  const state = {
2853
2855
  sessionName,
2856
+ manualMode: !!sessionState.manualMode,
2854
2857
  prune: {
2855
2858
  tools: Object.fromEntries(sessionState.prune.tools),
2856
2859
  messages: serializePruneMessagesState(sessionState.prune.messages)
@@ -2939,6 +2942,43 @@ async function loadSessionState(sessionId, logger) {
2939
2942
  return null;
2940
2943
  }
2941
2944
  }
2945
+ function emptyPersistedState(manualMode) {
2946
+ return {
2947
+ manualMode,
2948
+ prune: {
2949
+ tools: {},
2950
+ messages: {
2951
+ byMessageId: {},
2952
+ blocksById: {},
2953
+ activeBlockIds: [],
2954
+ activeByAnchorMessageId: {},
2955
+ nextBlockId: 1,
2956
+ nextRunId: 1
2957
+ }
2958
+ },
2959
+ nudges: {
2960
+ contextLimitAnchors: [],
2961
+ turnNudgeAnchors: [],
2962
+ iterationNudgeAnchors: []
2963
+ },
2964
+ stats: {
2965
+ pruneTokenCounter: 0,
2966
+ totalPruneTokens: 0
2967
+ },
2968
+ lastUpdated: (/* @__PURE__ */ new Date()).toISOString()
2969
+ };
2970
+ }
2971
+ async function loadManualModeSetting(sessionId, logger) {
2972
+ const state = await loadSessionState(sessionId, logger);
2973
+ return typeof state?.manualMode === "boolean" ? state.manualMode : void 0;
2974
+ }
2975
+ async function saveManualModeSetting(sessionId, manualMode, logger) {
2976
+ const existing = await loadSessionState(sessionId, logger);
2977
+ const state = existing ?? emptyPersistedState(manualMode);
2978
+ state.manualMode = manualMode;
2979
+ state.lastUpdated = (/* @__PURE__ */ new Date()).toISOString();
2980
+ await writePersistedSessionState(sessionId, state, logger);
2981
+ }
2942
2982
  async function loadAllSessionStats(logger) {
2943
2983
  const result = {
2944
2984
  totalTokens: 0,
@@ -3047,6 +3087,7 @@ var checkSession = async (client, state, logger, messages, manualModeDefault) =>
3047
3087
  });
3048
3088
  }
3049
3089
  state.currentTurn = countTurns(state, messages);
3090
+ await refreshManualMode(state, lastSessionId, logger, manualModeDefault);
3050
3091
  };
3051
3092
  function createSessionState() {
3052
3093
  return {
@@ -3134,6 +3175,9 @@ async function ensureSessionInitialized(client, state, sessionId, logger, messag
3134
3175
  if (persisted === null) {
3135
3176
  return;
3136
3177
  }
3178
+ if (typeof persisted.manualMode === "boolean") {
3179
+ state.manualMode = persisted.manualMode ? "active" : false;
3180
+ }
3137
3181
  state.prune.tools = loadPruneMap(persisted.prune.tools);
3138
3182
  state.prune.messages = loadPruneMessagesState(persisted.prune.messages);
3139
3183
  state.nudges.contextLimitAnchors = new Set(persisted.nudges.contextLimitAnchors || []);
@@ -3153,6 +3197,14 @@ async function ensureSessionInitialized(client, state, sessionId, logger, messag
3153
3197
  await saveSessionState(state, logger);
3154
3198
  }
3155
3199
  }
3200
+ async function refreshManualMode(state, sessionId, logger, manualModeDefault) {
3201
+ if (state.manualMode === "compress-pending") {
3202
+ return;
3203
+ }
3204
+ const persisted = await loadManualModeSetting(sessionId, logger);
3205
+ const enabled = persisted ?? manualModeDefault;
3206
+ state.manualMode = enabled ? "active" : false;
3207
+ }
3156
3208
 
3157
3209
  // lib/state/tool-cache.ts
3158
3210
  var MAX_TOOL_CACHE_SIZE = 1e3;
@@ -3866,6 +3918,7 @@ async function sendIgnoredMessage(client, sessionID, text, params, logger) {
3866
3918
 
3867
3919
  // lib/compress/pipeline.ts
3868
3920
  async function prepareSession(ctx, toolCtx, title) {
3921
+ await refreshManualMode(ctx.state, toolCtx.sessionID, ctx.logger, ctx.config.manualMode.enabled);
3869
3922
  if (ctx.state.manualMode && ctx.state.manualMode !== "compress-pending") {
3870
3923
  throw new Error(
3871
3924
  "Manual mode: compress blocked. Do not retry until `<compress triggered manually>` appears in user context."
@@ -6341,7 +6394,7 @@ function renderSystemPrompt(prompts, protectedToolsExtension, manual, subagent)
6341
6394
  }
6342
6395
 
6343
6396
  // lib/commands/context.ts
6344
- function analyzeTokens(state, messages) {
6397
+ function analyzeContextTokens(state, messages) {
6345
6398
  const breakdown = {
6346
6399
  system: 0,
6347
6400
  user: 0,
@@ -6520,7 +6573,7 @@ function formatContextMessage(breakdown) {
6520
6573
  }
6521
6574
  async function handleContextCommand(ctx) {
6522
6575
  const { client, state, logger, sessionId, messages } = ctx;
6523
- const breakdown = analyzeTokens(state, messages);
6576
+ const breakdown = analyzeContextTokens(state, messages);
6524
6577
  const message = formatContextMessage(breakdown);
6525
6578
  const params = getCurrentParams(state, messages, logger);
6526
6579
  await sendIgnoredMessage(client, sessionId, message, params, logger);
@@ -6824,23 +6877,20 @@ async function handleDecompressCommand(ctx) {
6824
6877
  }
6825
6878
 
6826
6879
  // lib/commands/help.ts
6827
- var BASE_COMMANDS = [
6828
- ["/dcp context", "Show token usage breakdown for current session"],
6829
- ["/dcp stats", "Show DCP pruning statistics"],
6830
- ["/dcp sweep [n]", "Prune tools since last user message, or last n tools"],
6831
- ["/dcp manual [on|off]", "Toggle manual mode or set explicit state"]
6880
+ var TUI_COMMANDS = [
6881
+ ["DCP Context", "Show token usage breakdown for current session"],
6882
+ ["DCP Stats", "Show DCP pruning statistics"],
6883
+ ["DCP Help", "Show this help in a modal"]
6832
6884
  ];
6833
6885
  var TOOL_COMMANDS = {
6834
- compress: ["/dcp compress [focus]", "Trigger manual compress tool execution"],
6886
+ compress: ["/dcp-compress [focus]", "Trigger manual compress tool execution"],
6835
6887
  decompress: ["/dcp decompress <n>", "Restore selected compression"],
6836
6888
  recompress: ["/dcp recompress <n>", "Re-apply a user-decompressed compression"]
6837
6889
  };
6838
6890
  function getVisibleCommands(state, config) {
6839
- const commands = [...BASE_COMMANDS];
6891
+ const commands = [...TUI_COMMANDS];
6840
6892
  if (compressPermission(state, config) !== "deny") {
6841
6893
  commands.push(TOOL_COMMANDS.compress);
6842
- commands.push(TOOL_COMMANDS.decompress);
6843
- commands.push(TOOL_COMMANDS.recompress);
6844
6894
  }
6845
6895
  return commands;
6846
6896
  }
@@ -6854,6 +6904,9 @@ function formatHelpMessage(state, config) {
6854
6904
  lines.push("");
6855
6905
  lines.push(` ${"Manual mode:".padEnd(colWidth)}${state.manualMode ? "ON" : "OFF"}`);
6856
6906
  lines.push("");
6907
+ lines.push(" Open the command palette for DCP modal commands.");
6908
+ lines.push(" Use /dcp-compress [focus] when you want DCP to ask the model to run compression.");
6909
+ lines.push("");
6857
6910
  for (const [cmd, desc] of commands) {
6858
6911
  lines.push(` ${cmd.padEnd(colWidth)}${desc}`);
6859
6912
  }
@@ -6870,7 +6923,7 @@ async function handleHelpCommand(ctx) {
6870
6923
  }
6871
6924
 
6872
6925
  // lib/commands/manual.ts
6873
- var MANUAL_MODE_ON = "Manual mode is now ON. Use /dcp compress to trigger context tools manually.";
6926
+ var MANUAL_MODE_ON = "Manual mode is now ON. Use /dcp-compress to trigger context tools manually.";
6874
6927
  var MANUAL_MODE_OFF = "Manual mode is now OFF.";
6875
6928
  var COMPRESS_TRIGGER_PROMPT = [
6876
6929
  "<compress triggered manually>",
@@ -6906,6 +6959,7 @@ async function handleManualToggleCommand(ctx, modeArg) {
6906
6959
  params,
6907
6960
  logger
6908
6961
  );
6962
+ await saveManualModeSetting(sessionId, !!state.manualMode, logger);
6909
6963
  logger.info("Manual mode toggled", { manualMode: state.manualMode });
6910
6964
  }
6911
6965
  async function handleManualTriggerCommand(ctx, tool3, userFocus) {
@@ -7154,6 +7208,29 @@ function formatCompressionTime(ms) {
7154
7208
  }
7155
7209
  async function handleStatsCommand(ctx) {
7156
7210
  const { client, state, logger, sessionId, messages } = ctx;
7211
+ const report = await buildStatsReport(state, logger);
7212
+ const message = formatStatsMessage(
7213
+ report.sessionTokens,
7214
+ report.sessionSummaryTokens,
7215
+ report.sessionTools,
7216
+ report.sessionMessages,
7217
+ report.sessionDurationMs,
7218
+ report.allTime
7219
+ );
7220
+ const params = getCurrentParams(state, messages, logger);
7221
+ await sendIgnoredMessage(client, sessionId, message, params, logger);
7222
+ logger.info("Stats command executed", {
7223
+ sessionTokens: report.sessionTokens,
7224
+ sessionSummaryTokens: report.sessionSummaryTokens,
7225
+ sessionTools: report.sessionTools,
7226
+ sessionMessages: report.sessionMessages,
7227
+ sessionDurationMs: report.sessionDurationMs,
7228
+ allTimeTokens: report.allTime.totalTokens,
7229
+ allTimeTools: report.allTime.totalTools,
7230
+ allTimeMessages: report.allTime.totalMessages
7231
+ });
7232
+ }
7233
+ async function buildStatsReport(state, logger) {
7157
7234
  const sessionTokens = state.stats.totalPruneTokens;
7158
7235
  const sessionSummaryTokens = Array.from(state.prune.messages.blocksById.values()).reduce(
7159
7236
  (total, block) => block.active ? total + block.summaryTokens : total,
@@ -7179,26 +7256,14 @@ async function handleStatsCommand(ctx) {
7179
7256
  }
7180
7257
  }
7181
7258
  const allTime = await loadAllSessionStats(logger);
7182
- const message = formatStatsMessage(
7259
+ return {
7183
7260
  sessionTokens,
7184
7261
  sessionSummaryTokens,
7185
7262
  sessionTools,
7186
7263
  sessionMessages,
7187
7264
  sessionDurationMs,
7188
7265
  allTime
7189
- );
7190
- const params = getCurrentParams(state, messages, logger);
7191
- await sendIgnoredMessage(client, sessionId, message, params, logger);
7192
- logger.info("Stats command executed", {
7193
- sessionTokens,
7194
- sessionSummaryTokens,
7195
- sessionTools,
7196
- sessionMessages,
7197
- sessionDurationMs,
7198
- allTimeTokens: allTime.totalTokens,
7199
- allTimeTools: allTime.totalTools,
7200
- allTimeMessages: allTime.totalMessages
7201
- });
7266
+ };
7202
7267
  }
7203
7268
 
7204
7269
  // lib/commands/sweep.ts
@@ -7478,7 +7543,7 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7478
7543
  if (!config.commands.enabled) {
7479
7544
  return;
7480
7545
  }
7481
- if (input.command === "dcp") {
7546
+ if (input.command === "dcp" || input.command === "dcp-compress") {
7482
7547
  const messagesResponse = await client.session.messages({
7483
7548
  path: { id: input.sessionID }
7484
7549
  });
@@ -7497,8 +7562,9 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7497
7562
  return;
7498
7563
  }
7499
7564
  const args = (input.arguments || "").trim().split(/\s+/).filter(Boolean);
7500
- const subcommand = args[0]?.toLowerCase() || "";
7501
- const subArgs = args.slice(1);
7565
+ const isCompressCommand = input.command === "dcp-compress";
7566
+ const subcommand = isCompressCommand ? "compress" : args[0]?.toLowerCase() || "";
7567
+ const subArgs = isCompressCommand ? args : args.slice(1);
7502
7568
  const commandCtx = {
7503
7569
  client,
7504
7570
  state,
@@ -7509,11 +7575,11 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7509
7575
  };
7510
7576
  if (subcommand === "context") {
7511
7577
  await handleContextCommand(commandCtx);
7512
- throw new Error("__DCP_CONTEXT_HANDLED__");
7578
+ return;
7513
7579
  }
7514
7580
  if (subcommand === "stats") {
7515
7581
  await handleStatsCommand(commandCtx);
7516
- throw new Error("__DCP_STATS_HANDLED__");
7582
+ return;
7517
7583
  }
7518
7584
  if (subcommand === "sweep") {
7519
7585
  await handleSweepCommand({
@@ -7521,11 +7587,11 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7521
7587
  args: subArgs,
7522
7588
  workingDirectory
7523
7589
  });
7524
- throw new Error("__DCP_SWEEP_HANDLED__");
7590
+ return;
7525
7591
  }
7526
7592
  if (subcommand === "manual") {
7527
7593
  await handleManualToggleCommand(commandCtx, subArgs[0]?.toLowerCase());
7528
- throw new Error("__DCP_MANUAL_HANDLED__");
7594
+ return;
7529
7595
  }
7530
7596
  if (subcommand === "compress") {
7531
7597
  const userFocus = subArgs.join(" ").trim();
@@ -7542,7 +7608,7 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7542
7608
  output.parts.length = 0;
7543
7609
  output.parts.push({
7544
7610
  type: "text",
7545
- text: rawArgs ? `/dcp ${rawArgs}` : `/dcp ${subcommand}`
7611
+ text: isCompressCommand ? rawArgs ? `/dcp-compress ${rawArgs}` : "/dcp-compress" : rawArgs ? `/dcp ${rawArgs}` : `/dcp ${subcommand}`
7546
7612
  });
7547
7613
  return;
7548
7614
  }
@@ -7551,17 +7617,17 @@ function createCommandExecuteHandler(client, state, logger, config, workingDirec
7551
7617
  ...commandCtx,
7552
7618
  args: subArgs
7553
7619
  });
7554
- throw new Error("__DCP_DECOMPRESS_HANDLED__");
7620
+ return;
7555
7621
  }
7556
7622
  if (subcommand === "recompress") {
7557
7623
  await handleRecompressCommand({
7558
7624
  ...commandCtx,
7559
7625
  args: subArgs
7560
7626
  });
7561
- throw new Error("__DCP_RECOMPRESS_HANDLED__");
7627
+ return;
7562
7628
  }
7563
7629
  await handleHelpCommand(commandCtx);
7564
- throw new Error("__DCP_HELP_HANDLED__");
7630
+ return;
7565
7631
  }
7566
7632
  };
7567
7633
  }
@@ -7872,9 +7938,9 @@ var server = (async (ctx) => {
7872
7938
  }
7873
7939
  if (config.commands.enabled && config.compress.permission !== "deny") {
7874
7940
  opencodeConfig.command ??= {};
7875
- opencodeConfig.command["dcp"] = {
7941
+ opencodeConfig.command["dcp-compress"] = {
7876
7942
  template: "",
7877
- description: "Show available DCP commands"
7943
+ description: "Trigger DCP manual compression with: /dcp-compress [focus]"
7878
7944
  };
7879
7945
  }
7880
7946
  const toolsToAdd = [];