zames_pro 2.94.6 → 2.95.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.
- package/CHANGELOG.md +12 -0
- package/dist/browser.js +25 -0
- package/dist/system-prompt.js +12 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.95.0] - 2026-11-03
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- **prompt:** send throwaway files to <project>/tmp
|
|
15
|
+
|
|
16
|
+
## [2.94.7] - 2026-11-03
|
|
17
|
+
|
|
18
|
+
### Fixed
|
|
19
|
+
|
|
20
|
+
- **deepseek:** recognise the server-busy notice from the SSE body
|
|
21
|
+
|
|
10
22
|
## [2.94.6] - 2026-11-03
|
|
11
23
|
|
|
12
24
|
### Fixed
|
package/dist/browser.js
CHANGED
|
@@ -117,6 +117,10 @@ export class DeepSeekBrowser {
|
|
|
117
117
|
// threw ds.send_no_new_answer while the chat plainly showed the rate limit.
|
|
118
118
|
// Reset before a send.
|
|
119
119
|
_netRateLimited;
|
|
120
|
+
// True when the LAST completion/continue body carried the server-busy
|
|
121
|
+
// notice ("Server busy, please try again later"). It arrives WITHOUT a
|
|
122
|
+
// DOM toast, so the SSE body is the authoritative source. Reset per send.
|
|
123
|
+
_netServerBusy;
|
|
120
124
|
_netChatId;
|
|
121
125
|
// The latest CONTEXT size (in tokens) DeepSeek reported in the current
|
|
122
126
|
// chat. It is the `accumulated_token_usage` counter taken from the SSE
|
|
@@ -228,6 +232,7 @@ export class DeepSeekBrowser {
|
|
|
228
232
|
this._netCaptureAt = 0;
|
|
229
233
|
this._netNoAnswer = false;
|
|
230
234
|
this._netRateLimited = false;
|
|
235
|
+
this._netServerBusy = false;
|
|
231
236
|
this._netChatId = null;
|
|
232
237
|
this._lastTokenUsage = null;
|
|
233
238
|
this._toggles = { deepThinking, webSearch };
|
|
@@ -537,6 +542,13 @@ export class DeepSeekBrowser {
|
|
|
537
542
|
this._netRateLimited = true;
|
|
538
543
|
this._netCapture = '';
|
|
539
544
|
}
|
|
545
|
+
// The SERVER-BUSY notice can arrive ONLY in the body: the toast is
|
|
546
|
+
// short-lived, and without this the loop waited out the deadline and
|
|
547
|
+
// reported "no answer" for a turn the server had refused.
|
|
548
|
+
if (isServerBusyText(body)) {
|
|
549
|
+
this._netServerBusy = true;
|
|
550
|
+
this._netCapture = '';
|
|
551
|
+
}
|
|
540
552
|
this._netCaptureAt = Date.now();
|
|
541
553
|
}
|
|
542
554
|
}
|
|
@@ -2198,6 +2210,7 @@ export class DeepSeekBrowser {
|
|
|
2198
2210
|
this._netCaptureAt = 0;
|
|
2199
2211
|
this._netNoAnswer = false;
|
|
2200
2212
|
this._netRateLimited = false;
|
|
2213
|
+
this._netServerBusy = false;
|
|
2201
2214
|
this._netBody = '';
|
|
2202
2215
|
// Align the DeepSeek chat toggles (deep thinking / web search) with the
|
|
2203
2216
|
// configured state BEFORE typing. Doing it here (after the send-pause) it
|
|
@@ -2324,6 +2337,12 @@ export class DeepSeekBrowser {
|
|
|
2324
2337
|
if (this._netRateLimited && this._netCaptureAt >= this._lastSentAt) {
|
|
2325
2338
|
throw new RateLimitError(this._netBody.slice(0, 300) || 'rate limit (from network)');
|
|
2326
2339
|
}
|
|
2340
|
+
// Body-only server-busy notice: retry instead of waiting out the
|
|
2341
|
+
// whole deadline (a live chat showed it while the agent reported
|
|
2342
|
+
// "no answer").
|
|
2343
|
+
if (this._netServerBusy && this._netCaptureAt >= this._lastSentAt) {
|
|
2344
|
+
throw new ServerBusyError(this._netBody.slice(-300));
|
|
2345
|
+
}
|
|
2327
2346
|
// The turn was truncated by the server: the SSE body carries
|
|
2328
2347
|
// finish_reason=generation_err / quasi_status=INCOMPLETE and the UI
|
|
2329
2348
|
// shows "Continue". Retry instead of waiting out the whole timeout.
|
|
@@ -2579,6 +2598,12 @@ export class DeepSeekBrowser {
|
|
|
2579
2598
|
if (this._netRateLimited && this._netCaptureAt >= this._lastSentAt) {
|
|
2580
2599
|
throw new RateLimitError(this._netBody.slice(0, 300) || 'rate limit (from network)');
|
|
2581
2600
|
}
|
|
2601
|
+
// Body-only server-busy notice: retry instead of waiting out the
|
|
2602
|
+
// whole deadline (a live chat showed it while the agent reported
|
|
2603
|
+
// "no answer").
|
|
2604
|
+
if (this._netServerBusy && this._netCaptureAt >= this._lastSentAt) {
|
|
2605
|
+
throw new ServerBusyError(this._netBody.slice(-300));
|
|
2606
|
+
}
|
|
2582
2607
|
// The exhausted context can likewise be visible only in the captured
|
|
2583
2608
|
// body rather than in a toast, so ask() must see it here as well.
|
|
2584
2609
|
if (this._netCaptureAt >= this._lastSentAt &&
|
package/dist/system-prompt.js
CHANGED
|
@@ -238,6 +238,17 @@ export function buildSystemPrompt({ workdir, tools, gitContext = null, locale =
|
|
|
238
238
|
'for current web information: it is slow, it burns the account quota ' +
|
|
239
239
|
'and it is not needed to read or edit files.\n'
|
|
240
240
|
: '';
|
|
241
|
+
// Where a THROWAWAY script belongs. Without this rule the agent drops
|
|
242
|
+
// scratch files right into the project root with ad-hoc names (zz_c.txt,
|
|
243
|
+
// i1.py, tmp2.sh) and they end up in `git status`. The folder already
|
|
244
|
+
// exists, is gitignored and is wiped on every launch.
|
|
245
|
+
const tmpSection = '\n## Throwaway files go to <project>/tmp\n\n' +
|
|
246
|
+
'A one-off script, a scratch dump, a generated sample or any other ' +
|
|
247
|
+
'temporary file MUST be written to <project>/tmp (it exists, is ' +
|
|
248
|
+
'gitignored and is wiped on every launch) and NOT into the project ' +
|
|
249
|
+
'root. Give it a descriptive name with the RIGHT extension (.mjs, ' +
|
|
250
|
+
'.py, .ts, .txt) - the extension is what makes a later read or run ' +
|
|
251
|
+
'work. Delete the file when you are done with it.\n';
|
|
241
252
|
const gitSection = gitContext
|
|
242
253
|
? `\n## Git context\n\n${gitContext}\n`
|
|
243
254
|
: '\n## Git context\n\nNot a git repository (or git is not installed).\n';
|
|
@@ -299,7 +310,7 @@ task is done (or when you must ask the operator), not between tool calls.
|
|
|
299
310
|
You have access to the following tools:
|
|
300
311
|
|
|
301
312
|
${toolDescriptions}
|
|
302
|
-
${runtimeSection}${gitSection}${attachSection}${contextSection}${selfSection}
|
|
313
|
+
${runtimeSection}${tmpSection}${gitSection}${attachSection}${contextSection}${selfSection}
|
|
303
314
|
## Choosing the right tool
|
|
304
315
|
|
|
305
316
|
Prefer the most specific tool; a wrong choice wastes a turn:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "zames_pro",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.95.0",
|
|
4
4
|
"description": "Terminal coding agent that drives a real browser to chat with DeepSeek, Qwen or GLM — 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": {
|