Metadata-Version: 2.4
Name: traeco-sdk
Version: 1.0.0
Summary: AI agent cost intelligence — trace LLM calls, attribute costs, get optimization recommendations.
Author-email: Traeco <hello@traeco.ai>
License: MIT
Project-URL: Homepage, https://traeco.ai
Project-URL: Documentation, https://traeco.ai/docs
Project-URL: Repository, https://github.com/saniagupta124/Agent-Optimization-Platform
Keywords: llm,openai,anthropic,cost,tracing,ai-agents,observability
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: httpx>=0.24
Provides-Extra: openai
Requires-Dist: openai>=1.0; extra == "openai"
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.20; extra == "anthropic"
Provides-Extra: all
Requires-Dist: openai>=1.0; extra == "all"
Requires-Dist: anthropic>=0.20; extra == "all"

# Traeco SDK

Stop paying for AI agent waste. Traeco traces every LLM call in your agent, attributes costs per function, and tells you exactly where to cut spend.

## Install

```bash
pip install traeco-sdk
```

## 3 lines to add tracing

```python
import traeco
from anthropic import Anthropic

traeco.init(api_key="tk_live_...", agent_name="my-agent")
client = traeco.wrap(Anthropic(api_key="..."))

# Your existing code — unchanged
response = client.messages.create(model="claude-sonnet-4-6", ...)
```

## Per-function cost breakdown

```python
from traeco import span

@span("market_analysis")
def analyze(data):
    return client.messages.create(...)

@span("trade_decision")
def decide(analysis):
    return client.messages.create(...)
```

Every `@span` shows up as its own row in the dashboard with token counts, cost, latency, and optimization recommendations.

## Works with OpenAI too

```python
from openai import OpenAI
client = traeco.wrap(OpenAI(api_key="..."))
```

## Dashboard

See costs at [traeco.ai](https://traeco.ai) — get your API key from Settings → API Keys.
