Documentation
¶
Overview ¶
Package datadog provides a client wrapper for the Datadog AI proxy API that complies with the ai.Provider interface.
Index ¶
Constants ¶
const DefaultModel = "gpt-4o"
DefaultModel is the default model to use when making requests to the API.
const ErrInvalidRequest xerrors.Error = "invalid request: must provide either an image or text"
ErrInvalidRequest is returned when the request provided to the Datadog proxy API is missing both an image and text.
Variables ¶
This section is empty.
Functions ¶
func NewRequest ¶
func NewRequest(req *ai.Request) openai.ChatCompletionRequest
NewTextRequest creates a chat completion request with streaming support for the Datadog API given the provided ai.Request object.
func NewRequestWithImage ¶
func NewRequestWithImage(req *ai.Request) openai.ChatCompletionRequest
NewRequestWithImage creates a chat completion request with streaming support for the Datadog API given the provided ai.Request object. The req.Content field should be a base64-encoded image.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client represents a Datadog AI proxy API client that complies with the ai.Provider interface.