|
1 | 1 | /** |
2 | 2 | * Cheap-model purpose titles for tool calls shown in the Control UI. |
3 | 3 | * |
4 | | - * Model selection delegates to the canonical utility-model resolver: the |
5 | | - * configured utilityModel, else the primary provider's declared small-model |
6 | | - * default (same provider as the session, so no new egress destination), and |
7 | | - * an explicit empty utilityModel disables titles entirely. Titles never fall |
8 | | - * through to the (potentially expensive) primary model — callers get an empty |
9 | | - * result and keep deterministic labels. |
| 4 | + * Model selection delegates to the canonical utility-model resolver and |
| 5 | + * follows the platform-wide utilityModel contract: an explicit utilityModel |
| 6 | + * is an operator decision and may name any provider (exactly like session |
| 7 | + * titles, thread titles, and narration, which already send bounded session |
| 8 | + * content there); the AUTO-derived small-model default stays on the session's |
| 9 | + * own provider so no silent new egress destination appears; and an explicit |
| 10 | + * empty utilityModel disables titles entirely. Titles never fall through to |
| 11 | + * the (potentially expensive) primary model — callers get an empty result and |
| 12 | + * keep deterministic labels. |
10 | 13 | * |
11 | 14 | * Generated titles cache in the per-agent SQLite database (`cache_entries`, |
12 | 15 | * scope below) keyed by a digest of tool name + input, so reopening a session |
@@ -295,10 +298,11 @@ export async function generateToolCallTitles(params: { |
295 | 298 | } |
296 | 299 | // Canonical utility routing decides eligibility BEFORE cache reads: cached |
297 | 300 | // titles must not outlive a later `utilityModel: ""` opt-out while the |
298 | | - // controlUi toggle stays on. Explicit utilityModel, else the small-model |
299 | | - // default declared by the SESSION's effective provider (per-session model |
300 | | - // overrides included), so titles stay on the provider the session already |
301 | | - // talks to; never the primary model itself. |
| 301 | + // controlUi toggle stays on. An explicit utilityModel is an operator |
| 302 | + // decision and may be cross-provider (the documented utility-task contract |
| 303 | + // shared with session/thread titles and narration); only the AUTO-derived |
| 304 | + // default is pinned to the SESSION's effective provider (per-session model |
| 305 | + // overrides included). Never the primary model itself. |
302 | 306 | const resolvedRef = resolveUtilityModelRefForAgent({ |
303 | 307 | cfg: params.cfg, |
304 | 308 | agentId: params.agentId, |
|
0 commit comments