File tree Expand file tree Collapse file tree 2 files changed +16
-12
lines changed
src/platform/src/Bridge/OpenAi Expand file tree Collapse file tree 2 files changed +16
-12
lines changed Original file line number Diff line number Diff line change 1616
1717require_once dirname (__DIR__ ).'/bootstrap.php ' ;
1818
19- $ platform = PlatformFactory::create (env ('OPENAI_API_KEY ' ), http_client ());
20-
21- $ messages = new MessageBag (
22- Message::ofUser (
23- 'What is this recording about? ' ,
24- Audio::fromFile (dirname (__DIR__ , 2 ).'/fixtures/audio.mp3 ' ),
25- ),
26- );
27- $ result = $ platform ->invoke ('gpt-4o-audio-preview ' , $ messages );
28-
29- echo $ result ->asText ().\PHP_EOL ;
19+ throw new RuntimeException ('This example is temporarily unavailable due to migration to Responses API (which does not support audio yet) ' );
20+ // $platform = PlatformFactory::create(env('OPENAI_API_KEY'), http_client());
21+ //
22+ // $messages = new MessageBag(
23+ // Message::ofUser(
24+ // 'What is this recording about?',
25+ // Audio::fromFile(dirname(__DIR__, 2).'/fixtures/audio.mp3'),
26+ // ),
27+ // );
28+ // $result = $platform->invoke('gpt-4o-audio-preview', $messages);
29+ //
30+ // echo $result->asText().\PHP_EOL;
Original file line number Diff line number Diff line change @@ -91,7 +91,6 @@ public function __construct(array $additionalModels = [])
9191 Capability::OUTPUT_TEXT ,
9292 Capability::OUTPUT_STREAMING ,
9393 Capability::TOOL_CALLING ,
94- Capability::INPUT_AUDIO ,
9594 Capability::INPUT_IMAGE ,
9695 Capability::OUTPUT_STRUCTURED ,
9796 ],
@@ -114,6 +113,10 @@ public function __construct(array $additionalModels = [])
114113 Capability::OUTPUT_STREAMING ,
115114 Capability::TOOL_CALLING ,
116115 Capability::INPUT_IMAGE ,
116+ // Audio is unsupported temporarily due to migration to Responses API;
117+ // Capability will be reintroduced when Responses API supports audio ("coming soon")
118+ // See: https://platform.openai.com/docs/guides/migrate-to-responses#responses-benefits
119+ // Capability::INPUT_AUDIO,
117120 ],
118121 ],
119122 'o3-mini ' => [
You can’t perform that action at this time.
0 commit comments