import type { SynthEvent } from "../types/index.js"; import { type AggregateGraphNode } from "./replay.js"; import type { IdentityRegistry } from "./identity-resolver.js"; import type { HistoricalAliasRegistry } from "./historical-aliases.js"; export type ReferenceResolutionKind = "resolved" | "recovered-alias" | "recovered-unique-candidate" | "unresolved"; export type ReferenceResolutionNotice = { kind: ReferenceResolutionKind; severity: "info" | "warning" | "error"; aggregateKind: AggregateGraphNode["kind"]; aggregateId: string; referenceName: "missionId" | "expeditionId"; originalReference: string; resolvedReference?: string; message: string; provenance: { eventId: string; reason: string; }; }; export type ReferenceResolutionResult = { events: SynthEvent[]; notices: ReferenceResolutionNotice[]; unresolved: ReferenceResolutionNotice[]; }; /** * Resolve parent references in creation events against the identity registry. * * If a parent reference does not match a canonical identity directly, an * optional historical alias registry is consulted. A registered alias is * recovered to its canonical id with an info-level notice rather than a * warning. */ export declare function resolveReferences(events: SynthEvent[], registry: IdentityRegistry, aliasRegistry?: HistoricalAliasRegistry): ReferenceResolutionResult;