Team Ai
Datasetpublic

Brunobkr/llama.cpp_AlgMor24_github

ΩFFFΣLLIa • llama.cpp • AlgMor24 ██████╗ ███████╗███████╗███████╗██╗ ██╗ ██╗ █████╗ ██╔═══██╗██╔════╝██╔════╝██╔════╝██║ ██║ ██║██╔══██╗ ██║ ██║█████╗ █████╗ █████╗ ██║ ██║ ██║███████║ ██║ ██║██╔══╝ ██╔══╝ ██╔══╝ ██║ ██║ ██║██╔══██║ ╚██████╔╝██║ ██║ ███████╗███████╗███████╗██║██║ ██║ ╚═════╝ ╚═╝ ╚═╝ ╚══════╝╚══════╝╚══════╝╚═╝╚═╝ ╚═╝ High-Performance LLM / VLM Inference & Autonomous Agentic Ecosystem… See the full description on the dataset page: https://huggingface.co/datasets/Brunobkr/llama.cpp_AlgMor24_github.

sourceHugging Faceupdated 2mo agoView on Hugging Face
0likes3kdownloads
1import './_version.js';2interface OnSyncCallbackOptions {3    queue: Queue;4}5interface OnSyncCallback {6    (options: OnSyncCallbackOptions): void | Promise<void>;7}8export interface QueueOptions {9    forceSyncFallback?: boolean;10    maxRetentionTime?: number;11    onSync?: OnSyncCallback;12}13interface QueueEntry {14    request: Request;15    timestamp?: number;16    metadata?: object;17}18/**19 * A class to manage storing failed requests in IndexedDB and retrying them20 * later. All parts of the storing and replaying process are observable via21 * callbacks.22 *23 * @memberof workbox-background-sync24 */25declare class Queue {26    private readonly _name;27    private readonly _onSync;28    private readonly _maxRetentionTime;29    private readonly _queueStore;30    private readonly _forceSyncFallback;31    private _syncInProgress;32    private _requestsAddedDuringSync;33    /**34     * Creates an instance of Queue with the given options35     *36     * @param {string} name The unique name for this queue. This name must be37     *     unique as it's used to register sync events and store requests38     *     in IndexedDB specific to this instance. An error will be thrown if39     *     a duplicate name is detected.40     * @param {Object} [options]41     * @param {Function} [options.onSync] A function that gets invoked whenever42     *     the 'sync' event fires. The function is invoked with an object43     *     containing the `queue` property (referencing this instance), and you44     *     can use the callback to customize the replay behavior of the queue.45     *     When not set the `replayRequests()` method is called.46     *     Note: if the replay fails after a sync event, make sure you throw an47     *     error, so the browser knows to retry the sync event later.48     * @param {number} [options.maxRetentionTime=7 days] The amount of time (in49     *     minutes) a request may be retried. After this amount of time has50     *     passed, the request will be deleted from the queue.51     * @param {boolean} [options.forceSyncFallback=false] If `true`, instead52     *     of attempting to use background sync events, always attempt to replay53     *     queued request at service worker startup. Most folks will not need54     *     this, unless you explicitly target a runtime like Electron that55     *     exposes the interfaces for background sync, but does not have a working56     *     implementation.57     */58    constructor(name: string, { forceSyncFallback, onSync, maxRetentionTime }?: QueueOptions);59    /**60     * @return {string}61     */62    get name(): string;63    /**64     * Stores the passed request in IndexedDB (with its timestamp and any65     * metadata) at the end of the queue.66     *67     * @param {QueueEntry} entry68     * @param {Request} entry.request The request to store in the queue.69     * @param {Object} [entry.metadata] Any metadata you want associated with the70     *     stored request. When requests are replayed you'll have access to this71     *     metadata object in case you need to modify the request beforehand.72     * @param {number} [entry.timestamp] The timestamp (Epoch time in73     *     milliseconds) when the request was first added to the queue. This is74     *     used along with `maxRetentionTime` to remove outdated requests. In75     *     general you don't need to set this value, as it's automatically set76     *     for you (defaulting to `Date.now()`), but you can update it if you77     *     don't want particular requests to expire.78     */79    pushRequest(entry: QueueEntry): Promise<void>;80    /**81     * Stores the passed request in IndexedDB (with its timestamp and any82     * metadata) at the beginning of the queue.83     *84     * @param {QueueEntry} entry85     * @param {Request} entry.request The request to store in the queue.86     * @param {Object} [entry.metadata] Any metadata you want associated with the87     *     stored request. When requests are replayed you'll have access to this88     *     metadata object in case you need to modify the request beforehand.89     * @param {number} [entry.timestamp] The timestamp (Epoch time in90     *     milliseconds) when the request was first added to the queue. This is91     *     used along with `maxRetentionTime` to remove outdated requests. In92     *     general you don't need to set this value, as it's automatically set93     *     for you (defaulting to `Date.now()`), but you can update it if you94     *     don't want particular requests to expire.95     */96    unshiftRequest(entry: QueueEntry): Promise<void>;97    /**98     * Removes and returns the last request in the queue (along with its99     * timestamp and any metadata). The returned object takes the form:100     * `{request, timestamp, metadata}`.101     *102     * @return {Promise<QueueEntry | undefined>}103     */104    popRequest(): Promise<QueueEntry | undefined>;105    /**106     * Removes and returns the first request in the queue (along with its107     * timestamp and any metadata). The returned object takes the form:108     * `{request, timestamp, metadata}`.109     *110     * @return {Promise<QueueEntry | undefined>}111     */112    shiftRequest(): Promise<QueueEntry | undefined>;113    /**114     * Returns all the entries that have not expired (per `maxRetentionTime`).115     * Any expired entries are removed from the queue.116     *117     * @return {Promise<Array<QueueEntry>>}118     */119    getAll(): Promise<Array<QueueEntry>>;120    /**121     * Returns the number of entries present in the queue.122     * Note that expired entries (per `maxRetentionTime`) are also included in this count.123     *124     * @return {Promise<number>}125     */126    size(): Promise<number>;127    /**128     * Adds the entry to the QueueStore and registers for a sync event.129     *130     * @param {Object} entry131     * @param {Request} entry.request132     * @param {Object} [entry.metadata]133     * @param {number} [entry.timestamp=Date.now()]134     * @param {string} operation ('push' or 'unshift')135     * @private136     */137    _addRequest({ request, metadata, timestamp }: QueueEntry, operation: 'push' | 'unshift'): Promise<void>;138    /**139     * Removes and returns the first or last (depending on `operation`) entry140     * from the QueueStore that's not older than the `maxRetentionTime`.141     *142     * @param {string} operation ('pop' or 'shift')143     * @return {Object|undefined}144     * @private145     */146    _removeRequest(operation: 'pop' | 'shift'): Promise<QueueEntry | undefined>;147    /**148     * Loops through each request in the queue and attempts to re-fetch it.149     * If any request fails to re-fetch, it's put back in the same position in150     * the queue (which registers a retry for the next sync event).151     */152    replayRequests(): Promise<void>;153    /**154     * Registers a sync event with a tag unique to this instance.155     */156    registerSync(): Promise<void>;157    /**158     * In sync-supporting browsers, this adds a listener for the sync event.159     * In non-sync-supporting browsers, or if _forceSyncFallback is true, this160     * will retry the queue on service worker startup.161     *162     * @private163     */164    private _addSyncListener;165    /**166     * Returns the set of queue names. This is primarily used to reset the list167     * of queue names in tests.168     *169     * @return {Set<string>}170     *171     * @private172     */173    static get _queueNames(): Set<string>;174}175export { Queue };176