Commit Graph

30 Commits

Author SHA1 Message Date
Akhilesh Kumar 5a020e7720 fix(core): avoid restarting subagent MCP servers
I've tactically refactored the `LocalAgentExecutor` so that it avoids shutting down and restarting subagent MCP servers for every agent execution, which mitigates the performance overhead caused by long startup times.

1. Leveraging the Global McpClientManager:
Instead of instantiating an entirely new `McpClientManager` instance within the `LocalAgentExecutor` per execution (and shutting it down in its `finally` block), we now use the single global `McpClientManager` available on `context.config`. Since the global manager deduplicates connection attempts by checking if the server is already active, subagent MCP servers will now naturally stay alive after their initial initialization.

2. Prefixing to Avoid Polluting the Global Namespace:
To isolate the agent-specific tools, we now register the subagent's MCP servers with a unique prefix: `__agent__${definition.name}__${name}`.

3. Strict Filtering for True Isolation (ToolRegistry):
- Main CLI context: Added a block in the global `ToolRegistry.getFunctionDeclarations()` that strictly hides any tool belonging to a server prefixed with `__agent__` if the registry `isMainRegistry`. This prevents internal subagent tools from leaking to the main agent.
- Subagent context (`LocalAgentExecutor`): When inheriting tools from the parent registry (the fallback when an agent doesn't explicitly define `tools: []`), the agent now ignores `__agent__` prefixed tools that belong to *other* agents, ensuring strict tool isolation while keeping the actual underlying server processes alive and reusable.
2026-03-11 20:43:25 +00:00
Akhilesh Kumar d4b7d358c5 feat(core): support inline MCP server definitions in subagent markdown 2026-03-11 17:10:36 +00:00
Akhilesh Kumar c68a2cb933 feat(core): implement configuration-based tool isolation for subagents 2026-03-11 17:09:46 +00:00
joshualitt 20a226a5ab feat(core): Thread AgentLoopContext through core. (#21944) 2026-03-11 01:12:59 +00:00
AK 527074b50a feat(policy): support subagent-specific policies in TOML (#21431) 2026-03-09 19:22:46 +00:00
Aditya Bijalwan 759575faa8 Feat/browser agent progress emission (#21218)
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-03-09 17:26:00 +00:00
nityam 28af4e127f fix: merge duplicate imports in packages/core (3/4) (#20928) 2026-03-04 00:12:59 +00:00
Abhi b7a8f0d1f9 fix(core): ensure subagents use qualified MCP tool names (#20801) 2026-03-02 21:12:13 +00:00
Christian Gunderman 7ca3a33f8b Subagent activity UX. (#17570) 2026-03-02 21:04:31 +00:00
Abhi d2d345f41a fix(cli): filter subagent sessions from resume history (#19698) 2026-02-21 17:41:27 +00:00
Christian Gunderman 58d637f919 Disallow and suppress unsafe assignment (#19736) 2026-02-20 22:28:55 +00:00
Christian Gunderman c276d0c7b6 Fix message too large issue. (#19499) 2026-02-19 19:06:36 +00:00
joshualitt 87f5dd15d6 feat(core): experimental in-progress steering hints (2 of 2) (#19307) 2026-02-18 22:05:50 +00:00
Yuna Seol 8aca3068cf feat: add role-specific statistics to telemetry and UI (cont. #15234) (#18824)
Co-authored-by: Yuna Seol <yunaseol@google.com>
2026-02-17 17:32:30 +00:00
Christian Gunderman fd65416a2f Disallow unsafe type assertions (#18688) 2026-02-10 00:10:15 +00:00
Abhi 11951592aa feat(core): pause agent timeout budget while waiting for tool confirmation (#18415) 2026-02-08 04:03:47 +00:00
Abhi b39cefe14e feat(core): add default execution limits for subagents (#18274) 2026-02-04 06:28:00 +00:00
Abhi eccc200f4f feat(core): enforce server prefixes for MCP tools in agent definitions (#17574) 2026-01-27 04:53:05 +00:00
Abhi 9d34ae52d6 feat(agents): migrate subagents to event-driven scheduler (#17567) 2026-01-26 22:12:55 +00:00
Christian Gunderman 77aef861fe fix(agents): default to all tools when tool list is omitted in subagents (#17422) 2026-01-24 01:30:18 +00:00
Christian Gunderman 2c6781d134 Refactor subagent delegation to be one tool per agent (#17346) 2026-01-23 02:18:31 +00:00
joshualitt 27d21f9921 feat(core): Have subagents use a JSON schema type for input. (#17152) 2026-01-22 00:56:01 +00:00
Christian Gunderman a15978593a Steer outer agent to use expert subagents when present (#16763) 2026-01-16 16:51:10 +00:00
joshualitt d66ec38f82 feat(core): Align internal agent settings with configs exposed through settings.json (#16458) 2026-01-13 22:31:34 +00:00
joshualitt 41a8809280 feat(core): Wire up model routing to subagents. (#16043) 2026-01-08 20:39:40 +00:00
Abhi 12c7c9cc42 feat(core,cli): enforce mandatory MessageBus injection (Phase 3 Hard Migration) (#15776) 2026-01-04 22:11:43 +00:00
Abhi 5566292cc8 refactor(core): extract static concerns from CoreToolScheduler (#15589) 2025-12-26 20:51:39 +00:00
Tommaso Sciortino 10ba348a3a Introspection agent demo (#15232) 2025-12-19 22:11:32 +00:00
Abhi 2b426c1d91 feat: add agent toml parser (#15112) 2025-12-18 03:46:55 +00:00
Adam Weidman d02f3f6809 feat(core): introduce remote agent infrastructure and rename local executor (#15110) 2025-12-17 17:06:38 +00:00