Metadata-Version: 2.4
Name: toqan-ds
Version: 0.0.1
Summary: Toqan DS — the open-source autonomous data scientist for relational databases (zero-LLM DuckDB DFS + provider-agnostic Autonomous Relational Data Scientist).
Author: Toqan DS Contributors
License: Apache-2.0
Project-URL: Homepage, https://github.com/prosusai/toqan-ds
Project-URL: Issues, https://github.com/prosusai/toqan-ds/issues
Keywords: autonomous-data-scientist,tabular,relational-learning,feature-engineering,deep-feature-synthesis,duckdb,sql-agent,temporal-leakage,lightgbm
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: Apache Software License
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 :: Artificial Intelligence
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
License-File: NOTICE
Requires-Dist: duckdb>=1.0.0
Requires-Dist: numpy>=1.24
Requires-Dist: pandas>=2.0
Requires-Dist: scikit-learn>=1.3
Requires-Dist: scipy>=1.10
Provides-Extra: lgbm
Requires-Dist: lightgbm>=4.0; extra == "lgbm"
Provides-Extra: agent
Requires-Dist: httpx>=0.25; extra == "agent"
Requires-Dist: lightgbm>=4.0; extra == "agent"
Provides-Extra: litellm
Requires-Dist: litellm>=1.40; extra == "litellm"
Requires-Dist: httpx>=0.25; extra == "litellm"
Requires-Dist: lightgbm>=4.0; extra == "litellm"
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Requires-Dist: ruff>=0.6; extra == "dev"
Requires-Dist: httpx>=0.25; extra == "dev"
Requires-Dist: lightgbm>=4.0; extra == "dev"
Dynamic: license-file

<p align="center">
  <img src="docs/assets/hero.svg" alt="toqan-ds — The Autonomous Data Scientist for Relational Databases" width="100%" />
</p>

<p align="center">
  <a href="pyproject.toml"><img src="https://img.shields.io/badge/Python-3.10%2B-252BDD?style=flat-square&labelColor=211D1D&logo=python&logoColor=white" alt="Python 3.10+" /></a>
  <a href="src/toqan_ds/dfs.py"><img src="https://img.shields.io/badge/Engine-DuckDB-895B00?style=flat-square&labelColor=211D1D&logo=duckdb&logoColor=white" alt="DuckDB" /></a>
  <a href="src/toqan_ds/sql_agent/llm.py"><img src="https://img.shields.io/badge/LLM-Any_API_Key_or_$0-C20000?style=flat-square&labelColor=211D1D&logoColor=white" alt="Any LLM API Key" /></a>
  <a href="tests/"><img src="https://img.shields.io/badge/Tests-22%2F22_Passing-007118?style=flat-square&labelColor=211D1D&logoColor=white" alt="Tests 22/22" /></a>
  <a href="LICENSE"><img src="https://img.shields.io/badge/License-Apache_2.0-6E4A0A?style=flat-square&labelColor=211D1D&logoColor=white" alt="License: Apache-2.0" /></a>
</p>

<p align="center">
  <a href="#quickstart">Quickstart</a> ·
  <a href="#architecture">Architecture</a> ·
  <a href="#roadmap">Roadmap</a> ·
  <a href="#licensing-notice">Licensing</a>
</p>

**`toqan-ds`** is an autonomous data scientist for relational databases. Powered by DuckDB, it connects to your multi-table schemas, enforces strict point-in-time (`event_time < cutoff`) hygiene across 6 automated leakage gates, and routes clean feature tables into **any downstream model** (Tabular Foundation Models / Prior-Fitted Networks, AutoML, GBDTs, or Decision Models).

## Architecture

<p align="center">
  <img src="docs/assets/architecture.svg" alt="toqan-ds Architecture — Database-to-Any-Model Router" width="100%" />
</p>

## Quickstart

```bash
# Option 1: Install directly from GitHub
pip install "git+https://github.com/prosusai/toqan-ds.git@main"

# Option 2: Clone & editable install (with LightGBM extra)
git clone https://github.com/prosusai/toqan-ds.git && cd toqan-ds && pip install -e ".[lgbm]"
```

```python
from toqan_ds import DataScientist

ds = DataScientist(task_kind="binary", verify_leakage=True)  # $0 zero-key DuckDB DFS
ds.fit(train_df, {"customers": customers, "orders": orders}, target_column="churn",
       cutoff_column="cutoff", time_columns={"orders": "order_time"}, key_columns=["customer_id"])
preds = ds.predict(test_df, {"customers": customers, "orders": orders})
```

> **Provider-agnostic by design:** Run at `$0` with zero keys, or pass any LLM API key with `llm="<your-model>"` (OpenAI, Anthropic, Google Gemini, Ollama / local OpenAI-compatible endpoints, or `provider="litellm"`). Try the `< 3s` offline synthetic demo: `python examples/quickstart_multitable.py`.

> **Privacy:** `toqan-ds` runs locally and sends no data or usage information to Prosus. When you enable the optional LLM agent, requests are sent only to your configured provider endpoint using your own API key and are subject to that provider's terms.

You can also run the standalone point-in-time leak canary (`verify_no_future_leakage(...)`) against *any* custom SQL, dbt, or Python feature pipeline.

## Roadmap

<p align="center">
  <img src="docs/assets/roadmap.svg" alt="toqan-ds Roadmap — v0.0.1 Shipped to v0.4+ Vision" width="100%" />
</p>

Reproducible multi-table benchmark suites and native tabular foundation model connectors will follow in subsequent releases. See **[`ROADMAP.md`](ROADMAP.md)** for detailed milestones and 100M+ row scaling plans, and **[`CITATIONS.md`](CITATIONS.md)** for academic references.

## Licensing notice

**Effective date:** 3 December 2026

**What the Apache-2.0 licence covers.** The Apache License 2.0 in this repository applies **only** to the toqan-ds source code, tests, scripts and documentation that MIH AI B.V. owns. It does **not** cover:
- **Third-party software.** Libraries such as DuckDB, pandas, scikit-learn and others are installed by you from public package indexes. They are not bundled with or distributed by toqan-ds, and each remains under its own licence. See [third-party-notices.md](third-party-notices.md).
- **Third-party models and weights.** toqan-ds does not include model weights. Any third-party pretrained models or weights you choose to connect or download at runtime are governed solely by their own licences, and you are responsible for complying with them (including any non-commercial restrictions).
- **Datasets.** This repository contains code, tests, and a synthetic offline demo only; no third-party datasets are included. Any external datasets you use with toqan-ds remain subject to their own terms.

**Licensor.** The code in this repository is licensed by MIH AI B.V. under the Apache License, Version 2.0.

**Third-party notices.** The SciPy wheel from PyPI contains libgfortran (GPL-3.0-or-later with the GCC Runtime Library Exception) and libquadmath (LGPL-2.1-or-later), which are loaded and not distributed by toqan-ds. GPU installs of optional PyTorch-based downstream libraries pull NVIDIA CUDA libraries that NVIDIA licenses under its own terms. If you redistribute toqan-ds together with any third-party package, you are responsible for complying with that package's licence.

**Trademarks.** "Toqan" is a trademark of MIH AI B.V. or its affiliates. No trademark rights are granted by the Apache License 2.0 or by this project.

**No warranty.** The software is provided "AS IS", without warranty of any kind. See the [LICENSE](LICENSE).

## Contributing

Contributions are welcome. By submitting a contribution you agree that it is licensed under the Apache License 2.0 (see Section 5 of that licence). See [CONTRIBUTING.md](CONTRIBUTING.md) for how to contribute.

Please report security issues privately as described in [SECURITY.md](SECURITY.md).

## Copyright

Copyright (c) 2026 MIH AI B.V. Licensed under the Apache License, Version 2.0.
