/** * `totem triage-pr ` — Categorized triage view of bot review * comments on a pull request. * * Fetches inline review comments, filters to bot authors, normalizes * into structured findings, deduplicates, categorizes by blast radius, * and renders a compact inbox to stdout. */ import type { CategorizedFinding } from '../parsers/triage-types.js'; /** Surface counts feeding the empty-state decision. */ export interface TriageSurfaceCounts { /** Inline comment threads whose root author is a recognized review bot. */ botThreads: number; /** Findings parsed from review-bodies + bot issue-comment summaries. */ bodyFindings: number; /** Bot-authored issue comments fetched (summaries), regardless of parsed findings. */ botIssueComments: number; /** Total inline review comments fetched (any author). */ inlineComments: number; /** Total review submissions fetched (any author). */ reviews: number; /** Total issue comments fetched (any author). */ issueComments: number; } /** * Decide whether there is anything to triage, and — when not — what to report. * * Invariant (mmnto-ai/totem#2192): triage is "empty" ONLY when zero bot material * was found across every surface (inline bot threads + parsed body/summary * findings + bot summary issue-comments). When raw comments WERE fetched but none * came from a recognized bot, the message surfaces the counts rather than a bare * "Nothing to triage", so a stale/incomplete classifier can never masquerade as a * clean PR (the #2190 miss). Pure + exported for testing. */ export declare function evaluateTriageEmptyState(counts: TriageSurfaceCounts): { empty: boolean; message?: string; /** True when raw material existed (→ log visibly), false when the PR was truly bare. */ surfaced?: boolean; }; /** * Format the complete triage output. Exported for testing. */ export declare function formatTriageOutput(prNumber: number, findings: CategorizedFinding[], totalComments: number, colorize: { red: (s: string) => string; yellow: (s: string) => string; blue: (s: string) => string; gray: (s: string) => string; bold: (s: string) => string; }): string; export interface TriagePrOptions { interactive?: boolean; } export declare function triagePrCommand(prNumber: string, options?: TriagePrOptions): Promise; //# sourceMappingURL=triage-pr.d.ts.map