Skip to content

cayu.evals.capacity

Public Cayu API. Definitions are grouped by their public source module, and definitions from private implementation modules appear on their package’s page; adding a symbol does not move existing links. The import shown at each entry is a supported public namespace. Read the Python API overview and install the required extra.

from cayu.evals import DEFAULT_EVAL_MAX_ACTIVE_TRIALS
DEFAULT_EVAL_MAX_ACTIVE_TRIALS = 100

Release source · Runtime guarantees · Capability guides

from cayu.evals import EvalExecutionCapacity

Bound aggregate active eval trials across cooperating run coordinators.

One instance is one process-local capacity domain. Applications that launch multiple evaluation runs or coordinators concurrently share the same instance. Per-run max_concurrency remains a separate, narrower dispatch control.

Capacity is intentionally operator-configurable and has no Runtime-defined upper ceiling. Concurrent use is confined to one event loop; after all active and waiting trials settle, the same object may be reused by a new loop during an application restart.

EvalExecutionCapacity.__init__(max_active_trials: int=DEFAULT_EVAL_MAX_ACTIVE_TRIALS) -> None
EvalExecutionCapacity.max_active_trials() -> int
EvalExecutionCapacity.active_trials() -> int
EvalExecutionCapacity.peak_active_trials() -> int
async EvalExecutionCapacity.slot() -> AsyncIterator[None]

Wait for one shared trial slot and release it on every exit path.

Release source · Runtime guarantees · Capability guides