@squidcloud/client
    Preparing search index...

    Class AiAgentReference

    AiAgentReference provides methods for managing AI agents, including retrieving, updating, and deleting agents, handling agent contexts, and interacting with chat or voice-based AI functionalities.

    Index

    Methods

    • Sends a prompt to the agent and receives streamed text responses.

      Parameters

      Returns Observable<string>

    • Deletes the AI agent.

      Returns Promise<void>

    • Deletes a specific context by its ID.

      Parameters

      • contextId: string

      Returns Promise<void>

    • Deletes multiple agent contexts.

      Parameters

      • contextIds: string[]

      Returns Promise<void>

    • Deletes the custom guardrails for the agent.

      Returns Promise<void>

    • Retrieves metadata and configuration of the AI agent.

      Returns Promise<undefined | AiAgent<undefined>>

    • Retrieves a specific agent context by its ID.

      Parameters

      • contextId: string

      Returns Promise<undefined | AiAgentContext>

    • Sends user feedback to the agent.

      Parameters

      • feedback: string

      Returns Promise<void>

    • Resets any feedback previously provided to the agent.

      Returns Promise<void>

    • Updates the agent's custom guardrails with the provided custom guardrail.

      Parameters

      • customGuardrail: string

      Returns Promise<void>

    • Updates the agent's guardrails with the provided options.

      Parameters

      Returns Promise<void>

    • Updates the agent's instruction prompt.

      Parameters

      • instructions: string

      Returns Promise<void>

    • Changes the AI model used by the agent.

      Parameters

      • model:
            | "o1"
            | "o1-mini"
            | "o3"
            | "o3-mini"
            | "o4-mini"
            | "gpt-4o"
            | "gpt-4o-mini"
            | "gemini-1.5-pro"
            | "gemini-2.0-flash"
            | "claude-3-5-haiku-latest"
            | "claude-3-5-sonnet-latest"
            | "claude-3-7-sonnet-latest"

      Returns Promise<void>

    • Adds or updates a single agent context.

      Parameters

      Returns Promise<void>

    • Adds or updates multiple agent contexts.

      Parameters

      Returns Promise<void>