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
0likes3.1kdownloads
offlineFallback.ts88 linesDownload Raw Back to src
1/*2  Copyright 2020 Google LLC3 4  Use of this source code is governed by an MIT-style5  license that can be found in the LICENSE file or at6  https://opensource.org/licenses/MIT.7*/8import {setCatchHandler} from 'workbox-routing/setCatchHandler.js';9import {matchPrecache} from 'workbox-precaching/matchPrecache.js';10import {RouteHandler, RouteHandlerCallbackOptions} from 'workbox-core/types.js';11 12import './_version.js';13 14export interface OfflineFallbackOptions {15  pageFallback?: string;16  imageFallback?: string;17  fontFallback?: string;18}19 20// Give TypeScript the correct global.21declare let self: ServiceWorkerGlobalScope;22 23/**24 * An implementation of the [comprehensive fallbacks recipe]{@link https://developers.google.com/web/tools/workbox/guides/advanced-recipes#comprehensive_fallbacks}. Be sure to include the fallbacks in your precache injection25 *26 * @memberof workbox-recipes27 *28 * @param {Object} [options]29 * @param {string} [options.pageFallback] Precache name to match for pag fallbacks. Defaults to offline.html30 * @param {string} [options.imageFallback] Precache name to match for image fallbacks.31 * @param {string} [options.fontFallback] Precache name to match for font fallbacks.32 */33function offlineFallback(options: OfflineFallbackOptions = {}): void {34  const pageFallback = options.pageFallback || 'offline.html';35  const imageFallback = options.imageFallback || false;36  const fontFallback = options.fontFallback || false;37 38  self.addEventListener('install', (event) => {39    const files = [pageFallback];40    if (imageFallback) {41      files.push(imageFallback);42    }43    if (fontFallback) {44      files.push(fontFallback);45    }46 47    event.waitUntil(48      self.caches49        .open('workbox-offline-fallbacks')50        .then((cache) => cache.addAll(files)),51    );52  });53 54  const handler: RouteHandler = async (55    options: RouteHandlerCallbackOptions,56  ) => {57    const dest = options.request.destination;58    const cache = await self.caches.open('workbox-offline-fallbacks');59 60    if (dest === 'document') {61      const match =62        (await matchPrecache(pageFallback)) ||63        (await cache.match(pageFallback));64      return match || Response.error();65    }66 67    if (dest === 'image' && imageFallback !== false) {68      const match =69        (await matchPrecache(imageFallback)) ||70        (await cache.match(imageFallback));71      return match || Response.error();72    }73 74    if (dest === 'font' && fontFallback !== false) {75      const match =76        (await matchPrecache(fontFallback)) ||77        (await cache.match(fontFallback));78      return match || Response.error();79    }80 81    return Response.error();82  };83 84  setCatchHandler(handler);85}86 87export {offlineFallback};88 
Brunobkr/llama.cpp_AlgMor24_github · Team Ai