/**
 * Core type definitions for the ShieldCortex memory system
 */
export type MemoryType = 'short_term' | 'long_term' | 'episodic';
export type MemoryStatus = 'active' | 'archived' | 'suppressed' | 'canonical';
export type MemorySourceKind = 'user' | 'cli' | 'hook' | 'plugin' | 'agent' | 'import' | 'cloud' | 'api' | 'system';
export type MemoryCaptureMethod = 'manual' | 'hook' | 'plugin' | 'import' | 'cloud' | 'api' | 'auto' | 'review';
export type MemoryPurpose = 'user' | 'feedback' | 'project' | 'reference';
export type MemoryScope = 'private' | 'team';
export type MemoryCategory = 'architecture' | 'pattern' | 'preference' | 'error' | 'context' | 'learning' | 'todo' | 'note' | 'relationship' | 'custom';
export interface Memory {
    id: number;
    uuid: string;
    type: MemoryType;
    category: MemoryCategory;
    title: string;
    content: string;
    project?: string;
    tags: string[];
    salience: number;
    accessCount: number;
    lastAccessed: Date;
    createdAt: Date;
    updatedAt: Date;
    decayedScore: number;
    metadata: Record<string, unknown>;
    embedding?: Buffer;
    scope: 'project' | 'global';
    transferable: boolean;
    status: MemoryStatus;
    pinned: boolean;
    reviewedAt: Date | null;
    reviewedBy: string | null;
    sourceKind: MemorySourceKind;
    captureMethod: MemoryCaptureMethod;
    trustScore: number;
    sensitivityLevel: string;
    source: string | null;
    cloudExcluded: boolean;
    memoryPurpose: MemoryPurpose;
    memoryScope: MemoryScope;
}
export interface MemoryInput {
    type?: MemoryType;
    category?: MemoryCategory;
    title: string;
    content: string;
    project?: string;
    tags?: string[];
    salience?: number;
    metadata?: Record<string, unknown>;
    scope?: 'project' | 'global';
    transferable?: boolean;
    status?: MemoryStatus;
    pinned?: boolean;
    reviewedBy?: string | null;
    sourceKind?: MemorySourceKind;
    captureMethod?: MemoryCaptureMethod;
    trustScore?: number;
    sensitivityLevel?: string;
    source?: string | null;
    cloudExcluded?: boolean;
    memoryPurpose?: MemoryPurpose;
    memoryScope?: MemoryScope;
}
export interface SearchOptions {
    query: string;
    project?: string;
    category?: MemoryCategory;
    type?: MemoryType;
    tags?: string[];
    minSalience?: number;
    limit?: number;
    includeDecayed?: boolean;
    includeGlobal?: boolean;
    includeArchived?: boolean;
    includeSuppressed?: boolean;
    memoryPurpose?: MemoryPurpose;
    memoryScope?: MemoryScope;
}
export interface SearchResult {
    memory: Memory;
    relevanceScore: number;
    contradictions?: {
        memoryId: number;
        title: string;
        score: number;
    }[];
    explanation?: SearchExplanation;
    recallEligibility?: RecallEligibility;
}
export interface SearchScoreBreakdown {
    ftsScore: number;
    vectorSimilarity: number;
    vectorBoost: number;
    decayedScore: number;
    priorityBoost: number;
    recencyBoost: number;
    categoryBoost: number;
    linkBoost: number;
    tagBoost: number;
    activationBoost: number;
    contradictionPenalty: number;
    finalScore: number;
    matchedTags: string[];
    matchedCategory: string | null;
}
export interface RecallEligibility {
    eligible: boolean;
    reasons: string[];
}
export interface SearchExplanation {
    query: string;
    reasons: string[];
    breakdown: SearchScoreBreakdown;
    eligibility?: RecallEligibility;
}
export interface ConsolidationResult {
    consolidated: number;
    decayed: number;
    deleted: number;
    contradictionsFound?: number;
    contradictionsLinked?: number;
    salienceEvolved?: number;
    deduplicated?: number;
}
export interface ContextSummary {
    project?: string;
    recentMemories: Memory[];
    keyDecisions: Memory[];
    activePatterns: Memory[];
    pendingItems: Memory[];
}
export interface SalienceFactors {
    explicitRequest: boolean;
    isArchitectureDecision: boolean;
    isErrorResolution: boolean;
    isCodePattern: boolean;
    isUserPreference: boolean;
    mentionCount: number;
    hasCodeReference: boolean;
    emotionalMarkers: boolean;
}
/**
 * Hybrid retrieval engine selection. RRF is the v4.15 default; `legacy`
 * keeps the pre-v4.15 weighted-sum scoring as a one-release safety belt.
 */
export type RankerEngine = 'rrf' | 'legacy';
export interface RankerWeights {
    fts: number;
    vector: number;
    graph: number;
}
export interface RankerConfig {
    engine: RankerEngine;
    /** RRF smoothing constant. Cormack et al. (2009) recommend 60. */
    rrfK: number;
    weights: RankerWeights;
}
export interface MemoryConfig {
    dbPath: string;
    decayRate: number;
    reinforcementFactor: number;
    salienceThreshold: number;
    consolidationThreshold: number;
    maxShortTermMemories: number;
    maxLongTermMemories: number;
    autoConsolidateHours: number;
    ranker: RankerConfig;
}
export declare const DEFAULT_RANKER_CONFIG: RankerConfig;
export declare const DEFAULT_CONFIG: MemoryConfig;
/**
 * Category-specific deletion thresholds
 * Lower threshold = harder to delete (more valuable)
 */
export declare const DELETION_THRESHOLDS: Record<MemoryCategory, number>;
export declare const VALID_MEMORY_PURPOSES: MemoryPurpose[];
export declare const VALID_MEMORY_SCOPES: MemoryScope[];
export declare function isValidMemoryPurpose(value: unknown): value is MemoryPurpose;
export declare function isValidMemoryScope(value: unknown): value is MemoryScope;
