imccyu пре 1 месец
родитељ
комит
25efb8ff6f
1 измењених фајлова са 4 додато и 19 уклоњено
  1. 4 19
      apps/web/tests/scaffold.ts

+ 4 - 19
apps/web/tests/scaffold.ts

@@ -70,8 +70,6 @@ import SessionStore, {
   type SessionHeader,
 } from '@deepseek-ai/dsh-session'
 import JsonlSessionPersistence from '@deepseek-ai/dsh-session-persistence-jsonl'
-import * as CordisHostRunner from '@deepseek-ai/dsh-cordis-host-runner'
-import * as ToolCordis from '@deepseek-ai/dsh-tool-cordis'
 // Empty type imports carry the webServer/agents/sessionPersistence Context merges.
 import type {} from '@deepseek-ai/dsh-host-webserver'
 import type {} from '@deepseek-ai/dsh-agent'
@@ -218,7 +216,7 @@ export interface LaunchOptions {
    */
   toolsMode?: 'native' | 'code' | 'both'
   /**
-   * Insert the opt-in self-referential Cordis tools into the shipped tree.
+   * Insert the opt-in model-facing Cordis tool provider into the shipped tree.
    * Record and replay use the same tool surface, so captured request headers
    * remain reconstructable without making the tools a product default.
    */
@@ -461,18 +459,11 @@ export async function launchWebScaffold(options: LaunchOptions = {}): Promise<We
       // be able to change a golden, whatever roots a scenario asks for.
       : [{ id: 'agent-presets', config: { ...options.agentPresets, includeUserRoot: false } }],
     ...options.toolsMode === undefined ? [] : [{ id: 'tools', config: { mode: options.toolsMode } }],
-    // The host halves ride Loader builtins (below) so the shipped CLI keeps no
-    // dependency on this opt-in package, but the two browser rows must carry
-    // their real package names: the modules node half reads `dshClient` from a
-    // row's resolved package root, and a `cordis:` builtin has none — it is
-    // permanently not a client row, so a builtin here would silently drop the
-    // browser half from the roster.
+    // The shipped Web bundle already owns both runners and the Cordis UI. This
+    // scenario adds only the model-facing tools that exercise those services.
     ...options.cordisTools === true
       ? [{ insert: [
-        { id: 'cordis-host-runner', name: 'cordis:cordis-host-runner' },
-        { id: 'tool-cordis', name: 'cordis:tool-cordis' },
-        { id: 'cordis-client-runner', name: '@deepseek-ai/dsh-cordis-client-runner' },
-        { id: 'ui-cordis', name: '@deepseek-ai/dsh-client-ui-cordis' },
+        { id: 'tool-cordis', name: '@deepseek-ai/dsh-tool-cordis' },
       ] }]
       : [],
     ...options.deepSeekSearch === undefined
@@ -525,12 +516,6 @@ export async function launchWebScaffold(options: LaunchOptions = {}): Promise<We
     // and a preset resolving package names from its own directory cannot reach
     // `@deepseek-ai/cordis-plugin-group` by name.
     ctx.loader.builtins.group = Group
-    // The shipped CLI deliberately has no dependency on this opt-in package.
-    // Keep the Loader row real without broadening the product installation.
-    if (options.cordisTools === true) {
-      ctx.loader.builtins['cordis-host-runner'] = CordisHostRunner
-      ctx.loader.builtins['tool-cordis'] = ToolCordis
-    }
     await ctx.loader.create({
       name: 'cordis:include',
       config: { path: pathToFileURL(rootConfig).href, patches },