import type { AuditOutput, PluginScoreTargets, Report } from '@code-pushup/models'; import type { ScoredReport } from './types.js'; export declare class GroupRefInvalidError extends Error { constructor(auditSlug: string, pluginSlug: string); } export declare function scoreReport(report: Report): ScoredReport; export declare function calculateScore(refs: T[], scoreFn: (ref: T) => number): number; /** * Sets audit score to 1 if it meets target. * @param audit audit output to evaluate * @param scoreTarget threshold for perfect score (0-1) * @returns Audit with scoreTarget field */ export declare function scoreAuditWithTarget(audit: AuditOutput, scoreTarget: number): AuditOutput; /** * Sets audit scores to 1 when targets are met. * @param audits audit outputs from plugin execution * @param scoreTargets number or { slug: target } mapping * @returns Transformed audits with scoreTarget field */ export declare function scoreAuditsWithTarget(audits: AuditOutput[], scoreTargets: PluginScoreTargets): AuditOutput[];