import * as Lib from "@metabase/embedding-sdk-react/dist/frontend/src/metabase-lib";
import type Metadata from "@metabase/embedding-sdk-react/dist/frontend/src/metabase-lib/v1/metadata/Metadata";
import type { ErrorWithMessage } from "./types";
type Token = {
    type: number;
    op: string;
    start: number;
    end: number;
};
export declare function countMatchingParentheses(tokens: Token[]): number;
export declare function diagnose({ source, startRule, query, stageIndex, metadata, name, expressionIndex, }: {
    source: string;
    startRule: "expression" | "aggregation" | "boolean";
    query: Lib.Query;
    stageIndex: number;
    name?: string | null;
    metadata?: Metadata;
    expressionIndex: number | undefined;
}): ErrorWithMessage | null;
export {};
