test(web): keep policy snapshots host-independent
This commit is contained in:
@@ -9,12 +9,13 @@
|
|||||||
// from live session memory), refresh (keyless replay that rewrites goldens).
|
// from live session memory), refresh (keyless replay that rewrites goldens).
|
||||||
//
|
//
|
||||||
// Composition divergences from `dsh web`, all deliberate, all via include
|
// Composition divergences from `dsh web`, all deliberate, all via include
|
||||||
// patches after the shipped surface overlay: temp persistenceRoot;
|
// patches after the shipped surface overlay: temp persistenceRoot; local skill
|
||||||
// workspace-context disabled (recorded fixtures must not embed this repo's
|
// roots confined to the temp workspace; workspace-context disabled (recorded
|
||||||
// AGENTS.md); session-title-llm disabled (its fire-and-forget title call
|
// fixtures must not embed this repo's AGENTS.md); session-title-llm disabled
|
||||||
// would race the loop for the session's replay cursor); webserver pinned to
|
// (its fire-and-forget title call would race the loop for the session's replay
|
||||||
// port 0 with the built dist; keyless modes disable llm-deepseek and fill
|
// cursor); webserver pinned to port 0 with the built dist; keyless modes
|
||||||
// the open llm seam post-boot with installLlmReplay on the settled root ctx
|
// disable llm-deepseek and fill the open llm seam post-boot with
|
||||||
|
// installLlmReplay on the settled root ctx
|
||||||
// (the plugin-row path discards the ReplayHandle; the direct install keeps
|
// (the plugin-row path discards the ReplayHandle; the direct install keeps
|
||||||
// assertConsumed for the teardown fixture-consumption check).
|
// assertConsumed for the teardown fixture-consumption check).
|
||||||
import { existsSync } from 'node:fs'
|
import { existsSync } from 'node:fs'
|
||||||
@@ -172,6 +173,18 @@ export async function launchWebScaffold(options: LaunchOptions = {}): Promise<We
|
|||||||
// per write; the scaffold restores the original cwd after boot, so the
|
// per write; the scaffold restores the original cwd after boot, so the
|
||||||
// row gets an absolute temp root (removed with the workspace at close).
|
// row gets an absolute temp root (removed with the workspace at close).
|
||||||
{ id: 'storage-json', config: { root: join(workspaceCwd, '.dsh-storages') } },
|
{ id: 'storage-json', config: { root: join(workspaceCwd, '.dsh-storages') } },
|
||||||
|
// Skill discovery is model-visible input. Pin every host-level root inside
|
||||||
|
// the owned temp world so ambient catalogs cannot change replay requests
|
||||||
|
// or conversation goldens; project roots still use the empty workspace.
|
||||||
|
{
|
||||||
|
id: 'skill-local',
|
||||||
|
config: {
|
||||||
|
dshHome: join(workspaceCwd, '.dsh-home'),
|
||||||
|
agentsHome: join(workspaceCwd, '.agents-home'),
|
||||||
|
bundledSkillDir: join(workspaceCwd, '.bundled-skills'),
|
||||||
|
watch: false,
|
||||||
|
},
|
||||||
|
},
|
||||||
// fs/bash cwd default to process.cwd(); the gateway injects the same
|
// fs/bash cwd default to process.cwd(); the gateway injects the same
|
||||||
// value into session.cwd — chdir below anchors all three to the temp
|
// value into session.cwd — chdir below anchors all three to the temp
|
||||||
// workspace, keeping the composition untouched.
|
// workspace, keeping the composition untouched.
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- 'button "Think The user wants me to write a single `run_code` program that:"':
|
- 'button "Think The user wants me to write a single `run_code` program that:"':
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to:":
|
- button "Think The user wants me to:":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to run a simple bash command and reply with \"DONE\".":
|
- button "Think The user wants me to run a simple bash command and reply with \"DONE\".":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to reply with a single word. Let me comply.":
|
- button "Think The user wants me to reply with a single word. Let me comply.":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- paragraph: partial
|
- paragraph: partial
|
||||||
- text: 已停止
|
- text: 已停止
|
||||||
- button "复制":
|
- button "复制":
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- textbox "Message the agent"
|
- textbox "Message the agent"
|
||||||
- button "Add attachment":
|
- button "Add attachment":
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user is asking for a one-sentence description of event sourcing. This is a straightforward knowledge question that doesn't require any skill loading or tool calls.":
|
- button "Think The user is asking for a one-sentence description of event sourcing. This is a straightforward knowledge question that doesn't require any skill loading or tool calls.":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to use the ask_user_question tool with specific parameters. Let me do exactly that.":
|
- button "Think The user wants me to use the ask_user_question tool with specific parameters. Let me do exactly that.":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- paragraph: partial
|
- paragraph: partial
|
||||||
- button "2 条排队消息"
|
- button "2 条排队消息"
|
||||||
- textbox "Message the agent"
|
- textbox "Message the agent"
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- paragraph: partial
|
- paragraph: partial
|
||||||
- button "2 条排队消息" [disabled] [expanded]
|
- button "2 条排队消息" [disabled] [expanded]
|
||||||
- list:
|
- list:
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- paragraph: partial
|
- paragraph: partial
|
||||||
- list:
|
- list:
|
||||||
- listitem:
|
- listitem:
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to use the ask_user_question tool to ask them a specific question with the given parameters. Let me do exactly that.":
|
- button "Think The user wants me to use the ask_user_question tool to ask them a specific question with the given parameters. Let me do exactly that.":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
@@ -15,10 +15,6 @@
|
|||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
- text: 上下文注入
|
- text: 上下文注入
|
||||||
- button "上下文注入":
|
|
||||||
- img
|
|
||||||
- img
|
|
||||||
- text: 上下文注入
|
|
||||||
- button "Think The user wants me to use the ask_user_question tool to ask them a specific question with the given parameters. Let me do exactly that.":
|
- button "Think The user wants me to use the ask_user_question tool to ask them a specific question with the given parameters. Let me do exactly that.":
|
||||||
- img
|
- img
|
||||||
- img
|
- img
|
||||||
|
|||||||
Reference in New Issue
Block a user