Sha256: feaf115ad8761166690bd2695278e74e4d86143bcc3960ed04c28f4a3b803868

Contents?: true

Size: 863 Bytes

Versions: 28

Compression:

Stored size: 863 Bytes

Contents

# frozen_string_literal: true

# Base Stage class
class BaseStage
  #
  # Initialize Stage with ConceptAI
  # @param concept_ai (ConceptAI)
  def initialize(concept_ai)
    @concept_ai = concept_ai
  end

  def run
    raise 'Implement run method!'
  end

  def concept
    @concept_ai.concept
  end

  def name(option = :raw)
    @concept_ai.concept.name(option)
  end

  def names
    raise 'Change names by concept.names'
  end

  def num
    @concept_ai.num
  end

  def lang
    raise 'Change lang by concept.lang'
  end

  def type
    raise 'Change type by concept.type'
  end

  def texts
    raise 'Change texts by cocept.texts'
  end

  def images
    raise 'Change images by cocept.images'
  end

  def neighbors
    raise 'Change neighbors by concept.neighbors'
  end

  def random_image_for(option)
    @concept_ai.random_image_for(option)
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
asker-tool-2.6.0 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.9 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.8 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.7 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.6 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.5 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.4 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.3 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.2 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.1 lib/asker/ai/stages/base_stage.rb
asker-tool-2.5.0 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.5 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.4 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.3 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.2 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.1 lib/asker/ai/stages/base_stage.rb
asker-tool-2.4.0 lib/asker/ai/stages/base_stage.rb
asker-tool-2.3.4 lib/asker/ai/stages/base_stage.rb
asker-tool-2.3.3 lib/asker/ai/stages/base_stage.rb
asker-tool-2.3.2 lib/asker/ai/stages/base_stage.rb