The only place where $catalog->getModels() is executed is in the SymfonyAiCompilerPass Class during Dependency Injection in the method buildBridgeDefinition. It handles the missing list (no apiKey at this point) gracefully and adds the provider to the list of providers. The set Flag $catalogIsDynamic is not passed to the configuration though.
Additionally at no point the model List is re-evaluated once an apiKey is set.
The Problem in itself manifests in the Model [model] drop-down when creating an AI Provider Configuration (tx_aim_configuration), which is never populated in this case.
Additionally the models capabilities are never re-evaluated as well.
I don't see a good solution for this problem as long as the models are evaluated during DependencyInjection, and not during runtime with all configurations available. It probably needs to move into the runtime and be cached via the cachingframework..
Maybe if the catalogIsDynamic flag could be passed to the provider/bridge configuration during the DependencyInjection, to be checked at a later point..
I see this as a problem going forward especially in the DACH region as most of my customers choose to host AI themselves or buy the service from 3rd party hosters in the region, which will only provide an apiKey and potentially a static list of models.
The only place where
$catalog->getModels()is executed is in theSymfonyAiCompilerPassClass during Dependency Injection in the methodbuildBridgeDefinition. It handles the missing list (no apiKey at this point) gracefully and adds the provider to the list of providers. The set Flag$catalogIsDynamicis not passed to the configuration though.Additionally at no point the model List is re-evaluated once an apiKey is set.
The Problem in itself manifests in the Model [model] drop-down when creating an AI Provider Configuration (tx_aim_configuration), which is never populated in this case.
Additionally the models capabilities are never re-evaluated as well.
I don't see a good solution for this problem as long as the models are evaluated during DependencyInjection, and not during runtime with all configurations available. It probably needs to move into the runtime and be cached via the cachingframework..
Maybe if the
catalogIsDynamicflag could be passed to the provider/bridge configuration during the DependencyInjection, to be checked at a later point..I see this as a problem going forward especially in the DACH region as most of my customers choose to host AI themselves or buy the service from 3rd party hosters in the region, which will only provide an apiKey and potentially a static list of models.