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
v7.js66 linesDownload Raw Back to dist-node
1import rng from './rng.js';2import { unsafeStringify } from './stringify.js';3const _state = {};4function v7(options, buf, offset) {5    let bytes;6    if (options) {7        bytes = v7Bytes(options.random ?? options.rng?.() ?? rng(), options.msecs, options.seq, buf, offset);8    }9    else {10        const now = Date.now();11        const rnds = rng();12        updateV7State(_state, now, rnds);13        bytes = v7Bytes(rnds, _state.msecs, _state.seq, buf, offset);14    }15    return buf ?? unsafeStringify(bytes);16}17export function updateV7State(state, now, rnds) {18    state.msecs ??= -Infinity;19    state.seq ??= 0;20    if (now > state.msecs) {21        state.seq = (rnds[6] << 23) | (rnds[7] << 16) | (rnds[8] << 8) | rnds[9];22        state.msecs = now;23    }24    else {25        state.seq = (state.seq + 1) | 0;26        if (state.seq === 0) {27            state.msecs++;28        }29    }30    return state;31}32function v7Bytes(rnds, msecs, seq, buf, offset = 0) {33    if (rnds.length < 16) {34        throw new Error('Random bytes length must be >= 16');35    }36    if (!buf) {37        buf = new Uint8Array(16);38        offset = 0;39    }40    else {41        if (offset < 0 || offset + 16 > buf.length) {42            throw new RangeError(`UUID byte range ${offset}:${offset + 15} is out of buffer bounds`);43        }44    }45    msecs ??= Date.now();46    seq ??= ((rnds[6] * 0x7f) << 24) | (rnds[7] << 16) | (rnds[8] << 8) | rnds[9];47    buf[offset++] = (msecs / 0x10000000000) & 0xff;48    buf[offset++] = (msecs / 0x100000000) & 0xff;49    buf[offset++] = (msecs / 0x1000000) & 0xff;50    buf[offset++] = (msecs / 0x10000) & 0xff;51    buf[offset++] = (msecs / 0x100) & 0xff;52    buf[offset++] = msecs & 0xff;53    buf[offset++] = 0x70 | ((seq >>> 28) & 0x0f);54    buf[offset++] = (seq >>> 20) & 0xff;55    buf[offset++] = 0x80 | ((seq >>> 14) & 0x3f);56    buf[offset++] = (seq >>> 6) & 0xff;57    buf[offset++] = ((seq << 2) & 0xff) | (rnds[10] & 0x03);58    buf[offset++] = rnds[11];59    buf[offset++] = rnds[12];60    buf[offset++] = rnds[13];61    buf[offset++] = rnds[14];62    buf[offset++] = rnds[15];63    return buf;64}65export default v7;66 
Brunobkr/llama.cpp_AlgMor24_github · Team Ai