Module: Omen::Spoken

Extended by:
ActiveSupport::Concern
Included in:
Answer, Question
Defined in:
app/models/omen/spoken.rb

Overview

Extends a question and an answer with the prose said in it, in the blocks Claude speaks in.

Instance Method Summary collapse

Instance Method Details

#textString

Returns everything said in prose, which on an answer may be nothing.

Returns:

  • (String)

    everything said in prose, which on an answer may be nothing.



4
# File 'app/models/omen/spoken.rb', line 4

def text = content.select { |block| block['type'] == 'text' }.pluck('text').join "\n"