You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Parse error: syntax error, unexpected token "array", expecting variable in /var/www/html/elkchatgpt/vendor/openai-php/client/src/ValueObjects/Transporter/Headers.php on line 20 #2
$result = $chatGPT->search('stocks', 'Return the first 10 documents of 2017');
//$result = $chatGPT->search('stocks', 'Return the first 30 names of all the different stock names');
//$result = $chatGPT->search('stocks', 'Return the max value of the field "high" for each stock in 2015');
//$result = $chatGPT->search('stocks', 'Return the average value of the field "high" for each stock in 2015');
//$result = $chatGPT->search('stocks', 'Return the max value of the field "high" for all the documents with name MON in 2014');
//$result = $chatGPT->search('stocks', 'Return the documents that have the difference between close and open fields > 20');
print_r($result->asArray());
printf("--- Last query:\n%s\n", $chatGPT->getLastQuery());
?>`
I just added the generated API keys to the code above and when running it gives me the following error:
Parse error: syntax error, unexpected token "array", expecting variable in /var/www/html/elkchatgpt/vendor/openai-php/client/src/ValueObjects/Transporter/Headers.php on line 20