1 file was added to this release more than 14 days after its initial publication. Inspect the release files before installing.
The Official Python library for the ShuttleAI API
The ShuttleAI Python library provides easy access to the ShuttleAI REST API for Python 3.9+ applications. It includes type definitions for all request parameters and response fields, offering both synchronous and asynchronous clients powered by httpx and aiohttp, respectively.
We prioritize performance optimizations across the library. Beyond using orjson for near-instant JSON processing, we implement various techniques to reduce overhead and enhance speed, ensuring efficient and swift API interactions. These optimizations include minimizing built-in library usage, leveraging reusable aiohttp client sessions, and incorporating several small adjustments to streamline operations.
Installation
pip install shuttleai
From Source
This client uses poetry as a dependency and virtual environment manager.
You can install poetry with
pip install poetry
poetry will set up a virtual environment and install dependencies with the following command:
poetry install
Run examples
You can run the examples in the examples/ directory using poetry run or by entering the virtual environment using poetry shell.
Using poetry run
cd examples
poetry run python chat_no_streaming.py
Using poetry shell
poetry shell
cd examples
>> python chat_no_streaming.py
API Key Setup
To use the ShuttleAI API, you need to have an API key. You can get a FREE API key by signing up at shuttleai.app and heading to the key management page.
After you have an API key, you can set it as an environment variable:
Windows
setx SHUTTLEAI_API_KEY "<your_api_key>"
macOS/Linux
export SHUTTLEAI_API_KEY=<your_api_key>
Contribution
We welcome and appreciate contributions to the ShuttleAI API Python SDK. Please see the contribution guide for more information. Benefits may apply! 😄
Scripts
Formatting/Checks
poetry run ruff check shuttleai- Check for code formatting issuespoetry run black shuttleai --diff --color- Check for code formatting issuespoetry run black shuttleai- Format codepoetry run mypy shuttleai- Check for type errors
Tools
poetry run clean- Clean up the project directorypoetry run key- Display your default API key (if set by environment variable)poetry run contributors- Display contributors
Interactive Chatbot
poetry run shuttleai- Run the interactive chatbot
Metadata
Release files for shuttleai 0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
File added late
1 file was uploaded more than 14 days after the first file in this release.
While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.
We recommend inspecting the release files before installing.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| shuttleai-0.tar.gz | 16.8 kB | Details |
Built distributions (wheels)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| shuttleai-0.0.0-py3-none-any.whl | Python 3 | none | any | Details |
| shuttleai-0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 81.0 kB
Release files / shuttleai-0.tar.gz
| Download URL | shuttleai-0.tar.gz |
|---|---|
| Size | 16.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cb86cbc8695f0801346a91ef0b2f328d22d7826e90529dc3b4ae9e8ac5adb8c7
|
|
BLAKE2b-256 checksum How to use checksums |
9244461ccb4d4fb7717932e7f0d50a411bb564c63390e3368eb0dae0af494983
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.3 Windows/11
|
Release files / shuttleai-0.0.0-py3-none-any.whl
File added late
This file was uploaded more than 14 days after the first file in this release.
While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.
We recommend inspecting the release file before installing.
| Download URL | shuttleai-0.0.0-py3-none-any.whl |
|---|---|
| Size | 38.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
db85c8b999166bab74e09009f33f84014666c91bc3459adbdbef18280b93f46b
|
|
BLAKE2b-256 checksum How to use checksums |
5858d11af78ee5cf3a89d2b90288ce9f00e3d56c74cfc40efc6f23ff7b33e51c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.11 {"installer":{"name":"uv","version":"0.9.11"},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / shuttleai-0-py3-none-any.whl
| Download URL | shuttleai-0-py3-none-any.whl |
|---|---|
| Size | 26.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6302728f1df7d4b6f5a4c86377b1982732485c1a6cff5e6956eb66810f5dc9c5
|
|
BLAKE2b-256 checksum How to use checksums |
4949830582b3c83a0d2ed7a6a5894c94d84f084cf4f821264502fceaecb76436
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.3 Windows/11
|