chat([['role' => 'user', 'content' => 'привет']]); } catch (AiException $e) { printf(' AiException через %.1f с: %s%s', microtime(true) - $started, $e->getMessage(), PHP_EOL); } echo PHP_EOL . '2) Retry::none() — ошибка сразу' . PHP_EOL; $agent = new Agent(new AiClient(apiKey: '', model: 'any', baseUrl: $deadUrl, retry: Retry::none())); try { $agent->ask('привет'); } catch (AiException $e) { echo ' ' . $e->getMessage() . PHP_EOL; echo ' В приложении здесь показывают «модель недоступна, попробуйте позже».' . PHP_EOL; }