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
bidiFirefox.js131 linesDownload Raw Back to bidi
1"use strict";2var __create = Object.create;3var __defProp = Object.defineProperty;4var __getOwnPropDesc = Object.getOwnPropertyDescriptor;5var __getOwnPropNames = Object.getOwnPropertyNames;6var __getProtoOf = Object.getPrototypeOf;7var __hasOwnProp = Object.prototype.hasOwnProperty;8var __export = (target, all) => {9  for (var name in all)10    __defProp(target, name, { get: all[name], enumerable: true });11};12var __copyProps = (to, from, except, desc) => {13  if (from && typeof from === "object" || typeof from === "function") {14    for (let key of __getOwnPropNames(from))15      if (!__hasOwnProp.call(to, key) && key !== except)16        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });17  }18  return to;19};20var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(21  // If the importer is in node compatibility mode or this is not an ESM22  // file that has been converted to a CommonJS file using a Babel-23  // compatible transform (i.e. "__esModule" has not been set), then set24  // "default" to the CommonJS "module.exports" for node compatibility.25  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,26  mod27));28var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);29var bidiFirefox_exports = {};30__export(bidiFirefox_exports, {31  BidiFirefox: () => BidiFirefox32});33module.exports = __toCommonJS(bidiFirefox_exports);34var import_os = __toESM(require("os"));35var import_path = __toESM(require("path"));36var import_ascii = require("../utils/ascii");37var import_browserType = require("../browserType");38var import_bidiBrowser = require("./bidiBrowser");39var import_bidiConnection = require("./bidiConnection");40var import_firefoxPrefs = require("./third_party/firefoxPrefs");41var import_manualPromise = require("../../utils/isomorphic/manualPromise");42class BidiFirefox extends import_browserType.BrowserType {43  constructor(parent) {44    super(parent, "_bidiFirefox");45  }46  executablePath() {47    return "";48  }49  async connectToTransport(transport, options) {50    return import_bidiBrowser.BidiBrowser.connect(this.attribution.playwright, transport, options);51  }52  doRewriteStartupLog(error) {53    if (!error.logs)54      return error;55    if (error.logs.includes(`as root in a regular user's session is not supported.`))56      error.logs = "\n" + (0, import_ascii.wrapInASCIIBox)(`Firefox is unable to launch if the $HOME folder isn't owned by the current user.57Workaround: Set the HOME=/root environment variable${process.env.GITHUB_ACTION ? " in your GitHub Actions workflow file" : ""} when running Playwright.`, 1);58    if (error.logs.includes("no DISPLAY environment variable specified"))59      error.logs = "\n" + (0, import_ascii.wrapInASCIIBox)(import_browserType.kNoXServerRunningError, 1);60    return error;61  }62  amendEnvironment(env) {63    if (!import_path.default.isAbsolute(import_os.default.homedir()))64      throw new Error(`Cannot launch Firefox with relative home directory. Did you set ${import_os.default.platform() === "win32" ? "USERPROFILE" : "HOME"} to a relative path?`);65    env = {66      ...env,67      "MOZ_CRASHREPORTER": "1",68      "MOZ_CRASHREPORTER_NO_REPORT": "1",69      "MOZ_CRASHREPORTER_SHUTDOWN": "1"70    };71    if (import_os.default.platform() === "linux") {72      return { ...env, SNAP_NAME: void 0, SNAP_INSTANCE_NAME: void 0 };73    }74    return env;75  }76  attemptToGracefullyCloseBrowser(transport) {77    this._attemptToGracefullyCloseBrowser(transport).catch(() => {78    });79  }80  async _attemptToGracefullyCloseBrowser(transport) {81    if (!transport.onmessage) {82      transport.send({ method: "session.new", params: { capabilities: {} }, id: import_bidiConnection.kShutdownSessionNewMessageId });83      await new Promise((resolve) => {84        transport.onmessage = (message) => {85          if (message.id === import_bidiConnection.kShutdownSessionNewMessageId)86            resolve(true);87        };88      });89    }90    transport.send({ method: "browser.close", params: {}, id: import_bidiConnection.kBrowserCloseMessageId });91  }92  supportsPipeTransport() {93    return false;94  }95  async prepareUserDataDir(options, userDataDir) {96    await (0, import_firefoxPrefs.createProfile)({97      path: userDataDir,98      preferences: options.firefoxUserPrefs || {}99    });100  }101  async defaultArgs(options, isPersistent, userDataDir) {102    const { args = [], headless } = options;103    const userDataDirArg = args.find((arg) => arg.startsWith("-profile") || arg.startsWith("--profile"));104    if (userDataDirArg)105      throw this._createUserDataDirArgMisuseError("--profile");106    if (args.find((arg) => !arg.startsWith("-")))107      throw new Error("Arguments can not specify page to be opened");108    const firefoxArguments = ["--remote-debugging-port=0"];109    if (headless)110      firefoxArguments.push("--headless");111    else112      firefoxArguments.push("--foreground");113    firefoxArguments.push(`--profile`, userDataDir);114    firefoxArguments.push(...args);115    return firefoxArguments;116  }117  async waitForReadyState(options, browserLogsCollector) {118    const result = new import_manualPromise.ManualPromise();119    browserLogsCollector.onMessage((message) => {120      const match = message.match(/WebDriver BiDi listening on (ws:\/\/.*)$/);121      if (match)122        result.resolve({ wsEndpoint: match[1] + "/session" });123    });124    return result;125  }126}127// Annotate the CommonJS export names for ESM import in node:1280 && (module.exports = {129  BidiFirefox130});131 
Brunobkr/llama.cpp_AlgMor24_github · Team Ai