支持关闭 Deep Agent 内置的 task(subagent spawner)提示词注入
- Dominant language
- Go
- Stars
- 13k
- Forks
- 1.1k
- Avg merge
- 4h 6m
- Merged PRs (30d)
- 41
Description
## 背景
使用 `adk/prebuilt/deep` 创建 Deep Agent 时,框架会通过 `AgentMiddleware.AdditionalInstruction` 将一段关于 **'task' (subagent spawner)** 的长提示词拼接到系统提示词中(见 `prompt.go` 中的 `taskPrompt`、`task_tool.go` 中 `newTaskToolMiddleware` 的 `AdditionalInstruction: taskPrompt`)。
对于部分场景(例如已有自己的主 agent 系统提示与 task 使用说明),希望**仅保留 task 工具能力,但不注入这段内置提示词**,以便完全由自己的提示词控制行为。
## 当前行为
- 只要启用了 SubAgents(或未关闭 general subagent),创建 Deep Agent 时就会自动注入 `taskPrompt` 全文到系统提示词。
- 没有配置项可以关闭该注入;`TaskToolDescriptionGenerator` 只能自定义**工具描述**,无法控制这段**附加说明**是否加入。
## 期望行为
- 提供一种方式(例如配置项)让调用方可以选择**不**将 `taskPrompt` 注入到系统提示词。
- task 工具本身仍然存在且可用,只是不再向 system instruction 追加这段固定文案。
感谢维护 eino 项目。
Contributor guide
Research direction
Start in prompt.go with taskPrompt, then trace newTaskToolMiddleware in task_tool.go and its AdditionalInstruction assignment. Define a configuration path that keeps the task tool available while optionally omitting that instruction; done means both enabled and disabled behavior are covered by the affected package's tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- ai
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 72/100