Official Python SDK for AGCMS — AI Governance & Compliance Monitoring.
Project description
AGCMS Python SDK
Official Python client for AGCMS — AI Governance & Compliance Monitoring. Drop-in replacement for the OpenAI client that routes every call through your AGCMS gateway, so you get PII redaction, prompt-injection detection, policy enforcement, and signed audit trails for free.
Install
pip install agcms
Quickstart
from agcms import AGCMSClient
client = AGCMSClient(
base_url="https://api.your-tenant.agcms.com",
api_key="agc_live_...",
)
resp = client.chat.completions.create(
model="groq:llama-3.3-70b-versatile",
messages=[{"role": "user", "content": "Hello!"}],
)
print(resp["choices"][0]["message"]["content"])
print("audit interaction_id:", client.last_interaction_id)
Wrap an existing OpenAI client (3-line integration)
from openai import OpenAI
from agcms import openai_wrap
client = openai_wrap(
OpenAI(api_key="sk-..."),
agcms_base_url="https://api.your-tenant.agcms.com",
agcms_api_key="agc_live_...",
)
# Use it exactly like a regular OpenAI client; AGCMS sits in the middle.
client.chat.completions.create(model="gpt-4o", messages=[...])
Verify an audit bundle (CLI)
agcms verify path/to/bundle.zip
Validates the hash chain, Merkle root, and signing-key chain offline — no network calls, no AGCMS credentials needed.
License
Apache-2.0
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 agcms-0.1.0.tar.gz.
File metadata
- Download URL: agcms-0.1.0.tar.gz
- Upload date:
- Size: 11.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe23aa4a36a693fe5e1c514adf35a0b519eb6b34a4a21d2e60c20fcc8a63f773
|
|
| MD5 |
d8286db9cba9d42f2fa2c4f9fef5cb59
|
|
| BLAKE2b-256 |
859ed10ad4637d49acab99121c0c8fa7fec507da9610905983f6edb1b6c05e24
|
File details
Details for the file agcms-0.1.0-py3-none-any.whl.
File metadata
- Download URL: agcms-0.1.0-py3-none-any.whl
- Upload date:
- Size: 10.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
662d5c169dacb4c69142e1eb324944a51e083c09e8861ee395017385ef89ee98
|
|
| MD5 |
70d5b0125ac23b3fff084ffbbf342af4
|
|
| BLAKE2b-256 |
79dfa54d7826ef502edbb037a8f7f54a2fe52b4ed7fa175508daab0692dfedd3
|