snow-ai 0.5.25 → 0.5.26

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/bundle/cli.mjs CHANGED
@@ -430131,6 +430131,16 @@ var init_codebaseSearch = __esm({
430131
430131
  return lastResults;
430132
430132
  } catch (error) {
430133
430133
  logger.error("Codebase search failed:", error);
430134
+ if (enableAgentReview) {
430135
+ codebaseSearchEvents.emitSearchEvent({
430136
+ type: "search-complete",
430137
+ attempt: 0,
430138
+ maxAttempts: MAX_SEARCH_RETRIES,
430139
+ currentTopN: topN,
430140
+ message: `Search failed: ${error instanceof Error ? error.message : "Unknown error"}`,
430141
+ query
430142
+ });
430143
+ }
430134
430144
  throw error;
430135
430145
  }
430136
430146
  }
@@ -441984,7 +441994,8 @@ error: ${error || "(empty)"}`);
441984
441994
  } else {
441985
441995
  try {
441986
441996
  const mcpConfig = getMCPConfig();
441987
- for (const configuredServiceName of Object.keys(mcpConfig.mcpServers)) {
441997
+ const serviceNames = Object.keys(mcpConfig.mcpServers).sort((a, b) => b.length - a.length);
441998
+ for (const configuredServiceName of serviceNames) {
441988
441999
  const prefix = `${configuredServiceName}-`;
441989
442000
  if (toolName.startsWith(prefix)) {
441990
442001
  serviceName = configuredServiceName;
@@ -543992,7 +544003,7 @@ function LoadingIndicator({ isStreaming, isStopping, isSaving, hasPendingToolCon
543992
544003
  retryStatus.attempt,
543993
544004
  "/5)"
543994
544005
  )
543995
- ) : (codebaseSearchStatus == null ? void 0 : codebaseSearchStatus.isSearching) ? import_react113.default.createElement(CodebaseSearchStatus, { status: codebaseSearchStatus }) : codebaseSearchStatus && !codebaseSearchStatus.isSearching && codebaseSearchStatus.reviewResults ? import_react113.default.createElement(CodebaseSearchStatus, { status: codebaseSearchStatus }) : import_react113.default.createElement(
544006
+ ) : (codebaseSearchStatus == null ? void 0 : codebaseSearchStatus.isSearching) ? import_react113.default.createElement(CodebaseSearchStatus, { status: codebaseSearchStatus }) : codebaseSearchStatus && !codebaseSearchStatus.isSearching ? import_react113.default.createElement(CodebaseSearchStatus, { status: codebaseSearchStatus }) : import_react113.default.createElement(
543996
544007
  Text,
543997
544008
  { color: theme14.colors.menuSecondary, dimColor: true },
543998
544009
  import_react113.default.createElement(ShimmerText, { text: isReasoning ? t.chatScreen.statusDeepThinking : streamTokenCount > 0 ? t.chatScreen.statusWriting : t.chatScreen.statusThinking }),
@@ -546809,41 +546820,6 @@ var init_useToolConfirmation = __esm({
546809
546820
  });
546810
546821
 
546811
546822
  // dist/utils/execution/toolExecutor.js
546812
- function fixMergedToolName(toolName) {
546813
- const knownPrefixes = getRegisteredServicePrefixes();
546814
- let foundPrefixes = [];
546815
- for (const prefix of knownPrefixes) {
546816
- let searchIndex = 0;
546817
- while (true) {
546818
- const index = toolName.indexOf(prefix, searchIndex);
546819
- if (index === -1)
546820
- break;
546821
- foundPrefixes.push({ prefix, index });
546822
- searchIndex = index + 1;
546823
- }
546824
- }
546825
- foundPrefixes.sort((a, b) => a.index - b.index);
546826
- if (foundPrefixes.length > 1) {
546827
- const firstPrefix = foundPrefixes[0];
546828
- const secondPrefix = foundPrefixes[1];
546829
- if (firstPrefix && secondPrefix && firstPrefix.index === 0) {
546830
- const firstToolName = toolName.substring(0, secondPrefix.index);
546831
- console.warn(`[Tool Name Fix] Detected merged tool names: "${toolName}"`);
546832
- console.warn(`[Tool Name Fix] Extracted first tool: "${firstToolName}"`);
546833
- console.warn(`[Tool Name Fix] Ignored second tool starting at: "${toolName.substring(secondPrefix.index)}"`);
546834
- return {
546835
- fixedName: firstToolName,
546836
- wasMerged: true,
546837
- originalName: toolName
546838
- };
546839
- }
546840
- }
546841
- return {
546842
- fixedName: toolName,
546843
- wasMerged: false,
546844
- originalName: toolName
546845
- };
546846
- }
546847
546823
  function safeParseToolArguments(argsString) {
546848
546824
  if (!argsString || argsString.trim() === "") {
546849
546825
  return {};
@@ -546937,16 +546913,6 @@ function extractMultimodalContent(result2) {
546937
546913
  };
546938
546914
  }
546939
546915
  async function executeToolCall(toolCall, abortSignal, onTokenUpdate, onSubAgentMessage, requestToolConfirmation, isToolAutoApproved, yoloMode, addToAlwaysApproved, onUserInteractionNeeded) {
546940
- const toolNameFix = fixMergedToolName(toolCall.function.name);
546941
- if (toolNameFix.wasMerged) {
546942
- toolCall = {
546943
- ...toolCall,
546944
- function: {
546945
- ...toolCall.function,
546946
- name: toolNameFix.fixedName
546947
- }
546948
- };
546949
- }
546950
546916
  let result2;
546951
546917
  let executionError = null;
546952
546918
  let escKeyListener;
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snow-ai",
3
- "version": "0.5.25",
3
+ "version": "0.5.26",
4
4
  "description": "Intelligent Command Line Assistant powered by AI",
5
5
  "license": "MIT",
6
6
  "bin": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "snow-ai",
3
- "version": "0.5.25",
3
+ "version": "0.5.26",
4
4
  "description": "Intelligent Command Line Assistant powered by AI",
5
5
  "license": "MIT",
6
6
  "bin": {