Skip to content

Commit c91b7d7

Browse files
committed
bug #1117 [AI Bundle] Added Azure OpenAI ModelCatalog to service definition to the Azure Platform (TimoBakx)
This PR was merged into the main branch. Discussion ---------- [AI Bundle] Added Azure OpenAI ModelCatalog to service definition to the Azure Platform | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | Docs? | no <!-- required for new features --> | Issues | Fix #1116 <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead --> | License | MIT Added DI configuration to use the Azure/OpenAI ModelCatalog for the Azure Platform Factory instead of the OpenAI ModelCatalog. Commits ------- c52e289 Added Azure OpenAI ModelCatalog in wiring
2 parents 0982329 + c52e289 commit c91b7d7

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/ai-bundle/config/services.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
use Symfony\AI\Platform\Bridge\Anthropic\Contract\AnthropicContract;
3030
use Symfony\AI\Platform\Bridge\Anthropic\ModelCatalog as AnthropicModelCatalog;
3131
use Symfony\AI\Platform\Bridge\Anthropic\TokenOutputProcessor as AnthropicTokenOutputProcessor;
32+
use Symfony\AI\Platform\Bridge\Azure\OpenAi\ModelCatalog as AzureOpenAiModelCatalog;
3233
use Symfony\AI\Platform\Bridge\Cartesia\ModelCatalog as CartesiaModelCatalog;
3334
use Symfony\AI\Platform\Bridge\Cerebras\ModelCatalog as CerebrasModelCatalog;
3435
use Symfony\AI\Platform\Bridge\Decart\ModelCatalog as DecartModelCatalog;
@@ -95,6 +96,7 @@
9596
->set('ai.platform.model_catalog.aimlapi', AiMlApiModelCatalog::class)
9697
->set('ai.platform.model_catalog.albert', AlbertModelCatalog::class)
9798
->set('ai.platform.model_catalog.anthropic', AnthropicModelCatalog::class)
99+
->set('ai.platform.model_catalog.azure.openai', AzureOpenAiModelCatalog::class)
98100
->set('ai.platform.model_catalog.cartesia', CartesiaModelCatalog::class)
99101
->set('ai.platform.model_catalog.cerebras', CerebrasModelCatalog::class)
100102
->set('ai.platform.model_catalog.decart', DecartModelCatalog::class)

src/ai-bundle/src/AiBundle.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ private function processPlatformConfig(string $type, array $platform, ContainerB
383383
$config['api_version'],
384384
$config['api_key'],
385385
new Reference($config['http_client'], ContainerInterface::NULL_ON_INVALID_REFERENCE),
386-
new Reference('ai.platform.model_catalog.openai'),
386+
new Reference('ai.platform.model_catalog.azure.openai'),
387387
new Reference('ai.platform.contract.openai'),
388388
new Reference('event_dispatcher'),
389389
])

0 commit comments

Comments
 (0)