UNPKG

@llamaindex/ui

Version:

A comprehensive UI component library built with React, TypeScript, and Tailwind CSS for LlamaIndex applications

18 lines (15 loc) 579 B
import { create } from 'zustand'; // src/store/ui-config-store.ts var DEFAULT_CONFIDENCE_THRESHOLD = 0.9; var createUIConfigStore = () => create((set) => ({ confidenceThreshold: DEFAULT_CONFIDENCE_THRESHOLD, setConfidenceThreshold: (value) => set({ confidenceThreshold: value }) })); var globalUIConfigStore = null; function useUIConfigStore(selector) { if (!globalUIConfigStore) { globalUIConfigStore = createUIConfigStore(); } return selector ? globalUIConfigStore(selector) : globalUIConfigStore(); } export { DEFAULT_CONFIDENCE_THRESHOLD, useUIConfigStore };