PHPackages                             papi-ai/ollama - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. papi-ai/ollama

ActiveLibrary

papi-ai/ollama
==============

Ollama (local) provider for PapiAI

v0.9.1(2mo ago)00MITPHPPHP ^8.2CI passing

Since Mar 7Pushed 1mo agoCompare

[ Source](https://github.com/papi-ai/ollama)[ Packagist](https://packagist.org/packages/papi-ai/ollama)[ RSS](/packages/papi-ai-ollama/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (5)Dependencies (4)Versions (6)Used By (0)

PapiAI Ollama Provider
======================

[](#papiai-ollama-provider)

[![CI](https://github.com/papi-ai/ollama/workflows/CI/badge.svg)](https://github.com/papi-ai/ollama/actions?query=workflow%3ACI) [![Latest Version](https://camo.githubusercontent.com/c6b327f9490ff9a2a71ee370f7bf594178bf1fc18c644b74000b0c2fe1d60e6e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f706170692d61692f6f6c6c616d612e737667)](https://packagist.org/packages/papi-ai/ollama) [![Total Downloads](https://camo.githubusercontent.com/469c2369ccebaa7055beb3df9ee485323436689f62368b7bc61e22f5fec07d49/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f706170692d61692f6f6c6c616d612e737667)](https://packagist.org/packages/papi-ai/ollama) [![PHP Version](https://camo.githubusercontent.com/2a8168d713865f376c3dd9cdd030aec9448efef1a57828f86fded8fe227f2d33/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f706170692d61692f6f6c6c616d612e737667)](https://packagist.org/packages/papi-ai/ollama) [![License](https://camo.githubusercontent.com/11ebf422166470c88ec2e9dd488f55de45386348e75dd00ce61dff83c5f2c8a3/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f706170692d61692f6f6c6c616d612e737667)](https://packagist.org/packages/papi-ai/ollama)

Ollama provider for [PapiAI](https://github.com/papi-ai/papi-core) - A simple but powerful PHP library for building AI agents.

Installation
------------

[](#installation)

```
composer require papi-ai/ollama
```

Usage
-----

[](#usage)

```
use PapiAI\Core\Agent;
use PapiAI\Ollama\OllamaProvider;

$provider = new OllamaProvider();

$agent = new Agent(
    provider: $provider,
    instructions: 'You are a helpful assistant.',
);

$response = $agent->run('Hello!');
echo $response->text;
```

Available Models
----------------

[](#available-models)

The following models are supported (as referenced in `OllamaProvider`):

ModelType`llama3.1` (default)General purpose`codellama`Code generation`mistral`General purpose`mixtral`Mixture of experts`qwen2.5-coder`Code generation`nomic-embed-text`Embeddings (default)Features
--------

[](#features)

- Tool/function calling
- Streaming support
- Embeddings support
- Vision support
- Structured output / JSON mode
- Runs locally via Ollama (no API key required)

License
-------

[](#license)

MIT

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance88

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

5

Last Release

60d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/126c34b4dff8d42336ea07ac5297bcc3ec0a0e306fd964a7497f02240da4b142?d=identicon)[md](/maintainers/md)

---

Top Contributors

[![MarcelloDuarte](https://avatars.githubusercontent.com/u/144535?v=4)](https://github.com/MarcelloDuarte "MarcelloDuarte (15 commits)")

###  Code Quality

TestsPest

Static AnalysisPsalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/papi-ai-ollama/health.svg)

```
[![Health](https://phpackages.com/badges/papi-ai-ollama/health.svg)](https://phpackages.com/packages/papi-ai-ollama)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
