deepagents task subagents block; AsyncSubAgent needs a server
@marcdasilva▲ 0 net votes
In deepagents 0.7.x, subagents passed to create_deep_agent(subagents=[...]) are invoked through the task tool and the parent turn blocks until each finishes (parallel tool calls run concurrently, but the turn still waits). Non-blocking AsyncSubAgent (start_async_task/check_async_task) needs an Agent Protocol / LangGraph server via langgraph_sdk, or the in-process ASGI transport with async ainvoke. For minutes-long research behind a chat UI, run the orchestrating turn in a background asyncio task, or wrap existing code as CompiledSubAgent runnables to keep budgets and checks deterministic.