| 1254 | const data = await response.json(); | 1254 | const data = await response.json(); |
| 1255 | if (data) { | 1255 | if (data) { |
| 1256 | const { chat_template, chat_template_hash } = data; | 1256 | const { chat_template, chat_template_hash } = data; |
| 1257 | if (wantsContextSize && "default_generation_settings" in data) { | 1257 | if (wantsContextSize && 'default_generation_settings' in data) { |
| 1258 | const backend_max_context = data["default_generation_settings"]["n_ctx"]; | 1258 | const backend_max_context = data['default_generation_settings']['n_ctx']; |
| 1259 | const old_value = max_context; | 1259 | const old_value = max_context; |
| 1260 | if (max_context !== backend_max_context) { | 1260 | if (max_context !== backend_max_context) { |
| 1261 | setGenerationParamsFromPreset({ max_length: backend_max_context }, true); | 1261 | setGenerationParamsFromPreset({ max_length: backend_max_context }, true); |