This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
import openai
openai.api_key = input("OpenAI API Key: ")
response = openai.Completion.create(engine="text-davinci-003", prompt=prompt, max_tokens=256, temperature=0.2)
print(response['choices'][0]['text'])
view raw
step4_query_gpt3.py
hosted with ❤ by
GitHub