Class: Agentic::Verification::CriticResult
- Inherits:
-
Object
- Object
- Agentic::Verification::CriticResult
- Defined in:
- lib/agentic/verification/critic_framework.rb
Overview
Represents the result of a critic’s evaluation
Instance Attribute Summary collapse
-
#comments ⇒ Array<String>
readonly
Comments from the critic.
-
#confidence ⇒ Float
readonly
The confidence of the evaluation (0.0-1.0).
-
#task_id ⇒ String
readonly
The ID of the task that was evaluated.
-
#verdict ⇒ Boolean
readonly
The verdict of the evaluation (true = pass, false = fail).
Instance Method Summary collapse
-
#initialize(task_id:, confidence:, verdict:, comments: []) ⇒ CriticResult
constructor
Initializes a new CriticResult.
-
#positive? ⇒ Boolean
Checks if the evaluation is positive.
-
#to_h ⇒ Hash
Converts the critic result to a hash.
Constructor Details
#initialize(task_id:, confidence:, verdict:, comments: []) ⇒ CriticResult
Initializes a new CriticResult
70 71 72 73 74 75 |
# File 'lib/agentic/verification/critic_framework.rb', line 70 def initialize(task_id:, confidence:, verdict:, comments: []) @task_id = task_id @confidence = confidence @verdict = verdict @comments = comments end |
Instance Attribute Details
#comments ⇒ Array<String> (readonly)
Returns Comments from the critic.
63 64 65 |
# File 'lib/agentic/verification/critic_framework.rb', line 63 def comments @comments end |
#confidence ⇒ Float (readonly)
Returns The confidence of the evaluation (0.0-1.0).
57 58 59 |
# File 'lib/agentic/verification/critic_framework.rb', line 57 def confidence @confidence end |
#task_id ⇒ String (readonly)
Returns The ID of the task that was evaluated.
54 55 56 |
# File 'lib/agentic/verification/critic_framework.rb', line 54 def task_id @task_id end |
#verdict ⇒ Boolean (readonly)
Returns The verdict of the evaluation (true = pass, false = fail).
60 61 62 |
# File 'lib/agentic/verification/critic_framework.rb', line 60 def verdict @verdict end |
Instance Method Details
#positive? ⇒ Boolean
Checks if the evaluation is positive
79 80 81 |
# File 'lib/agentic/verification/critic_framework.rb', line 79 def positive? @verdict end |
#to_h ⇒ Hash
Converts the critic result to a hash
85 86 87 88 89 90 91 92 |
# File 'lib/agentic/verification/critic_framework.rb', line 85 def to_h { task_id: @task_id, confidence: @confidence, verdict: @verdict, comments: @comments } end |