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

    Service to retrieve capability information for chat agents. Parses capability variables from agent prompt templates.

    interface ChatCapabilitiesService {
        onDidChangeCapabilities: Event<void>;
        getCapabilitiesForAgent(
            agentId: string,
            modeId?: string,
        ): Promise<ParsedCapability[]>;
        getUsedGenericCapabilitiesForAgent(
            agentId: string,
            modeId?: string,
        ): Promise<GenericCapabilitySelections>;
    }

    Implemented by

    Index

    Properties

    onDidChangeCapabilities: Event<void>

    Event fired when prompt fragments change, indicating that capabilities may need to be refreshed.

    Methods

    • Gets capabilities for a specific agent, optionally with a specific mode. Parses the agent's effective prompt template to extract capability variables.

      Parameters

      • agentId: string

        The agent ID to get capabilities for

      • OptionalmodeId: string

        Optional mode ID to use instead of the default

      Returns Promise<ParsedCapability[]>

      Array of parsed capabilities in order they appear in the template

    • Extracts generic capabilities that are already used in an agent's prompt template. Used to disable these items in the dropdown (they're already included).

      Parameters

      • agentId: string

        The agent ID to get capabilities for

      • OptionalmodeId: string

        Optional mode ID to use instead of the default

      Returns Promise<GenericCapabilitySelections>

      GenericCapabilitySelections containing IDs of capabilities already in the prompt