Metadata-Version: 2.4
Name: t3nets-sdk
Version: 0.1.2
Summary: Public SDK for building t3nets practices — contracts, models, interfaces, test doubles.
Author-email: Ellie Portugali <ellieportugali@gmail.com>
License: MIT
Project-URL: Homepage, https://github.com/WildEllie/t3nets
Project-URL: Repository, https://github.com/WildEllie/t3nets
Project-URL: Issues, https://github.com/WildEllie/t3nets/issues
Project-URL: Changelog, https://github.com/WildEllie/t3nets/blob/main/sdk/CHANGELOG.md
Requires-Python: >=3.12
Description-Content-Type: text/markdown
Requires-Dist: pydantic>=2.0
Requires-Dist: PyYAML>=6.0
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Requires-Dist: pytest-asyncio>=0.24; extra == "dev"
Requires-Dist: ruff>=0.8; extra == "dev"
Requires-Dist: mypy>=1.13; extra == "dev"

# t3nets-sdk

Public SDK for building [t3nets](https://github.com/WildEllie/t3nets) practices.

A practice is a bundle of skills, pages, and prompts that customizes a t3nets
deployment for a specific domain (engineering, therapy, ops, etc.). Practices
typically live in their own repos — this SDK is the only t3nets dependency
they need.

## What's in here

- **Models** (`t3nets_sdk.models`) — `RequestContext`, `Tenant`, `TenantUser`,
  `TenantSettings`, `InboundMessage`, `OutboundMessage`, channel types.
- **Interfaces** (`t3nets_sdk.interfaces`) — `BlobStore`, `SecretsProvider`,
  `EventBus`, `ConversationStore`. Abstract ports a skill worker may receive
  at runtime.
- **Contracts** (`t3nets_sdk.contracts`) — typed `SkillContext` /
  `SkillResult` worker contract. Workers receive a `SkillContext` and return
  a `SkillResult` carrying either `text` (verbatim) or `render_prompt`
  (router AI formatter).
- **Manifest validators** (`t3nets_sdk.manifest`) — pydantic validators for
  `practice.yaml` / `skill.yaml`.
- **Test doubles** (`t3nets_sdk.testing`) — in-memory `Mock*` implementations
  of every interface, for offline skill tests.
- **CLI** (`t3nets`) — `practice init`, `practice validate`,
  `practice package`, `practice run-local`.

## Design rules

- **Zero cloud SDKs.** No `boto3`, no `anthropic`, no `starlette`. The SDK must
  stay light enough to drop into any practice repo.
- **Stable surface.** SemVer strict. Practices pin a major.
- **Stdlib dataclasses on the hot path.** Pydantic only for manifest parsing —
  keeps Lambda cold starts lean.

## Installation

```bash
pip install t3nets-sdk
```

For local development against the t3nets monorepo:

```bash
pip install -e ./sdk
```
