@@ -72,7 +72,7 @@ public static function create(?array $items = null): self
7272 /**
7373 * @throws \JsonException
7474 */
75- public static function createFrom (...$ files ): self
75+ public static function createFrom (string ...$ files ): self
7676 {
7777 return new self (self ::readFrom (...$ files ));
7878 }
@@ -121,7 +121,7 @@ public function putLocal(int $options = \JSON_PRETTY_PRINT | \JSON_UNESCAPED_UNI
121121 public function putFile (string $ file , int $ options = \JSON_PRETTY_PRINT | \JSON_UNESCAPED_UNICODE ): bool |int
122122 {
123123 collect ($ this ->toDotArray ())
124- ->filter (static fn ($ val ): bool => !\is_scalar ($ val ) && null !== $ val )
124+ ->filter (static fn (mixed $ val ): bool => !\is_scalar ($ val ) && null !== $ val )
125125 ->keys ()
126126 ->push (
127127 'generators.openai.parameters.prompt ' ,
@@ -169,7 +169,7 @@ public function forget(array|string $keys): void
169169 */
170170 public function jsonSerialize (): array
171171 {
172- return array_map (static function ($ value ) {
172+ return array_map (static function (mixed $ value ) {
173173 if ($ value instanceof \JsonSerializable) {
174174 return $ value ->jsonSerialize ();
175175 }
@@ -193,7 +193,7 @@ public function toDotArray(): array
193193
194194 public function toArray (): array
195195 {
196- return array_map (static fn ($ value ) => $ value instanceof Arrayable ? $ value ->toArray () : $ value , $ this ->all ());
196+ return array_map (static fn (mixed $ value ) => $ value instanceof Arrayable ? $ value ->toArray () : $ value , $ this ->all ());
197197 }
198198
199199 /**
@@ -204,15 +204,15 @@ public function toArray(): array
204204 *
205205 * @throws \JsonException
206206 */
207- public function toJson ($ options = \JSON_PRETTY_PRINT | \JSON_UNESCAPED_UNICODE ): string
207+ public function toJson (mixed $ options = \JSON_PRETTY_PRINT | \JSON_UNESCAPED_UNICODE ): string
208208 {
209209 return json_encode ($ this ->jsonSerialize (), $ options );
210210 }
211211
212212 /**
213213 * @throws \JsonException
214214 */
215- public static function readFrom (...$ files ): array
215+ public static function readFrom (string ...$ files ): array
216216 {
217217 $ configurations = array_reduce ($ files , static function (array $ configurations , string $ file ): array {
218218 $ ext = str (pathinfo ($ file , \PATHINFO_EXTENSION ));
0 commit comments