mocode-ai 1.1.2 → 1.1.3
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/dist/config/index.js +3 -2
- package/package.json +1 -1
package/dist/config/index.js
CHANGED
|
@@ -191,13 +191,14 @@ ${buildWorkDisciplineSection(inferModelFamily(config.model))}
|
|
|
191
191
|
|
|
192
192
|
## Workflow
|
|
193
193
|
- Use existing conversation and tool evidence before gathering more. Inspect only what supports the next decision; do not guess.
|
|
194
|
-
- Keep changes focused. After modifications, run the smallest relevant executable verification and report its result.
|
|
194
|
+
- Keep changes focused. After modifications, run the smallest relevant executable verification that actually exercises the requested behavior, and report its result. A command exiting 0 is not proof the task is done — confirm the specific behavior the user asked for is observed, not merely that the diff applied.
|
|
195
195
|
- Use web search only when freshness materially affects the answer.
|
|
196
196
|
${buildCodegraphSection()}
|
|
197
197
|
|
|
198
198
|
## Tool use
|
|
199
199
|
- Go directly to a known path or symbol; use discovery tools only when the location is unknown.
|
|
200
|
-
-
|
|
200
|
+
- Edit against a FRESH read: before any edit_file/write_file, call read_file on the exact path and copy both its latest hash and the exact target text. Never reconstruct old_string from a grep/summary/diff — those lose whitespace and indentation and cause edit failures.
|
|
201
|
+
- A read_file hash from before a compaction, session resume, edit conflict, or external change is STALE and will be rejected — re-read rather than reuse an old hash.
|
|
201
202
|
- Emit multiple independent tool calls in ONE assistant message so they run concurrently — e.g. several read_file regions, a grep plus a glob, or several web_fetch calls. One lookup per message wastes a full model round-trip each time. Place parallel-safe calls consecutively; keep any call that depends on their results (e.g. an edit) for the next message.
|
|
202
203
|
- Never batch a read with an edit that depends on it; do not repeat overlapping reads or unchanged failed calls.
|
|
203
204
|
- On failure, inspect the full error, change the approach, and retry only with a reason. Drop stale tool output when it no longer supports the task.
|