import { z } from "zod"; import { Zep } from "../index.js"; export declare enum EntityPropertyType { Text = "Text", Int = "Int", Float = "Float", Boolean = "Boolean" } export declare const EntityTypeBaseField: z.ZodObject<{ type: z.ZodNativeEnum; description: z.ZodString; }, "strip", z.ZodTypeAny, { type: EntityPropertyType; description: string; }, { type: EntityPropertyType; description: string; }>; export interface EntityField { description: string; value?: V; } export declare const EntityTypeTextFieldSchema: z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }>; export type EntityTextField = z.infer; export declare const EntityTypeIntFieldSchema: z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }>; export type EntityIntField = z.infer; export declare const EntityTypeFloatFieldSchema: z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }>; export type EntityFloatField = z.infer; export declare const EntityTypeBooleanFieldSchema: z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }>; export type EntityBooleanField = z.infer; export declare const EntityTypeFieldSchema: z.ZodUnion<[z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }>]>; export type SupportedEntityField = EntityTextField | EntityIntField | EntityFloatField | EntityBooleanField; export declare const EntityFields: z.ZodRecord; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }>]>>; export declare const EntityTypeSchema: z.ZodObject<{ description: z.ZodDefault; fields: z.ZodRecord; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }>]>>; }, "strip", z.ZodTypeAny, { description: string; fields: Record; }, { fields: Record; description?: string | undefined; }>; export declare const EdgeTypeSchema: z.ZodObject<{ description: z.ZodDefault; fields: z.ZodRecord; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }, { type: EntityPropertyType.Text; description: string; value?: string | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }, { type: EntityPropertyType.Int; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }, { type: EntityPropertyType.Float; description: string; value?: number | undefined; }>, z.ZodObject<{ description: z.ZodString; } & { type: z.ZodLiteral; value: z.ZodOptional; }, "strip", z.ZodTypeAny, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }, { type: EntityPropertyType.Boolean; description: string; value?: boolean | undefined; }>]>>; } & { sourceTargets: z.ZodOptional; target: z.ZodOptional; }, "strip", z.ZodTypeAny, { source?: string | undefined; target?: string | undefined; }, { source?: string | undefined; target?: string | undefined; }>, "many">>; }, "strip", z.ZodTypeAny, { description: string; fields: Record; sourceTargets?: { source?: string | undefined; target?: string | undefined; }[] | undefined; }, { fields: Record; description?: string | undefined; sourceTargets?: { source?: string | undefined; target?: string | undefined; }[] | undefined; }>; export type EntityType = z.infer; export type EdgeType = z.infer; export type EntityData = { [P in keyof T["fields"]]: T["fields"][P] extends { value?: infer V; } ? V : never; }; export type EdgeData = { [P in keyof T["fields"]]: T["fields"][P] extends { value?: infer V; } ? V : never; }; export declare const entityFields: { text: (description: string) => EntityTextField; integer: (description: string) => EntityIntField; float: (description: string) => EntityFloatField; boolean: (description: string) => EntityBooleanField; }; export declare function entityModelToAPISchema(entityType: EntityType, name: string): Zep.EntityType; export declare function edgeModelToAPISchema(entityType: EdgeType, name: string): Zep.EdgeType;