/** * CRUD for the `claims`, `claim_symbols`, and `source_shas` tables. * * A Claim has a many-to-many relationship with Symbols: a single claim * ("must be idempotent") may govern multiple symbols (OrderProcessor and * BaseProcessor). Linkage rows live in `claim_symbols`. */ import type { Claim, Severity, SymbolId } from "../types.js"; import type { DatabaseInstance } from "./db.js"; export interface NewClaim { source: string; sourcePath: string; sourceSha: string; severity: Severity; claim: string; rationale?: string; excerpt?: string; symbolIds: readonly SymbolId[]; } export declare function insertClaim(db: DatabaseInstance, claim: NewClaim): number; export declare function insertClaims(db: DatabaseInstance, claims: readonly NewClaim[]): number[]; export declare function listAllClaims(db: DatabaseInstance): Claim[]; export declare function listClaimsForSymbol(db: DatabaseInstance, symbolId: SymbolId): Claim[]; /** * Delete every claim whose source file path matches. Used by incremental * reindex: when a doc changes, drop its claims and re-extract. */ export declare function deleteClaimsBySourcePath(db: DatabaseInstance, sourcePath: string): number; export declare function clearClaims(db: DatabaseInstance): void; export declare function setSourceSha(db: DatabaseInstance, sourcePath: string, sourceSha: string): void; export declare function getSourceSha(db: DatabaseInstance, sourcePath: string): string | null; export declare function listSourceShas(db: DatabaseInstance): Record; export declare function clearSourceShas(db: DatabaseInstance): void; //# sourceMappingURL=claims.d.ts.map