From 65ba766029be959a4a06747c22abb196717f9000 Mon Sep 17 00:00:00 2001 From: Christopher Hertel Date: Sun, 8 Dec 2024 01:45:10 +0100 Subject: [PATCH] fix: expose version for anthropic via platform factory as well (#154) --- src/Bridge/Anthropic/PlatformFactory.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Bridge/Anthropic/PlatformFactory.php b/src/Bridge/Anthropic/PlatformFactory.php index 38e7686..d22f3bc 100644 --- a/src/Bridge/Anthropic/PlatformFactory.php +++ b/src/Bridge/Anthropic/PlatformFactory.php @@ -9,9 +9,9 @@ final readonly class PlatformFactory { - public static function create(#[\SensitiveParameter] string $apiKey): Platform + public static function create(#[\SensitiveParameter] string $apiKey, string $version = '2023-06-01'): Platform { - $responseHandler = new ModelHandler(new EventSourceHttpClient(), $apiKey); + $responseHandler = new ModelHandler(new EventSourceHttpClient(), $apiKey, $version); return new Platform([$responseHandler], [$responseHandler]); }