nestor-sh 2.0.8 → 2.0.9

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/dist/nestor.mjs +26 -6
  2. package/package.json +1 -1
package/dist/nestor.mjs CHANGED
@@ -10593,7 +10593,7 @@ var SERVER_VERSION, startTime;
10593
10593
  var init_health = __esm({
10594
10594
  "../server/src/routes/health.ts"() {
10595
10595
  "use strict";
10596
- SERVER_VERSION = "2.0.8";
10596
+ SERVER_VERSION = "2.0.9";
10597
10597
  startTime = Date.now();
10598
10598
  }
10599
10599
  });
@@ -16968,7 +16968,21 @@ ${msg.content}` : msg.content;
16968
16968
  } catch {
16969
16969
  responseObj = { result: msg.content };
16970
16970
  }
16971
- const toolName = msg.toolCallId ?? "tool_result";
16971
+ let toolName = msg.toolName || "tool_result";
16972
+ if (toolName === "tool_result" && msg.toolCallId) {
16973
+ for (let j = contents.length - 1; j >= 0; j--) {
16974
+ const prev = contents[j];
16975
+ if (prev.role === "model" && prev.parts) {
16976
+ for (const part of prev.parts) {
16977
+ if (part.functionCall?.name) {
16978
+ toolName = part.functionCall.name;
16979
+ break;
16980
+ }
16981
+ }
16982
+ if (toolName !== "tool_result") break;
16983
+ }
16984
+ }
16985
+ }
16972
16986
  contents.push({
16973
16987
  role: "user",
16974
16988
  parts: [
@@ -17203,6 +17217,7 @@ var init_gemini = __esm({
17203
17217
  if (options?.tools && options.tools.length > 0) {
17204
17218
  const filteredTools = filterToolsForGemini(options.tools, messages);
17205
17219
  requestBody.tools = [{ functionDeclarations: mapToolDefs5(filteredTools) }];
17220
+ requestBody.generationConfig.thinkingConfig = { thinkingBudget: 0 };
17206
17221
  }
17207
17222
  const toolConfig = mapToolChoice3(options?.toolChoice);
17208
17223
  if (toolConfig) {
@@ -17266,6 +17281,7 @@ var init_gemini = __esm({
17266
17281
  if (options?.tools && options.tools.length > 0) {
17267
17282
  const filteredTools = filterToolsForGemini(options.tools, messages);
17268
17283
  requestBody.tools = [{ functionDeclarations: mapToolDefs5(filteredTools) }];
17284
+ requestBody.generationConfig.thinkingConfig = { thinkingBudget: 0 };
17269
17285
  }
17270
17286
  const toolConfig = mapToolChoice3(options?.toolChoice);
17271
17287
  if (toolConfig) {
@@ -19367,7 +19383,7 @@ function isNativeAvailable() {
19367
19383
  return nativeModule !== null;
19368
19384
  }
19369
19385
  function getNativeVersion() {
19370
- return nativeModule ? "2.0.8" : null;
19386
+ return nativeModule ? "2.0.9" : null;
19371
19387
  }
19372
19388
  function validateSsrf(url, allowPrivate = false) {
19373
19389
  if (nativeModule) {
@@ -103108,7 +103124,8 @@ var init_builder = __esm({
103108
103124
  return {
103109
103125
  role: "tool",
103110
103126
  content: wrappedOutput,
103111
- toolCallId: result.toolCallId
103127
+ toolCallId: result.toolCallId,
103128
+ toolName: result.toolName
103112
103129
  };
103113
103130
  });
103114
103131
  }
@@ -106673,6 +106690,9 @@ ${this.config.orgChartContext}` : this.config.orgChartContext;
106673
106690
  currentToolName = chunk.toolCall?.name;
106674
106691
  currentToolJson = "";
106675
106692
  stopReason = "tool_use";
106693
+ if (chunk.toolCall?.arguments && Object.keys(chunk.toolCall.arguments).length > 0) {
106694
+ currentToolJson = JSON.stringify(chunk.toolCall.arguments);
106695
+ }
106676
106696
  break;
106677
106697
  case "tool_call_delta":
106678
106698
  if (chunk.text) {
@@ -159051,7 +159071,7 @@ var init_server = __esm({
159051
159071
  MCP_PROTOCOL_VERSION = "2024-11-05";
159052
159072
  SERVER_INFO = {
159053
159073
  name: "nestor",
159054
- version: "2.0.8"
159074
+ version: "2.0.9"
159055
159075
  };
159056
159076
  SERVER_CAPABILITIES = {
159057
159077
  tools: { listChanged: false },
@@ -165293,7 +165313,7 @@ if (command2 && !["--help", "-h", "--version", "-V", "install"].includes(command
165293
165313
  }
165294
165314
  }
165295
165315
  var program = new Command();
165296
- program.name("nestor-sh").description("Nestor AI Agent Platform \u2014 orchestrate, secure and monitor AI agents").version("2.0.8");
165316
+ program.name("nestor-sh").description("Nestor AI Agent Platform \u2014 orchestrate, secure and monitor AI agents").version("2.0.9");
165297
165317
  registerStartCommand(program);
165298
165318
  registerInstallCommand(program);
165299
165319
  registerAgentCommand(program);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nestor-sh",
3
- "version": "2.0.8",
3
+ "version": "2.0.9",
4
4
  "description": "AI agent platform — security-first orchestration for autonomous agents",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",