Metadata-Version: 2.4
Name: ati-integrations-autogpt
Version: 0.1.1
Summary: ATI Integration for AutoGPT
Project-URL: Homepage, https://iocane.ai
Project-URL: Repository, https://github.com/iocane-ai/ati-integrations
Author-email: IOcane ATI Team <support@iocane.ai>
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Typing :: Typed
Requires-Python: >=3.10
Requires-Dist: ati-sdk==0.1.0
Description-Content-Type: text/markdown

# ATI Integration for AutoGPT

This package provides OpenTelemetry instrumentation for AutoGPT-style agents using IOcane ATI.

## Installation

```bash
pip install ati-integrations-autogpt opentelemetry-sdk opentelemetry-exporter-otlp
```

## Configuration

Set the standard OpenTelemetry environment variables:

```bash
export OTEL_EXPORTER_OTLP_ENDPOINT="https://api.iocane.ai"
export OTEL_EXPORTER_OTLP_HEADERS="x-iocane-key=YOUR_KEY,x-ati-env=YOUR_ENV_ID"
export OTEL_SERVICE_NAME="my-autogpt-agent"
```

## Usage

```python
import os
from ati_autogpt import AutoGPTInstrumentor
from opentelemetry import trace
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.sdk.trace.export import BatchSpanProcessor
from opentelemetry.exporter.otlp.proto.http.trace_exporter import OTLPSpanExporter

# 1. Configure OpenTelemetry
provider = TracerProvider()
exporter = OTLPSpanExporter()
provider.add_span_processor(BatchSpanProcessor(exporter))
trace.set_tracer_provider(provider)

# 2. Instrument AutoGPT
instrumentor = AutoGPTInstrumentor()
instrumentor.instrument() # auto-detects Agent class

# 3. Run your Agent
# ...

# 4. Flush traces
provider.shutdown()
```

## Configuration

Configure the instrumentation via environment variables:

| Variable | Description | Default |
|----------|-------------|---------|
| `ATI_CAPTURE_PAYLOADS` | Capture step inputs | `false` |

## Features
- Captures Agent steps (`ati.span.type=step`)
- Identifies Loop Iterations
