LLM Frames
Frame types for handling LLM interactions and responses in Pipecat
LLMMessagesFrame
Frame containing a list of messages for LLM chat completions.
Properties
List of message dictionaries representing the conversation history. Each message typically contains ‘role’ and ‘content’ keys.
Notes
Messages property is mutable and may be updated by ResponseAggregator processors.
LLMMessagesAppendFrame
Frame for adding new messages to the current context.
Properties
List of new messages to append to the current context
LLMMessagesUpdateFrame
Frame for replacing the current context with new messages.
Properties
List of messages that will replace the current context
LLMSetToolsFrame
Frame for configuring function calling capabilities.
Properties
List of tool definitions, typically in JSON Schema format
LLMEnablePromptCachingFrame
Frame for controlling prompt caching behavior.
Properties
Whether to enable or disable prompt caching
LLMFullResponseStartFrame
Control frame indicating the start of an LLM response sequence.
LLMFullResponseEndFrame
Control frame indicating the end of an LLM response sequence.
Usage Examples
Basic Message Management
Function Calling Setup
Common Pipeline Usage
Frame Flow
Notes
- Messages should follow the chat completion format of your LLM provider
- Tool definitions must match the schema expected by your LLM service
- Response sequences are bounded by Start/End frames
- Prompt caching can be controlled dynamically during pipeline execution