Class: Ask::Agent::ChatChunk

Inherits:
Data
  • Object
show all
Defined in:
lib/ask/agent/chat.rb

Overview

Chunk yielded during streaming from Ask::Agent::Chat#ask.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content

Returns:

  • (Object)

    the current value of content



16
17
18
# File 'lib/ask/agent/chat.rb', line 16

def content
  @content
end

#thinkingObject (readonly)

Returns the value of attribute thinking

Returns:

  • (Object)

    the current value of thinking



16
17
18
# File 'lib/ask/agent/chat.rb', line 16

def thinking
  @thinking
end

#tool_callsObject (readonly)

Returns the value of attribute tool_calls

Returns:

  • (Object)

    the current value of tool_calls



16
17
18
# File 'lib/ask/agent/chat.rb', line 16

def tool_calls
  @tool_calls
end

Instance Method Details

#tool_call?Boolean

Returns:

  • (Boolean)


17
# File 'lib/ask/agent/chat.rb', line 17

def tool_call? = !tool_calls.empty?