Theia API Documentation v1.76.0
    Preparing search index...

    Backend implementation of the Copilot language models manager. Manages registration and lifecycle of Copilot language models in the AI language model registry.

    Implements

    Index

    Constructors

    Properties

    discoveryFailure: undefined | string

    Why the last model discovery failed, if it did.

    Being signed in does not imply that requests are accepted: the credentials can lack the Copilot entitlement, be revoked, or belong to a subscription served by a different API host. Reporting the models as ready in those cases claims a working setup that is not there, so the failure is remembered and reflected in the status of the models.

    languageModelRegistry: LanguageModelRegistry
    logger: ILogger
    sdkClientProvider: CopilotSdkClientProvider
    toDispose: DisposableCollection = ...

    Methods

    • Nominates the models the chat input should show without the user asking, up to NOMINATED_MODEL_COUNT. Copilot serves models of several vendors under one provider, so ranking them against each other by the numbers in their ids would show several models of whichever vendor counts highest and none of the others. The list is therefore filled vendor by vendor: auto first, which lets Copilot itself choose and is the entry most users want, then the newest model of each major vendor, then the next of each in turn until the list is full.

      Everything else Copilot carries is left to be chosen deliberately: the list is meant to be the handful of models one switches between while chatting, not a survey of the catalogue.

      Release-pinned ids are left out: the undated id of the same model is nominated, and pinning a release is the deliberate choice the check on its row makes.

      Parameters

      • modelIds: string[]

      Returns Set<string>

    • The vendor a Copilot model id belongs to, or undefined for a vendor that is not nominated. Matching on the id is all there is — the CLI reports nothing else — and it is deliberately narrow: a model of a vendor this does not name is still registered and still selectable, it is simply not one of the few the chat input starts with.

      Parameters

      • id: string

      Returns undefined | string