Metadata-Version: 2.4
Name: weio-cli
Version: 0.3.0
Summary: Weio — an agentic coding assistant that routes inference through your Weio account.
Author: We I/O Labs
License: MIT
Project-URL: Homepage, https://weio.ai
Project-URL: Documentation, https://weio.ai/support
Keywords: weio,ai,cli,coding-assistant,llm
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Software Development :: Code Generators
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: httpx>=0.24
Requires-Dist: prompt_toolkit>=3.0
Dynamic: license-file

# weio-cli

An agentic coding assistant that runs on your machine and routes inference
through your [Weio](https://weio.ai) account.

## Install

```bash
pip install weio-cli        # or: pipx install weio-cli
```

Requires Python 3.9+.

## Authenticate

Generate an API key in **Settings → API & CLI** on weio.ai, then:

```bash
weio login                  # paste your weio_sk_… key (saved to ~/.weio/config.json)
# or, per-session:
export WEIO_API_KEY="weio_sk_…"
```

## Use

### Interactive TUI (default)

Run `weio` with no arguments to drop into an interactive coding session — like a
local pair-programmer in your terminal:

```bash
cd my-project
weio
```

```
weio › add a /health route to app.py that returns {"ok": true}

weio: I'll add a health check route…
  ● edit app.py
  --- a/app.py
  +++ b/app.py
  @@ …
  Apply 1 change(s)? [y/N] y
  ✓ applied 1 change(s). (/undo to revert)
```

Slash commands: `/add <file>`, `/drop <file>`, `/files`, `/auto` (auto-apply),
`/model <id>`, `/undo`, `/clear`, `/cwd`, `/help`, `/exit`. Arrow-up recalls
history. Files you mention or `/add` are kept in context and re-read each turn.

### One-shot & other commands

```bash
# Run a single coding task non-interactively (reads & edits files):
weio "add error handling to the fetch() in api.py"

# Add specific files to the context:
weio code "refactor to async" -f server.py -f db.py

# One-shot question (no file edits):
weio ask "what does a 502 from nginx usually mean?"

# Interactive chat:
weio chat

# Check connectivity and your key:
weio ping
```

Edits are shown as a diff and require confirmation before anything is written
(use `-y`/`--yes` to apply automatically). New files are created as needed.

## Updating

weio-cli checks PyPI once a day (fail-silent) and prints a one-line notice when a
newer version is available. To upgrade:

```bash
weio update           # upgrades in place via pip
# or
pip install -U weio-cli
```

Disable the check with `WEIO_NO_UPDATE_CHECK=1`.

## Configuration

| Setting | Flag | Env | Config file |
|---|---|---|---|
| API key | `--key` | `WEIO_API_KEY` | `~/.weio/config.json` |
| API base | `--base` | `WEIO_BASE` | `~/.weio/config.json` |
| Model | `--model` | — | — |

Self-hosted / LAN gateway? Point at it with `--base http://HOST:8901/v1`.

Output is billed against your Weio account usage.
