From 96b06278a518dd58cbf8b2853c65d28552469bba Mon Sep 17 00:00:00 2001 From: Tyler Longwell Date: Wed, 8 Oct 2025 11:12:33 -0400 Subject: [PATCH] Analyze focus mode hint when file specified --- crates/goose-mcp/src/developer/analyze/mod.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/crates/goose-mcp/src/developer/analyze/mod.rs b/crates/goose-mcp/src/developer/analyze/mod.rs index a6dccd7affbe..9c30a33607de 100644 --- a/crates/goose-mcp/src/developer/analyze/mod.rs +++ b/crates/goose-mcp/src/developer/analyze/mod.rs @@ -318,6 +318,14 @@ impl CodeAnalyzer { outgoing_chains: &outgoing_chains, }; - Ok(Formatter::format_focused_output(&focus_data)) + let mut output = Formatter::format_focused_output(&focus_data); + + if path.is_file() { + let hint = "NOTE: Focus mode works best with directory paths. \ + Use a parent directory in the path for cross-file analysis.\n\n"; + output = format!("{}{}", hint, output); + } + + Ok(output) } }