Class: KairosMcp::DslAst::DriftReport
- Inherits:
-
Struct
- Object
- Struct
- KairosMcp::DslAst::DriftReport
- Defined in:
- lib/kairos_mcp/dsl_ast/drift_detector.rb
Overview
Report of all detected drifts for a skill
Instance Attribute Summary collapse
-
#coverage_ratio ⇒ Object
Returns the value of attribute coverage_ratio.
-
#items ⇒ Object
Returns the value of attribute items.
-
#skill_id ⇒ Object
Returns the value of attribute skill_id.
-
#timestamp ⇒ Object
Returns the value of attribute timestamp.
Instance Method Summary collapse
Instance Attribute Details
#coverage_ratio ⇒ Object
Returns the value of attribute coverage_ratio
11 12 13 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 11 def coverage_ratio @coverage_ratio end |
#items ⇒ Object
Returns the value of attribute items
11 12 13 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 11 def items @items end |
#skill_id ⇒ Object
Returns the value of attribute skill_id
11 12 13 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 11 def skill_id @skill_id end |
#timestamp ⇒ Object
Returns the value of attribute timestamp
11 12 13 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 11 def @timestamp end |
Instance Method Details
#drifted? ⇒ Boolean
12 13 14 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 12 def drifted? !items.empty? end |
#errors ⇒ Object
16 17 18 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 16 def errors items.select { |i| i.severity == :error } end |
#infos ⇒ Object
24 25 26 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 24 def infos items.select { |i| i.severity == :info } end |
#summary ⇒ Object
28 29 30 31 32 33 34 35 36 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 28 def summary { total: items.size, errors: errors.size, warnings: warnings.size, info: infos.size, coverage_ratio: coverage_ratio } end |
#warnings ⇒ Object
20 21 22 |
# File 'lib/kairos_mcp/dsl_ast/drift_detector.rb', line 20 def warnings items.select { |i| i.severity == :warning } end |