logger

package
v1.0.61 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GinWriter *logr.Writer
View Source
var Logger *logr.Logger
View Source
var Support *logr.Logger

Functions

func Demo

func Demo()

func Init

func Init()

Types

type BinancePrice

type BinancePrice struct {
	Price  float64 `json:"lastPrice,string"`
	Volume float64 `json:"quoteVolume,string"`
}

type BitfinexPrice

type BitfinexPrice struct {
	Price  float64
	Volume float64
}

func (*BitfinexPrice) UnmarshalJSON

func (b *BitfinexPrice) UnmarshalJSON(buf []byte) error

type ChatHistory added in v1.0.38

type ChatHistory []*ChatHistoryItem

type ChatHistoryItem added in v1.0.47

type ChatHistoryItem struct {
	Role    string `json:"role"`
	Content string `json:"content"`
}

func Prompt added in v1.0.49

func Prompt(history ChatHistory, onSentence func(string), onToken func(string)) (*ChatHistoryItem, error)

type HitbtcPrice

type HitbtcPrice struct {
	Price  float64 `json:"last,string"`
	Volume float64 `json:"volume_quote,string"`
}

type RequestBody added in v1.0.38

type RequestBody struct {
	Model    string      `json:"model"`
	Messages ChatHistory `json:"messages"`
	Stream   bool        `json:"stream"`
}

type ResponseBody added in v1.0.38

type ResponseBody struct {
	Model   string          `json:"model"`
	Message ChatHistoryItem `json:"message"`
	Done    bool            `json:"done"`
}

Jump to

Keyboard shortcuts

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