diff --git a/src/lib/ai/ai-budgets.ts b/src/lib/ai/ai-budgets.ts index 29be245cb..df64ee566 100644 --- a/src/lib/ai/ai-budgets.ts +++ b/src/lib/ai/ai-budgets.ts @@ -19,8 +19,11 @@ export interface AiBudget { /** Sampling temperature. Low for reference surfaces, slightly higher for chat. */ temperature: number; - /** Output-token ceiling. Sized to the surface's documented output contract. */ - maxTokens: number; + /** + * Output-token ceiling. Sized to the surface's documented output contract. + * Optional for surfaces whose caller pins its own token const (self-context). + */ + maxTokens?: number; } /** @@ -94,4 +97,4 @@ export const AI_BUDGETS = { * questions. Temperature only; the caller pins its own token const. */ selfContext: { temperature: 0.4 }, -} as const satisfies Record; +} as const satisfies Record; diff --git a/src/lib/ai/prompts/status-batch.ts b/src/lib/ai/prompts/status-batch.ts index 21e3d65d5..8773188b3 100644 --- a/src/lib/ai/prompts/status-batch.ts +++ b/src/lib/ai/prompts/status-batch.ts @@ -36,15 +36,6 @@ export const STATUS_BATCH_KEY_BY_METRIC: Record = { general: "general", }; -/** Reverse of `STATUS_BATCH_KEY_BY_METRIC` — output key → InsightStatus scope. */ -export const STATUS_BATCH_METRIC_BY_KEY: Record = - Object.fromEntries( - Object.entries(STATUS_BATCH_KEY_BY_METRIC).map(([metric, key]) => [ - key, - metric, - ]), - ); - /** * Compose the batch system prompt: the shared assessment scaffold plus the * `{ perMetric }` output instruction. `presentKeys` are the output keys for