class Riffer::Providers::OpenAI
OpenAI provider for GPT models. Requires the openai gem.
Constants
- WEB_SEARCH_TOOL_TYPE
Public Class Methods
Source
# File lib/riffer/providers/open_ai.rb, line 17 def initialize(**options) depends_on "openai" api_key = options.fetch(:api_key, Riffer.config.openai.api_key) @client = ::OpenAI::Client.new(api_key: api_key, **options.except(:api_key)) end
Source
# File lib/riffer/providers/open_ai.rb, line 11 def self.semconv_provider_name "openai" end
The GenAI semconv well-known provider name.