Class: ClaudeMemory::Audit::Finding
- Inherits:
-
Data
- Object
- Data
- ClaudeMemory::Audit::Finding
- Defined in:
- lib/claude_memory/audit/finding.rb
Overview
A single audit finding. Immutable value object emitted by checks (see Audit::Checks) and aggregated by Audit::Runner.
Severity levels:
- :error — a contract violation; CI/automation should fail
- :warn — likely problem requiring attention but not blocking
- :info — observation; suggests an optimization or cleanup
Each finding embeds the suggested remediation command(s) as plain strings so the audit output is directly actionable. The skill ‘/audit-memory` reads these and offers to run them for the user.
Instance Attribute Summary collapse
-
#detail ⇒ Object
readonly
Returns the value of attribute detail.
-
#fact_ids ⇒ Object
readonly
Returns the value of attribute fact_ids.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#severity ⇒ Object
readonly
Returns the value of attribute severity.
-
#suggestion ⇒ Object
readonly
Returns the value of attribute suggestion.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
Instance Attribute Details
#detail ⇒ Object (readonly)
Returns the value of attribute detail
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def detail @detail end |
#fact_ids ⇒ Object (readonly)
Returns the value of attribute fact_ids
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def fact_ids @fact_ids end |
#id ⇒ Object (readonly)
Returns the value of attribute id
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def id @id end |
#severity ⇒ Object (readonly)
Returns the value of attribute severity
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def severity @severity end |
#suggestion ⇒ Object (readonly)
Returns the value of attribute suggestion
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def suggestion @suggestion end |
#title ⇒ Object (readonly)
Returns the value of attribute title
16 17 18 |
# File 'lib/claude_memory/audit/finding.rb', line 16 def title @title end |
Instance Method Details
#error? ⇒ Boolean
17 |
# File 'lib/claude_memory/audit/finding.rb', line 17 def error? = severity == :error |
#info? ⇒ Boolean
19 |
# File 'lib/claude_memory/audit/finding.rb', line 19 def info? = severity == :info |
#to_h ⇒ Object
21 22 23 24 25 26 27 28 29 30 |
# File 'lib/claude_memory/audit/finding.rb', line 21 def to_h { id: id, severity: severity, title: title, detail: detail, suggestion: suggestion, fact_ids: fact_ids } end |
#warn? ⇒ Boolean
18 |
# File 'lib/claude_memory/audit/finding.rb', line 18 def warn? = severity == :warn |