()
| 438 | * so a flag served as null/string/NaN leaks through. |
| 439 | */ |
| 440 | export function getPerMessageBudgetLimit(): number { |
| 441 | const override = getFeatureValue_CACHED_MAY_BE_STALE<number | null>( |
| 442 | 'ncode_hawthorn_window', |
| 443 | null, |
| 444 | ) |
| 445 | if ( |
| 446 | typeof override === 'number' && |
| 447 | Number.isFinite(override) && |
| 448 | override > 0 |
| 449 | ) { |
| 450 | return override |
| 451 | } |
| 452 | return MAX_TOOL_RESULTS_PER_MESSAGE_CHARS |
| 453 | } |
| 454 | |
| 455 | /** |
| 456 | * Provision replacement state for a new conversation thread. |
no test coverage detected