tuna-agent 0.1.176 → 0.1.177
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -156,6 +156,12 @@ export async function executePlanAndReport(task, plan, ws, resolvers, signal, co
|
|
|
156
156
|
if (status === 'waiting_input') {
|
|
157
157
|
return { sessions, status };
|
|
158
158
|
}
|
|
159
|
+
// Single 'self' task: the result was already delivered by onSubtaskDone (in the
|
|
160
|
+
// agent's own voice). Complete directly — no robotic "All sessions completed /
|
|
161
|
+
// continue?" wrapper. Follow-up happens naturally via a thread reply.
|
|
162
|
+
if (plan.subtasks.length <= 1) {
|
|
163
|
+
return { sessions, status };
|
|
164
|
+
}
|
|
159
165
|
const totalDuration = sessions.reduce((sum, s) => sum + (s.durationMs ?? 0), 0);
|
|
160
166
|
const durationStr = (totalDuration / 1000).toFixed(1);
|
|
161
167
|
// Announce result
|