mirror of
https://github.com/getcompanion-ai/co-mono.git
synced 2026-04-17 04:02:21 +00:00
feat(plan-mode): show final completed list in chat when plan finishes
Displays all completed items with strikethrough markdown when all todos are done.
This commit is contained in:
parent
5a6c194df8
commit
d7546f08ce
1 changed files with 14 additions and 1 deletions
|
|
@ -398,8 +398,21 @@ IMPORTANT: After completing each step, output [DONE:id] where id is the step's I
|
||||||
// Check if all complete
|
// Check if all complete
|
||||||
const allComplete = todoItems.every((t) => t.completed);
|
const allComplete = todoItems.every((t) => t.completed);
|
||||||
if (allComplete) {
|
if (allComplete) {
|
||||||
ctx.ui.notify("Plan execution complete!", "info");
|
// Show final completed list in chat
|
||||||
|
const completedList = todoItems
|
||||||
|
.map((t) => `~~${t.text}~~`)
|
||||||
|
.join("\n");
|
||||||
|
pi.sendMessage(
|
||||||
|
{
|
||||||
|
customType: "plan-complete",
|
||||||
|
content: `**Plan Complete!** ✓\n\n${completedList}`,
|
||||||
|
display: true,
|
||||||
|
},
|
||||||
|
{ triggerTurn: false },
|
||||||
|
);
|
||||||
|
|
||||||
executionMode = false;
|
executionMode = false;
|
||||||
|
const completedItems = [...todoItems]; // Keep for reference
|
||||||
todoItems = [];
|
todoItems = [];
|
||||||
pi.setTools(NORMAL_MODE_TOOLS);
|
pi.setTools(NORMAL_MODE_TOOLS);
|
||||||
updateStatus(ctx);
|
updateStatus(ctx);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue