UNPKG

@hashbrownai/react

Version:

React components for Hashbrown AI

28 lines (27 loc) 621 B
import { RuntimeFunctionRef, RuntimeRef } from '@hashbrownai/core'; /** * Options for creating a runtime. * * @public */ export interface UseRuntimeOptions { /** * The timeout for the runtime. * * @defaultValue 10000 */ timeout?: number; /** * The functions that are available in the runtime. */ functions: [...RuntimeFunctionRef<any, any>[]]; } /** * Creates a new runtime. * * @param options - The options for creating the runtime. * @returns A reference to the runtime. * * @public */ export declare function useRuntime(options: UseRuntimeOptions): RuntimeRef;