File tree 1 file changed +5
-5
lines changed
1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -61,13 +61,13 @@ public function generate(
61
61
$ request ['messages ' ][] = $ this ->messageMapper ->map ($ message );
62
62
}
63
63
64
- if ($ options ->has (Option::Tools)) {
64
+ if ($ options ->has (Option::Tools-> value )) {
65
65
$ request = $ this ->configureTools ($ options , $ request );
66
66
}
67
67
68
68
$ callback = null ;
69
- if ($ options ->has (Option::StreamChunkCallback)) {
70
- $ callback = $ options ->get (Option::StreamChunkCallback);
69
+ if ($ options ->has (Option::StreamChunkCallback-> value )) {
70
+ $ callback = $ options ->get (Option::StreamChunkCallback-> value );
71
71
\assert ($ callback instanceof StreamChunkCallbackInterface);
72
72
}
73
73
@@ -108,12 +108,12 @@ protected function buildOptions(OptionsInterface $options): array
108
108
return \array_filter ($ result , static fn ($ value ): bool => $ value !== null );
109
109
}
110
110
111
- protected function configureTools (Options $ options , array $ request ): array
111
+ protected function configureTools (OptionsInterface $ options , array $ request ): array
112
112
{
113
113
$ tools = \array_values (
114
114
\array_map (
115
115
fn (Tool $ tool ): array => $ this ->messageMapper ->map ($ tool ),
116
- $ options ->get (Option::Tools),
116
+ $ options ->get (Option::Tools-> value ),
117
117
),
118
118
);
119
119
You can’t perform that action at this time.
0 commit comments