Metadata-Version: 2.4
Name: astrooracle
Version: 0.1.0
Summary: AstroOracle: active learning oracle for astronomical anomaly triage (SkyView cutouts + annotations + retrain hooks).
Author: AstroOracle Contributors
License: MIT
Project-URL: Homepage, https://github.com/<OWNER>/AstroOracle
Project-URL: Issues, https://github.com/<OWNER>/AstroOracle/issues
Keywords: astronomy,anomaly-detection,active-learning,skyview,astropy
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3 :: Only
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Astronomy
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.23
Requires-Dist: pandas>=2.0
Requires-Dist: matplotlib>=3.7
Requires-Dist: astropy>=5.3
Requires-Dist: astroquery>=0.4.6
Requires-Dist: scikit-learn>=1.3
Requires-Dist: pyarrow>=12.0
Requires-Dist: pillow>=10.0
Provides-Extra: notebook
Requires-Dist: ipywidgets>=8.1; extra == "notebook"
Requires-Dist: jupyterlab>=4.0; extra == "notebook"
Requires-Dist: plotly>=5.18; extra == "notebook"
Provides-Extra: plotly
Requires-Dist: plotly>=5.18; extra == "plotly"
Provides-Extra: watch
Requires-Dist: watchdog>=3.0; extra == "watch"
Provides-Extra: dev
Requires-Dist: pytest<10,>=8; extra == "dev"
Requires-Dist: pytest-cov<8,>=5; extra == "dev"
Requires-Dist: coverage[toml]<8,>=7; extra == "dev"
Requires-Dist: ruff<1.0,>=0.6; extra == "dev"
Requires-Dist: black<27,>=24; extra == "dev"
Requires-Dist: pre-commit<5,>=3.7; extra == "dev"
Requires-Dist: mypy<2,>=1.10; extra == "dev"
Requires-Dist: types-requests>=2.32.0.20240914; extra == "dev"
Requires-Dist: build<2,>=1.2; extra == "dev"
Requires-Dist: twine<7,>=5; extra == "dev"
Requires-Dist: nox>=2024.4.15; extra == "dev"
Dynamic: license-file

# AstroOracle

AstroOracle is an active learning “oracle” for astronomical anomaly triage.

- Reads candidate detections from a Parquet file.
- Ranks them by uncertainty + optional embedding diversity.
- Pulls multi-survey cutouts from SkyView.
- Annotates via CLI (matplotlib) or Jupyter (ipywidgets + Plotly).
- Logs events in append-only JSONL.
- Optionally triggers retraining.

## Install (editable)

```bash
python -m venv .venv
source .venv/bin/activate
pip install -U pip
pip install -e ".[plotly,watch,notebook]"
```

## Quickstart (CLI)

Generate sample candidates:

```bash
python examples/sample_candidates.py
```

Run oracle:

```bash
astrooracle run --candidates candidates.parquet --interval 300 --n-query 6
```

Headless + PNG export:

```bash
astrooracle run --no-gui --save-cutouts cutouts/ --candidates candidates.parquet
```

## Jupyter UI

```bash
jupyter lab
```

Open `examples/oracle_notebook.ipynb`.

## Watch mode (watchdog)

```bash
astrooracle watch --candidates candidates.parquet
```

## Batch HTML export

```bash
astrooracle batch-html --candidates candidates.parquet --out-dir batch_out/ --n-query 60
```

Open `batch_out/index.html` and export annotations from the page.

## License

MIT
