/** * Decision provenance. * * Records AI decisions to the existing tamper-evident hash chain * (`history/store`), so every decision is traceable and the chain * proves it wasn't altered after the fact. Raw inputs/prompts/outputs * are stored as sha256 digests (+ optional short summaries), so the * record captures *what was decided* without retaining secrets verbatim. * * This is the substrate for the certificate's explainability dimension: * the regulations (EU AI Act, SR 11-7, NIST AI RMF) ask for traceability * and reproducible provenance, not neuron-level interpretability. * * @module history/decisions */ import type { DecisionRecordEntry, ActorIdentity } from "./types.js"; /** Raw decision inputs — large/sensitive fields are digested, not stored. */ export interface DecisionInput { /** Kind of decision (tool_call, classification, generation, refusal, …) */ decisionType: string; /** Model that produced the decision */ model: string; modelVersion?: string; /** The input/context that led to the decision (digested) */ input: string; /** The prompt, if applicable (digested) */ prompt?: string; /** The output/decision (digested) */ output: string; /** Tools/functions invoked */ toolsInvoked?: string[]; /** Short human-readable summary */ summary?: string; /** Rationale / explanation */ rationale?: string; /** Model confidence 0-100 */ confidence?: number; /** Associated certification, if any */ certificationId?: string; } export interface RecordDecisionOptions { actor?: ActorIdentity; /** Sigstore-sign the entry (requires OIDC; default false). */ sign?: boolean; } /** * Record an AI decision to the tamper-evident chain. Returns the appended * entry, including its integrity proof (hash + previousHash). */ export declare function recordDecision(projectPath: string, decision: DecisionInput, options?: RecordDecisionOptions): Promise; export interface DecisionProvenance { /** Head hash of the audit chain (anchors the certificate). */ auditTrailHead: string; /** Number of decision records captured. */ decisionRecords: number; } /** * Read the provenance anchor for a project: the head hash of the * tamper-evident chain and the count of decision records. Used to * populate a certificate's `provenance` block. */ export declare function getDecisionProvenance(projectPath: string): Promise; //# sourceMappingURL=decisions.d.ts.map