api

package
v0.0.1-20230324 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var KitexUnusedProtection = struct{}{}

KitexUnusedProtection is used to prevent 'imported and not used' error.

Functions

This section is empty.

Types

type ChatCompletionChoice

type ChatCompletionChoice struct {
	Index        int32                  `thrift:"Index,1" frugal:"1,default,i32" json:"Index"`
	Message      *ChatCompletionMessage `thrift:"Message,2" frugal:"2,default,ChatCompletionMessage" json:"Message"`
	FinishReason string                 `thrift:"FinishReason,3" frugal:"3,default,string" json:"FinishReason"`
}

func NewChatCompletionChoice

func NewChatCompletionChoice() *ChatCompletionChoice

func (*ChatCompletionChoice) BLength

func (p *ChatCompletionChoice) BLength() int

func (*ChatCompletionChoice) DeepEqual

func (p *ChatCompletionChoice) DeepEqual(ano *ChatCompletionChoice) bool

func (*ChatCompletionChoice) FastRead

func (p *ChatCompletionChoice) FastRead(buf []byte) (int, error)

func (*ChatCompletionChoice) FastReadField1

func (p *ChatCompletionChoice) FastReadField1(buf []byte) (int, error)

func (*ChatCompletionChoice) FastReadField2

func (p *ChatCompletionChoice) FastReadField2(buf []byte) (int, error)

func (*ChatCompletionChoice) FastReadField3

func (p *ChatCompletionChoice) FastReadField3(buf []byte) (int, error)

func (*ChatCompletionChoice) FastWrite

func (p *ChatCompletionChoice) FastWrite(buf []byte) int

for compatibility

func (*ChatCompletionChoice) FastWriteNocopy

func (p *ChatCompletionChoice) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*ChatCompletionChoice) Field1DeepEqual

func (p *ChatCompletionChoice) Field1DeepEqual(src int32) bool

func (*ChatCompletionChoice) Field2DeepEqual

func (p *ChatCompletionChoice) Field2DeepEqual(src *ChatCompletionMessage) bool

func (*ChatCompletionChoice) Field3DeepEqual

func (p *ChatCompletionChoice) Field3DeepEqual(src string) bool

func (*ChatCompletionChoice) GetFinishReason

func (p *ChatCompletionChoice) GetFinishReason() (v string)

func (*ChatCompletionChoice) GetIndex

func (p *ChatCompletionChoice) GetIndex() (v int32)

func (*ChatCompletionChoice) GetMessage

func (p *ChatCompletionChoice) GetMessage() (v *ChatCompletionMessage)

func (*ChatCompletionChoice) InitDefault

func (p *ChatCompletionChoice) InitDefault()

func (*ChatCompletionChoice) IsSetMessage

func (p *ChatCompletionChoice) IsSetMessage() bool

func (*ChatCompletionChoice) Read

func (p *ChatCompletionChoice) Read(iprot thrift.TProtocol) (err error)

func (*ChatCompletionChoice) ReadField1

func (p *ChatCompletionChoice) ReadField1(iprot thrift.TProtocol) error

func (*ChatCompletionChoice) ReadField2

func (p *ChatCompletionChoice) ReadField2(iprot thrift.TProtocol) error

func (*ChatCompletionChoice) ReadField3

func (p *ChatCompletionChoice) ReadField3(iprot thrift.TProtocol) error

func (*ChatCompletionChoice) SetFinishReason

func (p *ChatCompletionChoice) SetFinishReason(val string)

func (*ChatCompletionChoice) SetIndex

func (p *ChatCompletionChoice) SetIndex(val int32)

func (*ChatCompletionChoice) SetMessage

func (p *ChatCompletionChoice) SetMessage(val *ChatCompletionMessage)

func (*ChatCompletionChoice) String

func (p *ChatCompletionChoice) String() string

func (*ChatCompletionChoice) Write

func (p *ChatCompletionChoice) Write(oprot thrift.TProtocol) (err error)

type ChatCompletionMessage

type ChatCompletionMessage struct {
	Role    string `thrift:"Role,1" frugal:"1,default,string" json:"Role"`
	Content string `thrift:"Content,2" frugal:"2,default,string" json:"Content"`
	Name    string `thrift:"Name,3" frugal:"3,default,string" json:"Name"`
}
var ChatCompletionChoice_Message_DEFAULT *ChatCompletionMessage

func NewChatCompletionMessage

func NewChatCompletionMessage() *ChatCompletionMessage

func (*ChatCompletionMessage) BLength

func (p *ChatCompletionMessage) BLength() int

func (*ChatCompletionMessage) DeepEqual

func (*ChatCompletionMessage) FastRead

func (p *ChatCompletionMessage) FastRead(buf []byte) (int, error)

func (*ChatCompletionMessage) FastReadField1

func (p *ChatCompletionMessage) FastReadField1(buf []byte) (int, error)

func (*ChatCompletionMessage) FastReadField2

func (p *ChatCompletionMessage) FastReadField2(buf []byte) (int, error)

func (*ChatCompletionMessage) FastReadField3

func (p *ChatCompletionMessage) FastReadField3(buf []byte) (int, error)

func (*ChatCompletionMessage) FastWrite

func (p *ChatCompletionMessage) FastWrite(buf []byte) int

for compatibility

func (*ChatCompletionMessage) FastWriteNocopy

func (p *ChatCompletionMessage) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*ChatCompletionMessage) Field1DeepEqual

func (p *ChatCompletionMessage) Field1DeepEqual(src string) bool

func (*ChatCompletionMessage) Field2DeepEqual

func (p *ChatCompletionMessage) Field2DeepEqual(src string) bool

func (*ChatCompletionMessage) Field3DeepEqual

func (p *ChatCompletionMessage) Field3DeepEqual(src string) bool

func (*ChatCompletionMessage) GetContent

func (p *ChatCompletionMessage) GetContent() (v string)

func (*ChatCompletionMessage) GetName

func (p *ChatCompletionMessage) GetName() (v string)

func (*ChatCompletionMessage) GetRole

func (p *ChatCompletionMessage) GetRole() (v string)

func (*ChatCompletionMessage) InitDefault

func (p *ChatCompletionMessage) InitDefault()

func (*ChatCompletionMessage) Read

func (p *ChatCompletionMessage) Read(iprot thrift.TProtocol) (err error)

func (*ChatCompletionMessage) ReadField1

func (p *ChatCompletionMessage) ReadField1(iprot thrift.TProtocol) error

func (*ChatCompletionMessage) ReadField2

func (p *ChatCompletionMessage) ReadField2(iprot thrift.TProtocol) error

func (*ChatCompletionMessage) ReadField3

func (p *ChatCompletionMessage) ReadField3(iprot thrift.TProtocol) error

func (*ChatCompletionMessage) SetContent

func (p *ChatCompletionMessage) SetContent(val string)

func (*ChatCompletionMessage) SetName

func (p *ChatCompletionMessage) SetName(val string)

func (*ChatCompletionMessage) SetRole

func (p *ChatCompletionMessage) SetRole(val string)

func (*ChatCompletionMessage) String

func (p *ChatCompletionMessage) String() string

func (*ChatCompletionMessage) Write

func (p *ChatCompletionMessage) Write(oprot thrift.TProtocol) (err error)

type ChatCompletionRequest

type ChatCompletionRequest struct {
	Model            string                   `thrift:"Model,1" frugal:"1,default,string" json:"Model"`
	Messages         []*ChatCompletionMessage `thrift:"Messages,2" frugal:"2,default,list<ChatCompletionMessage>" json:"Messages"`
	MaxTokens        int32                    `thrift:"MaxTokens,3" frugal:"3,default,i32" json:"MaxTokens"`
	Temperature      float64                  `thrift:"Temperature,4" frugal:"4,default,double" json:"Temperature"`
	TopP             float64                  `thrift:"TopP,5" frugal:"5,default,double" json:"TopP"`
	N                int32                    `thrift:"N,6" frugal:"6,default,i32" json:"N"`
	Stream           bool                     `thrift:"Stream,7" frugal:"7,default,bool" json:"Stream"`
	Stop             []string                 `thrift:"Stop,8" frugal:"8,default,list<string>" json:"Stop"`
	PresencePenalty  float64                  `thrift:"PresencePenalty,9" frugal:"9,default,double" json:"PresencePenalty"`
	FrequencyPenalty float64                  `thrift:"FrequencyPenalty,10" frugal:"10,default,double" json:"FrequencyPenalty"`
	LogitBias        map[string]int32         `thrift:"LogitBias,11" frugal:"11,default,map<string:i32>" json:"LogitBias"`
	User             string                   `thrift:"User,12" frugal:"12,default,string" json:"User"`
}
var GPTServiceCreateChatCompletion35Args_Request_DEFAULT *ChatCompletionRequest

func NewChatCompletionRequest

func NewChatCompletionRequest() *ChatCompletionRequest

func (*ChatCompletionRequest) BLength

func (p *ChatCompletionRequest) BLength() int

func (*ChatCompletionRequest) DeepEqual

func (*ChatCompletionRequest) FastRead

func (p *ChatCompletionRequest) FastRead(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField1

func (p *ChatCompletionRequest) FastReadField1(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField10

func (p *ChatCompletionRequest) FastReadField10(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField11

func (p *ChatCompletionRequest) FastReadField11(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField12

func (p *ChatCompletionRequest) FastReadField12(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField2

func (p *ChatCompletionRequest) FastReadField2(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField3

func (p *ChatCompletionRequest) FastReadField3(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField4

func (p *ChatCompletionRequest) FastReadField4(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField5

func (p *ChatCompletionRequest) FastReadField5(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField6

func (p *ChatCompletionRequest) FastReadField6(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField7

func (p *ChatCompletionRequest) FastReadField7(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField8

func (p *ChatCompletionRequest) FastReadField8(buf []byte) (int, error)

func (*ChatCompletionRequest) FastReadField9

func (p *ChatCompletionRequest) FastReadField9(buf []byte) (int, error)

func (*ChatCompletionRequest) FastWrite

func (p *ChatCompletionRequest) FastWrite(buf []byte) int

for compatibility

func (*ChatCompletionRequest) FastWriteNocopy

func (p *ChatCompletionRequest) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*ChatCompletionRequest) Field10DeepEqual

func (p *ChatCompletionRequest) Field10DeepEqual(src float64) bool

func (*ChatCompletionRequest) Field11DeepEqual

func (p *ChatCompletionRequest) Field11DeepEqual(src map[string]int32) bool

func (*ChatCompletionRequest) Field12DeepEqual

func (p *ChatCompletionRequest) Field12DeepEqual(src string) bool

func (*ChatCompletionRequest) Field1DeepEqual

func (p *ChatCompletionRequest) Field1DeepEqual(src string) bool

func (*ChatCompletionRequest) Field2DeepEqual

func (p *ChatCompletionRequest) Field2DeepEqual(src []*ChatCompletionMessage) bool

func (*ChatCompletionRequest) Field3DeepEqual

func (p *ChatCompletionRequest) Field3DeepEqual(src int32) bool

func (*ChatCompletionRequest) Field4DeepEqual

func (p *ChatCompletionRequest) Field4DeepEqual(src float64) bool

func (*ChatCompletionRequest) Field5DeepEqual

func (p *ChatCompletionRequest) Field5DeepEqual(src float64) bool

func (*ChatCompletionRequest) Field6DeepEqual

func (p *ChatCompletionRequest) Field6DeepEqual(src int32) bool

func (*ChatCompletionRequest) Field7DeepEqual

func (p *ChatCompletionRequest) Field7DeepEqual(src bool) bool

func (*ChatCompletionRequest) Field8DeepEqual

func (p *ChatCompletionRequest) Field8DeepEqual(src []string) bool

func (*ChatCompletionRequest) Field9DeepEqual

func (p *ChatCompletionRequest) Field9DeepEqual(src float64) bool

func (*ChatCompletionRequest) GetFrequencyPenalty

func (p *ChatCompletionRequest) GetFrequencyPenalty() (v float64)

func (*ChatCompletionRequest) GetLogitBias

func (p *ChatCompletionRequest) GetLogitBias() (v map[string]int32)

func (*ChatCompletionRequest) GetMaxTokens

func (p *ChatCompletionRequest) GetMaxTokens() (v int32)

func (*ChatCompletionRequest) GetMessages

func (p *ChatCompletionRequest) GetMessages() (v []*ChatCompletionMessage)

func (*ChatCompletionRequest) GetModel

func (p *ChatCompletionRequest) GetModel() (v string)

func (*ChatCompletionRequest) GetN

func (p *ChatCompletionRequest) GetN() (v int32)

func (*ChatCompletionRequest) GetPresencePenalty

func (p *ChatCompletionRequest) GetPresencePenalty() (v float64)

func (*ChatCompletionRequest) GetStop

func (p *ChatCompletionRequest) GetStop() (v []string)

func (*ChatCompletionRequest) GetStream

func (p *ChatCompletionRequest) GetStream() (v bool)

func (*ChatCompletionRequest) GetTemperature

func (p *ChatCompletionRequest) GetTemperature() (v float64)

func (*ChatCompletionRequest) GetTopP

func (p *ChatCompletionRequest) GetTopP() (v float64)

func (*ChatCompletionRequest) GetUser

func (p *ChatCompletionRequest) GetUser() (v string)

func (*ChatCompletionRequest) InitDefault

func (p *ChatCompletionRequest) InitDefault()

func (*ChatCompletionRequest) Read

func (p *ChatCompletionRequest) Read(iprot thrift.TProtocol) (err error)

func (*ChatCompletionRequest) ReadField1

func (p *ChatCompletionRequest) ReadField1(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField10

func (p *ChatCompletionRequest) ReadField10(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField11

func (p *ChatCompletionRequest) ReadField11(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField12

func (p *ChatCompletionRequest) ReadField12(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField2

func (p *ChatCompletionRequest) ReadField2(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField3

func (p *ChatCompletionRequest) ReadField3(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField4

func (p *ChatCompletionRequest) ReadField4(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField5

func (p *ChatCompletionRequest) ReadField5(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField6

func (p *ChatCompletionRequest) ReadField6(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField7

func (p *ChatCompletionRequest) ReadField7(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField8

func (p *ChatCompletionRequest) ReadField8(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) ReadField9

func (p *ChatCompletionRequest) ReadField9(iprot thrift.TProtocol) error

func (*ChatCompletionRequest) SetFrequencyPenalty

func (p *ChatCompletionRequest) SetFrequencyPenalty(val float64)

func (*ChatCompletionRequest) SetLogitBias

func (p *ChatCompletionRequest) SetLogitBias(val map[string]int32)

func (*ChatCompletionRequest) SetMaxTokens

func (p *ChatCompletionRequest) SetMaxTokens(val int32)

func (*ChatCompletionRequest) SetMessages

func (p *ChatCompletionRequest) SetMessages(val []*ChatCompletionMessage)

func (*ChatCompletionRequest) SetModel

func (p *ChatCompletionRequest) SetModel(val string)

func (*ChatCompletionRequest) SetN

func (p *ChatCompletionRequest) SetN(val int32)

func (*ChatCompletionRequest) SetPresencePenalty

func (p *ChatCompletionRequest) SetPresencePenalty(val float64)

func (*ChatCompletionRequest) SetStop

func (p *ChatCompletionRequest) SetStop(val []string)

func (*ChatCompletionRequest) SetStream

func (p *ChatCompletionRequest) SetStream(val bool)

func (*ChatCompletionRequest) SetTemperature

func (p *ChatCompletionRequest) SetTemperature(val float64)

func (*ChatCompletionRequest) SetTopP

func (p *ChatCompletionRequest) SetTopP(val float64)

func (*ChatCompletionRequest) SetUser

func (p *ChatCompletionRequest) SetUser(val string)

func (*ChatCompletionRequest) String

func (p *ChatCompletionRequest) String() string

func (*ChatCompletionRequest) Write

func (p *ChatCompletionRequest) Write(oprot thrift.TProtocol) (err error)

type ChatCompletionResponse

type ChatCompletionResponse struct {
	ID      string                  `thrift:"ID,1" frugal:"1,default,string" json:"ID"`
	Object  string                  `thrift:"Object,2" frugal:"2,default,string" json:"Object"`
	Created int64                   `thrift:"Created,3" frugal:"3,default,i64" json:"Created"`
	Model   string                  `thrift:"Model,4" frugal:"4,default,string" json:"Model"`
	Choices []*ChatCompletionChoice `thrift:"Choices,5" frugal:"5,default,list<ChatCompletionChoice>" json:"Choices"`
	Usage   *Usage                  `thrift:"Usage,6" frugal:"6,default,Usage" json:"Usage"`
}
var GPTServiceCreateChatCompletion35Result_Success_DEFAULT *ChatCompletionResponse

func NewChatCompletionResponse

func NewChatCompletionResponse() *ChatCompletionResponse

func (*ChatCompletionResponse) BLength

func (p *ChatCompletionResponse) BLength() int

func (*ChatCompletionResponse) DeepEqual

func (*ChatCompletionResponse) FastRead

func (p *ChatCompletionResponse) FastRead(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField1

func (p *ChatCompletionResponse) FastReadField1(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField2

func (p *ChatCompletionResponse) FastReadField2(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField3

func (p *ChatCompletionResponse) FastReadField3(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField4

func (p *ChatCompletionResponse) FastReadField4(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField5

func (p *ChatCompletionResponse) FastReadField5(buf []byte) (int, error)

func (*ChatCompletionResponse) FastReadField6

func (p *ChatCompletionResponse) FastReadField6(buf []byte) (int, error)

func (*ChatCompletionResponse) FastWrite

func (p *ChatCompletionResponse) FastWrite(buf []byte) int

for compatibility

func (*ChatCompletionResponse) FastWriteNocopy

func (p *ChatCompletionResponse) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*ChatCompletionResponse) Field1DeepEqual

func (p *ChatCompletionResponse) Field1DeepEqual(src string) bool

func (*ChatCompletionResponse) Field2DeepEqual

func (p *ChatCompletionResponse) Field2DeepEqual(src string) bool

func (*ChatCompletionResponse) Field3DeepEqual

func (p *ChatCompletionResponse) Field3DeepEqual(src int64) bool

func (*ChatCompletionResponse) Field4DeepEqual

func (p *ChatCompletionResponse) Field4DeepEqual(src string) bool

func (*ChatCompletionResponse) Field5DeepEqual

func (p *ChatCompletionResponse) Field5DeepEqual(src []*ChatCompletionChoice) bool

func (*ChatCompletionResponse) Field6DeepEqual

func (p *ChatCompletionResponse) Field6DeepEqual(src *Usage) bool

func (*ChatCompletionResponse) GetChoices

func (p *ChatCompletionResponse) GetChoices() (v []*ChatCompletionChoice)

func (*ChatCompletionResponse) GetCreated

func (p *ChatCompletionResponse) GetCreated() (v int64)

func (*ChatCompletionResponse) GetID

func (p *ChatCompletionResponse) GetID() (v string)

func (*ChatCompletionResponse) GetModel

func (p *ChatCompletionResponse) GetModel() (v string)

func (*ChatCompletionResponse) GetObject

func (p *ChatCompletionResponse) GetObject() (v string)

func (*ChatCompletionResponse) GetUsage

func (p *ChatCompletionResponse) GetUsage() (v *Usage)

func (*ChatCompletionResponse) InitDefault

func (p *ChatCompletionResponse) InitDefault()

func (*ChatCompletionResponse) IsSetUsage

func (p *ChatCompletionResponse) IsSetUsage() bool

func (*ChatCompletionResponse) Read

func (p *ChatCompletionResponse) Read(iprot thrift.TProtocol) (err error)

func (*ChatCompletionResponse) ReadField1

func (p *ChatCompletionResponse) ReadField1(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) ReadField2

func (p *ChatCompletionResponse) ReadField2(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) ReadField3

func (p *ChatCompletionResponse) ReadField3(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) ReadField4

func (p *ChatCompletionResponse) ReadField4(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) ReadField5

func (p *ChatCompletionResponse) ReadField5(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) ReadField6

func (p *ChatCompletionResponse) ReadField6(iprot thrift.TProtocol) error

func (*ChatCompletionResponse) SetChoices

func (p *ChatCompletionResponse) SetChoices(val []*ChatCompletionChoice)

func (*ChatCompletionResponse) SetCreated

func (p *ChatCompletionResponse) SetCreated(val int64)

func (*ChatCompletionResponse) SetID

func (p *ChatCompletionResponse) SetID(val string)

func (*ChatCompletionResponse) SetModel

func (p *ChatCompletionResponse) SetModel(val string)

func (*ChatCompletionResponse) SetObject

func (p *ChatCompletionResponse) SetObject(val string)

func (*ChatCompletionResponse) SetUsage

func (p *ChatCompletionResponse) SetUsage(val *Usage)

func (*ChatCompletionResponse) String

func (p *ChatCompletionResponse) String() string

func (*ChatCompletionResponse) Write

func (p *ChatCompletionResponse) Write(oprot thrift.TProtocol) (err error)

type GPTService

type GPTService interface {
	Echo(ctx context.Context, req *Request) (r *Response, err error)

	CreateChatCompletion35(ctx context.Context, request *ChatCompletionRequest) (r *ChatCompletionResponse, err error)
}

type GPTServiceClient

type GPTServiceClient struct {
	// contains filtered or unexported fields
}

func NewGPTServiceClient

func NewGPTServiceClient(c thrift.TClient) *GPTServiceClient

func NewGPTServiceClientProtocol

func NewGPTServiceClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *GPTServiceClient

func (*GPTServiceClient) Client_

func (p *GPTServiceClient) Client_() thrift.TClient

func (*GPTServiceClient) CreateChatCompletion35

func (p *GPTServiceClient) CreateChatCompletion35(ctx context.Context, request *ChatCompletionRequest) (r *ChatCompletionResponse, err error)

func (*GPTServiceClient) Echo

func (p *GPTServiceClient) Echo(ctx context.Context, req *Request) (r *Response, err error)

type GPTServiceCreateChatCompletion35Args

type GPTServiceCreateChatCompletion35Args struct {
	Request *ChatCompletionRequest `thrift:"request,1" frugal:"1,default,ChatCompletionRequest" json:"request"`
}

func NewGPTServiceCreateChatCompletion35Args

func NewGPTServiceCreateChatCompletion35Args() *GPTServiceCreateChatCompletion35Args

func (*GPTServiceCreateChatCompletion35Args) BLength

func (*GPTServiceCreateChatCompletion35Args) DeepEqual

func (*GPTServiceCreateChatCompletion35Args) FastRead

func (p *GPTServiceCreateChatCompletion35Args) FastRead(buf []byte) (int, error)

func (*GPTServiceCreateChatCompletion35Args) FastReadField1

func (p *GPTServiceCreateChatCompletion35Args) FastReadField1(buf []byte) (int, error)

func (*GPTServiceCreateChatCompletion35Args) FastWrite

func (p *GPTServiceCreateChatCompletion35Args) FastWrite(buf []byte) int

for compatibility

func (*GPTServiceCreateChatCompletion35Args) FastWriteNocopy

func (p *GPTServiceCreateChatCompletion35Args) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*GPTServiceCreateChatCompletion35Args) Field1DeepEqual

func (*GPTServiceCreateChatCompletion35Args) GetFirstArgument

func (p *GPTServiceCreateChatCompletion35Args) GetFirstArgument() interface{}

func (*GPTServiceCreateChatCompletion35Args) GetRequest

func (*GPTServiceCreateChatCompletion35Args) InitDefault

func (p *GPTServiceCreateChatCompletion35Args) InitDefault()

func (*GPTServiceCreateChatCompletion35Args) IsSetRequest

func (p *GPTServiceCreateChatCompletion35Args) IsSetRequest() bool

func (*GPTServiceCreateChatCompletion35Args) Read

func (*GPTServiceCreateChatCompletion35Args) ReadField1

func (*GPTServiceCreateChatCompletion35Args) SetRequest

func (*GPTServiceCreateChatCompletion35Args) String

func (*GPTServiceCreateChatCompletion35Args) Write

type GPTServiceCreateChatCompletion35Result

type GPTServiceCreateChatCompletion35Result struct {
	Success *ChatCompletionResponse `thrift:"success,0,optional" frugal:"0,optional,ChatCompletionResponse" json:"success,omitempty"`
}

func NewGPTServiceCreateChatCompletion35Result

func NewGPTServiceCreateChatCompletion35Result() *GPTServiceCreateChatCompletion35Result

func (*GPTServiceCreateChatCompletion35Result) BLength

func (*GPTServiceCreateChatCompletion35Result) DeepEqual

func (*GPTServiceCreateChatCompletion35Result) FastRead

func (p *GPTServiceCreateChatCompletion35Result) FastRead(buf []byte) (int, error)

func (*GPTServiceCreateChatCompletion35Result) FastReadField0

func (p *GPTServiceCreateChatCompletion35Result) FastReadField0(buf []byte) (int, error)

func (*GPTServiceCreateChatCompletion35Result) FastWrite

func (p *GPTServiceCreateChatCompletion35Result) FastWrite(buf []byte) int

for compatibility

func (*GPTServiceCreateChatCompletion35Result) FastWriteNocopy

func (p *GPTServiceCreateChatCompletion35Result) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*GPTServiceCreateChatCompletion35Result) Field0DeepEqual

func (*GPTServiceCreateChatCompletion35Result) GetResult

func (p *GPTServiceCreateChatCompletion35Result) GetResult() interface{}

func (*GPTServiceCreateChatCompletion35Result) GetSuccess

func (*GPTServiceCreateChatCompletion35Result) InitDefault

func (p *GPTServiceCreateChatCompletion35Result) InitDefault()

func (*GPTServiceCreateChatCompletion35Result) IsSetSuccess

func (p *GPTServiceCreateChatCompletion35Result) IsSetSuccess() bool

func (*GPTServiceCreateChatCompletion35Result) Read

func (*GPTServiceCreateChatCompletion35Result) ReadField0

func (*GPTServiceCreateChatCompletion35Result) SetSuccess

func (p *GPTServiceCreateChatCompletion35Result) SetSuccess(x interface{})

func (*GPTServiceCreateChatCompletion35Result) String

func (*GPTServiceCreateChatCompletion35Result) Write

type GPTServiceEchoArgs

type GPTServiceEchoArgs struct {
	Req *Request `thrift:"req,1" frugal:"1,default,Request" json:"req"`
}

func NewGPTServiceEchoArgs

func NewGPTServiceEchoArgs() *GPTServiceEchoArgs

func (*GPTServiceEchoArgs) BLength

func (p *GPTServiceEchoArgs) BLength() int

func (*GPTServiceEchoArgs) DeepEqual

func (p *GPTServiceEchoArgs) DeepEqual(ano *GPTServiceEchoArgs) bool

func (*GPTServiceEchoArgs) FastRead

func (p *GPTServiceEchoArgs) FastRead(buf []byte) (int, error)

func (*GPTServiceEchoArgs) FastReadField1

func (p *GPTServiceEchoArgs) FastReadField1(buf []byte) (int, error)

func (*GPTServiceEchoArgs) FastWrite

func (p *GPTServiceEchoArgs) FastWrite(buf []byte) int

for compatibility

func (*GPTServiceEchoArgs) FastWriteNocopy

func (p *GPTServiceEchoArgs) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*GPTServiceEchoArgs) Field1DeepEqual

func (p *GPTServiceEchoArgs) Field1DeepEqual(src *Request) bool

func (*GPTServiceEchoArgs) GetFirstArgument

func (p *GPTServiceEchoArgs) GetFirstArgument() interface{}

func (*GPTServiceEchoArgs) GetReq

func (p *GPTServiceEchoArgs) GetReq() (v *Request)

func (*GPTServiceEchoArgs) InitDefault

func (p *GPTServiceEchoArgs) InitDefault()

func (*GPTServiceEchoArgs) IsSetReq

func (p *GPTServiceEchoArgs) IsSetReq() bool

func (*GPTServiceEchoArgs) Read

func (p *GPTServiceEchoArgs) Read(iprot thrift.TProtocol) (err error)

func (*GPTServiceEchoArgs) ReadField1

func (p *GPTServiceEchoArgs) ReadField1(iprot thrift.TProtocol) error

func (*GPTServiceEchoArgs) SetReq

func (p *GPTServiceEchoArgs) SetReq(val *Request)

func (*GPTServiceEchoArgs) String

func (p *GPTServiceEchoArgs) String() string

func (*GPTServiceEchoArgs) Write

func (p *GPTServiceEchoArgs) Write(oprot thrift.TProtocol) (err error)

type GPTServiceEchoResult

type GPTServiceEchoResult struct {
	Success *Response `thrift:"success,0,optional" frugal:"0,optional,Response" json:"success,omitempty"`
}

func NewGPTServiceEchoResult

func NewGPTServiceEchoResult() *GPTServiceEchoResult

func (*GPTServiceEchoResult) BLength

func (p *GPTServiceEchoResult) BLength() int

func (*GPTServiceEchoResult) DeepEqual

func (p *GPTServiceEchoResult) DeepEqual(ano *GPTServiceEchoResult) bool

func (*GPTServiceEchoResult) FastRead

func (p *GPTServiceEchoResult) FastRead(buf []byte) (int, error)

func (*GPTServiceEchoResult) FastReadField0

func (p *GPTServiceEchoResult) FastReadField0(buf []byte) (int, error)

func (*GPTServiceEchoResult) FastWrite

func (p *GPTServiceEchoResult) FastWrite(buf []byte) int

for compatibility

func (*GPTServiceEchoResult) FastWriteNocopy

func (p *GPTServiceEchoResult) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*GPTServiceEchoResult) Field0DeepEqual

func (p *GPTServiceEchoResult) Field0DeepEqual(src *Response) bool

func (*GPTServiceEchoResult) GetResult

func (p *GPTServiceEchoResult) GetResult() interface{}

func (*GPTServiceEchoResult) GetSuccess

func (p *GPTServiceEchoResult) GetSuccess() (v *Response)

func (*GPTServiceEchoResult) InitDefault

func (p *GPTServiceEchoResult) InitDefault()

func (*GPTServiceEchoResult) IsSetSuccess

func (p *GPTServiceEchoResult) IsSetSuccess() bool

func (*GPTServiceEchoResult) Read

func (p *GPTServiceEchoResult) Read(iprot thrift.TProtocol) (err error)

func (*GPTServiceEchoResult) ReadField0

func (p *GPTServiceEchoResult) ReadField0(iprot thrift.TProtocol) error

func (*GPTServiceEchoResult) SetSuccess

func (p *GPTServiceEchoResult) SetSuccess(x interface{})

func (*GPTServiceEchoResult) String

func (p *GPTServiceEchoResult) String() string

func (*GPTServiceEchoResult) Write

func (p *GPTServiceEchoResult) Write(oprot thrift.TProtocol) (err error)

type GPTServiceProcessor

type GPTServiceProcessor struct {
	// contains filtered or unexported fields
}

func NewGPTServiceProcessor

func NewGPTServiceProcessor(handler GPTService) *GPTServiceProcessor

func (*GPTServiceProcessor) AddToProcessorMap

func (p *GPTServiceProcessor) AddToProcessorMap(key string, processor thrift.TProcessorFunction)

func (*GPTServiceProcessor) GetProcessorFunction

func (p *GPTServiceProcessor) GetProcessorFunction(key string) (processor thrift.TProcessorFunction, ok bool)

func (*GPTServiceProcessor) Process

func (p *GPTServiceProcessor) Process(ctx context.Context, iprot, oprot thrift.TProtocol) (success bool, err thrift.TException)

func (*GPTServiceProcessor) ProcessorMap

func (p *GPTServiceProcessor) ProcessorMap() map[string]thrift.TProcessorFunction

type Request

type Request struct {
	Message string `thrift:"message,1" frugal:"1,default,string" json:"message"`
}
var GPTServiceEchoArgs_Req_DEFAULT *Request

func NewRequest

func NewRequest() *Request

func (*Request) BLength

func (p *Request) BLength() int

func (*Request) DeepEqual

func (p *Request) DeepEqual(ano *Request) bool

func (*Request) FastRead

func (p *Request) FastRead(buf []byte) (int, error)

func (*Request) FastReadField1

func (p *Request) FastReadField1(buf []byte) (int, error)

func (*Request) FastWrite

func (p *Request) FastWrite(buf []byte) int

for compatibility

func (*Request) FastWriteNocopy

func (p *Request) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*Request) Field1DeepEqual

func (p *Request) Field1DeepEqual(src string) bool

func (*Request) GetMessage

func (p *Request) GetMessage() (v string)

func (*Request) InitDefault

func (p *Request) InitDefault()

func (*Request) Read

func (p *Request) Read(iprot thrift.TProtocol) (err error)

func (*Request) ReadField1

func (p *Request) ReadField1(iprot thrift.TProtocol) error

func (*Request) SetMessage

func (p *Request) SetMessage(val string)

func (*Request) String

func (p *Request) String() string

func (*Request) Write

func (p *Request) Write(oprot thrift.TProtocol) (err error)

type Response

type Response struct {
	Message string `thrift:"message,1" frugal:"1,default,string" json:"message"`
}
var GPTServiceEchoResult_Success_DEFAULT *Response

func NewResponse

func NewResponse() *Response

func (*Response) BLength

func (p *Response) BLength() int

func (*Response) DeepEqual

func (p *Response) DeepEqual(ano *Response) bool

func (*Response) FastRead

func (p *Response) FastRead(buf []byte) (int, error)

func (*Response) FastReadField1

func (p *Response) FastReadField1(buf []byte) (int, error)

func (*Response) FastWrite

func (p *Response) FastWrite(buf []byte) int

for compatibility

func (*Response) FastWriteNocopy

func (p *Response) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*Response) Field1DeepEqual

func (p *Response) Field1DeepEqual(src string) bool

func (*Response) GetMessage

func (p *Response) GetMessage() (v string)

func (*Response) InitDefault

func (p *Response) InitDefault()

func (*Response) Read

func (p *Response) Read(iprot thrift.TProtocol) (err error)

func (*Response) ReadField1

func (p *Response) ReadField1(iprot thrift.TProtocol) error

func (*Response) SetMessage

func (p *Response) SetMessage(val string)

func (*Response) String

func (p *Response) String() string

func (*Response) Write

func (p *Response) Write(oprot thrift.TProtocol) (err error)

type Usage

type Usage struct {
	PromptTokens     int32 `thrift:"PromptTokens,1" frugal:"1,default,i32" json:"PromptTokens"`
	CompletionTokens int32 `thrift:"CompletionTokens,2" frugal:"2,default,i32" json:"CompletionTokens"`
	TotalTokens      int32 `thrift:"TotalTokens,3" frugal:"3,default,i32" json:"TotalTokens"`
}
var ChatCompletionResponse_Usage_DEFAULT *Usage

func NewUsage

func NewUsage() *Usage

func (*Usage) BLength

func (p *Usage) BLength() int

func (*Usage) DeepEqual

func (p *Usage) DeepEqual(ano *Usage) bool

func (*Usage) FastRead

func (p *Usage) FastRead(buf []byte) (int, error)

func (*Usage) FastReadField1

func (p *Usage) FastReadField1(buf []byte) (int, error)

func (*Usage) FastReadField2

func (p *Usage) FastReadField2(buf []byte) (int, error)

func (*Usage) FastReadField3

func (p *Usage) FastReadField3(buf []byte) (int, error)

func (*Usage) FastWrite

func (p *Usage) FastWrite(buf []byte) int

for compatibility

func (*Usage) FastWriteNocopy

func (p *Usage) FastWriteNocopy(buf []byte, binaryWriter bthrift.BinaryWriter) int

func (*Usage) Field1DeepEqual

func (p *Usage) Field1DeepEqual(src int32) bool

func (*Usage) Field2DeepEqual

func (p *Usage) Field2DeepEqual(src int32) bool

func (*Usage) Field3DeepEqual

func (p *Usage) Field3DeepEqual(src int32) bool

func (*Usage) GetCompletionTokens

func (p *Usage) GetCompletionTokens() (v int32)

func (*Usage) GetPromptTokens

func (p *Usage) GetPromptTokens() (v int32)

func (*Usage) GetTotalTokens

func (p *Usage) GetTotalTokens() (v int32)

func (*Usage) InitDefault

func (p *Usage) InitDefault()

func (*Usage) Read

func (p *Usage) Read(iprot thrift.TProtocol) (err error)

func (*Usage) ReadField1

func (p *Usage) ReadField1(iprot thrift.TProtocol) error

func (*Usage) ReadField2

func (p *Usage) ReadField2(iprot thrift.TProtocol) error

func (*Usage) ReadField3

func (p *Usage) ReadField3(iprot thrift.TProtocol) error

func (*Usage) SetCompletionTokens

func (p *Usage) SetCompletionTokens(val int32)

func (*Usage) SetPromptTokens

func (p *Usage) SetPromptTokens(val int32)

func (*Usage) SetTotalTokens

func (p *Usage) SetTotalTokens(val int32)

func (*Usage) String

func (p *Usage) String() string

func (*Usage) Write

func (p *Usage) Write(oprot thrift.TProtocol) (err error)

Directories

Path Synopsis
Code generated by Kitex v0.5.0.
Code generated by Kitex v0.5.0.

Jump to

Keyboard shortcuts

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