external

package
v0.0.0-...-e34f17a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 31, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DallE

type DallE interface {
	GenerateImage(ctx context.Context, description string) (image.Image, error)
	SaveImage(image image.Image) (*string, error)
}

type DallE2

type DallE2 struct {
	Client *openai.Client
	Size   string
	N      int
	Path   string
}

func NewDallE2

func NewDallE2(client *openai.Client, path string) *DallE2

func (*DallE2) GenerateImage

func (d *DallE2) GenerateImage(ctx context.Context, description string) (image.Image, error)

func (DallE2) SaveImage

func (d DallE2) SaveImage(image image.Image) (*string, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL