Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: use ollama list to find models #1854

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

mattf
Copy link
Contributor

@mattf mattf commented Apr 1, 2025

What does this PR do?

closes #1853

Test Plan

uv run llama stack build --image-type conda --image-name ollama --config llama_stack/templates/ollama/build.yaml

ollama pull llama3.2:3b

LLAMA_STACK_CONFIG=http://localhost:8321 uv run pytest tests/integration/inference/test_text_inference.py -v --text-model=llama3.2:3b

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Meta Open Source bot. label Apr 1, 2025
Copy link
Contributor

@raghotham raghotham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we then make sure the model is running when inference calls are made?

@mattf
Copy link
Contributor Author

mattf commented Apr 1, 2025

Can we then make sure the model is running when inference calls are made?

ollama will automatically start the requested model in response to a /api/chat request

Copy link
Collaborator

@leseb leseb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure this is right.

Copy link
Collaborator

@leseb leseb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could please add a comment in the code to explain Ollama's behavior we just discussed? Thanks!

@mattf
Copy link
Contributor Author

mattf commented Apr 1, 2025

Could please add a comment in the code to explain Ollama's behavior we just discussed? Thanks!

@leseb ptal

@mattf
Copy link
Contributor Author

mattf commented Apr 1, 2025

@leseb the ci failure looks transient, please rerun

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Meta Open Source bot.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ollama][inference] registering llm model registration fails if model not running
5 participants