dragon.ai.inference.config.DynamicWorkerConfig

class DynamicWorkerConfig[source]

Bases: object

Dynamic inference worker spin-up/down configuration.

__init__(enabled: bool = True, min_active_workers_per_cpu: int = 1, spin_down_threshold_seconds: int = 3600, spin_up_threshold_seconds: int = 3, spin_up_prompt_threshold: int = 5) None

Methods

__init__([enabled, ...])

validate()

Validate dynamic worker configuration.

Attributes

enabled

min_active_workers_per_cpu

spin_down_threshold_seconds

spin_up_prompt_threshold

spin_up_threshold_seconds

enabled: bool = True
min_active_workers_per_cpu: int = 1
spin_down_threshold_seconds: int = 3600
spin_up_threshold_seconds: int = 3
spin_up_prompt_threshold: int = 5
validate() None [source]

Validate dynamic worker configuration.

__init__(enabled: bool = True, min_active_workers_per_cpu: int = 1, spin_down_threshold_seconds: int = 3600, spin_up_threshold_seconds: int = 3, spin_up_prompt_threshold: int = 5) None