real

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2025 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDifyInvocationDaemon

func NewDifyInvocationDaemon(base string, calling_key string) (dify_invocation.BackwardsInvocation, error)

func Request

func Request[T any](i *RealBackwardsInvocation, method string, path string, options ...http_requests.HttpOptions) (*T, error)

Send a request to dify inner api and validate the response

func StreamResponse

func StreamResponse[T any](i *RealBackwardsInvocation, method string, path string, options ...http_requests.HttpOptions) (
	*stream.Stream[T], error,
)

Types

type BaseBackwardsInvocationResponse

type BaseBackwardsInvocationResponse[T any] struct {
	Data  *T     `json:"data,omitempty"`
	Error string `json:"error"`
}

type RealBackwardsInvocation

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

func (*RealBackwardsInvocation) InvokeApp

func (*RealBackwardsInvocation) InvokeEncrypt

func (i *RealBackwardsInvocation) InvokeEncrypt(payload *dify_invocation.InvokeEncryptRequest) (map[string]any, error)

func (*RealBackwardsInvocation) InvokeLLM

func (*RealBackwardsInvocation) InvokeModeration

func (*RealBackwardsInvocation) InvokeParameterExtractor

func (*RealBackwardsInvocation) InvokeQuestionClassifier

func (*RealBackwardsInvocation) InvokeRerank

func (*RealBackwardsInvocation) InvokeSpeech2Text

func (*RealBackwardsInvocation) InvokeSummary

func (*RealBackwardsInvocation) InvokeTTS

func (*RealBackwardsInvocation) InvokeTextEmbedding

func (*RealBackwardsInvocation) InvokeTool

func (*RealBackwardsInvocation) UploadFile

Jump to

Keyboard shortcuts

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