@nanobpm/nano-coder 0.22.1 → 0.24.0

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/README.md +14 -2
  2. package/package.json +5 -5
package/README.md CHANGED
@@ -201,8 +201,14 @@ The harness exposes 6 lifecycle hook events:
201
201
  - `read_file` - Numbered lines of a text file; `path`, optional `offset` (1-based) and `limit`
202
202
  (default 2000 lines). Refuses binary files.
203
203
  - `write_file` - Create or overwrite a file (`path`, `content`), creating parent directories.
204
- - `edit_file` - Replace exact text (`path`, `old_string`, `new_string`, optional `replace_all`).
205
- Fails unless `old_string` matches exactly once (or `replace_all` is set).
204
+ - `edit_file` - Replace text (`path`, `old_string`, `new_string`, optional `replace_all`).
205
+ Fails unless `old_string` matches exactly once (or `replace_all` is set). With no exact match,
206
+ it retries ignoring `read_file` line-number prefixes, then trailing whitespace, then
207
+ indentation (re-indenting `new_string` to fit), and uses such a match only if it is unique;
208
+ otherwise the error shows the closest lines. Returns the edited lines with 3 lines of context.
209
+ - `edit_file`, and `write_file` over an existing file, require the file to have been read with
210
+ `read_file` (or written by these tools) in this process, and to be unchanged on disk since.
211
+ Otherwise they ask the model to read it again, so an edit can't land on stale text.
206
212
  - `plan_add`, `plan_update`, `plan_show` - The agent's task plan (see [Task Plans](#task-plans)).
207
213
  - `report_outcome` - Report the task `completed`, `blocked` or `needs_input`, with a `summary`; ends
208
214
  the turn (see [Outcomes](#outcomes)).
@@ -634,6 +640,12 @@ It needs a session log, and falls back to a standard summary when `persist_sessi
634
640
 
635
641
  - **Message IDs.** A message's ID is the line of the session log where it was first
636
642
  recorded, shown as `#N`. IDs are stable across compactions and `--resume`.
643
+ - **Recorded detail.** Each assistant message in the log also keeps the model's reasoning
644
+ text (`thinking`), the request's token `usage` and its wall-clock `duration_ms`. These
645
+ are for inspecting a session later (see #57) and `history_read`, which includes the
646
+ reasoning. These recorded log fields themselves are never sent back to the model. This
647
+ is separate from `replay_reasoning` (see above): when a provider has reasoning replay
648
+ enabled, its reasoning blocks are still returned to the model as that provider requires.
637
649
  - **Citing summary.** The summarizer sees each message labelled `[#N]` and is asked to cite
638
650
  `(#N)` for details whose exact text may matter (errors, commands, outputs, the user's
639
651
  wording) instead of copying them. The summary ends with the range it covers and a note
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nanobpm/nano-coder",
3
- "version": "0.22.1",
3
+ "version": "0.24.0",
4
4
  "description": "A 6MB coding agent. Run a fleet on your laptop.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -31,9 +31,9 @@
31
31
  "node": ">=18"
32
32
  },
33
33
  "optionalDependencies": {
34
- "@nanobpm/nano-coder-darwin-arm64": "0.22.1",
35
- "@nanobpm/nano-coder-darwin-x64": "0.22.1",
36
- "@nanobpm/nano-coder-linux-arm64": "0.22.1",
37
- "@nanobpm/nano-coder-linux-x64": "0.22.1"
34
+ "@nanobpm/nano-coder-darwin-arm64": "0.24.0",
35
+ "@nanobpm/nano-coder-darwin-x64": "0.24.0",
36
+ "@nanobpm/nano-coder-linux-arm64": "0.24.0",
37
+ "@nanobpm/nano-coder-linux-x64": "0.24.0"
38
38
  }
39
39
  }