OpenAI Node - "msearch() is not a valid tool, select another one"

N8N OpenAI Node

I am communicating with OpenAI GPT-40-mini model via OpenAI Node – Message Assistant operation. Generally, this works fine, but I have been running into issues as executions have increased.

tools attached: (see workflow nodes at bottom of post)

  • google calendar tool
  • custom code node to generate a date/time string using today’s date/time
  • add user context pulls data from Google Sheets

– OpenAI Thread with error

msearch() error messages

When I view the Thread run logs in OpenAI platform dashboard (platform.openai.com/threads) I see a common theme: an error message:

msearch(
{"queries": ["Christmas break", "Winter holiday schedule"]})
Dec 17, 2024, 9:14 AM
msearch is not a valid tool, try another one.
Dec 17, 2024, 9:14 AM

If I run the same set of questions via the OpenAI API playground (platform.openai.com/playground/assistants) the assistant replies without any of the msearch() errors.

I am wondering if this is related to n8n’s usage of Langchain? Or something else? Please help!

Information on your n8n setup

  • n8n version: 1.67.1
  • Database (default: SQLite): SQLlite
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): npm
  • Operating system: Windows 10

@oleg have you seen this issue before?

Can’t say I have :thinking: Is msearch one fo the tools. you’re defining? Could you please share the full workflow so that I can reproduce this locally?

1 Like

@oleg

Is msearch one fo the tools. you’re defining?

Answer: No, it is not.

See below for the n8n OpenAI node where I call OpenAI Assistant API.
I am still unable to figure out where msearch() is referenced…

My OpenAI node has three tools:

  1. google calendar,
  2. code node,
  3. execute workflow node.

Here is my Assistant configuration:

  • custom system prompt (can share privately if you’d like to see the prompt)
  • gpt-4o-mini,
  • file_search tool enabled,
  • attached OpenAI Vector store,
  • response format=text.


additional_run_context function definition:
function additional context
google_calendar function definition:

get_current_time_date_time:
get current date time

Any update or thoughts on why I am seeing this issue with msearch() ?

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.