open-agents-ai 0.187.222 → 0.187.223

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.
Files changed (2) hide show
  1. package/dist/index.js +30 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -324906,7 +324906,7 @@ function createTaskCompleteTool(modelTier) {
324906
324906
  const summaryDesc = modelTier === "small" || modelTier === "medium" ? "Your complete response to the user. For questions/chat: put your FULL answer here (this is what the user will see). For coding tasks: brief summary of what was accomplished." : "Brief summary of what was accomplished";
324907
324907
  return {
324908
324908
  name: "task_complete",
324909
- description: "Signal that the task is complete.",
324909
+ description: "Signal that the task is complete. GUARDED: cannot fire while the active todo list (todo_write) has pending, in_progress, or blocked items. If you're truly done, first call todo_write to mark every remaining item completed. If you're not done, continue working down the list and call this only after the last item flips to completed.",
324910
324910
  parameters: {
324911
324911
  type: "object",
324912
324912
  properties: {
@@ -324915,6 +324915,35 @@ function createTaskCompleteTool(modelTier) {
324915
324915
  required: ["summary"]
324916
324916
  },
324917
324917
  async execute(args) {
324918
+ try {
324919
+ const sessionId = getTodoSessionId();
324920
+ const todos = readTodos(sessionId);
324921
+ if (todos.length > 0) {
324922
+ const incomplete = todos.filter(
324923
+ (t2) => t2.status === "pending" || t2.status === "in_progress" || t2.status === "blocked"
324924
+ );
324925
+ if (incomplete.length > 0) {
324926
+ const incompleteList = incomplete.slice(0, 10).map((t2) => ` - [${t2.status}] ${t2.content}${t2.blocker ? ` (blocked: ${t2.blocker})` : ""}`).join("\n");
324927
+ const more = incomplete.length > 10 ? `
324928
+ ... +${incomplete.length - 10} more` : "";
324929
+ return {
324930
+ success: false,
324931
+ output: "",
324932
+ error: `task_complete BLOCKED — ${incomplete.length} todo item(s) still incomplete. You must either:
324933
+ 1. Continue working on the remaining items, OR
324934
+ 2. If they're actually done, call todo_write with status='completed' for each one, THEN call task_complete again.
324935
+
324936
+ Incomplete items:
324937
+ ${incompleteList}${more}`
324938
+ };
324939
+ }
324940
+ try {
324941
+ writeTodos(sessionId, []);
324942
+ } catch {
324943
+ }
324944
+ }
324945
+ } catch {
324946
+ }
324918
324947
  return { success: true, output: args["summary"] || "Task completed." };
324919
324948
  }
324920
324949
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "open-agents-ai",
3
- "version": "0.187.222",
3
+ "version": "0.187.223",
4
4
  "description": "AI coding agent powered by open-source models (Ollama/vLLM) — interactive TUI with agentic tool-calling loop",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",