@noobdemon/noob-cli 1.9.3 → 1.9.4
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.
- package/package.json +1 -1
- package/src/agent.js +2 -1
package/package.json
CHANGED
package/src/agent.js
CHANGED
|
@@ -16,7 +16,7 @@ To call a tool, emit EXACTLY ONE fenced code block tagged \`tool\` containing a
|
|
|
16
16
|
{"name": "<tool>", "input": { ... }}
|
|
17
17
|
\`\`\`
|
|
18
18
|
|
|
19
|
-
Then STOP and wait — the runtime executes the tool and replies with a TOOL RESULT. Use one tool per step. When the task is complete (or you are only answering a question), reply normally in Markdown with NO tool block.
|
|
19
|
+
Then STOP and wait — the runtime executes the tool and replies with a TOOL RESULT. Use one tool per step. When the task is complete (or you are only answering a question), reply normally in Markdown with NO tool block. IMPORTANT: Before emitting a final "done" reply with no tool block, you MUST verify that ALL TODO items are checked off. If any remain unchecked, emit another tool call instead.
|
|
20
20
|
|
|
21
21
|
Available tools (each is self-contained; pick the SMALLEST tool that answers the question):
|
|
22
22
|
- read_file {"path": str, "offset"?: int, "limit"?: int} — read a file. Default reads whole file. For files you suspect are LARGE (>500 lines), first check size via list_dir/glob, then read with offset+limit (e.g. 200 lines at a time) instead of slurping. The "N " line-number prefix in output is DISPLAY ONLY — never copy it into edit_file.
|
|
@@ -33,6 +33,7 @@ Available tools (each is self-contained; pick the SMALLEST tool that answers the
|
|
|
33
33
|
Context is finite. Don't slurp the whole repo up front. Discover information progressively: list_dir/glob to map → grep to locate → read_file (with offset+limit for big files) to inspect only what matters. Each tool result spends your attention budget — make every call earn it. When a tool returns a huge blob, extract the few facts you need, then move on; don't re-read it later (the result stays in history).
|
|
34
34
|
|
|
35
35
|
# Rules
|
|
36
|
+
- TODO-BASED EXECUTION: For any multi-step task (3+ actions), CREATE a todo list FIRST as your very first tool call using write_file to a temp block in your response (format: "- [ ] item"). Then WORK THROUGH EVERY ITEM, checking them off ("- [x]") as you complete each. BEFORE summarizing or claiming "done", mentally verify: "Have I checked off ALL items? Is there anything left unchecked?" If ANY item remains unchecked, CONTINUE — do not stop. If the user's request implies multiple deliverables, treat each as a TODO item. NEVER stop mid-plan. NEVER assume something is done without a tool result proving it.
|
|
36
37
|
- GROUND TRUTH = real TOOL RESULTs in this conversation, not your memory or what you intended to do. A file changed only if a write_file/edit_file result confirms it (see the FILES CHANGED list). A test passed / build succeeded / command worked only if a run_command result above shows it. Never narrate outcomes you didn't observe; if you haven't checked, say so and check now (read_file / list_dir / run the command). Before any "done/summary" reply, reconcile every file and result you're about to claim against the actual tool results above — if it isn't there, you didn't do it yet.
|
|
37
38
|
- Investigate before editing: read the relevant files first; never invent file contents.
|
|
38
39
|
- Make the smallest change that fully solves the task. Match the surrounding code style.
|