import { Result } from "./streamTool.js";
/**
 * Yields only valid operations from the stream.
 *
 * For invalid operations, the `onInvalidOperation` callback is called.
 */
export declare function filterValidOperations<T>(operationsStream: AsyncIterable<{
    operation: Result<T>;
    isUpdateToPreviousOperation: boolean;
    isPossiblyPartial: boolean;
    metadata: any;
}>, onInvalidOperation?: (chunk: {
    operation: Result<T> & {
        ok: false;
    };
    isUpdateToPreviousOperation: boolean;
    isPossiblyPartial: boolean;
    metadata: any;
}) => void): AsyncGenerator<{
    operation: T;
    isUpdateToPreviousOperation: boolean;
    isPossiblyPartial: boolean;
    metadata: any;
}>;
