UNPKG

@hotmeshio/hotmesh

Version:

Permanent-Memory Workflows & AI Agents

52 lines (51 loc) 2.25 kB
import { ILogger } from '../logger'; import { StoreService } from '../store'; import { ExportOptions, MemFlowJobExport, TimelineType, TransitionType, ExportFields } from '../../types/exporter'; import { ProviderClient, ProviderTransaction } from '../../types/provider'; import { StringStringType, Symbols } from '../../types/serializer'; declare class ExporterService { appId: string; logger: ILogger; store: StoreService<ProviderClient, ProviderTransaction>; symbols: Promise<Symbols> | Symbols; private static symbols; constructor(appId: string, store: StoreService<ProviderClient, ProviderTransaction>, logger: ILogger); /** * Convert the job hash from its compiles format into a MemFlowJobExport object with * facets that describe the workflow in terms relevant to narrative storytelling. */ export(jobId: string, options?: ExportOptions): Promise<MemFlowJobExport>; /** * Inflates the job data into a MemFlowJobExport object * @param jobHash - the job data * @param dependencyList - the list of dependencies for the job * @returns - the inflated job data */ inflate(jobHash: StringStringType, options: ExportOptions): MemFlowJobExport; resolveValue(raw: string, withValues: boolean): Record<string, any> | string | number | null; /** * Inflates the key * into a human-readable JSON path, reflecting the * tree-like structure of the unidimensional Hash * @private */ inflateKey(key: string): string; filterFields(fullObject: MemFlowJobExport, block?: ExportFields[], allow?: ExportFields[]): Partial<MemFlowJobExport>; inflateTransition(match: RegExpMatchArray, value: string, transitionsObject: Record<string, TransitionType>): void; sortEntriesByCreated(obj: { [key: string]: TransitionType; }): TransitionType[]; /** * marker names are overloaded with details like sequence, type, etc */ keyToObject(key: string): { index: number; dimension?: string; secondary?: number; }; /** * idem list has a complicated sort order based on indexes and dimensions */ sortParts(parts: TimelineType[]): TimelineType[]; } export { ExporterService };