diff --git a/docs/en-US/pi-runtime.md b/docs/en-US/pi-runtime.md index 88be538c..69872ec2 100644 --- a/docs/en-US/pi-runtime.md +++ b/docs/en-US/pi-runtime.md @@ -15,7 +15,7 @@ The launcher and self-update build prepare the worker. Dependency installation u ## Configuration -`agent_runtime.engine` accepts only `pi` (also the default). The former engine and dependencies have been removed. Optional `node_path`, `worker_path`, and `session_dir` control deployment. Settings displays Pi and exposes the DSH-Purge-derived capability guidance. `purge.model_instructions` provides additive guidance by exact `provider/model` or model ID. +`agent_runtime.engine` accepts only `pi` (also the default). The former engine and dependencies have been removed. Optional `node_path`, `worker_path`, and `session_dir` control deployment. Under Agent config → Advanced settings, you can turn the built-in work guidance on or off and add optional instructions. When enabled, a blank field still uses the built-in guidance; turning it off omits both the built-in guidance and additional instructions. `purge.model_instructions` provides additive guidance by exact `provider/model` or model ID. The guidance combines capability selection, main/child task anchors and evidence requirements. It does not ship DSH host patches or encrypted identity prompts. Attribution is in `runtime/pi/THIRD_PARTY_NOTICES.md`. diff --git a/docs/zh-CN/pi-runtime.md b/docs/zh-CN/pi-runtime.md index f36759e2..0309ebc5 100644 --- a/docs/zh-CN/pi-runtime.md +++ b/docs/zh-CN/pi-runtime.md @@ -26,7 +26,7 @@ agent_runtime: "provider/model-id": "此模型的额外工作约定" ``` -设置页显示唯一的 Pi 运行时,可开关能力增强及编辑附加指令。`worker_path` 是管理员的显式覆盖,适合开发或独立打包;留空使用源码指纹校验后的构建包。未填写 engine 的新代码默认使用 Pi;现有部署的运行数据和模型配置不会因此自动迁移或部署。 +系统固定使用 Pi。「Agent 配置 → 高级设置」可开关内置工作提示及编辑附加指令。开启时,附加指令留空仍会使用内置提示;关闭时,两者都不加入模型提示词。`worker_path` 是管理员的显式覆盖,适合开发或独立打包;留空使用源码指纹校验后的构建包。现有部署的运行数据和模型配置不会因此自动迁移或部署。 ## 执行边界 diff --git a/web/static/i18n/en-US.json b/web/static/i18n/en-US.json index 5b91fc25..ee9c938c 100644 --- a/web/static/i18n/en-US.json +++ b/web/static/i18n/en-US.json @@ -3283,10 +3283,10 @@ "testErrorForbidden": "Request denied. Check account permissions or model access.", "testErrorModelUnavailable": "Model is unavailable or the model name is incorrect.", "testErrorBaseUrl": "Base URL is unavailable. Check that the endpoint is correct.", - "agentRuntime": "Agent runtime", - "purgeEnabled": "Enable DSH-Purge capability guidance", - "purgeHint": "Add capability selection, task anchors and evidence requirements to main and child agents.", - "purgeInstruction": "Model guidance" + "purgeEnabled": "Use built-in work guidance", + "purgeHint": "Give main agents and subagents guidance on choosing tools, following up on tasks and recording evidence. Tool permissions stay the same.", + "purgeInstruction": "Additional work instructions (optional)", + "purgeInstructionHint": "These instructions apply to all models when built-in work guidance is enabled. Leave blank to keep using the built-in guidance." }, "settingsTerminal": { "title": "Terminal", diff --git a/web/static/i18n/zh-CN.json b/web/static/i18n/zh-CN.json index 1039b168..746009ff 100644 --- a/web/static/i18n/zh-CN.json +++ b/web/static/i18n/zh-CN.json @@ -3271,10 +3271,10 @@ "testErrorForbidden": "请求被拒绝,请检查账号权限或模型访问权限", "testErrorModelUnavailable": "模型不可用或模型名不正确,请检查模型名称", "testErrorBaseUrl": "Base URL 不可用,请检查地址是否正确", - "agentRuntime": "智能体运行时", - "purgeEnabled": "启用 DSH-Purge 能力增强", - "purgeHint": "为主代理和子代理补充能力选择、任务锚点与证据要求。", - "purgeInstruction": "模型增强指令" + "purgeEnabled": "使用内置工作提示", + "purgeHint": "为主代理和子代理添加工具选择、任务跟进和证据记录提示,不改变工具权限。", + "purgeInstruction": "附加工作指令(可选)", + "purgeInstructionHint": "开启内置工作提示后,此处的指令适用于所有模型。留空仍会使用内置提示。" }, "settingsTerminal": { "title": "终端", diff --git a/web/static/js/settings.js b/web/static/js/settings.js index 64182dda..ae489fc6 100644 --- a/web/static/js/settings.js +++ b/web/static/js/settings.js @@ -883,13 +883,11 @@ async function loadConfig(loadTools = true, options = {}) { } // 填充Agent配置 - const runtimeConfig = currentConfig.agent_runtime || {}; - const runtimeEngineEl = document.getElementById('agent-runtime-engine'); - if (runtimeEngineEl) runtimeEngineEl.value = runtimeConfig.engine || 'pi'; + const promptProfile = currentConfig.agent_runtime?.purge; const purgeEnabledEl = document.getElementById('agent-purge-enabled'); - if (purgeEnabledEl) purgeEnabledEl.checked = runtimeConfig.purge?.enabled !== false; + if (purgeEnabledEl) purgeEnabledEl.checked = promptProfile?.enabled !== false; const purgeInstructionEl = document.getElementById('agent-purge-instruction'); - if (purgeInstructionEl) purgeInstructionEl.value = runtimeConfig.purge?.instruction || ''; + if (purgeInstructionEl) purgeInstructionEl.value = promptProfile?.instruction || ''; document.getElementById('agent-max-iterations').value = currentConfig.agent.max_iterations || 30; const toolWaitTimeoutEl = document.getElementById('agent-tool-wait-timeout-seconds'); if (toolWaitTimeoutEl) { @@ -2084,10 +2082,7 @@ async function applySettings() { audit_agent_prompt_review_edit: document.getElementById('hitl-audit-agent-prompt-review-edit-settings')?.value.trim() || '' }, agent_runtime: { - ...(currentConfig.agent_runtime || {}), - engine: document.getElementById('agent-runtime-engine')?.value || currentConfig.agent_runtime?.engine || 'pi', purge: { - ...(currentConfig.agent_runtime?.purge || {}), enabled: document.getElementById('agent-purge-enabled')?.checked ?? currentConfig.agent_runtime?.purge?.enabled ?? true, instruction: document.getElementById('agent-purge-instruction')?.value ?? currentConfig.agent_runtime?.purge?.instruction ?? '' } diff --git a/web/templates/index.html b/web/templates/index.html index bf430c50..36c78bea 100644 --- a/web/templates/index.html +++ b/web/templates/index.html @@ -3950,18 +3950,6 @@