/**
 * Sanitize filename — same rules as backend/src/tracks/store.ts sanitizeTrackFilename,
 * but expects `.flow` suffix.
 *
 * Returns sanitized basename WITHOUT extension on success, null on invalid input.
 */
export declare function sanitizeFlowFilename(raw: string): string | null;
export interface FlowFileInfo {
    filename: string;
    basename: string;
    size: number;
    mtimeMs: number;
}
export declare function listFlows(projectFolder: string): FlowFileInfo[];
export declare function loadFlow(projectFolder: string, basename: string): unknown | null;
export declare function loadTrainJson(projectFolder: string, basename: string): Record<string, unknown> | null;
export type SaveFlowResult = {
    ok: true;
} | {
    ok: false;
    reason: 'exists' | 'io';
};
/** Save flow. `mode='create'` 要求文件不存在；upsert 直接覆盖。 */
export declare function saveFlow(projectFolder: string, basename: string, flow: unknown, mode?: 'create' | 'upsert'): SaveFlowResult;
export declare function saveTrainJson(projectFolder: string, basename: string, trainJson: Record<string, unknown>): boolean;
export declare function deleteFlow(projectFolder: string, basename: string): boolean;
//# sourceMappingURL=store.d.ts.map