UNPKG

rashi-discord-bot-lib

Version:

🚀 Powerful Discord bot framework with built-in database, event handling, and utilities

21 lines • 780 B
type ChatMessage = { role: 'user' | 'assistant' | 'system'; content: string; }; export declare class ChatMemory { private memory; private maxMessages; constructor(maxMessages?: number); /** Zwraca historię wiadomości dla danego użytkownika */ getHistory(userId: string): ChatMessage[]; /** Dodaje wiadomość do historii użytkownika */ addMessage(userId: string, message: ChatMessage): void; /** Czyści historię użytkownika */ clearHistory(userId: string): void; /** Ustawia historię użytkownika ręcznie */ setHistory(userId: string, messages: ChatMessage[]): void; /** Sprawdza, czy użytkownik ma jakąś historię */ hasHistory(userId: string): boolean; } export {}; //# sourceMappingURL=ChatMemory.d.ts.map