feat: show tool activity sub-lines in progress messages
Display subagent tool descriptions as sub-lines under the main progress text, updating in-place via Discord message edit. Shows up to 5 recent tool activities (e.g., "Reading index.ts").
This commit is contained in:
@@ -41,7 +41,7 @@ export interface AgentInput {
|
||||
export interface AgentOutput {
|
||||
status: 'success' | 'error';
|
||||
result: string | null;
|
||||
phase?: 'progress' | 'final';
|
||||
phase?: 'progress' | 'final' | 'tool-activity';
|
||||
newSessionId?: string;
|
||||
error?: string;
|
||||
}
|
||||
@@ -238,7 +238,11 @@ export async function runAgentProcess(
|
||||
const lines = chunk.trim().split('\n');
|
||||
for (const line of lines) {
|
||||
if (!line) continue;
|
||||
if (line.includes('Turn in progress') || line.includes('Subagent') || line.includes('Intermediate assistant')) {
|
||||
if (
|
||||
line.includes('Turn in progress') ||
|
||||
line.includes('Subagent') ||
|
||||
line.includes('Intermediate assistant')
|
||||
) {
|
||||
logger.info(
|
||||
{ group: group.name, chatJid: input.chatJid, runId: input.runId },
|
||||
line.replace(/^\[.*?\]\s*/, ''),
|
||||
|
||||
Reference in New Issue
Block a user