custom

package
v1.29.0 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2024 License: MIT Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Count

func Count(input string) (int, error)

func NewTokenCounter

func NewTokenCounter()

Types

type Provider

type Provider struct {
	Id                  string         `json:"id"`
	CreatedAt           int64          `json:"created_at"`
	UpdatedAt           int64          `json:"updated_at"`
	Provider            string         `json:"provider"`
	RouteConfigs        []*RouteConfig `json:"route_configs"`
	AuthenticationParam string         `json:"authentication_param"`
}

type RouteConfig

type RouteConfig struct {
	Path                             string `json:"path"`
	TargetUrl                        string `json:"target_url"`
	StreamLocation                   string `json:"stream_location"`
	ModelLocation                    string `json:"model_location"`
	RequestPromptLocation            string `json:"request_prompt_location"`
	ResponseCompletionLocation       string `json:"response_completion_location"`
	StreamEndWord                    string `json:"stream_end_word"`
	StreamResponseCompletionLocation string `json:"stream_response_completion_location"`
	StreamMaxEmptyMessages           int    `json:"stream_max_empty_messages"`
}

type UpdateProvider added in v1.3.1

type UpdateProvider struct {
	UpdatedAt           int64          `json:"updated_at"`
	RouteConfigs        []*RouteConfig `json:"route_configs"`
	AuthenticationParam *string        `json:"authentication_param"`
}

Jump to

Keyboard shortcuts

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