Unable to set keep_alive parameter
Open
@ParthSareen is already working on this.
Since Jan 30, 2025.
- Dominant language
- Python
- Stars
- 10.5k
- Forks
- 1.2k
- Avg merge
- 4m
- Merged PRs (30d)
- 1
Description
Hi,
I am using ollama.AsyncClient() for parallel processing of documents. I am setting keep_alive parameter from ollama.AsyncClient().chat(keep_alive=-1).
I have also tried setting env variable, os.environ["OLLAMA_KEEP_ALIVE"] = "-1"
While checking ollama ps from the terminal, I see connective alive UNTIL 5 minutes (which is default). While running python script, after 5 minutes the code is getting stuck because ollama models running using ollama python client is getting stopped.
How can I resolve this issue?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.