Skip to content

Commit e391f86

Browse files
fix(scouts): add web_search/web_fetch fallback when MCPs fail (#53)
When Brave/Exa/Tavily MCP servers auth-fail (as happened 2026-04-22 when all three API keys were unavailable in the cron env), scout agents had no tool to fall back on and silently degraded — every scout reported status: complete with 0 repos added and error: null. The entire nightly fleet produced zero live-verified discoveries. Kiro ships native web_search and web_fetch built-ins, but the scout agent configs narrowed their tool whitelist to ["read","write", "@brave-search","@Tavily","@exa"] only, so those built-ins were unreachable even when MCP providers broke. Add web_search/web_fetch to the tool whitelist for both project-watcher (scout root) and probe-topic (parallel subagent), and update the steering prompts to instruct the agents to fall back to native web tools when an MCP provider auth-fails rather than abandoning the topic or synthesizing from training knowledge. Prefer MCP providers for structured results and source diversity; native tools are the always-available safety net.
1 parent e324f41 commit e391f86

4 files changed

Lines changed: 39 additions & 4 deletions

File tree

src/data/probe-topic.json

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,23 @@
22
"name": "probe-topic",
33
"description": "Intra-scout subagent: deep-dives a single topic from the parent scout's manifest and returns a structured repo-discovery report. Invoked via use_subagent(InvokeSubagents) with one topic per call so topics are explored in parallel isolated contexts.",
44
"model": "claude-haiku-4-5-20251001",
5-
"tools": ["read", "write", "@brave-search", "@tavily", "@exa"],
6-
"allowedTools": ["read", "@brave-search", "@tavily", "@exa"],
5+
"tools": [
6+
"read",
7+
"write",
8+
"web_search",
9+
"web_fetch",
10+
"@brave-search",
11+
"@tavily",
12+
"@exa"
13+
],
14+
"allowedTools": [
15+
"read",
16+
"web_search",
17+
"web_fetch",
18+
"@brave-search",
19+
"@tavily",
20+
"@exa"
21+
],
722
"includeMcpJson": true,
823
"prompt": "file://../steering/probe-topic.md"
924
}

src/data/probe-topic.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ for that one topic and return. You never fan out further.
1818
## What to do
1919

2020
1. Search across `@brave-search`, `@tavily`, and `@exa` for trending GitHub
21-
repositories matching the topic. Deduplicate by `owner/name`.
21+
repositories matching the topic. Deduplicate by `owner/name`. If any of
22+
those MCP providers returns an auth / rate-limit error, fall back to
23+
Kiro's built-in `web_search` and `web_fetch` rather than abandoning the
24+
topic.
2225
2. For each candidate repo, note: star count, last-commit date, primary
2326
language, and a one-sentence description.
2427
3. Filter to repos that:

src/data/project-watcher.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
{
22
"name": "project-watcher",
33
"description": "Iterative deep research agent for discovering trending GitHub repos matching watched topics and languages. Fans out per-topic deep dives to the probe-topic subagent.",
4-
"tools": ["read", "write", "@brave-search", "@tavily", "@exa"],
4+
"tools": [
5+
"read",
6+
"write",
7+
"web_search",
8+
"web_fetch",
9+
"@brave-search",
10+
"@tavily",
11+
"@exa"
12+
],
513
"allowedTools": ["*"],
614
"includeMcpJson": true,
715
"resources": [

src/data/watcher-context.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,15 @@ Cast a wide net across all search tools:
8080
- Search for blog posts announcing new tools and frameworks
8181
- Search for "awesome list" additions in your topic areas
8282

83+
**Fallback — Kiro native `web_search` / `web_fetch`:**
84+
If a given MCP search provider returns an authentication or rate-limit
85+
error, fall back to the built-in `web_search` and `web_fetch` tools rather
86+
than giving up or synthesizing from training knowledge. Prefer the MCP
87+
providers for their structured results and source diversity, but do not
88+
treat them as the only path. A scout run with zero discoveries because all
89+
three MCPs auth-failed is a preventable failure mode — native search is
90+
always available.
91+
8392
For each candidate repo found, record:
8493
- Full repo name (owner/repo)
8594
- GitHub URL

0 commit comments

Comments
 (0)