/**
 * Next.js metadata audit (T1).
 *
 * Walks `app/**\/page.{tsx,jsx,ts,js}` files for `metadata` /
 * `generateMetadata` exports, scores each page using a weighted formula
 * (per design D4), and aggregates a per-route audit result with grade
 * distribution and top issues.
 */
import { type MetadataFields } from "../utils/nextjs.js";
export type MetadataGrade = "poor" | "needs_work" | "good" | "excellent";
export interface MetadataField {
    name: string;
    present: boolean;
    weight: number;
}
export interface MetadataScore {
    score: number;
    grade: MetadataGrade;
    violations: string[];
}
export interface NextjsMetadataAuditEntry {
    url_path: string;
    file_path: string;
    score: number;
    grade: MetadataGrade;
    violations: string[];
    missing_fields: string[];
}
export interface NextjsMetadataAuditCounts {
    excellent: number;
    good: number;
    needs_work: number;
    poor: number;
}
export interface NextjsMetadataAuditResult {
    total_pages: number;
    scores: NextjsMetadataAuditEntry[];
    counts: NextjsMetadataAuditCounts;
    top_issues: string[];
    workspaces_scanned: string[];
    parse_failures: string[];
    scan_errors: string[];
    limitations: string[];
}
export interface NextjsMetadataAuditOptions {
    workspace?: string | undefined;
    max_routes?: number | undefined;
}
export type { MetadataFields };
/** Field weights per design D4. Sum = 100. */
export declare const METADATA_WEIGHTS: {
    readonly title: 25;
    readonly description: 20;
    readonly og_image: 20;
    readonly canonical: 15;
    readonly twitter: 10;
    readonly json_ld: 10;
};
/**
 * Score a `MetadataFields` object against the weighted rubric (D4).
 *
 * Pure function — no I/O, no AST. Returns a numeric score 0-100, a grade
 * bucket, and a list of violation tags. Length gates zero out title/desc
 * scores when below thresholds. Placeholder OG images zero out the OG image
 * score and flag a violation.
 */
export declare function scoreMetadata(fields: MetadataFields): MetadataScore;
/**
 * Audit a Next.js project's metadata coverage. Walks app/page.* files,
 * extracts metadata via tree-sitter, scores each page, and returns a per-route
 * + aggregate report.
 */
export declare function nextjsMetadataAudit(repo: string, options?: NextjsMetadataAuditOptions): Promise<NextjsMetadataAuditResult>;
//# sourceMappingURL=nextjs-metadata-tools.d.ts.map