Metadata-Version: 2.4
Name: analogai-sdk
Version: 0.1.7
Summary: Minimal Python SDK for AnalogAI completion endpoints
Author: Your Name
Author-email: you@example.com
Requires-Python: >=3.9,<4.0
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: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Requires-Dist: python-dotenv (>=1.0.1)
Requires-Dist: requests (>=2.31.0)
Description-Content-Type: text/markdown

# AnalogAI SDK (minimal)

This workspace contains a tiny Python helper for calling AnalogAI chat endpoints.

## Setup

1. Install dependencies with Poetry.
2. Set environment variables in `.env` (already created with placeholders):
    - `ANALOGAI_API_KEY` (optional, if your server requires auth)
    - `ANALOGAI_AGENT_ID` (required)
    - `CHAT_BASE_URL` (optional override; defaults to `https://chat.analogai.net:8001`)

## Install (Poetry)

```bash
poetry install
```

### Local install (editable)

```bash
poetry run pip install -e .
```

### Global install (Poetry)

```bash
poetry build
pip install dist/analogai-0.1.0-py3-none-any.whl
```

## PyPI name

Once published, the package will be available on PyPI as `analogai`.

## Usage

```python
import os
from analogai_sdk import AnalogAIClient

os.environ["CHAT_BASE_URL"] = "http://localhost:8001"

client = AnalogAIClient()
response = client.generate_completion("your text here", mode="auto")
print(response)

for chunk in client.generate_streaming_completion("your text here"):
    print(chunk)
```

### Using explicit messages

```python
from analogai_sdk import AnalogAIClient

client = AnalogAIClient()
response = client.generate_completion(
    message_text="",
    messages=[
        {"role": "system", "content": "You are a helpful assistant."},
        {"role": "user", "content": "Say hello"},
    ],
    mode="auto",
)
print(response)
```

