settings

package
v0.0.0-...-7467467 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2023 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// GPTCli       *chatgpt.Client
	GPTCli2 *openai.Client
	LCA     *biz.LangChainAgent

	AllowIps     *AllowedKeys
	AllowApiKeys *AllowedKeys

	Logger      *wrap.Logger
	TransLogger *zap.Logger // transaction
	ReqLogger   *zap.Logger // request
	AppLogger   *zap.Logger // application

)

Functions

func Config

func Config() string

func Project

func Project() string

func SetProject

func SetProject(str string) (err error)

func SetupLoggers

func SetupLoggers()

func Version

func Version() string

Types

type AllowedKeys

type AllowedKeys struct {
	Enable bool     `mapstructure:"enable"`
	Items  []string `mapstructure:"items"`
	// contains filtered or unexported fields
}

func NewAllowedKeys

func NewAllowedKeys(fp, key string) (cfg *AllowedKeys, err error)

func (*AllowedKeys) Check

func (cfg *AllowedKeys) Check(item string) bool

Jump to

Keyboard shortcuts

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