Documentation
¶
Index ¶
- Variables
- func EmbeddingText(ctx context.Context, input string) (embedded []float32, tokenUsage model.Usage, err error)
- func GenerateChat(ctx context.Context, historyMsgList ...string) (answer string)
- func SingleChat(ctx context.Context, sysPrompt, userPrompt string) (string, error)
- func SingleChatModel(ctx context.Context, sysPrompt, userPrompt, modelID string) (string, error)
- func SingleChatPrompt(ctx context.Context, prompt string) (string, error)
- func SingleChatStreamingPrompt(ctx context.Context, sysPrompt, modelID string, files ...string) (iter.Seq[*ModelStreamRespReasoning], error)
- type ModelStreamRespReasoning
Constants ¶
This section is empty.
Variables ¶
View Source
var ( DOUBAO_EMBEDDING_EPID = os.Getenv("DOUBAO_EMBEDDING_EPID") DOUBAO_API_KEY = os.Getenv("DOUBAO_API_KEY") ARK_NORMAL_EPID = os.Getenv("ARK_NORMAL_EPID") ARK_REASON_EPID = os.Getenv("ARK_REASON_EPID") ARK_VISION_EPID = os.Getenv("ARK_VISION_EPID") NORMAL_MODEL_BOT_ID = os.Getenv("NORMAL_MODEL_BOT_ID") REASON_MODEL_BOT_ID = os.Getenv("REASON_MODEL_BOT_ID") )
Functions ¶
func EmbeddingText ¶
func EmbeddingText(ctx context.Context, input string) (embedded []float32, tokenUsage model.Usage, err error)
EmbeddingText returns the embedding of the input text.
@param ctx @param input @return embedded @return err
func GenerateChat ¶
func SingleChat ¶
func SingleChatModel ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.