Class: LLM::Shell::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/llm/shell/config.rb

Instance Method Summary collapse

Constructor Details

#initialize(provider) ⇒ LLM::Shell::Config

Parameters:

  • provider (String)


8
9
10
# File 'lib/llm/shell/config.rb', line 8

def initialize(provider)
  @provider = provider
end

Instance Method Details

#merge(other) ⇒ Hash

Returns:

  • (Hash)


14
15
16
# File 'lib/llm/shell/config.rb', line 14

def merge(other)
  to_h.merge(other)
end

#to_hHash

Returns:

  • (Hash)


20
21
22
# File 'lib/llm/shell/config.rb', line 20

def to_h
  yaml[@provider] || {}
end