Class: Olyx::Guardrails::CheckRunner
- Inherits:
-
Object
- Object
- Olyx::Guardrails::CheckRunner
- Defined in:
- lib/olyx/guardrails/check_runner.rb
Overview
Orchestrates deterministic checks and optional semantic enrichment.
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(input, policy:, llm_provider:) ⇒ CheckRunner
constructor
A new instance of CheckRunner.
Constructor Details
#initialize(input, policy:, llm_provider:) ⇒ CheckRunner
Returns a new instance of CheckRunner.
18 19 20 21 22 23 |
# File 'lib/olyx/guardrails/check_runner.rb', line 18 def initialize(input, policy:, llm_provider:) @source = input.to_s @policy = policy @llm_provider = llm_provider end |
Class Method Details
.call(input) ⇒ Object
14 15 16 |
# File 'lib/olyx/guardrails/check_runner.rb', line 14 def self.call(input, **) new(input, **).call end |
Instance Method Details
#call ⇒ Object
25 26 27 28 |
# File 'lib/olyx/guardrails/check_runner.rb', line 25 def call checks = CheckSet.call(@source, policy: @policy) CheckPipeline.call(@source, checks, policy: @policy, llm_provider: @llm_provider) end |