[GH-ISSUE #3125] [BUG]: Agent not working - FETCH FAILED error #2007

Closed
opened 2026-02-22 18:27:43 -05:00 by yindo · 1 comment
Owner

Originally created by @emad-qadri on GitHub (Feb 5, 2025).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/3125

How are you running AnythingLLM?

AnythingLLM desktop app

What happened?

I thoroughly reviewed the past related issue - https://github.com/Mintplex-Labs/anything-llm/issues/1608 but didn't find any resolution.

I have already testing manually communicating with Ollama, it works completely fine. See screenshot. So, Ollama is NOT the problem. AnythingLLM seems to fail to communicate with Ollama. Could it be that for Agents to work properly; the default AnythingLLM Embedder should be used?

I am using ":llama3:8b-instruct-q8_0" as Agent LLM model.

{"level":"info","message":"\u001b[32m[Event Logged]\u001b[0m - sent_chat","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Start 14d3a948-d52b-4958-996b-2cb2fab70dde::ollama:llama3:8b-instruct-q8_0","service":"backend"}
{"level":"info","message":"\u001b[32m[TELEMETRY SENT]\u001b[0m {"event":"agent_chat_started","distinctId":"4dd208d1-fca3-4021-bc4d-3503352ebefb","properties":{"runtime":"desktop"}}","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached websocket plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached chat-history plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attaching user and default agent to Agent cluster.","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached rag-memory plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached document-summarizer plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached web-scraping plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached save-file-to-browser plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached create-chart plugin to Agent cluster","service":"backend"}
{"level":"info","message":"\u001b[36m[NativeEmbedder]\u001b[0m Initialized","service":"backend"}
{"level":"error","message":"fetch failed TypeError: fetch failed\n at Object.fetch (node:internal/deps/undici/undici:11457:11)\n at async post (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\node_modules\ollama\dist\browser.cjs:114:20)\n at async Ollama.processStreamableRequest (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\node_modules\ollama\dist\browser.cjs:252:22)\n at async #e (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:255:2228)\n at async Oi.functionCall (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:241:931)\n at async Oi.complete (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:255:2404)\n at async Xi.handleExecution (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:274:406)\n at async Xi.reply (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:274:274)\n at async Xi.chat (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:255:32084)\n at async Xi.start (C:\Users\emadq\AppData\Local\Programs\AnythingLLM\resources\backend\server.js:255:31518)","service":"backend"}

Image

Are there known steps to reproduce?

No response

Originally created by @emad-qadri on GitHub (Feb 5, 2025). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/3125 ### How are you running AnythingLLM? AnythingLLM desktop app ### What happened? I thoroughly reviewed the past related issue - https://github.com/Mintplex-Labs/anything-llm/issues/1608 but didn't find any resolution. I have already testing manually communicating with Ollama, it works completely fine. See screenshot. So, Ollama is NOT the problem. AnythingLLM seems to fail to communicate with Ollama. Could it be that for Agents to work properly; the default AnythingLLM Embedder should be used? I am using ":llama3:8b-instruct-q8_0" as Agent LLM model. {"level":"info","message":"\u001b[32m[Event Logged]\u001b[0m - sent_chat","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Start 14d3a948-d52b-4958-996b-2cb2fab70dde::ollama:llama3:8b-instruct-q8_0","service":"backend"} {"level":"info","message":"\u001b[32m[TELEMETRY SENT]\u001b[0m {\"event\":\"agent_chat_started\",\"distinctId\":\"4dd208d1-fca3-4021-bc4d-3503352ebefb\",\"properties\":{\"runtime\":\"desktop\"}}","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached websocket plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached chat-history plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attaching user and default agent to Agent cluster.","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached rag-memory plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached document-summarizer plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached web-scraping plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached save-file-to-browser plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[AgentHandler]\u001b[0m Attached create-chart plugin to Agent cluster","service":"backend"} {"level":"info","message":"\u001b[36m[NativeEmbedder]\u001b[0m Initialized","service":"backend"} {"level":"error","message":"fetch failed TypeError: fetch failed\n at Object.fetch (node:internal/deps/undici/undici:11457:11)\n at async post (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\node_modules\\ollama\\dist\\browser.cjs:114:20)\n at async Ollama.processStreamableRequest (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\node_modules\\ollama\\dist\\browser.cjs:252:22)\n at async #e (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:255:2228)\n at async Oi.functionCall (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:241:931)\n at async Oi.complete (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:255:2404)\n at async Xi.handleExecution (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:274:406)\n at async Xi.reply (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:274:274)\n at async Xi.chat (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:255:32084)\n at async Xi.start (C:\\Users\\emadq\\AppData\\Local\\Programs\\AnythingLLM\\resources\\backend\\server.js:255:31518)","service":"backend"} ![Image](https://github.com/user-attachments/assets/6145534b-37f5-40b8-ba23-d4a072602d36) ### Are there known steps to reproduce? _No response_
yindo added the possible bug label 2026-02-22 18:27:43 -05:00
yindo closed this issue 2026-02-22 18:27:43 -05:00
Author
Owner

@timothycarambat commented on GitHub (Feb 5, 2025):

With the same model I am unable to replicate. That PS shows you using the REST API. What base URL are you using in AnythingLLM to reach the Ollama instance. You should see models in the dropdown and everything.

If we can fetch the models, we can run agents, and we can send chats. All are using the same base URL

@timothycarambat commented on GitHub (Feb 5, 2025): With the same model I am unable to replicate. That PS shows you using the REST API. What base URL are you using in AnythingLLM to reach the Ollama instance. You should see models in the dropdown and everything. If we can fetch the models, we can run agents, and we can send chats. All are using the same base URL
yindo changed title from [BUG]: Agent not working - FETCH FAILED error to [GH-ISSUE #3125] [BUG]: Agent not working - FETCH FAILED error 2026-06-05 14:43:59 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#2007