[GH-ISSUE #2142] Subagents dynamic prompt #269

Closed
opened 2026-02-17 17:19:31 -05:00 by yindo · 0 comments
Owner

Originally created by @zzzrbx on GitHub (Jan 8, 2026).
Original GitHub issue: https://github.com/langchain-ai/docs/issues/2142

As per documentation subagent is created like:

research_subagent = {
    "name": "research-agent",
    "description": "Used to research more in depth questions",
    "system_prompt": "You are a great researcher",
    "tools": [internet_search],
    "model": "openai:gpt-4o",  # Optional override, defaults to main agent model
}

subagents = [research_subagent]

agent = create_deep_agent(
    model="claude-sonnet-4-5-20250929",
    subagents=subagents
)
  1. is it possible to have the supervisor dynamically changing the prompt? If not, is creating a subagent as a tool the only option?
  2. can the supervisor spawn multiple subagents of the same type (for example for processing large documents, each subagent having a few pages to process)? In this case the supervisor should have the ability to modify the prompt
Originally created by @zzzrbx on GitHub (Jan 8, 2026). Original GitHub issue: https://github.com/langchain-ai/docs/issues/2142 As per [documentation](https://docs.langchain.com/oss/python/deepagents/subagents) subagent is created like: ``` research_subagent = { "name": "research-agent", "description": "Used to research more in depth questions", "system_prompt": "You are a great researcher", "tools": [internet_search], "model": "openai:gpt-4o", # Optional override, defaults to main agent model } subagents = [research_subagent] agent = create_deep_agent( model="claude-sonnet-4-5-20250929", subagents=subagents ) ``` 1. is it possible to have the supervisor dynamically changing the prompt? If not, is creating a subagent as a tool the only option? 2. can the supervisor spawn multiple subagents of the same type (for example for processing large documents, each subagent having a few pages to process)? In this case the supervisor should have the ability to modify the prompt
yindo added the external label 2026-02-17 17:19:31 -05:00
yindo closed this issue 2026-02-17 17:19:31 -05:00
yindo changed title from Subagents dynamic prompt to [GH-ISSUE #2142] Subagents dynamic prompt 2026-06-05 17:25:59 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/docs#269