Rendering
Fluent interface for rendering templates and generating LLM responses. Provides operations for:
Creating strongly-typed objects from rendered templates
Generating text from rendered templates
Responding in conversations with templates as system prompts
Instances are obtained via PromptRunner.rendering.
Inheritors
Functions
Generate text using the given model to render the template and LLM options from context.
Safely respond to the user in the conversation using the rendered template as system prompt, returning an error message if something goes wrong. Cannot throw an exception.
Respond in the conversation using the rendered template as system prompt.
Respond to a system-initiated trigger using the rendered template as system prompt. The trigger prompt is appended as a user message to the LLM call but not stored in the conversation.
Set the template renderer to use for rendering templates in this mode. By default, this Renderer will use the platform's default TemplateRenderer, but this allows for custom renderers to be used on a per-rendering basis.