Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions examples/openclaw-plugin/INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ openclaw status

```bash
openclaw plugins enable openviking
openclaw config set plugins.entries.openviking.hooks.allowPromptInjection true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Design] (blocking)

同 install.sh:626 - 如果这个配置确实必要,需要在文档中添加说明:

  • 为什么需要这个配置?
  • 如果缺少会发生什么?
  • OpenClaw 框架的哪个机制依赖它?

openclaw config set gateway.mode local
openclaw config set plugins.slots.contextEngine openviking
openclaw config set plugins.entries.openviking.config.mode remote
Expand Down
1 change: 1 addition & 0 deletions examples/openclaw-plugin/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ curl -X POST http://localhost:1933/api/v1/admin/accounts/my-team/users \

```bash
openclaw plugins enable openviking
openclaw config set plugins.entries.openviking.hooks.allowPromptInjection true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Design] (blocking)

同 INSTALL.md:202 - 需要在文档中说明配置的作用。另外,建议在 Troubleshooting 章节添加相关内容,帮助用户理解这个配置。

openclaw config set gateway.mode local
openclaw config set plugins.slots.contextEngine openviking
openclaw config set plugins.entries.openviking.config.mode remote
Expand Down
1 change: 1 addition & 0 deletions examples/openclaw-plugin/install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ function Configure-OpenClawPlugin {
# Enable plugin (files already deployed to extensions dir by Deploy-Plugin)
openclaw plugins enable openviking
if ($LASTEXITCODE -ne 0) { throw "openclaw plugins enable failed (exit code $LASTEXITCODE)" }
openclaw config set plugins.entries.openviking.hooks.allowPromptInjection true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Design] (blocking)

同 install.sh:626 - 配置的必要性和正确性无法验证。整个 OpenViking 代码库中没有任何 allowPromptInjection 的引用,插件代码也不依赖此配置。

openclaw config set plugins.slots.contextEngine openviking

# Set gateway mode
Expand Down
1 change: 1 addition & 0 deletions examples/openclaw-plugin/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -623,6 +623,7 @@ configure_openclaw_plugin() {

# Enable plugin (files already deployed to extensions dir by deploy_plugin)
"${oc_env[@]}" openclaw plugins enable openviking || { err "$(tr "openclaw plugins enable failed" "openclaw 插件启用失败")"; exit 1; }
"${oc_env[@]}" openclaw config set plugins.entries.openviking.hooks.allowPromptInjection true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Design] (blocking)

配置必要性无法验证:hooks.allowPromptInjection 在整个 OpenViking 代码库中完全不存在(包括插件源码、配置定义、文档、commit 历史)。

发现:

  1. 插件的 before_prompt_build hook 在 index.ts:412 无条件注册,没有检查任何 allowPromptInjection 配置
  2. auto-recall 功能由 cfg.autoRecall 控制(config.ts,默认 true),不依赖 hooks.* 配置
  3. 配置路径 plugins.entries.openviking.hooks.* 不符合标准模式(通常是 plugins.entries.<name>.config.*

需要验证:

  • 在没有这个配置的情况下,auto-recall 是否真的不工作?
  • OpenClaw 框架是否确实需要这个配置?如果需要,请提供文档或源码引用
  • 配置路径是否正确?

如果配置确实必要,需要在 OpenViking 文档中说明其作用和必要性。

"${oc_env[@]}" openclaw config set plugins.slots.contextEngine openviking

# Set gateway mode
Expand Down
3 changes: 3 additions & 0 deletions examples/openclaw-plugin/setup-helper/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -654,6 +654,9 @@ async function configureOpenClawPlugin(pluginPath = PLUGIN_DEST) {
if (enableResult.code !== 0) throw new Error(`openclaw plugins enable failed (exit code ${enableResult.code})`);
await oc(["config", "set", "plugins.slots.contextEngine", "openviking"]);

// Enable prompt injection hooks (required for auto-recall feature)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[Design] (blocking)

同 install.sh:626 - 配置的必要性和正确性无法验证。建议先通过实际测试确认:在没有这个配置的情况下,auto-recall 功能是否真的无法工作?

await oc(["config", "set", "plugins.entries.openviking.hooks.allowPromptInjection", "true"]);

// Set gateway mode
await oc(["config", "set", "gateway.mode", "local"]);

Expand Down
Loading