UNPKG

@axarai/axar

Version:

TypeScript-based agent framework for building agentic applications powered by LLMs

24 lines (23 loc) 907 B
import { SchemaConstructor } from './types'; import { ZodSchema } from 'zod'; /** * Checks if a class has an associated Zod schema. * * This function determines whether the specified class constructor * has been decorated with a Zod schema, by checking for the presence * of metadata associated with the schema. * * @internal * @param target - The class constructor to check for schema metadata. * @returns A boolean indicating if the Zod schema metadata is present. */ export declare function hasSchemaDef(target: SchemaConstructor): boolean; /** * Retrieves the Zod schema associated with the specified class constructor. * * @internal * @param target - The class constructor to retrieve the schema for. * @returns The Zod schema associated with the class constructor * @throws Error if no schema is present. */ export declare function getSchemaDef(target: SchemaConstructor): ZodSchema;