Documentation
¶
Index ¶
Constants ¶
View Source
const ( DEEPSEEK_CHAT_MODEL = "deepseek-chat" DEEPSEEK_REASONER_MODEL = "deepseek-reasoner" )
View Source
const DEFAULT_TIMEOUT_SECONDS = 120
Variables ¶
This section is empty.
Functions ¶
func NewConfigWithDefaults ¶ added in v0.4.0
NewConfigWithDefaults returns client config with default values.
Types ¶
type Client ¶
type Client interface { // CallChatCompletionsChat calls chat api with model=deepseek-chat and stream=false. // It returns response from DeepSeek-V3 model. CallChatCompletionsChat(ctx context.Context, chatReq *request.ChatCompletionsRequest) (*response.ChatCompletionsResponse, error) // CallChatCompletionsReasoner calls chat api with model=deepseek-reasoner and stream=false. // It returns response from DeepSeek-R1 model. CallChatCompletionsReasoner(ctx context.Context, chatReq *request.ChatCompletionsRequest) (*response.ChatCompletionsResponse, error) // StreamChatCompletionsChat calls chat api with model=deepseek-chat and stream=true. // It returns response from DeepSeek-V3 model. StreamChatCompletionsChat(ctx context.Context, chatReq *request.ChatCompletionsRequest) (response.StreamReader, error) // StreamChatCompletionsReasoner calls chat api with model=deepseek-reasoner and stream=true. // It returns response from DeepSeek-R1 model. StreamChatCompletionsReasoner(ctx context.Context, chatReq *request.ChatCompletionsRequest) (response.StreamReader, error) // PingChatCompletions is a ping to check go deepseek client is working fine. PingChatCompletions(ctx context.Context, inputMessage string) (outputMessge string, err error) }
Client interface defines methods for interacting with the DeepSeek API.
Click to show internal directories.
Click to hide internal directories.