Class: RubyLLM::Contract::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/ruby_llm/contract/configuration.rb

Overview

Configuration for ruby_llm-contract.

API keys should be configured directly via RubyLLM:

RubyLLM.configure { |c| c.openai_api_key = ENV["OPENAI_API_KEY"] }

Then configure contract-specific options:

RubyLLM::Contract.configure { |c| c.default_model = "gpt-4.1-mini" }

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



15
16
17
18
19
# File 'lib/ruby_llm/contract/configuration.rb', line 15

def initialize
  @default_adapter = nil
  @default_model = nil
  @logger = nil
end

Instance Attribute Details

#default_adapterObject

Returns the value of attribute default_adapter.



13
14
15
# File 'lib/ruby_llm/contract/configuration.rb', line 13

def default_adapter
  @default_adapter
end

#default_modelObject

Returns the value of attribute default_model.



13
14
15
# File 'lib/ruby_llm/contract/configuration.rb', line 13

def default_model
  @default_model
end

#loggerObject

Returns the value of attribute logger.



13
14
15
# File 'lib/ruby_llm/contract/configuration.rb', line 13

def logger
  @logger
end