40 lines
926 B
TypeScript
40 lines
926 B
TypeScript
// Metro module 4768 (f4769).
|
|
import { createApexExperiment } from "../../experiments/apex/index";
|
|
const apexExperiment = createApexExperiment({
|
|
name: "2026-04-kestrel",
|
|
kind: "user",
|
|
defaultConfig: {
|
|
enabled: false,
|
|
threshold: 0
|
|
},
|
|
variations: {
|
|
0: {
|
|
enabled: false,
|
|
threshold: 0
|
|
},
|
|
1: {
|
|
enabled: true,
|
|
threshold: 15
|
|
},
|
|
2: {
|
|
enabled: true,
|
|
threshold: 20
|
|
},
|
|
3: {
|
|
enabled: true,
|
|
threshold: 25
|
|
}
|
|
}
|
|
});
|
|
export function getKestrelConfig(a0) {
|
|
return apexExperiment.getConfig({
|
|
location: a0.location
|
|
});
|
|
}
|
|
export function getEffectiveKestrelLimit(a0, a1) {
|
|
return a0.enabled ? Math.max(1048576 * a0.threshold, a1) : a1;
|
|
}
|
|
export function getKestrelVariantName(a0) {
|
|
return a0.enabled ? a0.threshold !== 15 ? a0.threshold !== 20 ? a0.threshold === 25 ? "kestrel_c" : "unknown" : "kestrel_b" : "kestrel_a" : "control";
|
|
}
|