Documentation ¶
Index ¶
- Constants
- func Init(cfg *Config) error
- func IsErrorConcurrentRequest(err error) bool
- func NewBigModelService() bigmodel.BigModel
- func NewErrorConcurrentRequest(err error) errorConcurrentRequest
- type ApiService
- type CloudConfig
- type Config
- type Endpoints
- type Moderation
- type OBSAuthInfo
- type OBSConfig
- type WuKong
- type WuKongSample
Constants ¶
View Source
const ( CodeInputTextAuditError = "code_input_text_audit_error" CodeOutputTextAuditError = "code_output_text_audit_error" CodeBaiChuanGenerationError = "code_baichuan_generation_error" )
Variables ¶
This section is empty.
Functions ¶
func NewBigModelService ¶
func NewErrorConcurrentRequest ¶
func NewErrorConcurrentRequest(err error) errorConcurrentRequest
Types ¶
type ApiService ¶
type ApiService struct {
TokenExpire string
}
type CloudConfig ¶
type Config ¶
type Config struct { OBS OBSConfig `json:"obs" required:"true"` Cloud CloudConfig `json:"cloud" required:"true"` WuKong WuKong `json:"wukong" required:"true"` Endpoints Endpoints `json:"endpoints" required:"true"` Moderation Moderation `json:"moderation" required:"true"` CloudGY CloudConfig `json:"auth_gy" required:"true"` MaxPictureSizeToDescribe int64 `json:"max_picture_size_to_describe"` MaxPictureSizeToVQA int64 `json:"max_picture_size_to_vqa"` }
func (*Config) SetDefault ¶
func (cfg *Config) SetDefault()
type Endpoints ¶
type Endpoints struct { VQA string `json:"vqa" required:"true"` VQAHF string `json:"vqa_hf" required:"true"` Pangu string `json:"pangu" required:"true"` LuoJia string `json:"luojia" required:"true"` LuoJiaHF string `json:"luojia_hf" required:"true"` WuKong string `json:"wukong" required:"true"` WuKong4IMG string `json:"wukong_4img" required:"true"` WuKongHF string `json:"wukong_hf" required:"true"` WuKongUser string `json:"wukong_user" required:"true"` CodeGeex string `json:"codegeex" required:"true"` DescPicture string `json:"desc_picture" required:"true"` DescPictureHF string `json:"desc_picture_hf" required:"true"` SinglePicture string `json:"single_picture" required:"true"` MultiplePictures string `json:"multiple_pictures" required:"true"` AIDetector string `json:"ai_detector" required:"true"` BaiChuan string `json:"baichuan" required:"true"` GLM2 string `json:"glm" required:"true"` LLAMA2 string `json:"llama" required:"true"` SkyWork string `json:"skywork" required:"true"` IFlytekspark string `json:"iflytekspark" required:"true"` IFlyteksparkLong string `json:"iflytekspark_long" required:"true"` }
type Moderation ¶
type OBSAuthInfo ¶
type OBSConfig ¶
type OBSConfig struct { OBSAuthInfo VQABucket string `json:"vqa_bucket" required:"true"` LuoJiaBucket string `json:"luo_jia_bucket" required:"true"` }
type WuKong ¶
type WuKong struct { WuKongSample CloudConfig OBSAuthInfo Bucket string `json:"bucket" required:"true"` // DownloadExpiry specifies the timeout to download a obs file. // The unit is second. DownloadExpiry int `json:"download_expiry"` }
type WuKongSample ¶
Click to show internal directories.
Click to hide internal directories.