From 7e5d9ff118483463ad4a3ecc42e8bf2bd367cea6 Mon Sep 17 00:00:00 2001 From: agentforce314 <273884145+agentforce314@users.noreply.github.com> Date: Sun, 16 Aug 2026 02:23:38 -0700 Subject: [PATCH] feat(nano): three distilled care/delivery/verification guidelines MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Restores, as one line each, the general practices whose absence the first TB 2.1 nano run exposed (analysis in my-docs/clawcodex-nano/): * copy-before-probing for state a task needs intact — db-wal-recovery was lost because the first exploratory sqlite3 open of the database reset its invalid WAL, destroying what the task asked to recover * minimal-working-deliverable-early — four tasks died at the per-task wall clock mid-polish with no passing artifact in place, on tasks the same model solved in pi's run by crossing the line earlier * verify-requirements-before-finishing — three tasks ended with a confident summary the verifier rejected All three are distillations of clawcodex's full-prompt sections (Executing actions with care / Doing tasks), not benchmark-specific knowledge. Fixed payload grows ~120 est. tokens (~2.4K total, budget 2.5K); 59 nano tests pass. Co-Authored-By: Claude Fable 5 --- src/nano/prompt.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/nano/prompt.py b/src/nano/prompt.py index ec0594da..11dc5d10 100644 --- a/src/nano/prompt.py +++ b/src/nano/prompt.py @@ -48,6 +48,13 @@ "Glob": "find files by glob pattern", } +# The three non-tool guidelines at the end are distilled from clawcodex's +# full "Doing tasks" / "Executing actions with care" sections, restored +# after the first TB 2.1 nano run showed exactly the failures they exist +# to prevent (my-docs/clawcodex-nano/: a recovery task lost because the +# first exploratory open of a database mutated it; tasks failed at the +# wall clock with no artifact in place; confident summaries the verifier +# rejected). Each is a universal engineering practice, kept to one line. _GUIDELINES = ( "- Use Read to examine files instead of cat/sed/head, and Grep/Glob " "instead of shell grep/find", @@ -56,6 +63,15 @@ "- When changing multiple places in one file, use ONE Edit call with " "multiple entries in edits[]; keep each old_string as small as " "possible while still unique, and never overlap edits", + "- Before probing or modifying state you might need intact later — " + "databases, files a task asks you to repair or recover, anything " + "one-of-a-kind — copy it somewhere safe first; some tools mutate " + "files merely by opening them", + "- Get a minimal working version of the requested deliverable in " + "place early, then iterate to improve it", + "- Before finishing, re-read the task and verify each explicit " + "requirement against what you actually produced; plausible output " + "is not verified output", "- Be concise in your responses", "- Show file paths clearly when working with files", )