Metadata-Version: 2.4
Name: navian-pulse
Version: 2.3.2
Summary: Python SDK for Navian Pulse — real-time stateful event engine + structured-entity memory layer for AI agents
Author-email: Navian AI <engineering@navian.ai>
License: Apache-2.0
Keywords: navian,pulse,events,fraud,grpc,sdk,memory,mcp,agents
Requires-Python: >=3.11
Description-Content-Type: text/markdown
Requires-Dist: cryptography>=42.0
Requires-Dist: grpcio>=1.60
Requires-Dist: protobuf<7,>=5.27
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Requires-Dist: mypy>=1.8; extra == "dev"
Provides-Extra: mcp
Requires-Dist: mcp<2.0,>=1.0; extra == "mcp"
Requires-Dist: httpx>=0.27; extra == "mcp"
Provides-Extra: llm
Requires-Dist: anthropic>=0.40; extra == "llm"
Requires-Dist: openai>=1.55; extra == "llm"
Provides-Extra: llm-cloud
Requires-Dist: boto3>=1.35; extra == "llm-cloud"
Requires-Dist: google-cloud-aiplatform>=1.70; extra == "llm-cloud"
Provides-Extra: all
Requires-Dist: navian-pulse[llm,llm-cloud,mcp]; extra == "all"

# Navian Pulse Python SDK

```bash
pip install navian-pulse
```

## Quick Start

```python
from navian_pulse import PulseConfig, NavianClient

# Load TOML config — syncs SDK with engine's event types and field definitions
config = PulseConfig.from_toml_file("config/fraud-comprehensive.toml")

# Generate typed event classes (run once, check into repo)
# navian-codegen config/fraud-comprehensive.toml --output my_events.py

from my_events import PulseEventFactory

# Connect to engine
client = NavianClient("localhost:50051", config)

# Send typed events — IDE catches missing fields, SDK validates before sending
event = PulseEventFactory.cash_deposit(entity_token="cust-001", amount=9400.0)
result = client.send(event)
print(result)  # SendResult(response='ALLOW', rules=25, score=1.00)
```

## Features

- **TOML config sync** — parses known_types, fields, policies, agent scopes
- **Code generation** — typed dataclass per event type with required payload fields
- **Pre-send validation** — unknown event types rejected before network call
- **Field protection** — HMAC-SHA-256 + AES-256-GCM + HKDF (cross-SDK conformance)
- **gRPC + HTTP fallback** — connects via gRPC, falls back to REST
