Oriora Python SDK
Thin Python client for Oriora — Managed API BYOK.
Two ways to use it:
model_select()— decision only. Oriora tells you the best model for a task; you run the call yourself with your own vendor key. Oriora never sees your key, prompt, or output. Flat $0.001 per decision.chat()— OpenAI-compatible. Oriora routes and executes the call server-side using the BYOK vendor key you configured, and returns an OpenAI-shaped response.
Install
pip install oriora
Authenticate
Generate an sk_oriora_ API key in your Oriora account → Settings. Pass it directly or set ORIORA_API_KEY.
from oriora import Oriora
client = Oriora(api_key="sk_oriora_...") # or: Oriora() with ORIORA_API_KEY set
model_select() — decision only (you run the call)
rec = client.model_select(task_type="coding")
# {'model': 'anthropic/claude-sonnet-4.6', 'alternatives': [...], 'task_type': 'coding'}
# Then call that model yourself, with your own vendor key:
import anthropic
anthropic.Anthropic().messages.create(model="claude-sonnet-4.6", messages=[...])
Restrict the recommendation to your own candidate list (your quality order is kept):
client.model_select(task_type="coding", models=["openai/gpt-5", "anthropic/claude-sonnet-4.6"])
Discover the valid task types:
client.task_types()
# ['agentic', 'coding', 'general', 'math', 'reasoning', ...]
chat() — OpenAI-compatible (we run the call via your BYOK key)
First, in your Oriora account, store your vendor key and enable BYOK for an app label (e.g. my-app). Then:
resp = client.chat(
app="my-app", # the BYOK app label you enabled
messages=[{"role": "user", "content": "Explain merge sort in one line."}],
# model defaults to "oriora-auto" — Oriora picks the best model for your prompt
)
print(resp["choices"][0]["message"]["content"])
The response is an OpenAI-shaped ChatCompletion dict (id, choices, usage, …), so existing OpenAI-style code works with minimal changes.
Note:
usagetoken counts onchat()are currently estimated. Specific-model pinning and streaming are not yet supported (usemodel="oriora-auto").
Errors
Non-2xx responses raise OrioraError (with .status_code and .message).
from oriora import OrioraError
try:
client.model_select(task_type="coding")
except OrioraError as e:
print(e.status_code, e.message)
Pricing
model_select()— flat $0.001 / decision.chat()— Managed API BYOK orchestration fee on the call (your vendor bills you directly for the AI usage on your own key).
Metadata
Release files for oriora 0.1.0
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 | Actions |
|---|---|---|---|---|
| oriora-0.1.0.tar.gz | 3.5 kB | Without provenance | Details for oriora-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| oriora-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for oriora-0.1.0-py3-none-any.whl |
Total release size: 7.8 kB
Release files / oriora-0.1.0.tar.gz
| Download URL | oriora-0.1.0.tar.gz |
|---|---|
| Size | 3.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
38372c985ab44c289565f04a2aa49f0e115479a1fe4abb410df69c1580c3fdd8
|
|
BLAKE2b-256 checksum How to use checksums |
06ffb00a32246a8d91e12a2f11076fd5c5f52904be2a8dc9b329fc1398b60a9d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Release files / oriora-0.1.0-py3-none-any.whl
| Download URL | oriora-0.1.0-py3-none-any.whl |
|---|---|
| Size | 4.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
63e073614145756badba58342c04a24140a4becf5a6ceb9d458fc524f458ed21
|
|
BLAKE2b-256 checksum How to use checksums |
ed58f718871603063ac350d1b7bf673e8a8d167ac3ee6de2596594c5c1a3dcd6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.3
|
Security for oriora 0.1.0
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.