import { Prettify } from "../utils/misc.cjs";
import { ApiClient } from "../clients/index.cjs";
import { Gemini } from "./api-types.cjs";
import { ChatGoogleFields } from "./types.cjs";
import { BaseChatModel, BaseChatModelCallOptions, BaseChatModelParams, BindToolsInput, LangSmithParams } from "@langchain/core/language_models/chat_models";
import { AIMessageChunk, BaseMessage } from "@langchain/core/messages";
import { CallbackManagerForLLMRun } from "@langchain/core/callbacks/manager";
import { ChatModelStreamEvent } from "@langchain/core/language_models/event";
import { ChatGenerationChunk, ChatResult } from "@langchain/core/outputs";
import { ModelProfile } from "@langchain/core/language_models/profile";
import { BaseLanguageModelInput, StructuredOutputMethodOptions } from "@langchain/core/language_models/base";
import { Runnable } from "@langchain/core/runnables";
import { JsonSchema7Type } from "@langchain/core/utils/json_schema";
import { InteropZodType } from "@langchain/core/utils/types";
import { SerializableSchema } from "@langchain/core/utils/standard_schema";
type GooglePlatformType = "gai" | "gcp";
interface BaseChatGoogleParams extends BaseChatModelParams, ChatGoogleFields {
  /**
   * The name of the Gemini model to use.
   *
   * Example: "gemini-3-pro-preview"
   */
  model: string;
  /**
   * Optional. The API client implementation for making HTTP requests to the Gemini API.
   * If not set, a default client will be used based on the runtime environment.
   */
  apiClient?: ApiClient;
  /**
   * Hostname for the API call (if this is running on GCP)
   * Usually this is computed based on location and platformType.
   **/
  endpoint?: string;
  /**
   * Region where the LLM is stored (if this is running on GCP)
   * Defaults to "global"
   **/
  location?: string;
  /**
   * The version of the API functions. Part of the path.
   * Usually this is computed based on platformType.
   **/
  apiVersion?: string;
  /**
   * What platform to run the service on.
   * If not specified, the class should determine this from other
   * means. Either way, the platform actually used will be in
   * the "platform" getter.
   */
  platformType?: GooglePlatformType;
  /**
   * For compatibility with Google's libraries, should this use Vertex?
   * The "platformType" parmeter takes precedence.
   */
  vertexai?: boolean;
  /**
   * Backwards compatibility.
   * @deprecated in favor of using `disableStreaming` or `.stream()`
   */
  streaming?: boolean;
  streamUsage?: boolean;
}
interface BaseChatGoogleCallOptions extends BaseChatModelCallOptions, ChatGoogleFields {}
declare abstract class BaseChatGoogle<CallOptions extends BaseChatGoogleCallOptions = BaseChatGoogleCallOptions> extends BaseChatModel<CallOptions, AIMessageChunk> {
  protected params: BaseChatGoogleParams & {
    credentials?: unknown;
    googleAuthOptions?: unknown;
  };
  model: string;
  streaming: boolean;
  disableStreaming: boolean;
  streamUsage: boolean;
  protected _platform?: GooglePlatformType;
  protected _endpoint?: string;
  protected _customHeaders?: Record<string, string>;
  protected _location?: string;
  protected _apiVersion?: string;
  protected apiClient: ApiClient;
  constructor(params: BaseChatGoogleParams & {
    credentials?: unknown;
    googleAuthOptions?: unknown;
  });
  _llmType(): string;
  protected get platformType(): GooglePlatformType | undefined;
  protected get platform(): GooglePlatformType;
  protected get isVertexExpress(): boolean;
  protected get apiVersion(): string;
  protected get location(): string;
  protected get endpoint(): string;
  protected get publisher(): string;
  protected get urlMethod(): string;
  /**
   * Returns the model profile for this instance's model, describing its
   * capabilities and constraints (e.g. max tokens, input/output modalities,
   * tool calling support).
   *
   * @example
   * ```typescript
   * const model = new ChatGoogle({ model: "gemini-2.5-pro" });
   * const profile = model.profile;
   * console.log(profile.maxInputTokens); // 1048576
   * console.log(profile.imageInputs); // true
   * ```
   */
  get profile(): ModelProfile;
  protected buildUrlGemini(urlMethod?: string): Promise<string>;
  protected get endpointUrl(): string;
  protected buildUrlVertexExpress(urlMethod?: string): Promise<string>;
  protected buildUrlVertexLocation(urlMethod?: string): Promise<string>;
  protected buildUrlVertex(urlMethod?: string): Promise<string>;
  protected buildUrl(urlMethod?: string): Promise<string>;
  invocationParams(options: this["ParsedCallOptions"]): {
    serviceTier?: ServiceTier | undefined;
    tools?: Gemini.Tool[] | undefined;
    toolConfig?: Gemini.Tools.ToolConfig | undefined;
    safetySettings: {
      category: "HARM_CATEGORY_CIVIC_INTEGRITY" | "HARM_CATEGORY_DANGEROUS" | "HARM_CATEGORY_DANGEROUS_CONTENT" | "HARM_CATEGORY_DEROGATORY" | "HARM_CATEGORY_HARASSMENT" | "HARM_CATEGORY_HATE_SPEECH" | "HARM_CATEGORY_MEDICAL" | "HARM_CATEGORY_SEXUAL" | "HARM_CATEGORY_SEXUALLY_EXPLICIT" | "HARM_CATEGORY_TOXICITY" | "HARM_CATEGORY_UNSPECIFIED" | "HARM_CATEGORY_VIOLENCE" | {
        readonly [x: number]: string;
        toString: {};
        charAt: {};
        charCodeAt: {};
        concat: {};
        indexOf: {};
        lastIndexOf: {};
        localeCompare: {};
        match: {};
        replace: {};
        search: {};
        slice: {};
        split: {};
        substring: {};
        toLowerCase: {};
        toLocaleLowerCase: {};
        toUpperCase: {};
        toLocaleUpperCase: {};
        trim: {};
        readonly length: number;
        substr: {};
        valueOf: {};
        codePointAt: {};
        includes: {};
        endsWith: {};
        normalize: {};
        repeat: {};
        startsWith: {};
        anchor: {};
        big: {};
        blink: {};
        bold: {};
        fixed: {};
        fontcolor: {};
        fontsize: {};
        italics: {};
        link: {};
        small: {};
        strike: {};
        sub: {};
        sup: {};
        [Symbol.iterator]: {};
        padStart: {};
        padEnd: {};
        trimEnd: {};
        trimStart: {};
        trimLeft: {};
        trimRight: {};
        matchAll: {};
        replaceAll: {};
      };
      threshold: "BLOCK_LOW_AND_ABOVE" | "BLOCK_MEDIUM_AND_ABOVE" | "BLOCK_NONE" | "BLOCK_ONLY_HIGH" | "HARM_BLOCK_THRESHOLD_UNSPECIFIED" | "OFF" | {
        readonly [x: number]: string;
        toString: {};
        charAt: {};
        charCodeAt: {};
        concat: {};
        indexOf: {};
        lastIndexOf: {};
        localeCompare: {};
        match: {};
        replace: {};
        search: {};
        slice: {};
        split: {};
        substring: {};
        toLowerCase: {};
        toLocaleLowerCase: {};
        toUpperCase: {};
        toLocaleUpperCase: {};
        trim: {};
        readonly length: number;
        substr: {};
        valueOf: {};
        codePointAt: {};
        includes: {};
        endsWith: {};
        normalize: {};
        repeat: {};
        startsWith: {};
        anchor: {};
        big: {};
        blink: {};
        bold: {};
        fixed: {};
        fontcolor: {};
        fontsize: {};
        italics: {};
        link: {};
        small: {};
        strike: {};
        sub: {};
        sup: {};
        [Symbol.iterator]: {};
        padStart: {};
        padEnd: {};
        trimEnd: {};
        trimStart: {};
        trimLeft: {};
        trimRight: {};
        matchAll: {};
        replaceAll: {};
      };
    }[] | undefined;
    generationConfig: {
      temperature: number | undefined;
      topP: number | undefined;
      topK: number | undefined;
      maxOutputTokens: number | undefined;
      presencePenalty: number | undefined;
      frequencyPenalty: number | undefined;
      stopSequences: string[] | undefined;
      responseMimeType?: string | undefined;
      responseJsonSchema?: Record<string, unknown> | JsonSchema7Type | undefined;
      responseModalities?: Prettify<Gemini.GenerativeLanguageModality>[] | undefined;
      candidateCount: number;
      seed: number | undefined;
      responseLogprobs: boolean | undefined;
      logprobs: number | undefined;
      enableEnhancedCivicAnswers?: boolean | undefined;
      thinkingConfig: Gemini.ThinkingConfig | undefined;
      speechConfig: Gemini.SpeechConfig | undefined;
      imageConfig?: {
        aspectRatio?: string;
        imageSize?: string;
      } | undefined;
      mediaResolution?: "MEDIA_RESOLUTION_HIGH" | "MEDIA_RESOLUTION_LOW" | "MEDIA_RESOLUTION_MEDIUM" | "MEDIA_RESOLUTION_UNSPECIFIED" | (string & {}) | undefined;
    };
  };
  getLsParams(options: this["ParsedCallOptions"]): LangSmithParams;
  getHeaders(options: this["ParsedCallOptions"]): HeadersInit;
  _generate(messages: BaseMessage[], options: this["ParsedCallOptions"], runManager?: CallbackManagerForLLMRun): Promise<ChatResult>;
  _streamChatModelEvents(messages: BaseMessage[], options: this["ParsedCallOptions"], _runManager?: CallbackManagerForLLMRun): AsyncGenerator<ChatModelStreamEvent>;
  _streamResponseChunks(messages: BaseMessage[], options: this["ParsedCallOptions"], runManager?: CallbackManagerForLLMRun): AsyncGenerator<ChatGenerationChunk>;
  /**
   * Bind tool-like objects to this chat model.
   *
   * @param tools A list of tool definitions to bind to this chat model.
   * Can be a structured tool, an OpenAI formatted tool, or a Gemini function declaration.
   * @param kwargs Any additional parameters to bind.
   */
  bindTools(tools: BindToolsInput[], kwargs?: Partial<CallOptions>): Runnable<BaseMessage[], AIMessageChunk, CallOptions>;
  withStructuredOutput<RunOutput extends Record<string, any> = Record<string, any>>(outputSchema: InteropZodType<RunOutput> | SerializableSchema<RunOutput> | Record<string, any>, config?: StructuredOutputMethodOptions<false>): Runnable<BaseLanguageModelInput, RunOutput>;
  withStructuredOutput<RunOutput extends Record<string, any> = Record<string, any>>(outputSchema: InteropZodType<RunOutput> | SerializableSchema<RunOutput> | Record<string, any>, config?: StructuredOutputMethodOptions<true>): Runnable<BaseLanguageModelInput, {
    raw: BaseMessage;
    parsed: RunOutput;
  }>;
  withStructuredOutput<RunOutput extends Record<string, any> = Record<string, any>>(outputSchema: InteropZodType<RunOutput> | SerializableSchema<RunOutput> | Record<string, any>, config?: StructuredOutputMethodOptions<boolean>): Runnable<BaseLanguageModelInput, RunOutput> | Runnable<BaseLanguageModelInput, {
    raw: BaseMessage;
    parsed: RunOutput;
  }>;
}
//#endregion
export { BaseChatGoogle, BaseChatGoogleCallOptions, BaseChatGoogleParams, GooglePlatformType };
//# sourceMappingURL=base.d.cts.map