Skip to content

Report

A report is what every grade returns. It bundles findings with top-level metadata so a caller (agent, CLI, Action) can render a verdict without recomputing anything.

{
"summary": "12 findings (0 errors, 7 warns, 5 info). Verdict: approve.",
"verdict": { "kind": "approve" },
"counts": { "info": 5, "warn": 7, "error": 0 },
"findings": [
{
"rule_id": "builtin.size.file-length",
"severity": "warn",
"path": "src/parser.rs",
"line": 412,
"message": "File length 412 exceeds warn threshold (400)"
},
]
}
FieldTypeNotes
summarystringOne-line synopsis suitable for an agent or a chat reply. Read this first.
verdictobject{ "kind": "approve" } or { "kind": "request_changes", "reasons": [...] }. See Verdict.
countsobject{ info, warn, error } totals.
findingsarrayAll findings, sorted by (severity desc, path, line). See Finding.

sextant grade --pr returns a richer wrapper around two reports:

{
"head": { /* full Report for the PR head */ },
"baseline": { /* full Report for the base SHA */ },
"delta": {
"new": [ /* findings only in head */ ],
"fixed": [ /* findings only in baseline */ ],
"unchanged_count": 12,
"new_counts": { "info": 0, "warn": 1, "error": 0 },
"fixed_counts": { "info": 0, "warn": 2, "error": 0 }
},
"verdict": { "kind": "approve" },
"summary": "1 new finding (1 warn). 2 findings fixed. Verdict: approve."
}

The verdict on a PrReport is computed against delta.new_counts, not against the head report’s totals — a PR that merely exposes an existing finding doesn’t block. See Verdict → regression mode.

FormatWhat you get
humanColoured terminal output for sextant grade (default).
jsonThe structured Report (or PrReport) above.
markdownA PR-comment-friendly markdown rendering. PR mode only.
sarifSARIF 2.1.0 for GitHub Code Scanning.
review-jsonA Review payload ready to POST to the GitHub PR Reviews API. PR mode only.

The --report-json <PATH> CLI flag is a side-channel: it always writes the structured report to a file, even when --format is markdown or SARIF. The Action uses this to render a markdown review while still parsing the JSON for verdict / counts.