ragna
ragna copied to clipboard
Pull Ollama models before use
Bug description
If the user has not run ollama pull <model-name>, they will get the error
ragna.core.RagnaException: API call failed, request_method=POST, request_url=http://localhost:11434/api/chat, response_status_code=404, response_content={'error': 'model "mistral" not found, try pulling it first'}
How to reproduce the bug?
Send a prompt to Ollama before running ollama pull <model-name>
Versions and dependencies used
No response
Anything else?
The fix is to run ollama pull <model-name> (or make the corresponding API call) sometime before sending the first prompt. The questions is when. That is, should we run it at the first prompt, or at the initialization of the assistant?
@pmeier do you have any input?
Go for it.