AIAgentLLMWriteSessionAPI
API of the AIAgentLLMWriteSession
Inheritors
Properties
Config of the agent running the session.
Represents the current execution environment for the AI agent.
Represents the active response processor within the session. The processor defines the post-processing of messages returned from the LLM.
A registry that holds information about available tools within the system. This registry is typically used for managing tool instances and their configurations.
Represents a collection of tools that are available for the session. The tools can be accessed or modified only if the session is in an active state.
Functions
Appends messages to the current prompt by applying modifications defined in the provided block. The modifications are applied using a PromptBuilder instance, allowing for customization of the prompt's content, structure, and associated messages.
Updates the language model's parameters used in the current session prompt.
Updates the underlying model in the current prompt with the specified new model.
Parses a structured response from the language model using the specified configuration.
Sends a request to the underlying LLM and returns the first response. This method ensures the session is active before executing the request.
Sends a request to the language model while enforcing the use of a specific tool, and returns the response.
Sends a request to the language model, potentially utilizing multiple tools, and returns a list of responses from the model.
Sends a request to the language model, potentially receiving multiple choices, and returns a list of choices from the model.
Sends a request to the language model that enforces the usage of tools and retrieves all responses.
Sends a request to the language model without utilizing any tools and returns multiple responses.
Sends a request to the language model that enforces the usage of tools and retrieves the response.
Sends a streaming request to the underlying LLM and returns the streamed response. This method ensures the session is active before executing the request.
Streams the result of a request to a language model.
Sends a request to LLM and gets a structured response.
Sends a request to the language model without utilizing any tools and returns the response.
Sends a moderation request to the specified or default large language model (LLM) for content moderation.
Rewrites the current prompt by applying a transformation function.
Updates the current prompt by applying modifications defined in the provided block. The modifications are applied using a PromptBuilder instance, allowing for customization of the prompt's content, structure, and associated messages.