diff --git a/desktop/src/features/chats/ui/ChatDetail.tsx b/desktop/src/features/chats/ui/ChatDetail.tsx index 5aceb466a..73ec971ab 100644 --- a/desktop/src/features/chats/ui/ChatDetail.tsx +++ b/desktop/src/features/chats/ui/ChatDetail.tsx @@ -539,8 +539,14 @@ export function ChatDetail({ hasObserver, latestOwnMessageNeedsAgent, ]); + // A stopped default agent always shows the card — "is it running, is it + // silent?" must never be ambiguous. The delayed path still covers a + // running-but-unresponsive agent. + const defaultAgentInactive = + defaultAgent != null && !isManagedAgentActive(defaultAgent); const shouldShowAgentActivationCard = - latestOwnMessageNeedsAgent && (!hasObserver || showDelayedActivationCard); + (defaultAgentInactive && latestVisibleMessage != null) || + (latestOwnMessageNeedsAgent && (!hasObserver || showDelayedActivationCard)); const forceScrollSignature = latestVisibleMessageIsOwn ? latestVisibleMessage.id : null; @@ -728,6 +734,7 @@ export function ChatDetail({ { if (!onAutomationPrompt || !effectiveHref) { return; @@ -155,7 +161,8 @@ export function ChatWorkPanel({ onAutomationPrompt( `There are unanswered review comments on ${effectiveHref}. Address each comment and its replies, push any needed changes, reply to the threads, and resolve every conversation that has been addressed.`, ); - }, [chatId, effectiveHref, onAutomationPrompt, openThreads]); + toast.success(`Asked ${agentName} to address the review comments`); + }, [agentName, chatId, effectiveHref, onAutomationPrompt, openThreads]); // Automation: prompt the agent on CI failure / newly-open review threads. // Watermarks keep this to one nudge per failing sha and per rise in open