Skip to main content

PinionAI Python Library

This is the official Python client library for the PinionAI platform. It provides a convenient, asynchronous way to interact with PinionAI agents, manage sessions, and use its various features including AI interactions and gRPC messaging. AI Agent authoring is performed in PinionAI Studio.

Website and Documentation

PinionAI website

PinionAI documentation

Run PinionAI Agent from Github

Installation

From PyPI

This package is available on PyPI and can be installed with pip or uv. We recommend uv for its speed.

With uv

If you don't have uv, you can install it from astral.sh.

# On macOS and Linux
curl -LsSf https://astral.sh/uv/install.sh | sh
#OR
brew install uv
# On Windows
powershell -c "irm https://astral.sh/uv/install.ps1 | iex"

Once uv is installed, you can install the pinionai package from PyPI:

uv pip install pinionai

With pip

If you prefer to use pip, you can still install the package with:

pip install pinionai

From GitHub

To install the latest development version directly from the GitHub repository:

pip install git+https://github.com/pinionai/pinionai-package.git

Optional Features

The client includes optional features that require extra dependencies. You can install them as needed based on the services you intend to use.

  • gcp: Google Cloud Storage support (google-cloud-storage)
  • aws: AWS S3 support (boto3)
  • openai: Support for OpenAI models (openai)
  • anthropic: Support for Anthropic models (anthropic)
  • javascript: Support for running JavaScript snippets (mini-racer)
  • sendgrid: Support for running sendgrid delivery (twiliio service)
  • twilio: Support for sms delivery

To install one or more optional features, specify them in brackets. For example, to get support for GCP and AWS:

pip install pinionai[gcp,aws]

To install all optional features at once, use the all extra:

pip install pinionai[all]

Options include:

  • dev = [ "build", "twine", "ruff", "grpcio-tools", ]
  • gcp = ["google-cloud-storage"]
  • aws = ["boto3"]
  • openai = ["openai"]
  • anthropic = ["anthropic"]
  • javascript = ["mini-racer"]
  • sendgrid = ["sendgrid"]
  • twilio = ["twilio"]
  • all = [ "pinionai[gcp,aws,openai,anthropic,javascript,twilio,sendgrid]" ]

Adding to Requirements

To add this library to your project's requirements file, you can use the following formats.

For requirements.txt or requirements.in:

# For a specific version from PyPI
pinionai==0.2.7

# With optional features
pinionai[gcp,openai]==0.2.7

# From the main branch on GitHub
git+https://github.com/pinionai/pinionai-package.git@main

Usage

Here's a Github link to a complete, fully functional example of how to use the AsyncPinionAIClient. In the link to our complete example, you can run a Streamlit or a CLI chat. Note: you can run a specific agent or deploy it to run and accept AIA files to run various agents.

PinionAI Agent on Github

Configuration For Developers

Setting up the environment

To set up a development environment, first create and activate a virtual environment using uv:

# Create a virtual environment named .venv +uv venv
# Activate the virtual environment
# On macOS and Linux
source .venv/bin/activate
# On Windows
.venv\Scripts\activate

Then, install the package in editable mode with its development dependencies:

uv pip install -e .[dev]

Metadata

Release files for pinionai 0.2.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pinionai 0.2.7
File Size Uploaded Provenance Actions
pinionai-0.2.7.tar.gz 57.6 kB Without provenance Details for pinionai-0.2.7.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pinionai 0.2.7
File Interpreter ABI Platform Actions
pinionai-0.2.7-py3-none-any.whl Python 3 none any Details for pinionai-0.2.7-py3-none-any.whl

Total release size: 114.3 kB

Release files / pinionai-0.2.7.tar.gz

Download URL pinionai-0.2.7.tar.gz
Size 57.6 kB
Tags Source
SHA-256 checksum
How to use checksums
b6da02877b19d40576a6e60d1ba7a4f69bcb642f70b9064446956c3adc44a56e
BLAKE2b-256 checksum
How to use checksums
769b206952877075bf531c896f24bf3bee80869c1fd3068c5747f78d8788d81f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.12

Release files / pinionai-0.2.7-py3-none-any.whl

Download URL pinionai-0.2.7-py3-none-any.whl
Size 56.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
296296c18d8bf633c4d8c817e8c22dbf0d247f4a88b5f1374ae5ec25a87a2f8a
BLAKE2b-256 checksum
How to use checksums
c96277a06a7b82c089d20d40db33a40ecac56cf4ee4e03cc382982a4cdd6347c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.12

Security for pinionai 0.2.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.7 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page