Class: Boxcars::Together
- Inherits:
-
IntelligenceBase
- Object
- Engine
- IntelligenceBase
- Boxcars::Together
- Defined in:
- lib/boxcars/engine/together.rb
Overview
A engine that uses Google’s API
Constant Summary collapse
- DEFAULT_PARAMS =
The default parameters to use when asking the engine
{ model: "deepseek-ai/DeepSeek-R1-Distill-Llama-70B", temperature: 0.1 }.freeze
- DEFAULT_NAME =
the default name of the engine
"DeepSeek R1 Distill Llama 70B AI engine"- DEFAULT_DESCRIPTION =
the default description of the engine
"useful for when you need to use DeepSeek AI to process complex content. " \ "Supports text, images, and other content types"
Instance Attribute Summary
Attributes inherited from IntelligenceBase
Attributes inherited from Engine
#batch_size, #prompts, #user_id
Instance Method Summary collapse
- #default_model_params ⇒ Object
-
#initialize(name: DEFAULT_NAME, description: DEFAULT_DESCRIPTION, prompts: [], batch_size: 20) ⇒ Together
constructor
A DeepSeek Engine is used by Boxcars to generate output from prompts.
- #lookup_provider_api_key(params:) ⇒ Object
Methods inherited from IntelligenceBase
#adapter, #client, #process_content, #run, #validate_content
Methods inherited from Engine
#extract_answer, #generate, #generation_info, #get_num_tokens, #run, #validate_response!
Constructor Details
#initialize(name: DEFAULT_NAME, description: DEFAULT_DESCRIPTION, prompts: [], batch_size: 20) ⇒ Together
A DeepSeek Engine is used by Boxcars to generate output from prompts
24 25 26 |
# File 'lib/boxcars/engine/together.rb', line 24 def initialize(name: DEFAULT_NAME, description: DEFAULT_DESCRIPTION, prompts: [], batch_size: 20, **) super(provider: :together_ai, description:, name:, prompts:, batch_size:, **) end |
Instance Method Details
#default_model_params ⇒ Object
28 29 30 |
# File 'lib/boxcars/engine/together.rb', line 28 def default_model_params DEFAULT_PARAMS end |
#lookup_provider_api_key(params:) ⇒ Object
32 33 34 |
# File 'lib/boxcars/engine/together.rb', line 32 def lookup_provider_api_key(params:) Boxcars.configuration.together_api_key(**params) end |