refactor: release v1.0.5 安全精简与网站发布
web-platform-ci / Standalone decision service (no cloud credentials) (push) Has been cancelled
web-platform-ci / TypeScript, lint, unit, build (push) Has been cancelled
web-platform-ci / Playwright E2E (push) Has been cancelled
lekiwi-compatibility / cpu-compatibility (push) Has been cancelled
web-platform-ci / Standalone decision service (no cloud credentials) (push) Has been cancelled
web-platform-ci / TypeScript, lint, unit, build (push) Has been cancelled
web-platform-ci / Playwright E2E (push) Has been cancelled
lekiwi-compatibility / cpu-compatibility (push) Has been cancelled
This commit is contained in:
@@ -2,7 +2,6 @@ import type {
|
||||
ObjectiveWeights,
|
||||
RewardConfiguration,
|
||||
TuningSessionState,
|
||||
TuningTrial,
|
||||
} from '../training/types';
|
||||
|
||||
export type RewardSection = keyof RewardConfiguration;
|
||||
@@ -232,12 +231,6 @@ export function mergeRewardPatch(
|
||||
};
|
||||
}
|
||||
|
||||
export function latestCompletedTrial(trials: readonly TuningTrial[]): TuningTrial | undefined {
|
||||
return [...trials]
|
||||
.reverse()
|
||||
.find((trial) => trial.state === 'completed' && trial.evaluation !== undefined);
|
||||
}
|
||||
|
||||
export function formatMetric(value: number | null | undefined, digits = 4): string {
|
||||
if (value === null || value === undefined || !Number.isFinite(value)) return '—';
|
||||
const magnitude = Math.abs(value);
|
||||
|
||||
Reference in New Issue
Block a user