dfinke / PSAI

PowerShell AI module. Brings OpenAI to the console and scripts
MIT License
80 stars 9 forks source link

Returned response to Invoke-OAIChat is always the -UserInput string #5

Closed mikenelson-io closed 4 months ago

mikenelson-io commented 4 months ago

PSAI Module Version: 0.1.2 OpenAIKey variable set: Yes PowerShell v7.4.2

PS> Invoke-OAIChat 'How do I output all files in a directory PowerShell?'
How do I output all files in a directory PowerShell?
PS> $env:OpenAIKey
sk-proj-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
PS> Invoke-OAIChat 'How do I output all files in a directory PowerShell?'
How do I output all files in a directory PowerShell?
PS> Invoke-OAIChat -UserInput "What is the weather today?"
What is the weather today?
PS>
dfinke commented 4 months ago

Not sure. The key seems right. Try https://github.com/dfinke/PSAI/blob/main/examples/Simple-Tutor.ps1

Unfortunately, works for me. image

TheITRx commented 4 months ago

I'm having the same thing.

It just echoes my input.

dfinke commented 4 months ago

@TheITRx, @mikenelson-io please check if you updated your payments to OpenAI.

You need to "deposit" money for credits. $5 should last a long while.

Others had this issue and unfortunately the server does not throw an error that the account billing needs to be updated.

TheITRx commented 4 months ago

Put in some $s and its working. thanks!