module RubyLLM::ActiveRecord::ChatHelper

View helpers for a chat’s page, available in every view of a Rails app. The views bin/rails generate ruby_llm:chat_ui writes use them.

<%= render tool_call_partial(tool_call), message:, tool_call: %>
Cost so far: <%= cost_label(@chat.cost) %>

To change one, define a method with the same name in a helper of your own, such as app/helpers/messages_helper.rb: it takes the place of RubyLLM’s. An app whose chat UI was generated before RubyLLM shipped these keeps the MessagesHelper the generator wrote, and its methods win the same way.