Metadata-Version: 2.4
Name: picsha
Version: 0.1.1
Summary: Official Python SDK for Picsha AI - Store, Encode, Understand.
Author: Peter
Author-email: peter@picsha.ai
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: httpx (>=0.27.0,<0.28.0)
Requires-Dist: pydantic (>=2.6.0,<3.0.0)
Description-Content-Type: text/markdown

# Picsha AI Python SDK 🐍

The official Python client for Picsha AI. Designed specifically for data scientists, computational biologists, and ML engineers.

## Installation

We recommend using poetry:

```bash
poetry add picsha
```

Or pip:

```bash
pip install picsha
```

## Quickstart

```python
import picsha

client = picsha.Client(api_key="sk_your_key_here")

# 1. Semantic Search
results = client.search(
    query="fluorescent cancer cell cultures", 
    mode="ai"  # Hybrid Vector Search
)

# 2. Get transformed URLs for ML pipelines
for asset in results.assets:
    url = asset.generate_url(width=512, height=512, format="webp")
    print(url)
```

## Asynchronous Support

For high-throughput workloads, an `AsyncClient` is included out-of-the-box:

```python
import picsha
import asyncio

async def main():
    async with picsha.AsyncClient(api_key="sk_your_key_here") as client:
        result = await client.search(query="cancer cells", mode="ai")
        print(f"Found {result.total_count} assets.")

asyncio.run(main())
```

See the `notebooks/` directory for full examples integrating with Pandas, PyTorch, and SciPy.

