[Bug] Does not provide capabilities for /show api call #255

Open
opened 2026-02-15 16:29:14 -05:00 by yindo · 2 comments
Owner

Originally created by @adar2378 on GitHub (Apr 4, 2025).

Hi, please notice that ollama api docs says it provides capabilities via /show endpoint.

https://github.com/ollama/ollama/blob/main/docs/api.md#response-26

But this python sdk does not support that. Without it, it's hard to determine which models have what kind of capabilities.

Originally created by @adar2378 on GitHub (Apr 4, 2025). Hi, please notice that ollama api docs says it provides capabilities via /show endpoint. https://github.com/ollama/ollama/blob/main/docs/api.md#response-26 But this python sdk does not support that. Without it, it's hard to determine which models have what kind of capabilities.
Author
Owner

@ckuethe commented on GitHub (Apr 9, 2025):

Same. My workaround is to do something like this:

model_name = "codestral"
model_info = ollama_client._request_raw("POST", "/api/show",json={"name":model_name}).json()
print(model_info["capabilities"])
@ckuethe commented on GitHub (Apr 9, 2025): Same. My workaround is to do something like this: ```python model_name = "codestral" model_info = ollama_client._request_raw("POST", "/api/show",json={"name":model_name}).json() print(model_info["capabilities"]) ```
Author
Owner

@jayrinaldime commented on GitHub (Apr 28, 2025):

Hello,

Please consider my pull request to add capabilities in show api

https://github.com/ollama/ollama-python/pull/511

here is the sample python code

from ollama import ShowResponse, show

model_details: ShowResponse = show("gemma3")
if "embedding" in model_details.capabilities:
  print("Embedding model")
elif "vision" in model_details.capabilities:
  print("Vision model")
elif "completion" in model_details.capabilities:
  print("Chat model")
else:
  print("Unknown", model_details.capabilities)
 
@jayrinaldime commented on GitHub (Apr 28, 2025): Hello, Please consider my pull request to add capabilities in show api https://github.com/ollama/ollama-python/pull/511 here is the sample python code ``` python from ollama import ShowResponse, show model_details: ShowResponse = show("gemma3") if "embedding" in model_details.capabilities: print("Embedding model") elif "vision" in model_details.capabilities: print("Vision model") elif "completion" in model_details.capabilities: print("Chat model") else: print("Unknown", model_details.capabilities) ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: ollama/ollama-python#255