Skip to content

Commit e7ac407

Browse files
committed
fix
1 parent 46e2c37 commit e7ac407

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/ai-bundle/src/AiBundle.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@
5656
use Symfony\AI\Store\StoreInterface;
5757
use Symfony\AI\Store\VectorStoreInterface;
5858
use Symfony\Component\Config\Definition\Configurator\DefinitionConfigurator;
59+
use Symfony\Component\DependencyInjection\Attribute\Target;
5960
use Symfony\Component\DependencyInjection\ChildDefinition;
6061
use Symfony\Component\DependencyInjection\ContainerBuilder;
6162
use Symfony\Component\DependencyInjection\ContainerInterface;
@@ -457,7 +458,7 @@ private function processAgentConfig(string $name, array $config, ContainerBuilde
457458
;
458459

459460
$container->setDefinition('ai.agent.'.$name, $agentDefinition);
460-
$container->registerAliasForArgument('ai.agent.'.$name, AgentInterface::class, $name.'Agent');
461+
$container->registerAliasForArgument('ai.agent.'.$name, AgentInterface::class, (new Target($name.'Agent'))->getParsedName());
461462
}
462463

463464
/**

0 commit comments

Comments
 (0)