Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions src/shared/generated/governor/CascadeAction.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.

/**
* Decision the cascade evaluator emits per signal. PR-3c2 wires
* these into the local governor's `on_pressure_signal` to actually
* rewrite the policy.
*/
export type CascadeAction = { "kind": "hold" } | { "kind": "advance" } | { "kind": "retreat" } | { "kind": "emergencyAdvanceToMax" };
24 changes: 24 additions & 0 deletions src/shared/generated/governor/CascadeThresholds.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
import type { ThermalSeverity } from "./ThermalSeverity";

/**
* Tuneable thresholds for the cascade. Loaded from policy file in
* PR-3c2 (extends PolicyFile). For PR-3c1, callers pass typed values
* so the evaluator is testable with any threshold set.
*
* Pinned to the values from the spec's §"Adjustment Cascade" table;
* callers may override per-policy (the spec's table is the default
* for the M-Air anchor + 5090 anchor).
*/
export type CascadeThresholds = { specMissRateAdvance: number, specMissRateRetreat: number, inferenceQueueDepthAdvance: number, inferenceQueueDepthRetreat: number, vramUsedPctAdvance: number, vramUsedPctRetreat: number, systemMemUsedPctAdvance: number, systemMemUsedPctRetreat: number,
/**
* Thermal severity at or above which step 2 enters. Step 2's
* other enter conditions are step 1 sustained + mem high.
*/
thermalAdvance: ThermalSeverity, batteryPctAdvance: number, batteryPctRetreat: number,
/**
* Battery percentage that triggers EmergencyAdvanceToMax. Below
* this, the cascade jumps straight to MAX regardless of current
* step. Default 10% per spec.
*/
batteryPctEmergency: number, };
2 changes: 2 additions & 0 deletions src/shared/generated/governor/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
// Re-generate: cargo test --lib --features metal,accelerate governor::

export type { CadenceMultipliers } from './CadenceMultipliers';
export type { CascadeAction } from './CascadeAction';
export type { CascadeThresholds } from './CascadeThresholds';
export type { ConcurrencyCaps } from './ConcurrencyCaps';
export type { ConsolidationSchedule } from './ConsolidationSchedule';
export type { FederationCadence } from './FederationCadence';
Expand Down
Loading
Loading