Metadata-Version: 2.5
Name: osprey-optimizer
Version: 2026.11.1
Summary: Xopt-driven machine optimization service for OSPREY
License: BSD-3-Clause
License-File: LICENSE
Requires-Python: >=3.11
Requires-Dist: osprey-connectors>=2026.11.15
Requires-Dist: pydantic>=2.12.5
Requires-Dist: pyyaml>=6.0.2
Provides-Extra: service
Requires-Dist: botorch==0.17.2; extra == 'service'
Requires-Dist: fastapi>=0.141.1; extra == 'service'
Requires-Dist: gpytorch==1.15.2; extra == 'service'
Requires-Dist: joblib>=1.5.2; extra == 'service'
Requires-Dist: numpy>=2.2.6; extra == 'service'
Requires-Dist: pandas>=2.2.3; extra == 'service'
Requires-Dist: polars>=2.0.0; extra == 'service'
Requires-Dist: python-multipart>=0.0.32; extra == 'service'
Requires-Dist: redis>=5.0.4; extra == 'service'
Requires-Dist: scikit-learn>=1.8.0; extra == 'service'
Requires-Dist: starlette; extra == 'service'
Requires-Dist: torch==2.13.0; extra == 'service'
Requires-Dist: uvicorn[standard]>=0.52.1; extra == 'service'
Requires-Dist: xopt==3.1.2; extra == 'service'
Description-Content-Type: text/markdown

# osprey-optimizer

The OSPREY optimizer service: Xopt-driven tuning runs against a control
system, with every write going through an OSPREY connector, so the write
switch, channel limits and `max_step` apply to each one. An optimization
environment is a YAML file of setpoint/readback channels and observables;
Python environments register on the `osprey.optimizer.environments`
entry-point group and are opt-in: the service loads only those named in
`OPTIMIZER_PLUGINS` (comma-separated). A plugin must reach the machine through
`ConnectorInterface`; that is not yet enforced for plugin code.

## Install

```
pip install osprey-optimizer             # models and environment files only
pip install "osprey-optimizer[service]"  # the engine and its HTTP service
```

The base install is what the OSPREY framework imports: the request, config
and status models, and the environment-file format. It does not load the
search stack. The `service` extra adds Xopt, PyTorch, BoTorch, Redis and
FastAPI, and is what the optimizer's container image installs. For a
CPU-only PyTorch, add `--extra-index-url https://download.pytorch.org/whl/cpu`.

The service app is `osprey_optimizer.api.main:app`.
