Skip to content

partial alias/mapping between a container and the model being used #1268

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

Open
benoitf opened this issue Apr 24, 2025 · 7 comments
Open

partial alias/mapping between a container and the model being used #1268

benoitf opened this issue Apr 24, 2025 · 7 comments
Labels
bug Something isn't working

Comments

@benoitf
Copy link
Contributor

benoitf commented Apr 24, 2025

Issue Description

if I use RamaLama on the host and it starts a container with ramalama run ollama://tinyllama:latest I have

ai.ramalama.model: ollama://tinyllama:latest

so I know which model is used if I compare with the value of ramalama model list command

but if I use ramalama serve tinyllama the value is ai.ramalama.model: tinyllama

so it contains the value I provided so it's difficult/impossible to map the container to the original model

I would expect to see ollama://tinyllama:latest as well for ai.ramalama.model

in container mode, there is an alias being added but the alias is not the fully qualified model name as well
#1009

Steps to reproduce the issue

start models using shortnames or a subpart
or use the CLI container

Describe the results you received

different format of ai.ramalama.model

Describe the results you expected

I expect to always see one of the name returned by ramalama list

ramalama info output

0.7.5 / macOS

Upstream Latest Release

Yes

Additional environment details

No response

Additional information

No response

@benoitf benoitf added the bug Something isn't working label Apr 24, 2025
@benoitf benoitf changed the title alias/mapping between a container and the model being used partial alias/mapping between a container and the model being used Apr 24, 2025
@rhatdan
Copy link
Member

rhatdan commented May 1, 2025

We do translate if we have the name expanded by shortnames, but if ollama expands it we don't.

@ericcurtin Do you know if there is an easy way to figure out tinylama=ollama://tinyllama:latest?

I guess we could just check if the name has

@rhatdan
Copy link
Member

rhatdan commented May 1, 2025

We could decorate the shortname our self with TRANSPORT://model:TAG, if we don't see TRANSPORT or TAG specified, but in some cases doesn't ollama translate tiny->tinyllama.

@ericcurtin
Copy link
Collaborator

I guess:

ramalama model list == ramalama list

playing with docker I guess 😄

I think ramalama list/ls is fine, we don't really do reverse-shortname resolution though (to display the shortname version). Should we? What does podman do here?

@ericcurtin
Copy link
Collaborator

@ericcurtin Do you know if there is an easy way to figure out tinylama=ollama://tinyllama:latest?

It wouldn't be that hard to do a reverse lookup if we wanted to.

@benoitf
Copy link
Contributor Author

benoitf commented May 1, 2025

The idea behind this is: How to get the model id from 'model list' command when I have a container running

So no change expected on the list command, but on the annotation/label applied on the container to have as model name the FQN model, the one we can get from 'list' command

It's to be able to know which containers are related to a given model or from a model, what are the containers using that model.

@rhatdan
Copy link
Member

rhatdan commented May 1, 2025

I agree with @benoitf here, it would be nice to have this label match the FQN of the pulled model. The question is how easy is this to get with ollama short names.

@rhatdan
Copy link
Member

rhatdan commented May 2, 2025

Podman does not list shortnames after the fact. Only reports the full name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants