abyss-ai-sdk (Python)
Multi-provider AI utility with structured responses and streaming. Supports Groq, OpenAI, and Anthropic with a unified API.
Install
pip install abyss-ai-sdk
Usage
create_client() - recommended
from abyss_ai_sdk import create_client, AskOptions
from pydantic import BaseModel
ai = create_client(provider="groq/openai/anthropic", api_key="your_api_key")
# Plain text
res = ai.ask(AskOptions(prompt="Say hello in one sentence."))
print(res.data)
# Structured
class Sentiment(BaseModel):
sentiment: str
confidence: float
summary: str
res = ai.ask(AskOptions(
prompt="Analyse: 'I love this product!'",
schema=Sentiment,
))
print(res.data.sentiment)
print(res.data.confidence)
# Streaming
for chunk in ai.stream(AskOptions(prompt="Tell me a story.")):
print(chunk, end="", flush=True)
Embeddings (OpenAI only)
from abyss_ai_sdk import create_client, EmbedOptions
ai = create_client(provider="openai", api_key="your_openai_key")
res = ai.embed(EmbedOptions(input=["cat", "dog"]))
print(len(res.embeddings[0])) # 1536
One-off calls
from abyss_ai_sdk import ask, stream, AskOptions
from abyss_ai_sdk import AbyssConfig
config = AbyssConfig(provider="groq", api_key="your_groq_key")
res = ask(config, AskOptions(prompt="What is 2 + 2?"))
print(res.data)
Providers
Providers
| Provider | Default Model |
|---|---|
groq |
llama-3.1-8b-instant |
openai |
gpt-4o-mini |
anthropic |
claude-sonnet-4-6 |
Override the model:
ai = create_client(provider="groq/openai/anthropic", api_key="api_key", model="model_of_your_choice")
API
create_client(provider, api_key, model=None)
Returns an AbyssClient with .ask(), .stream(), and .embed().
AskOptions
| Field | Type | Description |
|---|---|---|
prompt |
str |
The user message |
system |
str | None |
System prompt |
schema |
BaseModel | None |
Pydantic model for structured output |
temperature |
float |
Default 0.7 |
max_tokens |
int |
Default 1024 |
EmbedOptions
| Field | Type | Description |
|---|---|---|
input |
str | list[str] |
Text to embed |
model |
str | None |
Override default model |
License
MIT
Metadata
Release files for abyss-ai-sdk 0.2.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| abyss_ai_sdk-0.2.3.tar.gz | 4.2 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| abyss_ai_sdk-0.2.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 11.1 kB
Release files / abyss_ai_sdk-0.2.3.tar.gz
| Download URL | abyss_ai_sdk-0.2.3.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2fe357b85ae04faa458d385415bdf19a41b5504c47cebb302fc44fd8a97dd4ba
|
|
BLAKE2b-256 checksum How to use checksums |
25934db500034e531cee1efe0636b36f3d9a9452416da4fa0da9ed0152f7d1b0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Hatch/1.17.0 {"ci":null,"cpu":"AMD64","implementation":{"name":"CPython","version":"3.14.6"},"installer":{"name":"hatch","version":"1.17.0"},"openssl_version":"OpenSSL 3.5.7 9 Jun 2026","python":"3.14.6","system":{"name":"Windows","release":"11"}} HTTPX2/2.5.0
|
Release files / abyss_ai_sdk-0.2.3-py3-none-any.whl
| Download URL | abyss_ai_sdk-0.2.3-py3-none-any.whl |
|---|---|
| Size | 6.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f7656b392e003d5f3d593669e69591026e49729eb8b5b22fb544eea314551c77
|
|
BLAKE2b-256 checksum How to use checksums |
fb0ebb4cd107f641aa6796e2a59d7324cb10a3a67cd5cafd9f2d01e421d20663
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Hatch/1.17.0 {"ci":null,"cpu":"AMD64","implementation":{"name":"CPython","version":"3.14.6"},"installer":{"name":"hatch","version":"1.17.0"},"openssl_version":"OpenSSL 3.5.7 9 Jun 2026","python":"3.14.6","system":{"name":"Windows","release":"11"}} HTTPX2/2.5.0
|
Security for abyss-ai-sdk 0.2.3
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.