A GPT-3 completion program, which runs STDIN through GPT-3, then writes the completion to STDOUT.
The code requires an API key for OpenAI's API. You can get one here.
Then, generate the lib/api_key.go
from the template with:
$ go generate ./...
To build:
$ go build -o complete ./cmd/complete/
You can tweak the model parameters of this program to make the output more dynamic, or even make the execution cheaper by using a different GPT-3 model.