Metadata-Version: 2.4
Name: causilo-client
Version: 0.8.13
Summary: Python client for the Causilo inference API
License: Proprietary
Project-URL: Homepage, https://nums.world
Requires-Python: >=3.11
Description-Content-Type: text/markdown
Requires-Dist: pandas>=2.0
Requires-Dist: pyarrow>=15
Requires-Dist: requests>=2.32
Requires-Dist: google-auth>=2.28

# causilo-client

Python client for the Causilo inference API. Send a table with the answers
filled in and a table with them blank; get a prediction for every blank row.

## Install

```bash
pip install -U causilo-client
```

Python 3.11 or newer. `pandas`, `pyarrow`, `requests` and `google-auth` are
pulled in automatically.

The import name is `causilo_client`. `causilo` on PyPI is the model package,
and the two can be installed side by side. Code written against the earlier
`radix` name changes one import line: `from causilo_client import Causilo`.

## Use

```python
import os

from causilo_client import Causilo

cx = Causilo(
    os.environ["CAUSILO_ENDPOINT"],
    key_file=os.environ["CAUSILO_KEY_FILE"],
)

pred = cx.predict(context_df, query_df, target="churned", model="causilo-clf")
```

`context_df` holds the target column; `query_df` does not. The feature columns
must match in name and order across the two. The endpoint URL and the
credential are issued to you at handover; neither is published here.

Authentication takes either a service account key file (`key_file=`) or a
bearer token issued by the operator (`token=`). Which one applies is agreed
before handover.

The integration guide covers the call arguments, the input rules, the response
metadata, what each error means, and what the client does on your behalf when a
call times out.
