provider

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: AGPL-3.0, Apache-2.0, MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewOllamaProxy

func NewOllamaProxy(host string) (api.TranslationProxy, error)

func NewOpenAIProxy

func NewOpenAIProxy(target, token string) (api.TranslationProxy, error)

func NewVertexProxy added in v1.1.0

func NewVertexProxy(target, serviceAccount string) (api.TranslationProxy, error)

Types

type OllamaProxy

type OllamaProxy struct {
	api.TranslationProxy
}

type OpenAIProxy

type OpenAIProxy struct {
	// contains filtered or unexported fields
}

func (*OpenAIProxy) ModifyRequest

func (in *OpenAIProxy) ModifyRequest(r *httputil.ProxyRequest)

func (*OpenAIProxy) ModifyResponse

func (in *OpenAIProxy) ModifyResponse(r *http.Response) error

func (OpenAIProxy) Proxy

func (in OpenAIProxy) Proxy() http.HandlerFunc

type VertexProxy added in v1.1.0

type VertexProxy struct {
	// contains filtered or unexported fields
}

func (*VertexProxy) ModifyRequest added in v1.1.0

func (in *VertexProxy) ModifyRequest(r *httputil.ProxyRequest)

func (*VertexProxy) ModifyResponse added in v1.1.0

func (in *VertexProxy) ModifyResponse(r *http.Response) error

func (VertexProxy) Proxy added in v1.1.0

func (in VertexProxy) Proxy() http.HandlerFunc

Jump to

Keyboard shortcuts

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