The official SynapsAI Cloud Python SDK
Project description
SynapsAI Python SDK
The official SynapsAI Cloud AI inference Python SDK. Seamlessly integrate multi-modal AI capabilities into your applications.
Installation
Install the latest version of the SDK:
pip install --upgrade synapsai-python
Requirements
- Python >= 3.8
httpx>= 0.23.0, < 1.0.0pydantic>= 2.0, < 3typing-extensions>= 4.5, < 5Pillow>= 9.5.0, < 11numpy>= 1.21.0, < 2
Quick Start
1. Setup Environment Variables
You can configure the SDK using environment variables instead of hardcoding your credentials:
SYNAPSAI_API_KEY- Your SynapsAI API keySYNAPSAI_API_BASE- Custom base URL (Defaults tohttps://api.synapsai.cloud/v1)
2. Initialization & Example Usage
Here is how to initialize the client and fetch a list of all deployed models on your account:
import os
from synapsai import SynapsAI
# Initialize the client (picks up env variables automatically if arguments are omitted)
client = SynapsAI(
api_key=os.environ.get("SYNAPSAI_API_KEY"),
)
# Fetch and view deployed models
models_page = client.models.list()
for model in models_page.data:
print(f"Model ID: {model.id} | Status: {model.status}")
Documentation
For advanced configurations, deep-dive usage guides, and comprehensive code examples for every resource, visit our Examples Documentation.
Available Resources
The SDK provides native support for the following SynapsAI Cloud capabilities:
| Resource | Description |
|---|---|
models |
Model management and discovery |
chat.completions |
Chat completions and real-time streaming |
completions |
Classic text completions |
embeddings |
Text embeddings generation |
images |
Image generation and manipulation |
audio |
Speech-to-text and text-to-speech processing |
videos |
Video generation and processing |
classifications |
Text classification tasks |
question_answering |
Targeted question answering |
feature_extraction |
Feature extraction pipelines |
fill_mask |
Masked Language Modeling (MLM) |
rerank |
Text reranking for search optimization |
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file synapsai_python-0.1.0.tar.gz.
File metadata
- Download URL: synapsai_python-0.1.0.tar.gz
- Upload date:
- Size: 37.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
579ed57b1ebc09951ded056a2b8b57d7ead08d0d07f763547e5dc0179d8572da
|
|
| MD5 |
d6ef2a2c4ed0cba0ce6967d14686c3c2
|
|
| BLAKE2b-256 |
83d194d156b465dba527eff7f7a4274b1361c59da655a88a2613042ec11231b2
|
File details
Details for the file synapsai_python-0.1.0-py3-none-any.whl.
File metadata
- Download URL: synapsai_python-0.1.0-py3-none-any.whl
- Upload date:
- Size: 56.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d1c9f0a09873b55ba95e3e31270b26c42377f9f01d74df92721eb31bcf2da0b3
|
|
| MD5 |
69965680ae8f9d385f592583f54bd51f
|
|
| BLAKE2b-256 |
0012e34bcd799a5f5a5ee382e560072f8038ebc805563781cb4f154d232eef73
|