Skip to content
This repository was archived by the owner on Jul 16, 2025. It is now read-only.

Commit ac666de

Browse files
authored
feat: register processor interfaces for autoconfiguration (#40)
1 parent 8cfacf6 commit ac666de

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/DependencyInjection/LlmChainExtension.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55
namespace PhpLlm\LlmChainBundle\DependencyInjection;
66

7+
use PhpLlm\LlmChain\Chain\InputProcessor;
8+
use PhpLlm\LlmChain\Chain\OutputProcessor;
79
use PhpLlm\LlmChain\EmbeddingsModel;
810
use PhpLlm\LlmChain\LanguageModel;
911
use PhpLlm\LlmChain\OpenAI\Model\Embeddings;
@@ -76,6 +78,11 @@ public function load(array $configs, ContainerBuilder $container): void
7678
]);
7779
});
7880

81+
$container->registerForAutoconfiguration(InputProcessor::class)
82+
->addTag('llm_chain.chain.input_processor');
83+
$container->registerForAutoconfiguration(OutputProcessor::class)
84+
->addTag('llm_chain.chain.output_processor');
85+
7986
if (false === $container->getParameter('kernel.debug')) {
8087
$container->removeDefinition(DataCollector::class);
8188
$container->removeDefinition(TraceableToolBox::class);

0 commit comments

Comments
 (0)