@@ -389,7 +389,7 @@ public function testProcessorTagsUseFullAgentId()
389
389
['service ' => 'some_tool ' , 'description ' => 'Test tool ' ],
390
390
],
391
391
'structured_output ' => true ,
392
- 'system_prompt ' => 'You are a test assistant. ' ,
392
+ 'prompt ' => 'You are a test assistant. ' ,
393
393
],
394
394
],
395
395
],
@@ -440,14 +440,14 @@ public function testMultipleAgentsWithProcessors()
440
440
'tools ' => [
441
441
['service ' => 'tool_one ' , 'description ' => 'Tool for first agent ' ],
442
442
],
443
- 'system_prompt ' => 'First agent prompt ' ,
443
+ 'prompt ' => 'First agent prompt ' ,
444
444
],
445
445
'second_agent ' => [
446
446
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\Anthropic\Claude ' ],
447
447
'tools ' => [
448
448
['service ' => 'tool_two ' , 'description ' => 'Tool for second agent ' ],
449
449
],
450
- 'system_prompt ' => 'Second agent prompt ' ,
450
+ 'prompt ' => 'Second agent prompt ' ,
451
451
],
452
452
],
453
453
],
@@ -656,8 +656,8 @@ public function testSystemPromptWithArrayStructure()
656
656
'agent ' => [
657
657
'test_agent ' => [
658
658
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
659
- 'system_prompt ' => [
660
- 'prompt ' => 'You are a helpful assistant. ' ,
659
+ 'prompt ' => [
660
+ 'text ' => 'You are a helpful assistant. ' ,
661
661
],
662
662
'tools ' => [
663
663
['service ' => 'some_tool ' , 'description ' => 'Test tool ' ],
@@ -683,8 +683,8 @@ public function testSystemPromptWithIncludeToolsEnabled()
683
683
'agent ' => [
684
684
'test_agent ' => [
685
685
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
686
- 'system_prompt ' => [
687
- 'prompt ' => 'You are a helpful assistant. ' ,
686
+ 'prompt ' => [
687
+ 'text ' => 'You are a helpful assistant. ' ,
688
688
'include_tools ' => true ,
689
689
],
690
690
'tools ' => [
@@ -704,16 +704,16 @@ public function testSystemPromptWithIncludeToolsEnabled()
704
704
$ this ->assertSame ('ai.toolbox.test_agent ' , (string ) $ arguments [1 ]);
705
705
}
706
706
707
- #[TestDox('System prompt with only prompt key defaults include_tools to false ' )]
708
- public function testSystemPromptWithOnlyPromptKey ()
707
+ #[TestDox('System prompt with only text key defaults include_tools to false ' )]
708
+ public function testSystemPromptWithOnlyTextKey ()
709
709
{
710
710
$ container = $ this ->buildContainer ([
711
711
'ai ' => [
712
712
'agent ' => [
713
713
'test_agent ' => [
714
714
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
715
- 'system_prompt ' => [
716
- 'prompt ' => 'You are a helpful assistant. ' ,
715
+ 'prompt ' => [
716
+ 'text ' => 'You are a helpful assistant. ' ,
717
717
],
718
718
'tools ' => [
719
719
['service ' => 'some_tool ' , 'description ' => 'Test tool ' ],
@@ -756,8 +756,8 @@ public function testValidSystemPromptCreatesProcessor()
756
756
'agent ' => [
757
757
'test_agent ' => [
758
758
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
759
- 'system_prompt ' => [
760
- 'prompt ' => 'Valid prompt ' ,
759
+ 'prompt ' => [
760
+ 'text ' => 'Valid prompt ' ,
761
761
'include_tools ' => true ,
762
762
],
763
763
'tools ' => [
@@ -777,38 +777,38 @@ public function testValidSystemPromptCreatesProcessor()
777
777
$ this ->assertSame ('ai.toolbox.test_agent ' , (string ) $ arguments [1 ]);
778
778
}
779
779
780
- #[TestDox('Empty prompt in array structure throws configuration exception ' )]
781
- public function testEmptyPromptInArrayThrowsException ()
780
+ #[TestDox('Empty text in array structure throws configuration exception ' )]
781
+ public function testEmptyTextInArrayThrowsException ()
782
782
{
783
783
$ this ->expectException (InvalidConfigurationException::class);
784
- $ this ->expectExceptionMessage ('The "prompt " cannot be empty. ' );
784
+ $ this ->expectExceptionMessage ('The "text " cannot be empty. ' );
785
785
786
786
$ this ->buildContainer ([
787
787
'ai ' => [
788
788
'agent ' => [
789
789
'test_agent ' => [
790
790
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
791
- 'system_prompt ' => [
792
- 'prompt ' => '' ,
791
+ 'prompt ' => [
792
+ 'text ' => '' ,
793
793
],
794
794
],
795
795
],
796
796
],
797
797
]);
798
798
}
799
799
800
- #[TestDox('System prompt array without prompt key throws configuration exception ' )]
801
- public function testSystemPromptArrayWithoutPromptKeyThrowsException ()
800
+ #[TestDox('System prompt array without text key throws configuration exception ' )]
801
+ public function testSystemPromptArrayWithoutTextKeyThrowsException ()
802
802
{
803
803
$ this ->expectException (InvalidConfigurationException::class);
804
- $ this ->expectExceptionMessage ('The "prompt " cannot be empty. ' );
804
+ $ this ->expectExceptionMessage ('The "text " cannot be empty. ' );
805
805
806
806
$ this ->buildContainer ([
807
807
'ai ' => [
808
808
'agent ' => [
809
809
'test_agent ' => [
810
810
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
811
- 'system_prompt ' => [
811
+ 'prompt ' => [
812
812
'include_tools ' => true ,
813
813
],
814
814
],
@@ -825,7 +825,7 @@ public function testSystemPromptWithStringFormat()
825
825
'agent ' => [
826
826
'test_agent ' => [
827
827
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\OpenAi\Gpt ' ],
828
- 'system_prompt ' => 'You are a helpful assistant. ' ,
828
+ 'prompt ' => 'You are a helpful assistant. ' ,
829
829
'tools ' => [
830
830
['service ' => 'some_tool ' , 'description ' => 'Test tool ' ],
831
831
],
@@ -1270,8 +1270,8 @@ private function getFullConfig(): array
1270
1270
],
1271
1271
'structured_output ' => false ,
1272
1272
'track_token_usage ' => true ,
1273
- 'system_prompt ' => [
1274
- 'prompt ' => 'You are a helpful assistant. ' ,
1273
+ 'prompt ' => [
1274
+ 'text ' => 'You are a helpful assistant. ' ,
1275
1275
'include_tools ' => true ,
1276
1276
],
1277
1277
'tools ' => [
@@ -1285,7 +1285,7 @@ private function getFullConfig(): array
1285
1285
],
1286
1286
'another_agent ' => [
1287
1287
'model ' => ['class ' => 'Symfony\AI\Platform\Bridge\Anthropic\Claude ' , 'name ' => 'claude-3-opus-20240229 ' ],
1288
- 'system_prompt ' => 'Be concise. ' ,
1288
+ 'prompt ' => 'Be concise. ' ,
1289
1289
],
1290
1290
],
1291
1291
'store ' => [
0 commit comments