$npx skillfedfor your agent

ollama

The official Python client for Ollama.

Worth itPyPI Artificial IntelligenceReleased Apr 202619.9M downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — ollama-0.6.2-py3-none-any.whl
v0.6.2 · released 2026-04-29 · Python >=3.8 · 2 runtime deps: httpx, pydantic

Yes. The package is actively maintained, has no known vulnerabilities, carries a permissive MIT license, and installs with minimal friction. It is the official client for Ollama and is well-suited for any Python project that needs to call local or cloud LLMs. Install it if you are already running Ollama or plan to; if you have no Ollama server, it is not useful on its own.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Ollama must be installed and running locally (or accessible at a configured host), and a model must be pulled beforehand (e.g., `ollama pull gemma3`).
  • Low install friction with only two runtime dependencies (httpx and pydantic).
  • Actively maintained with a recent release on 2026-04-29 and steady commit activity; the repository shows strong community engagement with 10407 stars.

License · maintenance · safety

MIT (permissive) — MIT license permits unrestricted use, modification, and distribution in both open-source and commercial projects with minimal restrictions.

last release 2026-04-29 (107 days) · last repo commit 2026-08-12 · 10,407 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 19,885,974 downloads/mo, #1,052 on PyPI

Verify before relying

pip install ollama

from ollama import chat
response = chat(model='gemma3', messages=[{'role': 'user', 'content': 'Why is the sky blue?'}])
print(response.message.content)
  • Whether the package supports Python versions beyond 3.8 despite the requirement stating >=3.8.
  • Performance characteristics and latency for streaming responses under typical loads.
  • Compatibility guarantees with specific Ollama server versions.
Same gist for agents: .md · .json

What it is and what it does

Ollama is the official Python client library for interacting with Ollama, a system for running large language models locally or via cloud. It wraps Ollama's REST API into a straightforward Python interface, letting you send chat messages, generate text, create embeddings, and manage models without dealing with HTTP calls directly. The library supports both synchronous and asynchronous workflows, streaming responses for real-time output, and custom client configuration via httpx.

The package is designed for developers who want to integrate local or cloud-hosted LLMs into Python applications. It handles the common patterns—chat conversations, single-prompt generation, batch embeddings, and model lifecycle operations—with minimal boilerplate. Dependencies are light (httpx for HTTP, pydantic for response validation), and the API closely mirrors Ollama's REST endpoints, so the learning curve is shallow if you're already familiar with the server.

Use it for

  • Build a chatbot or conversational AI feature in a Python application by sending user messages to a local Ollama instance and streaming responses back.
  • Generate text embeddings for semantic search or similarity comparisons without calling an external API.
  • Automate model management tasks—pulling, creating, copying, or deleting models—as part of a larger data pipeline.
  • Prototype LLM-powered features locally during development before deploying to cloud models via Ollama's cloud API.
  • Create an async worker that processes chat or generation requests concurrently using AsyncClient.
  • Integrate Ollama cloud models (e.g., gpt-oss, deepseek-v3.1) into Python code by authenticating with an API key.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

The package is actively maintained, has no known vulnerabilities, carries a permissive MIT license, and installs with minimal friction. It is the official client for Ollama and is well-suited for any Python project that needs to call local or cloud LLMs. Install it if you are already running Ollama or plan to; if you have no Ollama server, it is not useful on its own.

Install

ollama on PyPI

Before you install

Low install friction with only two runtime dependencies (httpx and pydantic). Actively maintained with a recent release on 2026-04-29 and steady commit activity; the repository shows strong community engagement with 10407 stars.

Ollama must be installed and running locally (or accessible at a configured host), and a model must be pulled beforehand (e.g., `ollama pull gemma3`).

License in practice

MIT license permits unrestricted use, modification, and distribution in both open-source and commercial projects with minimal restrictions.

Quickstart

pip install ollama

from ollama import chat
response = chat(model='gemma3', messages=[{'role': 'user', 'content': 'Why is the sky blue?'}])
print(response.message.content)

Verify before relying

  • Whether the package supports Python versions beyond 3.8 despite the requirement stating >=3.8.
  • Performance characteristics and latency for streaming responses under typical loads.
  • Compatibility guarantees with specific Ollama server versions.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.8
Install frictionLow. Pure-Python wheel
Runtime dependencies
2 packages
httpxpydantic
MaintenanceActively maintained 107 days since the last release
Last repo commit
First released
Downloads19,885,974 / month, #1,052 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14

Evidence: ollama-0.6.2-py3-none-any.whl

Tags

Capabilities
ollama python clientlocal llm integrationchat with language modelstext generation apiembedding generationmodel management pythonllm inference client
Topics
llm-clientlocal-inferenceasync-support

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “ollama python client”

Give your agent the search over MCP, or paste the wish link into any chat.

More Artificial Intelligence packages

litellm With conditions
PyPI · Artificial Intelligence · released Aug 2026

LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.

Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.

MITcompiled wheel
682.8Mdownloads / mo
huggingface-hub Worth it
PyPI · Artificial Intelligence · released Aug 2026

Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.

Install it if you work with Hugging Face Hub models or datasets.

Apache-2.0pure Python · 3.10.0+
442.4Mdownloads / mo
langchain Worth it
PyPI · Python Modules · released Aug 2026

LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.

MITpure Python
315.4Mdownloads / mo
hf-xet With conditions
PyPI · Artificial Intelligence · released Aug 2026

hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.

Apache-2.0compiled wheel · 3.8+
258.4Mdownloads / mo
tokenizers Worth it
PyPI · Artificial Intelligence · released Apr 2026

Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.

Apache-2.0compiled wheel · 3.10+
222.9Mdownloads / mo
transformers Worth it
PyPI · Artificial Intelligence · released Aug 2026

Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.

Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.

permissive licensepure Python · 3.10.0+
186.6Mdownloads / mo

See also llama-index-llms-ollama · xinference-client · text-generation · gigachat · llama-index-llms-openai · llama-index-llms-azure-openai · g4f · llama-index-embeddings-ollama · llm · npmai