Class: Ask::Agent::Configuration

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# File 'lib/ask/agent/configuration.rb', line 17

def initialize
  @default_model = "gpt-4o"
  @default_max_turns = 25
  @compactor_enabled = true
  @compactor_threshold = nil
  @compactor_reserve_tokens = nil
  @compactor_keep_recent_tokens = nil
  @parallel_tool_execution = true
  @max_tool_retries = 3
  @prompt_caching = true

  @middleware = Middleware::Pipeline.new
  @stream_transforms = StreamTransforms::Pipeline.new
  @scheduler_config = SchedulerConfig.new(self)
end

Instance Attribute Details

#audit_logObject

Returns the value of attribute audit_log.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def audit_log
  @audit_log
end

#compactor_enabledObject

Returns the value of attribute compactor_enabled.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def compactor_enabled
  @compactor_enabled
end

#compactor_keep_recent_tokensObject

Returns the value of attribute compactor_keep_recent_tokens.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def compactor_keep_recent_tokens
  @compactor_keep_recent_tokens
end

#compactor_reserve_tokensObject

Returns the value of attribute compactor_reserve_tokens.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def compactor_reserve_tokens
  @compactor_reserve_tokens
end

#compactor_thresholdObject

Returns the value of attribute compactor_threshold.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def compactor_threshold
  @compactor_threshold
end

#default_evaluator_modelObject

Returns the value of attribute default_evaluator_model.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def default_evaluator_model
  @default_evaluator_model
end

#default_max_turnsObject

Returns the value of attribute default_max_turns.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def default_max_turns
  @default_max_turns
end

#default_modelObject

Returns the value of attribute default_model.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def default_model
  @default_model
end

#default_providerObject

Returns the value of attribute default_provider.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def default_provider
  @default_provider
end

#max_tool_retriesObject

Returns the value of attribute max_tool_retries.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def max_tool_retries
  @max_tool_retries
end

#middlewareMiddleware::Pipeline (readonly)

Returns the middleware pipeline for provider calls.

Returns:



12
13
14
# File 'lib/ask/agent/configuration.rb', line 12

def middleware
  @middleware
end

#parallel_tool_executionObject

Returns the value of attribute parallel_tool_execution.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def parallel_tool_execution
  @parallel_tool_execution
end

#prompt_cachingObject

Returns the value of attribute prompt_caching.



6
7
8
# File 'lib/ask/agent/configuration.rb', line 6

def prompt_caching
  @prompt_caching
end

#stream_transformsStreamTransforms::Pipeline (readonly)

Returns the stream transforms pipeline.

Returns:



15
16
17
# File 'lib/ask/agent/configuration.rb', line 15

def stream_transforms
  @stream_transforms
end

Instance Method Details

#schedulerSchedulerConfig

Returns DSL for defining recurring agent tasks.

Returns:



34
35
36
# File 'lib/ask/agent/configuration.rb', line 34

def scheduler
  @scheduler_config
end