Module: Ollama::Handlers::Concern

Extended by:
Tins::Concern, Tins::Implement
Included in:
Collector, DumpJSON, DumpYAML, Markdown, NOP, Print, Progress, Say, Single
Defined in:
lib/ollama/handlers/concern.rb

Defined Under Namespace

Modules: ClassMethods

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#outputObject (readonly)

Returns the value of attribute output.



12
13
14
# File 'lib/ollama/handlers/concern.rb', line 12

def output
  @output
end

#resultObject (readonly)

Returns the value of attribute result.



14
15
16
# File 'lib/ollama/handlers/concern.rb', line 14

def result
  @result
end

Instance Method Details

#initialize(output: $stdout) ⇒ Object



8
9
10
# File 'lib/ollama/handlers/concern.rb', line 8

def initialize(output: $stdout)
  @output = output
end

#to_procObject



18
19
20
# File 'lib/ollama/handlers/concern.rb', line 18

def to_proc
  -> response { call(response) }
end