natureco-cli 5.64.5 → 5.64.6
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 +10 -0
- package/README.md +1 -0
- package/package.json +1 -1
- package/src/tools/agentic-runner.js +36 -3
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to NatureCo CLI will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [5.64.6] - 2026-07-13 — Typed MiniMax tool arguments
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- MiniMax XML tool parameters are now coerced from text to their declared JSON Schema types before validation and execution.
|
|
9
|
+
- `computer_use_loop` now accepts XML values such as `<parameter name="maxSteps">30</parameter>` as the number `30`, so visible GUI automation starts instead of failing with `expected number, got string`.
|
|
10
|
+
- Conversion also covers integer, boolean, object, and array parameters while leaving invalid values untouched for normal schema validation.
|
|
11
|
+
|
|
12
|
+
### Tests
|
|
13
|
+
- Added regressions for valid type conversion, invalid-value preservation, and the exact `computer_use_loop` `maxSteps` failure reported on macOS.
|
|
14
|
+
|
|
5
15
|
## [5.64.5] - 2026-07-13 — Deterministic visible-browser recovery
|
|
6
16
|
|
|
7
17
|
### Fixed
|
package/README.md
CHANGED
|
@@ -51,6 +51,7 @@ natureco code
|
|
|
51
51
|
|
|
52
52
|
| Version | Highlights |
|
|
53
53
|
|---------|-----------|
|
|
54
|
+
| **v5.64.6** | **Reliable MiniMax tool calls:** XML parameters are converted to their declared schema types, fixing `computer_use_loop` failures such as `maxSteps: expected number, got string`. |
|
|
54
55
|
| **v5.64.5** | **Deterministic GUI recovery:** visible web tasks use one verified GUI loop; failures expose their concrete reason and stop blind browser/AppleScript fallback chains. |
|
|
55
56
|
| **v5.64.4** | **Unified MiniMax media:** the existing MiniMax key now powers `MiniMax-VL-01` analysis, `image-01` generation, `MiniMax-Hailuo-2.3` video, and verified GUI vision—no second key required. |
|
|
56
57
|
| **v5.64.3** | **Evidence-based GUI completion:** desktop actions require a changed screen plus independent visual evidence before success. MiniMax screenshots use the Token Plan VLM with the existing provider key. |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "natureco-cli",
|
|
3
|
-
"version": "5.64.
|
|
3
|
+
"version": "5.64.6",
|
|
4
4
|
"description": "Terminal-native AI agent CLI with bilingual TR/EN UI, multi-agent orchestration, persistent memory, secure tools and messaging integrations.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"natureco": "bin/natureco.js"
|
|
@@ -288,6 +288,37 @@ function buildFeedback(norm, res) {
|
|
|
288
288
|
return body ? `${head}:\n${body}` : head;
|
|
289
289
|
}
|
|
290
290
|
|
|
291
|
+
function coerceArgsForSchema(args, schema) {
|
|
292
|
+
if (!args || typeof args !== 'object' || !schema || typeof schema !== 'object') return { ...(args || {}) };
|
|
293
|
+
const properties = schema.properties || {};
|
|
294
|
+
const result = { ...args };
|
|
295
|
+
|
|
296
|
+
for (const [key, property] of Object.entries(properties)) {
|
|
297
|
+
const value = result[key];
|
|
298
|
+
if (typeof value !== 'string' || !property) continue;
|
|
299
|
+
const types = Array.isArray(property.type) ? property.type : [property.type];
|
|
300
|
+
const trimmed = value.trim();
|
|
301
|
+
|
|
302
|
+
if (types.includes('integer') && /^[-+]?\d+$/.test(trimmed)) {
|
|
303
|
+
const number = Number(trimmed);
|
|
304
|
+
if (Number.isSafeInteger(number)) result[key] = number;
|
|
305
|
+
} else if (types.includes('number') && trimmed !== '' && Number.isFinite(Number(trimmed))) {
|
|
306
|
+
result[key] = Number(trimmed);
|
|
307
|
+
} else if (types.includes('boolean') && /^(true|false)$/i.test(trimmed)) {
|
|
308
|
+
result[key] = trimmed.toLowerCase() === 'true';
|
|
309
|
+
} else if (types.includes('object') || types.includes('array')) {
|
|
310
|
+
try {
|
|
311
|
+
const parsed = JSON.parse(trimmed);
|
|
312
|
+
if ((types.includes('array') && Array.isArray(parsed)) ||
|
|
313
|
+
(types.includes('object') && parsed && typeof parsed === 'object' && !Array.isArray(parsed))) {
|
|
314
|
+
result[key] = parsed;
|
|
315
|
+
}
|
|
316
|
+
} catch {}
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
return result;
|
|
320
|
+
}
|
|
321
|
+
|
|
291
322
|
/**
|
|
292
323
|
* Tek bir parse edilmis cagriyi calistir.
|
|
293
324
|
* Donus: { records: [...], feedback: '...' }
|
|
@@ -389,9 +420,11 @@ async function executeCall(call, opts = {}) {
|
|
|
389
420
|
records.push({ tool: norm, status: 'error', error: 'execute yok' });
|
|
390
421
|
return { records, feedback: `${norm} HATA: execute fonksiyonu yok` };
|
|
391
422
|
}
|
|
423
|
+
const schema = mod.inputSchema || mod.parameters || (mod.default && (mod.default.inputSchema || mod.default.parameters));
|
|
424
|
+
const typedArgs = coerceArgsForSchema(args, schema);
|
|
392
425
|
const res = await executeThroughGateway({
|
|
393
426
|
toolName: norm,
|
|
394
|
-
args,
|
|
427
|
+
args: typedArgs,
|
|
395
428
|
resolveTool: () => mod,
|
|
396
429
|
execute: fn,
|
|
397
430
|
normalizeSuccess: value => value,
|
|
@@ -401,7 +434,7 @@ async function executeCall(call, opts = {}) {
|
|
|
401
434
|
const ok = typeof res === 'string' ? true : (res && res.success !== false);
|
|
402
435
|
const status = ok ? 'done' : 'error';
|
|
403
436
|
const feedback = buildFeedback(norm, res);
|
|
404
|
-
records.push({ tool: norm, status, args: sanitizeArgs(
|
|
437
|
+
records.push({ tool: norm, status, args: sanitizeArgs(typedArgs), result: res, error: ok ? undefined : res.error });
|
|
405
438
|
return { records, feedback };
|
|
406
439
|
}
|
|
407
440
|
|
|
@@ -462,4 +495,4 @@ async function runAgentic({ callModel, systemPrompt, historyMessages, task, tool
|
|
|
462
495
|
return { records: allRecords, reply: finalReply, iterations };
|
|
463
496
|
}
|
|
464
497
|
|
|
465
|
-
module.exports = { parseAgenticCalls, stripProtocolTokens, executeCall, runAgentic, expandHome, makeStreamFilter, makeSanitizeStream, agentExecAllowed, buildFeedback, TOOL_ALIASES, DEFAULT_ALLOWED };
|
|
498
|
+
module.exports = { parseAgenticCalls, stripProtocolTokens, executeCall, runAgentic, expandHome, makeStreamFilter, makeSanitizeStream, agentExecAllowed, buildFeedback, coerceArgsForSchema, TOOL_ALIASES, DEFAULT_ALLOWED };
|