cmd

package
v1.2.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 3, 2026 License: AGPL-3.0 Imports: 48 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute()

Types

type DraftFileReport added in v1.1.0

type DraftFileReport struct {
	Filename    string              `json:"file"`
	Score       int                 `json:"score"`
	Grade       string              `json:"grade"`
	Profile     string              `json:"profile"` // "strict" | "free-form"
	Suggestions []angela.Suggestion `json:"suggestions"`
}

DraftFileReport captures the result of analyzing a single document. Used by both human and JSON reporters to avoid a second data pass.

type DraftReport added in v1.1.0

type DraftReport struct {
	Version  int                         `json:"version"`
	Mode     string                      `json:"mode"`     // "lore-native"|"hybrid"|"standalone"
	Scanned  int                         `json:"scanned"`  // total docs analyzed
	Reviewed int                         `json:"reviewed"` // docs with at least one finding
	Files    []DraftFileReport           `json:"files"`
	Summary  DraftSummary                `json:"summary"`
	Diff     *angela.DraftDiff           `json:"diff_summary,omitempty"`
	Resolved []angela.ResolvedSuggestion `json:"resolved,omitempty"`
}

DraftReport is the complete output of a draft run (single file or --all). It captures everything the reporters need: mode, counts, per-file details and aggregated summary.

Diff + Resolved (omitempty): when differential mode is active, Diff carries the aggregate new/persisting/resolved counts and Resolved lists the findings that disappeared since the previous run (including findings whose source file was deleted entirely).

type DraftReporter added in v1.1.0

type DraftReporter interface {
	Report(r DraftReport) error
	ReportFile(f DraftFileReport)
}

DraftReporter renders a DraftReport to an output stream. Implementations decide the format (human-readable or machine-parseable JSON).

Report() is called once with the complete, finalized report. This is the primary rendering path for JSON and tests.

ReportFile() is an optional streaming hook: the runner calls it after each per-file analysis to let the human reporter show the row inline with the progress bar. JSON reporters implement it as a no-op and emit the full payload only from Report().

type DraftSummary added in v1.1.0

type DraftSummary struct {
	TotalSuggestions int            `json:"total_suggestions"`
	BySeverity       map[string]int `json:"by_severity"`
	ByCategory       map[string]int `json:"by_category"`
}

DraftSummary holds aggregated counts for the report footer and for structured CI consumption.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL