blun-king-cli 9.1.110 → 9.1.111

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/blun.mjs +3 -3
  2. package/package.json +1 -1
package/blun.mjs CHANGED
@@ -260584,12 +260584,12 @@ function blunFastConversationTools(tools, input, pendingMediaJobIds = []) {
260584
260584
  * name through ToolSearch. The absolute cap prevents large context windows
260585
260585
  * from turning every deferred schema into permanent request overhead.
260586
260586
  */
260587
- function blunSelectTurnTools(tools, maxContextTokens, loadedToolNames) {
260587
+ function blunSelectTurnTools(tools, maxContextTokens, loadedToolNames, requiredToolNames = /* @__PURE__ */ new Set()) {
260588
260588
  if (estimateTokensForTools(tools) <= toolSchemaBudgetTokens(maxContextTokens)) return {
260589
260589
  tools,
260590
260590
  deferredToolCount: 0
260591
260591
  };
260592
- const selected = tools.filter((tool) => BLUN_LEAN_TOOL_NAMES.has(tool.name) || loadedToolNames.has(tool.name));
260592
+ const selected = tools.filter((tool) => BLUN_LEAN_TOOL_NAMES.has(tool.name) || loadedToolNames.has(tool.name) || requiredToolNames.has(tool.name));
260593
260593
  const selectedNames = new Set(selected.map((tool) => tool.name));
260594
260594
  const deferred = tools.filter((tool) => !selectedNames.has(tool.name));
260595
260595
  if (deferred.length > 0) selected.push(createDeferredToolLoader(selected, deferred, loadedToolNames));
@@ -261430,7 +261430,7 @@ var init_turn = __esmMin((() => {
261430
261430
  const toolSelection = fastConversation ? {
261431
261431
  tools: [...blunFastConversationTools(eligibleTools, input, pendingMediaJobIds)],
261432
261432
  deferredToolCount: 0
261433
- } : turnNeedsTools ? blunSelectTurnTools(eligibleTools, this.agent.config.modelCapabilities?.max_context_tokens, this.loadedToolNames) : {
261433
+ } : turnNeedsTools ? blunSelectTurnTools(eligibleTools, this.agent.config.modelCapabilities?.max_context_tokens, this.loadedToolNames, turnHasAttachment ? new Set(["mcp__plugin-telegram_telegram__download_attachment"]) : void 0) : {
261434
261434
  tools: [],
261435
261435
  deferredToolCount: 0
261436
261436
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "blun-king-cli",
3
- "version": "9.1.110",
3
+ "version": "9.1.111",
4
4
  "description": "BLUN CLI - your own AI agent with a Telegram channel. Get it done. With BLUN.",
5
5
  "license": "MIT",
6
6
  "bin": {