entity

package
v1.2.0-beta Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ModelTypeLLM           = "llm"
	ModelTypeTextEmbedding = "text-embedding"
	ModelTypeSpeech2Text   = "speech2text"
	ModelTypeTTS           = "tts"
	ModelTypeModeration    = "moderation"

	LanguageEnglish = "en_US"
	LanguageChinese = "zh_Hans"
)

Functions

This section is empty.

Types

type AIModel

type AIModel struct {
	Model           string            `json:"model" yaml:"model"`
	Label           map[string]string `json:"label" yaml:"label"`
	ModelType       string            `json:"model_type" yaml:"model_type"`
	Features        []string          `json:"features" yaml:"features"`
	ModelProperties map[string]string `json:"model_properties" yaml:"model_properties"`
	ParameterRules  []ParameterRule   `json:"parameter_rules" yaml:"parameter_rules"`
}

type CredentialFormSchema

type CredentialFormSchema struct {
	Variable    string            `json:"variable" yaml:"variable"`
	Label       map[string]string `json:"label" yaml:"label"`
	Type        string            `json:"type" yaml:"type"`
	Required    bool              `json:"required" yaml:"required"`
	Placeholder map[string]string `json:"placeholder" yaml:"placeholder"`
}

type Help

type Help struct {
	Title map[string]string `json:"title" yaml:"title"`
	URL   map[string]string `json:"url" yaml:"url"`
}

type ParameterRule

type ParameterRule struct {
	Name      string            `json:"name" yaml:"name"`
	Default   interface{}       `json:"default" yaml:"default"`
	Label     map[string]string `json:"label" yaml:"label"`
	Type      string            `json:"type" yaml:"type"`
	Min       float64           `json:"min" yaml:"min"`
	Max       float64           `json:"max" yaml:"max"`
	Precision int               `json:"precision" yaml:"precision"`
	Required  bool              `json:"required" yaml:"required"`
}

type Provider

type Provider struct {
	Provider                 string                   `json:"provider" yaml:"provider"`
	Label                    map[string]string        `json:"label" yaml:"label"`
	Description              map[string]string        `json:"description" yaml:"description"`
	IconSmall                map[string]string        `json:"icon_small" yaml:"icon_small"`
	IconLarge                map[string]string        `json:"icon_large" yaml:"icon_large"`
	Background               string                   `json:"background" yaml:"background"`
	Help                     Help                     `json:"help" yaml:"help"`
	SupportedModelTypes      []string                 `json:"supported_model_types" yaml:"supported_model_types"`
	ProviderCredentialSchema ProviderCredentialSchema `json:"provider_credential_schema" yaml:"provider_credential_schema"`
	Default                  map[string]string        `json:"default" yaml:"default"`
	Address                  string                   `json:"address" yaml:"address"`
	Recommend                bool                     `json:"recommend" yaml:"recommend"`
	Sort                     int                      `json:"sort" yaml:"sort"`
}

type ProviderCredentialSchema

type ProviderCredentialSchema struct {
	CredentialFormSchemas []CredentialFormSchema `json:"credential_form_schemas" yaml:"credential_form_schemas"`
}

Jump to

Keyboard shortcuts

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