zames_pro 2.82.2 → 2.82.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/CHANGELOG.md +6 -0
- package/dist/answer-parse.js +15 -4
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.82.3] - 2026-10-22
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- **answer-parse:** a line-boundary cut never keeps a lone surrogate
|
|
15
|
+
|
|
10
16
|
## [2.82.2] - 2026-10-22
|
|
11
17
|
|
|
12
18
|
### Fixed
|
package/dist/answer-parse.js
CHANGED
|
@@ -23,12 +23,23 @@ export function truncateToolResult(text, limit) {
|
|
|
23
23
|
const nl = text.lastIndexOf(NL, limit);
|
|
24
24
|
// Cut AFTER the newline (include it) so the kept part is a whole number of
|
|
25
25
|
// lines — a cut that EXCLUDED the newline left a half line before the marker.
|
|
26
|
-
if (nl >= searchFrom)
|
|
26
|
+
if (nl >= searchFrom) {
|
|
27
27
|
cut = nl + 1;
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
// The char that would end the kept text is the one BEFORE the newline.
|
|
29
|
+
// Stepping back here drops only the dangling newline, so the high
|
|
30
|
+
// surrogate is never the last unit the model sees.
|
|
31
|
+
const beforeNl = text.charCodeAt(cut - 2);
|
|
32
|
+
if (beforeNl >= 0xd800 && beforeNl <= 0xdbff) {
|
|
33
|
+
cut--;
|
|
34
|
+
const hi = text.charCodeAt(cut - 1);
|
|
35
|
+
if (hi >= 0xd800 && hi <= 0xdbff)
|
|
36
|
+
cut--;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
31
39
|
else {
|
|
40
|
+
// Never split a surrogate PAIR (an emoji / astral CJK char): the high half
|
|
41
|
+
// alone is a lone surrogate — a broken code point some channels replace
|
|
42
|
+
// with '?' or truncate at. Step back one unit so the pair is dropped WHOLE.
|
|
32
43
|
const c = text.charCodeAt(cut - 1);
|
|
33
44
|
if (c >= 0xd800 && c <= 0xdbff)
|
|
34
45
|
cut--;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zames_pro",
|
|
3
|
-
"version": "2.82.
|
|
3
|
+
"version": "2.82.3",
|
|
4
4
|
"description": "Terminal coding agent that drives a real browser to chat with DeepSeek, Qwen and other web LLMs — no API key required. Reads and edits files, runs commands, commits to git, like Claude Code / Codex CLI.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|