UNPKG

n8n-nodes-roundrobin

Version:

n8n node to store and retrieve messages in a round-robin fashion, particularly for LLM conversation loops with multiple personas

39 lines 1.4 kB
import { IExecuteFunctions, IDataObject, INodeExecutionData } from 'n8n-workflow'; export interface IRoundRobinExternalMessage { role: string; content: string; spotIndex: number; timestamp: number; } export interface IRoundRobinExternalRole { name: string; description: string; color?: string; icon?: string; tone?: string; expertise?: string[]; systemPrompt?: string; isEnabled?: boolean; } export interface IRoundRobinMetrics { roundCount?: number; maxRounds?: number; [key: string]: any; } export declare class ExternalStorageManager { private executeFunctions; private storageType; private storageId; constructor(executeFunctions: IExecuteFunctions, storageType: string, storageId: string); storeToBinary(messages: IRoundRobinExternalMessage[], roles: IRoundRobinExternalRole[], spotCount: number, metrics?: IRoundRobinMetrics): Promise<INodeExecutionData>; loadFromBinary(binaryData: IDataObject): Promise<{ messages: IRoundRobinExternalMessage[]; roles: IRoundRobinExternalRole[]; spotCount: number; lastUpdated: number; roundCount?: number; maxRounds?: number; }>; } export declare function createStorageManager(executeFunctions: IExecuteFunctions, storageType?: string, storageId?: string): ExternalStorageManager; //# sourceMappingURL=ExternalStorage.d.ts.map