interface AsyncOverrideParams { async?: boolean; clarify?: boolean; } export function applyForceTopLevelAsyncOverride( params: T, depth: number, forceTopLevelAsync: boolean, ): T { if (!(depth === 0 && forceTopLevelAsync)) return params; return { ...params, async: true, clarify: false }; }