Class: Phronomy::Configuration

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

Overview

Holds global configuration for the entire framework. Configure via the Phronomy.configure block.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
# File 'lib/phronomy/configuration.rb', line 60

def initialize
  @recursion_limit = 25
  @tracer = Phronomy::Tracing::NullTracer.new
  @trace_pii = false
  @parallel_tool_execution = false
  @event_loop_stop_grace_seconds = 5
  @llm_adapter = Phronomy::LLMAdapter::RubyLLM.new
  @event_loop_starvation_threshold_seconds = nil
  @event_loop_dispatch_threshold_seconds = nil
  @scheduler_debug = false
  @blocking_detect_threshold_ms = nil
  @stream_callback_error_policy = :report
  @blocking_io_pool_size = 10
  @blocking_io_queue_size = 100
  @authorization_pool_size = 4
  @authorization_queue_size = 100
  @authorization_timeout = 5
  @starvation_threshold_ms = 50
  @runtime_backend = :thread
  @strict_runtime_guards = false
end

Instance Attribute Details

#authorization_pool_sizeObject

Returns the value of attribute authorization_pool_size.



31
32
33
# File 'lib/phronomy/configuration.rb', line 31

def authorization_pool_size
  @authorization_pool_size
end

#authorization_queue_sizeObject

Returns the value of attribute authorization_queue_size.



32
33
34
# File 'lib/phronomy/configuration.rb', line 32

def authorization_queue_size
  @authorization_queue_size
end

#authorization_timeoutObject

Returns the value of attribute authorization_timeout.



33
34
35
# File 'lib/phronomy/configuration.rb', line 33

def authorization_timeout
  @authorization_timeout
end

#before_llm_inputObject

Returns the value of attribute before_llm_input.



14
15
16
# File 'lib/phronomy/configuration.rb', line 14

def before_llm_input
  @before_llm_input
end

#blocking_detect_threshold_msObject

Returns the value of attribute blocking_detect_threshold_ms.



27
28
29
# File 'lib/phronomy/configuration.rb', line 27

def blocking_detect_threshold_ms
  @blocking_detect_threshold_ms
end

#blocking_io_pool_sizeObject

Returns the value of attribute blocking_io_pool_size.



29
30
31
# File 'lib/phronomy/configuration.rb', line 29

def blocking_io_pool_size
  @blocking_io_pool_size
end

#blocking_io_queue_sizeObject

Returns the value of attribute blocking_io_queue_size.



30
31
32
# File 'lib/phronomy/configuration.rb', line 30

def blocking_io_queue_size
  @blocking_io_queue_size
end

#default_embedding_modelObject

Returns the value of attribute default_embedding_model.



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

def default_embedding_model
  @default_embedding_model
end

#default_modelObject

Returns the value of attribute default_model.



11
12
13
# File 'lib/phronomy/configuration.rb', line 11

def default_model
  @default_model
end

#default_output_reserveObject

Returns the value of attribute default_output_reserve.



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

def default_output_reserve
  @default_output_reserve
end

#event_loop_dispatch_threshold_secondsObject

Returns the value of attribute event_loop_dispatch_threshold_seconds.



25
26
27
# File 'lib/phronomy/configuration.rb', line 25

def event_loop_dispatch_threshold_seconds
  @event_loop_dispatch_threshold_seconds
end

#event_loop_starvation_threshold_secondsObject

Returns the value of attribute event_loop_starvation_threshold_seconds.



24
25
26
# File 'lib/phronomy/configuration.rb', line 24

def event_loop_starvation_threshold_seconds
  @event_loop_starvation_threshold_seconds
end

#event_loop_stop_grace_secondsObject

Returns the value of attribute event_loop_stop_grace_seconds.



20
21
22
# File 'lib/phronomy/configuration.rb', line 20

def event_loop_stop_grace_seconds
  @event_loop_stop_grace_seconds
end

#llm_adapterObject

Returns the value of attribute llm_adapter.



23
24
25
# File 'lib/phronomy/configuration.rb', line 23

def llm_adapter
  @llm_adapter
end

#loggerObject

Returns the value of attribute logger.



19
20
21
# File 'lib/phronomy/configuration.rb', line 19

def logger
  @logger
end

#parallel_tool_executionObject

Returns the value of attribute parallel_tool_execution.



17
18
19
# File 'lib/phronomy/configuration.rb', line 17

def parallel_tool_execution
  @parallel_tool_execution
end

#recursion_limitObject

Returns the value of attribute recursion_limit.



16
17
18
# File 'lib/phronomy/configuration.rb', line 16

def recursion_limit
  @recursion_limit
end

#runtime_backendObject

Returns the value of attribute runtime_backend.



35
36
37
# File 'lib/phronomy/configuration.rb', line 35

def runtime_backend
  @runtime_backend
end

#scheduler_debugObject

Returns the value of attribute scheduler_debug.



26
27
28
# File 'lib/phronomy/configuration.rb', line 26

def scheduler_debug
  @scheduler_debug
end

#starvation_threshold_msObject

Returns the value of attribute starvation_threshold_ms.



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

def starvation_threshold_ms
  @starvation_threshold_ms
end

#state_storeObject

Returns the value of attribute state_store.



21
22
23
# File 'lib/phronomy/configuration.rb', line 21

def state_store
  @state_store
end

#stream_callback_error_policyObject

Returns the value of attribute stream_callback_error_policy.



28
29
30
# File 'lib/phronomy/configuration.rb', line 28

def stream_callback_error_policy
  @stream_callback_error_policy
end

#strict_runtime_guardsObject

Returns the value of attribute strict_runtime_guards.



36
37
38
# File 'lib/phronomy/configuration.rb', line 36

def strict_runtime_guards
  @strict_runtime_guards
end

#tool_result_max_sizeObject

Returns the value of attribute tool_result_max_size.



22
23
24
# File 'lib/phronomy/configuration.rb', line 22

def tool_result_max_size
  @tool_result_max_size
end

#trace_piiObject

Returns the value of attribute trace_pii.



18
19
20
# File 'lib/phronomy/configuration.rb', line 18

def trace_pii
  @trace_pii
end

#tracerObject

Returns the value of attribute tracer.



13
14
15
# File 'lib/phronomy/configuration.rb', line 13

def tracer
  @tracer
end