Skip to content

Node 18 UND_ERR_HEADERS_TIMEOUT error encountered when calling Ollama invoke, even when overriding keepAlive default #5734

Discussion options

You must be logged in to vote

This does not work. I've tried this before as well and neglected to mention it in my question:

keepAlive:"30m"

again based on my understanding of what this parameter does in context of the fetch, the above value should provide 30 minutes before timeout, but it reliably times out after 5 minutes. I've personally timed and observed the response.

TypeError: fetch failed
    at node:internal/deps/undici/undici:12618:11
    at async createOllamaStream (/home/elliot/recipes/node_modules/@langchain/community/dist/utils/ollama.cjs:12:22)
    at async createOllamaGenerateStream (/home/elliot/recipes/node_modules/@langchain/community/dist/utils/ollama.cjs:57:5)
    at async Ollama._streamResponseCh…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by elliotrodriguez
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant