File tree Expand file tree Collapse file tree 3 files changed +4
-6
lines changed
Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -48,7 +48,7 @@ public function submit(UserMessage $message): AssistantMessage|AccumulatingStrea
4848
4949 if ($ result instanceof StreamResult || $ result instanceof ToolboxStreamResult) {
5050 if (!$ this ->store instanceof StreamableStoreInterface) {
51- throw new RuntimeException ($ this ->store ::class . ' does not support streaming. ' );
51+ throw new RuntimeException ($ this ->store ::class. ' does not support streaming. ' );
5252 }
5353
5454 return new AccumulatingStreamResult ($ result , function (AssistantMessage $ assistantMessage ) use ($ messages ) {
Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ public function addOnComplete(\Closure $callback): void
4141 $ existingCallback ($ message );
4242 $ callback ($ message );
4343 }
44- : $ callback ;
44+ : $ callback ;
4545 }
4646
4747 public function getContent (): \Generator
@@ -61,9 +61,9 @@ public function getContent(): \Generator
6161 yield $ value ;
6262 }
6363 } finally {
64- if ($ this -> onComplete !== null ) {
64+ if (null !== $ this -> onComplete ) {
6565 $ assistantMessage = Message::ofAssistant (
66- $ accumulatedContent === '' ? null : $ accumulatedContent ,
66+ '' === $ accumulatedContent ? null : $ accumulatedContent ,
6767 $ toolCalls ?: null
6868 );
6969
@@ -79,4 +79,3 @@ public function getMetadata(): Metadata
7979 return $ this ->innerResult ->getMetadata ();
8080 }
8181}
82-
Original file line number Diff line number Diff line change 1717interface StreamableStoreInterface
1818{
1919}
20-
You can’t perform that action at this time.
0 commit comments