This release is a pre-release and may not be stable for production use.
tria-ai
Python SDK for Tria intent-aware runtime governance.
0.5.0a1is an alpha release. Start inauditmode, validate decisions, then enable enforcement for selected agents in the Tria dashboard.
Install
python -m pip install --pre tria-ai
Connected quick start
from openai import OpenAI
from tria import TriaClient
from tria.integrations.openai import wrap_openai
tria = TriaClient(
api_key="YOUR_TRIA_API_KEY",
backend_url="https://tria.intellectmachines.com",
mode="audit",
)
intent = tria.register_intent(
agent_id="support-bot",
natural_language="Answer customer questions using support documents",
permitted_actions=["lookup_order", "search_knowledge_base"],
excluded_actions=["delete_order", "modify_payment"],
)
client = wrap_openai(
OpenAI(api_key="YOUR_OPENAI_API_KEY"),
tria=tria,
intent_id=intent.intent_id,
)
register_intent() writes the intent to the backend and stores the same backend-issued ID locally. It raises if connected registration fails; it never silently creates a local-only policy.
Enforcement
Set the organization or agent to enforce in Tria before using mode="enforce". The SDK fails closed when an enforce-mode client reaches an audit-only backend. Unknown tools are sent for policy evaluation instead of being silently allowlisted.
Local-only mode
Omit backend_url to use local intent evaluation and deterministic guards. Local decisions are not persisted or cryptographically signed by the Tria control plane.
Links
- Website: https://intellectmachines.com/
- Dashboard: https://tria.intellectmachines.com/ui/
- Documentation: https://intellectmachines.com/docs.html
- Source: https://github.com/IntellectMachines/tria-sdk
Apache-2.0
Metadata
Release files for tria-ai 0.5.0a1
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 |
|---|---|---|---|---|
| tria_ai-0.5.0a1.tar.gz | 55.0 kB | Without provenance | Details for tria_ai-0.5.0a1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| tria_ai-0.5.0a1-py3-none-any.whl | Python 3 | none | any | Details for tria_ai-0.5.0a1-py3-none-any.whl |
Total release size: 118.5 kB
Release files / tria_ai-0.5.0a1.tar.gz
| Download URL | tria_ai-0.5.0a1.tar.gz |
|---|---|
| Size | 55.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7912e13f13b9683a1880ca1ca5200a4c10ad3b51c9edf26ae8f848243a05f373
|
|
BLAKE2b-256 checksum How to use checksums |
d28ebfa68ff1885be1087c831b69e1b4b5e4a6bbe511371b9cf2594fcbac4b3b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.15
|
Release files / tria_ai-0.5.0a1-py3-none-any.whl
| Download URL | tria_ai-0.5.0a1-py3-none-any.whl |
|---|---|
| Size | 63.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
76d8c7d980ad77bdced653bbd7a0fce002a7090780900b4d8c55fc3177617e5a
|
|
BLAKE2b-256 checksum How to use checksums |
ac1623ec45b180c1aa8a9047fd1707de1d6d8e2cb838872b2ab668b8e8869c70
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.15
|
Security for tria-ai 0.5.0a1
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.