- At least Python 3.8
- OpenAI API key - you can generate one, by creating an account, then navigating to Personal > View API key > Create new secret key, then save the API key to a file named
.env
in a variable calledOPENAI_API_KEY
pip install openai
- installs the OpenAI librarypip install python-dotenv
- allows the application to fetch environmental variables from a .env file
In their documentation, OpenAI advertise text-davinci-003
as the most capable language model and text-ada-001
as the fastest one. I wanted to see how this translates into numbers, so I used the Natural Language Toolkit (nltk) to get the BLEU score of each language model.