Hello everyone,
I am replicating an agent that originally uses OpenAI and Conebase by replacing these services with open source alternatives (Ollama and Qdrant) in my self-hosted n8n setup. While the agent can send emails when given explicit instructions, retrieving a contact by name from the Qdrant database results in the following error:
"Non string tool message content is not supported"
The output I receive from the node is:
[
{
"response": [
{
"type": "text",
"text": "{\"pageContent\":\"name,email_address: Sara Smith ,sara.smith@gmail.com\"}"
}
]
}
]
I have tried filtering the output, but it appears that the agent is receiving a JSON-encoded string rather than a plain text string. I suspect this wrapping is causing the issue. My goal is to adjust the workflow so that the final output is a simple string (e.g., "name,email_address: Sara Smith ,sara.smith@gmail.com") before it is forwarded to the agent/tool.
Any help to parse or reformat this output correctly would be greatly appreciated.
Additional Setup Information:
- n8n version: Self hosted
- Database: Qdrant
- n8n EXECUTIONS_PROCESS setting: default
- Running n8n via: Docker
- Operating system: Linux Server