Skip to content

seemywingz/goai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GOAI

Go OpenAI API Library

go get github.com/seemywingz/goai

// main.go
package main

import (
	"os"

	"github.com/seemywingz/goai"
)

func main() {
	oai := goai.NewClient(os.Getenv("OPENAI_API_KEY"), false)
	oaiRes, err := oai.TextCompletion("This is a test.")
	if err != nil {
		panic(err)
	}
	println(oaiRes.Choices[0].Text)
}

About

Go Open AI API Library

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages