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
nodePlatform.js149 linesDownload Raw Back to utils
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 nodePlatform_exports = {};30__export(nodePlatform_exports, {31  nodePlatform: () => nodePlatform,32  setBoxedStackPrefixes: () => setBoxedStackPrefixes33});34module.exports = __toCommonJS(nodePlatform_exports);35var import_crypto = __toESM(require("crypto"));36var import_fs = __toESM(require("fs"));37var import_path = __toESM(require("path"));38var util = __toESM(require("util"));39var import_stream = require("stream");40var import_events = require("events");41var import_utilsBundle = require("../../utilsBundle");42var import_debugLogger = require("./debugLogger");43var import_zones = require("./zones");44var import_debug = require("./debug");45const pipelineAsync = util.promisify(import_stream.pipeline);46class NodeZone {47  constructor(zone) {48    this._zone = zone;49  }50  push(data) {51    return new NodeZone(this._zone.with("apiZone", data));52  }53  pop() {54    return new NodeZone(this._zone.without("apiZone"));55  }56  run(func) {57    return this._zone.run(func);58  }59  data() {60    return this._zone.data("apiZone");61  }62}63let boxedStackPrefixes = [];64function setBoxedStackPrefixes(prefixes) {65  boxedStackPrefixes = prefixes;66}67const coreDir = import_path.default.dirname(require.resolve("../../../package.json"));68const nodePlatform = {69  name: "node",70  boxedStackPrefixes: () => {71    if (process.env.PWDEBUGIMPL)72      return [];73    return [coreDir, ...boxedStackPrefixes];74  },75  calculateSha1: (text) => {76    const sha1 = import_crypto.default.createHash("sha1");77    sha1.update(text);78    return Promise.resolve(sha1.digest("hex"));79  },80  colors: import_utilsBundle.colors,81  coreDir,82  createGuid: () => import_crypto.default.randomBytes(16).toString("hex"),83  defaultMaxListeners: () => import_events.EventEmitter.defaultMaxListeners,84  fs: () => import_fs.default,85  env: process.env,86  inspectCustom: util.inspect.custom,87  isDebugMode: () => (0, import_debug.debugMode)() === "inspector",88  isJSDebuggerAttached: () => !!require("inspector").url(),89  isLogEnabled(name) {90    return import_debugLogger.debugLogger.isEnabled(name);91  },92  isUnderTest: () => (0, import_debug.isUnderTest)(),93  log(name, message) {94    import_debugLogger.debugLogger.log(name, message);95  },96  path: () => import_path.default,97  pathSeparator: import_path.default.sep,98  showInternalStackFrames: () => !!process.env.PWDEBUGIMPL,99  async streamFile(path2, stream) {100    await pipelineAsync(import_fs.default.createReadStream(path2), stream);101  },102  streamReadable: (channel) => {103    return new ReadableStreamImpl(channel);104  },105  streamWritable: (channel) => {106    return new WritableStreamImpl(channel);107  },108  zones: {109    current: () => new NodeZone((0, import_zones.currentZone)()),110    empty: new NodeZone(import_zones.emptyZone)111  }112};113class ReadableStreamImpl extends import_stream.Readable {114  constructor(channel) {115    super();116    this._channel = channel;117  }118  async _read() {119    const result = await this._channel.read({ size: 1024 * 1024 });120    if (result.binary.byteLength)121      this.push(result.binary);122    else123      this.push(null);124  }125  _destroy(error, callback) {126    this._channel.close().catch((e) => null);127    super._destroy(error, callback);128  }129}130class WritableStreamImpl extends import_stream.Writable {131  constructor(channel) {132    super();133    this._channel = channel;134  }135  async _write(chunk, encoding, callback) {136    const error = await this._channel.write({ binary: typeof chunk === "string" ? Buffer.from(chunk) : chunk }).catch((e) => e);137    callback(error || null);138  }139  async _final(callback) {140    const error = await this._channel.close().catch((e) => e);141    callback(error || null);142  }143}144// Annotate the CommonJS export names for ESM import in node:1450 && (module.exports = {146  nodePlatform,147  setBoxedStackPrefixes148});149 
Brunobkr/llama.cpp_AlgMor24_github · Team Ai