UNPKG

donobu

Version:

Create browser automations with an LLM agent and replay them as Playwright scripts.

33 lines 1.45 kB
import { z } from 'zod/v4'; import type { GoogleGenerativeAiConfig } from '../models/GptConfig'; import type { AssistantMessage, GptMessage, ProposedToolCallsMessage, StructuredOutputMessage } from '../models/GptMessage'; import type { ToolOption } from './GptClient'; import { GptClient } from './GptClient'; /** * Implementation using the Google API * @see https://ai.google.dev/api/all-methods#service:-generativelanguage.googleapis.com */ export declare class GoogleGenerativeAiGptClient extends GptClient { private readonly delegate; constructor(config: GoogleGenerativeAiConfig); ping(options?: { signal?: AbortSignal; }): Promise<void>; getMessage(messages: GptMessage[], options?: { signal?: AbortSignal; }): Promise<AssistantMessage>; getStructuredOutput<T>(messages: GptMessage[], zodSchema: z.ZodSchema<T>, options?: { signal?: AbortSignal; }): Promise<StructuredOutputMessage<T>>; getToolCalls(messages: GptMessage[], tools: ToolOption[], options?: { signal?: AbortSignal; }): Promise<ProposedToolCallsMessage>; } /** * Fix the "assert1" field issue in tool call parameters (Gemini has severe * troubles trying to say the word "assert" on its own... really). * * Recursively search and replace any field containing "assert1" with "assert" */ export declare function fixAssertFields(obj: unknown): void; //# sourceMappingURL=GoogleGenerativeAiGptClient.d.ts.map