cryptoapebot
cryptoapebot
See @luoyashuo comment above. The text-davinci-003 needs a longer timeout, especially if you are feeding it a lot of tokens in the prompts.
Couple of things. Add a timeout to your service. ``` service = new OpenAiService(API_KEY, Duration.ofSeconds(45)); ``` Switch to the newer davinci model. ``` .model("text-davinci-003") ``` You probably want to add...
A couple more ideas. 1) You have to include in your prompt an instruction part. For instance: BoBAlpha is a chat bot that is friendly, helpful and very knowlegeable about...
``` List choices = service.createCompletion(completionRequest).getChoices(); assertEquals(5, choices.size()); for (CompletionChoice c : choices) { System.out.println(c.getText()); // or whatever the exact command is. c.toString(() will give you the log_probs and finish reason...
Just a commment though. lombok.Data should create a no args constructor automagically. I suspect it's not a code problem. @Data @huajiayi Can you confirm you have lombok installed correctly in...
Check to see if your openai token is valid, but please be aware that China is not currently a supported region in their terms of service.
This is the IP I get: ``` PS F:\workspace\openai-java> nslookup api.openai.com Server: dns-cac-lb-01.rr.com Address: 2001:1998:f00:1::1 Non-authoritative answer: Name: api.openai.com Address: 52.152.96.252 ```
What was it?
Just checking to see if related to a diff problem. Please post results of: ``` java --version ```
To use 1.8.0_100 or less you have to use the keytool to upgrade the certs which is complicated and not secure. Upgrading java will fix your issue. Thanks @qianyx !