Metadata-Version: 2.4
Name: loop-cli
Version: 0.1.0
Summary: Loop PM Agent — paste a deployed URL, get top 5 recommendations.
Project-URL: Homepage, https://oddgroup.ai
Project-URL: Documentation, https://oddgroup.ai/docs
Project-URL: Repository, https://github.com/quine-labs/loop
Project-URL: Issues, https://github.com/quine-labs/loop/issues
Author: oddgroup
License: MIT
Keywords: agent,cli,eval,loop,pm
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.11
Requires-Dist: httpx-sse>=0.4.0
Requires-Dist: httpx>=0.27.0
Requires-Dist: pydantic>=2.9.0
Requires-Dist: rich>=13.0.0
Requires-Dist: typer>=0.12.0
Description-Content-Type: text/markdown

# loop-cli

Loop is a PM agent for AI builders. Paste a deployed URL, get a top-5 ranking of what to ship next, with rationale grounded in real product probing, code analysis, and a calibrated evaluator.

```bash
pip install loop-cli
export LOOP_API_KEY=sk_...
loop run https://your-product.com
```

The agent runs five phases (Probing → Stress-testing → Reading code → Auditing → Synthesizing, ~3 minutes) and prints recommendations to your terminal.

## Install

```bash
pip install loop-cli
# or with uv
uv tool install loop-cli
```

Requires Python 3.11+.

## Usage

```bash
# Bare run
loop run https://your-product.com

# With a GitHub repo for code context
loop run https://your-product.com --repo https://github.com/you/repo

# Steer the eval toward a specific concern
loop run https://your-product.com --prompt "focus on retention"

# Machine-readable output (no progress lines, no Rich formatting)
loop run https://your-product.com --json
```

## Authentication

`/api/run` requires a Bearer token. Get one from your Loop account, then:

```bash
export LOOP_API_KEY=sk_...
loop run https://your-product.com
```

Or pass it explicitly (note: this leaks the key into shell history; prefer the env var):

```bash
loop run https://your-product.com --api-key sk_...
```

## Environment variables

| Variable | Default | Purpose |
|---|---|---|
| `LOOP_API_KEY` | (none) | Bearer token for `/api/run` |
| `LOOP_API_URL` | `https://loop.oddgroup.ai` | API endpoint, override for local dev |

## Exit codes

| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | API error (4xx, 5xx, mid-pipeline failure) |
| 2 | Could not reach the API |
| 3 | Request timed out |
| 4 | Stream ended without a result |

## Issues

Report bugs at https://github.com/quine-labs/loop/issues
