AskSQL API Reference (core v0.10.0)
    Preparing search index...

    Interface FewShotStore

    Stores question->SQL pairs a user approved, retrieved as few-shots for new questions. userId scopes storage and retrieval per user; undefined userId (local mode) is its own bucket.

    interface FewShotStore {
        add(
            connectionId: string,
            example: FewShotExample,
            userId?: string,
        ): Promise<void>;
        retrieve(
            connectionId: string,
            question: string,
            limit: number,
            userId?: string,
        ): Promise<readonly FewShotExample[]>;
    }

    Implemented by

    Index
    • Parameters

      • connectionId: string
      • question: string
      • limit: number
      • OptionaluserId: string

      Returns Promise<readonly FewShotExample[]>