llmwire - v2.2.0
    Preparing search index...

    Class GeminiProvider

    Hierarchy (View Summary)

    Index
    _supportedModels: string[] = []
    baseConfig: BaseProviderConfig
    • get baseURL(): string

      Origin this provider talks to; shown in PROVIDER_UNREACHABLE hints.

      Returns string

    • A fresh AIError for a failure this provider detects itself (no key, no model, blocked answer).

      Parameters

      • code: AIErrorCode
      • message: string
      • extra: { details?: unknown; hint?: string; model?: string } = {}

      Returns AIError

    • Streaming request: the body as an async iterable of bytes, idle-guarded. Non-2xx throws [HttpError].

      Parameters

      Returns Promise<AsyncIterable<Uint8Array>>

    • Gemini's streamGenerateContent, read as server-sent events.

      Same body as [process] -- system instruction, JSON mode and schema all travel unchanged -- so a streamed answer is the same answer, delivered in pieces. A frame that does not parse is skipped rather than thrown on.

      Parameters

      Returns AsyncGenerator<AIStreamChunk, void, void>

    • Records what discovery found, keeping any seeded models first so the caller's chosen default stays the default.

      Parameters

      • ids: string[]

      Returns string[]