Metadata-Version: 2.4
Name: exhibit-cli
Version: 0.1.1
Summary: AI-powered data analysis CLI that treats analysis as a persistent, resumable investigation.
Author-email: Zimehr Abbasi <zimehrabbasigh@gmail.com>
License: Business Source License 1.1
Project-URL: Homepage, https://github.com/ziwalker/exhibit-cli
Project-URL: Repository, https://github.com/ziwalker/exhibit-cli
Project-URL: Issues, https://github.com/ziwalker/exhibit-cli/issues
Keywords: data-analysis,cli,duckdb,llm,sql,analytics,claude,investigation
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: Other/Proprietary License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
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: Topic :: Scientific/Engineering :: Information Analysis
Classifier: Topic :: Database :: Front-Ends
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: typer>=0.12
Requires-Dist: rich>=13.7
Requires-Dist: duckdb>=1.0
Requires-Dist: pydantic>=2.7
Requires-Dist: sqlglot>=25.0
Requires-Dist: matplotlib>=3.8
Requires-Dist: plotext>=5.2
Requires-Dist: numpy>=1.24
Requires-Dist: scipy>=1.10
Requires-Dist: anthropic>=0.69
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Dynamic: license-file

# Exhibit

[![PyPI](https://img.shields.io/pypi/v/exhibit-cli)](https://pypi.org/project/exhibit-cli/) [![Python](https://img.shields.io/pypi/pyversions/exhibit-cli)](https://pypi.org/project/exhibit-cli/) [![CI](https://github.com/ziwalker/exhibit-cli/actions/workflows/ci.yml/badge.svg)](https://github.com/ziwalker/exhibit-cli/actions/workflows/ci.yml) [![License: BSL 1.1](https://img.shields.io/badge/license-BSL--1.1-blue)](https://github.com/ziwalker/exhibit-cli/blob/main/LICENSE)

Exhibit is a data-analysis CLI that **shows its work** — every analysis is a
persistent, replayable *investigation*: an append-only graph of typed steps
(question → plan → read-only SQL → result → evidence-backed conclusion), not a
chat transcript. Load a CSV/Parquet file (or snapshot a Postgres table), ask in
plain English, and get an inspectable, replayable, exportable trail.

**Read-only by construction.** Data is loaded once into a per-investigation
DuckDB opened read-only with external access disabled; every generated query is
parsed by a static guard that permits a single `SELECT` and blocks writes,
`ATTACH`, `COPY`, and file access. See
[THREAT_MODEL.md](https://github.com/ziwalker/exhibit-cli/blob/main/THREAT_MODEL.md).

## Install

```bash
pip install exhibit-cli
export ANTHROPIC_API_KEY=...        # for Claude; or run fully offline with --llm mock
```

## Use

```bash
exhibit start data.csv                                   # one file
exhibit start orders.csv customers.csv                   # several (joins across them)
exhibit start postgresql://user@host/db --tables orders  # live Postgres (read-only snapshot)
```

Then ask questions in plain English. Inside an investigation:

- `/judge` — adversarial self-review (weak claims, missing evidence, untested alternatives)
- `/branch <id> <question>` — fork a question off an earlier step
- `/rerun <id>` — deterministically replay a stored query or a whole plan (no LLM)
- `/cost` — token usage + cost for the session, including prompt-cache savings
- `/export [html]` — Markdown, or a self-contained HTML report
- `/help` — everything else

Resume anytime with `exhibit open <id>`.

## License

Source-available under the
[Business Source License 1.1](https://github.com/ziwalker/exhibit-cli/blob/main/LICENSE):
read the source and use it freely in production, but don't offer a competing
commercial or hosted data-analysis product. Converts to Apache-2.0 on 2030-07-31.
Not an OSI open-source license.
