openai-java
openai-java copied to clipboard
Updating example to not use new api
/** Use {@link OpenAiService#createCompletion(CompletionRequest)} and {@link CompletionRequest#model}instead */
@Deprecated
public CompletionResult createCompletion(String engineId, CompletionRequest request)
The example in the readme uses the old completion, which should be updated as it is the one people probably use at first. I've also formatted it so after pasting it into an editor you won't get syntax errors. (Added semicolon and made API key a string)