Expand description
This module enables the implementation of chat completion on LLM providers
The main trait to implement is ChatCompletion
, which takes a ChatCompletionRequest
and returns a ChatCompletionResponse
.
A chat completion request is comprised of a list of ChatMessage
to complete, with optionally
tool specifications. The response optionally contains a message and zero or more tool calls.
Modules§
Structs§
- A chat completion request represents a series of chat messages and tool interactions that can be send to any LLM.
- Builder for
ChatCompletionRequest
. - Builder for
ChatCompletionResponse
. - Builder for
ParamSpec
. - A tool call that can be executed by the executor
- Builder for
ToolCall
. - A typed tool specification intended to be usable for multiple LLMs
- Builder for
ToolSpec
.
Enums§
- Error type for ChatCompletionRequestBuilder
- Error type for ParamSpecBuilder
- Error type for ToolCallBuilder
- Output of a
ToolCall
which will be added as a message for the agent to use. - Error type for ToolSpecBuilder