ak-gemini 2.0.7 → 2.1.1

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/GUIDE.md CHANGED
@@ -349,6 +349,22 @@ console.log(result.text); // "There were 47 new signups this week. I've se
349
349
  console.log(result.toolCalls); // [{ name: 'query_db', args: {...}, result: [...] }, { name: 'send_email', ... }]
350
350
  ```
351
351
 
352
+ ### Parallel Tool Execution
353
+
354
+ Control whether tool calls within a round execute in parallel or sequentially:
355
+
356
+ ```javascript
357
+ const agent = new ToolAgent({
358
+ tools: [...],
359
+ toolExecutor: myExecutor,
360
+ parallelToolCalls: true, // default: unlimited parallel execution
361
+ // parallelToolCalls: false, // sequential execution
362
+ // parallelToolCalls: 3, // max 3 concurrent tool executions
363
+ });
364
+ ```
365
+
366
+ When the model returns multiple tool calls in a single response, parallel execution runs them concurrently — significantly faster for I/O-bound tools (HTTP requests, database queries, etc.).
367
+
352
368
  ### Streaming
353
369
 
354
370
  Stream the agent's output in real-time — useful for showing progress in a UI:
package/README.md CHANGED
@@ -413,6 +413,7 @@ All classes accept `BaseGeminiOptions`:
413
413
  | `maxToolRounds` | number | `10` | Max tool-use loop iterations |
414
414
  | `onToolCall` | function | — | Notification callback when tool is called |
415
415
  | `onBeforeExecution` | function | — | `async (toolName, args) => boolean` — gate execution |
416
+ | `parallelToolCalls` | boolean \| number | `true` | Parallel tool execution: `false` = sequential, `true` = unlimited, number = concurrency limit |
416
417
 
417
418
  ### CodeAgent-Specific
418
419