Metadata-Version: 2.5
Name: kobil-aitrust
Version: 3.0.1
Summary: KOBIL AI Trust Platform — unified meta-package wrapping SDK and Audit into a simple developer-facing API
License-Expression: LicenseRef-KOBIL-Agent-Trust-SDK-1.0
License-File: LICENSE
Keywords: agent,ai,audit,ciba,fga,kobil,mfa,oauth,security,trust
Requires-Python: >=3.10
Requires-Dist: kobil-agent-sdk<4,>=3.0
Requires-Dist: mcp>=2.0.0
Provides-Extra: all
Requires-Dist: anthropic>=0.20; extra == 'all'
Requires-Dist: kobil-agent-audit<4,>=3.0; extra == 'all'
Requires-Dist: openai>=1.0; extra == 'all'
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.20; extra == 'anthropic'
Provides-Extra: audit
Requires-Dist: kobil-agent-audit<4,>=3.0; extra == 'audit'
Provides-Extra: dev
Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Provides-Extra: openai
Requires-Dist: openai>=1.0; extra == 'openai'
Description-Content-Type: text/markdown

# kobil-aitrust (Python)

Python mirror of the `@uveysservetoglu/kobil-aitrust` TypeScript meta-package — wraps the SDK
and Audit packages into a single developer-facing API via `AITrust()`.

Behavioral 1:1 port of the TypeScript package in `../src`. The TypeScript
source is the reference specification.

## Dependency note

`AITrust()` constructs a `KobilAI` from `kobil_agent_sdk` (the agent-sdk port).
That dependency is resolved lazily through `kobil_aitrust.trust._make_kobil_ai`
so the package imports without agent-sdk installed and so tests can inject a
fake — mirroring the TS `vi.mock('@uveysservetoglu/kobil-agent-sdk')`. Audit is resolved
the same way via `_import_audit_cls`.

## Install (dev)

```bash
python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
```

## Test

```bash
pytest
```

## Usage

```python
import asyncio
from kobil_aitrust import AITrust, AITrustConfig

ai = AITrust(AITrustConfig(platform_url="https://trust.kobil.com", client_id="my-agent"))

@ai.tool  # or: secured = ai.tool(fn, ToolOptions(name="get_weather", scopes=["weather:read"]))
async def get_weather(city, ctx):
    return "sunny"
```
