Formats scanner findings for console, Markdown, or HTML presentation.
Value
A character vector of formatted finding explanations. For
format = "text", the value is returned invisibly after printing bullets.
Details
explain_findings() is a presentation helper. It does not rescore or
reclassify findings; it formats the finding metadata already present in a
shieldr_report(). Console output uses severity-colored bullets. Markdown
and HTML outputs return character vectors suitable for reports, notebooks,
or lightweight dashboards. Text output prints one set of bullets and returns
the character vector invisibly, so an interactive call does not repeat it.
Examples
report <- scan_prompt("email me at neel@example.com", policy("enterprise_default"))
explain_findings(report)
#> • llm02.pii.email [medium, llm02]: Email address.
