dfinke / PSAI

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

Chat option? #13

Closed CantCode321 closed 3 days ago

CantCode321 commented 1 week ago

Is there a way to change from 4o to 3.5 turbo or any other version?I tried the old command Get-chatsessionoptions but it doesnt work...

dfinke commented 1 week ago

Correct that does not work can you give me a snippet of what function you are using?

image

CantCode321 commented 1 week ago

Στιγμιότυπο οθόνης 2024-06-23 030707 is this what you mean?sorry i am not good at this as per my name😅

dfinke commented 1 week ago

Get-ChatOptions no longer exists.

try this ai 'capital of france' -model 'gpt-3.5-turbo'

and what happens with this ai 'capital of france'

CantCode321 commented 1 week ago

using ai 'capital of france' -model 'gpt-3.5-turbo' echoes 'capital of france' and using ai 'capital of france' gives me
throw $targetError | ~~~~~~ | The requested model 'gpt-4o' does not exist.

i still dont have a 3,5turbo so thats why it echoes when using the first command?I am waiting to see if it works before buying one!

dfinke commented 1 week ago

I'm confused 🙂

You need to have and set an OpenAI key and have bought credits on it.

CantCode321 commented 1 week ago

Yeah a key was generated but i didnt put credit in it or something like that. i was just worried i would buy the subscription and then i wouldnt be able to figure out how to use this.So everything should work as normal after i activate my key properly?

dfinke commented 1 week ago

You need a key and add credit. It is not a pay as you go subscription.

The credit minimum I think is $6 and only is deducted when you hit the AI service. ai 'capital of france which costs like $.000001

Also, when you use the credit up, it does not auto recharge, you have to go in and explicitly add more.

CantCode321 commented 1 week ago

ok ill try it out and let you know if i have any problems! also can it be used with other apis like perplexity?

dfinke commented 1 week ago

PSAI supports OpenAI and Azure OpenAI. Azure OpenAI lets you deploy the OpenAI models in your Azure tenant.

I'm thinking through how to best to implement a plugin approach for different services like Perplexity.