/**
 * src/autonomy/types.ts
 *
 * Autonomy layer — what makes Muassis an SMB employee instead of a chatbot.
 * Five concepts:
 *   • Goal       — KPI the agent is driving toward (sales, follow-ups, etc.)
 *   • Journal    — append-only log of every autonomous action with outcome
 *   • Policy     — bounded-write rule: "auto-act under SAR X for tool Y"
 *   • Identity   — persistent facts the agent knows about its business
 *   • Escalation — surfaced decision with brain's recommendation + counterargument
 */
import { z } from 'zod';
export declare const goalSchema: z.ZodObject<{
    id: z.ZodString;
    tenant_id: z.ZodString;
    title: z.ZodString;
    description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    category: z.ZodDefault<z.ZodEnum<{
        sales: "sales";
        leads: "leads";
        finance: "finance";
        compliance: "compliance";
        marketing: "marketing";
        operations: "operations";
        "customer-success": "customer-success";
        general: "general";
    }>>;
    target_value: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
    current_value: z.ZodDefault<z.ZodNumber>;
    unit: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    deadline: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    status: z.ZodDefault<z.ZodEnum<{
        active: "active";
        achieved: "achieved";
        missed: "missed";
        archived: "archived";
    }>>;
    priority: z.ZodDefault<z.ZodNumber>;
    metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
    created_at: z.ZodString;
    updated_at: z.ZodString;
}, z.core.$strip>;
export type Goal = z.infer<typeof goalSchema>;
export declare const journalEntrySchema: z.ZodObject<{
    id: z.ZodString;
    tenant_id: z.ZodString;
    kind: z.ZodString;
    actor: z.ZodDefault<z.ZodString>;
    action: z.ZodString;
    target: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    outcome: z.ZodDefault<z.ZodEnum<{
        success: "success";
        failure: "failure";
        pending: "pending";
        escalated: "escalated";
        declined: "declined";
    }>>;
    reason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
    related_goal_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    cost_usd: z.ZodDefault<z.ZodNumber>;
    created_at: z.ZodString;
}, z.core.$strip>;
export type JournalEntry = z.infer<typeof journalEntrySchema>;
export declare const policyModeSchema: z.ZodEnum<{
    never: "never";
    auto: "auto";
    ask: "ask";
}>;
export type PolicyMode = z.infer<typeof policyModeSchema>;
export declare const policySchema: z.ZodObject<{
    id: z.ZodString;
    tenant_id: z.ZodString;
    policy_key: z.ZodString;
    description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    mode: z.ZodDefault<z.ZodEnum<{
        never: "never";
        auto: "auto";
        ask: "ask";
    }>>;
    threshold_amount: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
    threshold_currency: z.ZodDefault<z.ZodString>;
    conditions: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
    enabled: z.ZodDefault<z.ZodBoolean>;
    created_at: z.ZodString;
    updated_at: z.ZodString;
}, z.core.$strip>;
export type Policy = z.infer<typeof policySchema>;
export declare const identityFactSchema: z.ZodObject<{
    id: z.ZodString;
    tenant_id: z.ZodString;
    fact_key: z.ZodString;
    fact_value: z.ZodString;
    category: z.ZodDefault<z.ZodEnum<{
        business: "business";
        owner: "owner";
        team: "team";
        product: "product";
        customer: "customer";
        preference: "preference";
    }>>;
    source: z.ZodDefault<z.ZodEnum<{
        owner: "owner";
        inferred: "inferred";
        imported: "imported";
    }>>;
    confidence: z.ZodDefault<z.ZodNumber>;
    created_at: z.ZodString;
    updated_at: z.ZodString;
}, z.core.$strip>;
export type IdentityFact = z.infer<typeof identityFactSchema>;
export declare const escalationSchema: z.ZodObject<{
    id: z.ZodString;
    tenant_id: z.ZodString;
    approval_request_id: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    title: z.ZodString;
    context: z.ZodString;
    recommendation: z.ZodString;
    counterargument: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    alternatives: z.ZodDefault<z.ZodArray<z.ZodString>>;
    risk_level: z.ZodDefault<z.ZodEnum<{
        low: "low";
        medium: "medium";
        high: "high";
        critical: "critical";
    }>>;
    status: z.ZodDefault<z.ZodEnum<{
        pending: "pending";
        resolved: "resolved";
        expired: "expired";
    }>>;
    resolution: z.ZodOptional<z.ZodNullable<z.ZodString>>;
    expires_at: z.ZodString;
    created_at: z.ZodString;
    resolved_at: z.ZodOptional<z.ZodNullable<z.ZodString>>;
}, z.core.$strip>;
export type Escalation = z.infer<typeof escalationSchema>;
export interface PolicyDecision {
    allow: boolean;
    mode: PolicyMode;
    reason: string;
    policy: Policy | null;
}
//# sourceMappingURL=types.d.ts.map