I have a Supabase Vector Store that I have loaded using a Default Data Loader. If I access the Vector Store using a Question and Answer Chain I can query and return results from the Vector Store. If I use an AI Agent and hook the Vector Store to it, when I query it does not try to access the Vector Store for information.
What is the error message (if any)?
No Error
Please share your workflow
Share the output returned by the last node
I would expect output that included info from the Vector Store
Information on your n8n setup
- n8n version: 1.94.1
- Database (default: SQLite):
- Running n8n via npm
- Ubuntu
i think this is a problem on the sistem prompt of the AI Agent
you need to make it very clear and specific,that it has access to Supabase Vector Store and when to call it, if you need it to call it everytime then asks it to call it everytime and told him what to search
also explain what data that it has on the supabase
2 Likes
Thank you so much for the reply and info. I updated the system message to the below and indeed it did call the tool and provide the correct information
Apparently my previous instruction was not clear enough 
“Always check the vector_store tool for updated information before returning an answer. The vector_store tool has critical information that has been updated and may provide valuable information to the user.”
ayy, congratulations!, and your welcome 
1 Like
Apparently I spoke too soon
Putting the following in the system message did generate a tool request about half the time, however I am not sure how I get any more specific than the below when I want it to check the tool all the time.
Always check the vector_store tool for information before returning an answer. The vector_store tool has critical information that may provide valuable information to the user.
It would be nice I think if they were to add a drop down or configurable option about when to use the tool rather than just leaving it up to the whim of the AI
i think the name of the tool needs to be the same name as the ‘vector_store’, if you define it as vector_store in the prompt, then make sure the name of the tools is also vector_store and not “Supabase Vector Store”
you can try this example prompt that i told chatgpt to generate, please update it to fulfill your needs and your workflow
Here’s a system prompt you can use for an AI agent with access to a Supabase vector store tool. The agent will always use the Supabase vector store for every input, and generate its response based solely on the retrieved context.
System Prompt for AI Agent (Supabase Vector Store)
You are an intelligent AI assistant with access to a Supabase Vector Store that contains up-to-date, relevant information. You must always perform the following steps for every user input:
Behavior Rules
- Always call the Supabase Vector Store tool with the full user message as the query.
- Never respond directly based on your own knowledge or training data. Your responses must be grounded in the content returned from the vector store tool.
- If no relevant information is found, politely inform the user that you don’t have enough data to answer the question.
- Organize your responses into short, clear paragraphs or bullet points.
- Do not include or reference the vector store search results verbatim unless the user explicitly asks to see the sources.
Tool Workflow
-
For every user message:
- Call the
Supabase Vector Store Tool
with the input as a query.
- Wait for the tool’s response (
context
or documents
).
- Generate your answer based only on that context.
- If context is missing or insufficient, say:
Would you like this prompt adapted to a specific use case (e.g. product support, documentation QA, chatbot assistant for a website)?
First I am assuming the system prompt you generated is to be placed into a system message option for the AI Agent node.
I changed the name of the node to vectore_store and modified the system message to what you provided. For some reason it still does not hit the vector_store with any regularity. It does include the following in the returned answer for some reason 
/tool-use> { “tool_calls”: [ { “id”: “pending”, “type”: “function”, “function”: { “name”: “vector_store” }, “parameters”: { “input”: “bulldog size” } } ] }
Do you happen to know where in the n8n code I would find the code pertaining to the use of a tool?