Team Ai
Modelpublic

Felipe97/llama-cpp-compiled

sourceHugging Faceupdated 21d agoView on Hugging Face
0likes1.2kdownloads
database.constants.ts30 linesDownload Raw Back to constants
1/**2 * Database-related constants (IndexedDB, Dexie).3 *4 * Centralized to ensure consistency across the app and simplify future5 * naming changes.6 */7 8import { STORAGE_APP_NAME } from './storage.constants';9 10/** IndexedDB database name */11export const DB_NAME = STORAGE_APP_NAME;12 13/** IndexedDB store / table names */14export const IDXDB_TABLES = {15	conversations: 'conversations',16	messages: 'messages'17} as const;18 19/** IndexedDB store schemas */20export const IDXDB_STORE_SCHEMAS = {21	conversations: 'id, lastModified, currNode, name',22	messages: 'id, convId, type, role, timestamp, parent, children'23} as const;24 25/** Combined Dexie stores definition — keys are table names, values are schemas */26export const IDXDB_STORES = {27	[IDXDB_TABLES.conversations]: IDXDB_STORE_SCHEMAS.conversations,28	[IDXDB_TABLES.messages]: IDXDB_STORE_SCHEMAS.messages29} as const;30