UNPKG

trellis

Version:

Agentic State Engine — event-sourced causal graph with branching, decision traces, and realtime sync for AI-native applications

21 lines 1.1 kB
/** * Upload core — transfer state machine (ADR 0034 wedge 5). * * Framework-free, DOM-free, timer-free: the only moving parts are the * injected transport's promise settlements and the caller's explicit * actions, so every behavior is deterministic and testable in Node. * * const upload = createUploadCore({ transport: myHttpTransport }); * upload.actions.add({ id: 'a1', name: 'photo.png', size: 2048, data: blob }); * * The transport reports progress through callbacks; the core owns the * queue (FIFO), the concurrency limit, cancel/retry, and idempotency — * dependency of composer-core attachments (the chat flagship) and the * sprite. Anatomy reference: ui-thing Attachment. * * @module trellis/upload */ import type { UploadConfig, UseUploadReturn } from './types.js'; export type { UploadActions, UploadCallbacks, UploadConfig, UploadHandle, UploadItem, UploadState, UploadStatus, UploadTaskState, UploadTransport, UseUploadReturn, } from './types.js'; export declare function createUploadCore(config: UploadConfig): UseUploadReturn; //# sourceMappingURL=index.d.ts.map