Back to directory

Ollama PHP Library

A PHP client library for the Ollama API, covering chat and text completion (including streaming), model management and embeddings, for PHP 8.1 and above.

Ollama PHP Library

Ollama PHP Library is a PHP client for the Ollama local-LLM server API. It provides resources for completions and chat, including streamed responses, and for listing, creating, copying, deleting, pulling and pushing models, as well as retrieving currently running models.

It also exposes blob and embedding endpoints, and supports a tools parameter for function calling in chat requests, with the restriction that tools cannot be combined with streamed chat. It is installed through Composer and defaults to Ollama's local endpoint, with a configurable base URL for remote servers.

More in Inference

See all 770
  • OpenDecision

    deepanwadhwa.github.io

    An open-source Python package that answers typed questions about application state or documents using a local natural-language-inference model, returning structured choice, score, yes/no or evidence-relation values instead of free text.

  • Lifeboat

    iterate.ai

    A local inference server that puts an OpenAI- and Anthropic-compatible API in front of open-weight language models running on hardware you control, from a laptop to a GPU cluster.

  • Claude S40

    github.com

    An unofficial Claude chat client for 2007-era Nokia Series 40 phones, built as a Java ME app plus a small Go relay server, with web search, reading mode and saved chats.