more
This commit is contained in:
dopeuni444
2025-07-31 12:23:33 +04:00
parent 20b46678b7
commit b5a22951ae
3401 changed files with 331100 additions and 0 deletions

28
unified-ai-platform/node_modules/@xtuc/ieee754/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,28 @@
Copyright (c) 2008, Fair Oaks Labs, Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of Fair Oaks Labs, Inc. nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.

View File

View File

@@ -0,0 +1,84 @@
export function read(buffer, offset, isLE, mLen, nBytes) {
var e, m
var eLen = (nBytes * 8) - mLen - 1
var eMax = (1 << eLen) - 1
var eBias = eMax >> 1
var nBits = -7
var i = isLE ? (nBytes - 1) : 0
var d = isLE ? -1 : 1
var s = buffer[offset + i]
i += d
e = s & ((1 << (-nBits)) - 1)
s >>= (-nBits)
nBits += eLen
for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {}
m = e & ((1 << (-nBits)) - 1)
e >>= (-nBits)
nBits += mLen
for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {}
if (e === 0) {
e = 1 - eBias
} else if (e === eMax) {
return m ? NaN : ((s ? -1 : 1) * Infinity)
} else {
m = m + Math.pow(2, mLen)
e = e - eBias
}
return (s ? -1 : 1) * m * Math.pow(2, e - mLen)
}
export function write(buffer, value, offset, isLE, mLen, nBytes) {
var e, m, c
var eLen = (nBytes * 8) - mLen - 1
var eMax = (1 << eLen) - 1
var eBias = eMax >> 1
var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0)
var i = isLE ? 0 : (nBytes - 1)
var d = isLE ? 1 : -1
var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0
value = Math.abs(value)
if (isNaN(value) || value === Infinity) {
m = isNaN(value) ? 1 : 0
e = eMax
} else {
e = Math.floor(Math.log(value) / Math.LN2)
if (value * (c = Math.pow(2, -e)) < 1) {
e--
c *= 2
}
if (e + eBias >= 1) {
value += rt / c
} else {
value += rt * Math.pow(2, 1 - eBias)
}
if (value * c >= 2) {
e++
c /= 2
}
if (e + eBias >= eMax) {
m = 0
e = eMax
} else if (e + eBias >= 1) {
m = ((value * c) - 1) * Math.pow(2, mLen)
e = e + eBias
} else {
m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen)
e = 0
}
}
for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}
e = (e << mLen) | m
eLen += mLen
for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}
buffer[offset + i - d] |= s * 128
}

View File

@@ -0,0 +1,42 @@
{
"name": "@xtuc/ieee754",
"description": "Read/write IEEE754 floating point numbers from/to a Buffer or array-like object",
"version": "1.2.0",
"author": {
"name": "Feross Aboukhadijeh",
"email": "feross@feross.org",
"url": "http://feross.org"
},
"contributors": [
"Romain Beauxis <toots@rastageeks.org>"
],
"devDependencies": {
"airtap": "0.0.7",
"standard": "*",
"tape": "^4.0.0",
"@babel/cli": "^7.0.0-beta.54",
"@babel/core": "^7.0.0-beta.54",
"@babel/plugin-transform-modules-commonjs": "^7.0.0-beta.54"
},
"keywords": [
"IEEE 754",
"buffer",
"convert",
"floating point",
"ieee754"
],
"license": "BSD-3-Clause",
"main": "dist/index.cjs.js",
"module": "index.js",
"repository": {
"type": "git",
"url": "git://github.com/feross/ieee754.git"
},
"scripts": {
"test": "standard && npm run test-node && npm run test-browser",
"test-browser": "airtap -- test/*.js",
"test-browser-local": "airtap --local -- test/*.js",
"test-node": "tape test/*.js"
},
"prepublish": "babel --plugins @babel/plugin-transform-modules-commonjs index.js -o dist/index.cjs.js"
}

429
unified-ai-platform/node_modules/@xtuc/long/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,429 @@
export = Long;
export as namespace Long;
declare namespace Long { }
declare class Long {
/**
* Constructs a 64 bit two's-complement integer, given its low and high 32 bit values as signed integers. See the from* functions below for more convenient ways of constructing Longs.
*/
constructor(low: number, high?: number, unsigned?: boolean);
/**
* Maximum unsigned value.
*/
static MAX_UNSIGNED_VALUE: Long;
/**
* Maximum signed value.
*/
static MAX_VALUE: Long;
/**
* Minimum signed value.
*/
static MIN_VALUE: Long;
/**
* Signed negative one.
*/
static NEG_ONE: Long;
/**
* Signed one.
*/
static ONE: Long;
/**
* Unsigned one.
*/
static UONE: Long;
/**
* Unsigned zero.
*/
static UZERO: Long;
/**
* Signed zero
*/
static ZERO: Long;
/**
* The high 32 bits as a signed value.
*/
high: number;
/**
* The low 32 bits as a signed value.
*/
low: number;
/**
* Whether unsigned or not.
*/
unsigned: boolean;
/**
* Returns a Long representing the 64 bit integer that comes by concatenating the given low and high bits. Each is assumed to use 32 bits.
*/
static fromBits(lowBits: number, highBits: number, unsigned?: boolean): Long;
/**
* Returns a Long representing the given 32 bit integer value.
*/
static fromInt(value: number, unsigned?: boolean): Long;
/**
* Returns a Long representing the given value, provided that it is a finite number. Otherwise, zero is returned.
*/
static fromNumber(value: number, unsigned?: boolean): Long;
/**
* Returns a Long representation of the given string, written using the specified radix.
*/
static fromString(str: string, unsigned?: boolean | number, radix?: number): Long;
/**
* Creates a Long from its byte representation.
*/
static fromBytes(bytes: number[], unsigned?: boolean, le?: boolean): Long;
/**
* Creates a Long from its little endian byte representation.
*/
static fromBytesLE(bytes: number[], unsigned?: boolean): Long;
/**
* Creates a Long from its big endian byte representation.
*/
static fromBytesBE(bytes: number[], unsigned?: boolean): Long;
/**
* Tests if the specified object is a Long.
*/
static isLong(obj: any): obj is Long;
/**
* Converts the specified value to a Long.
*/
static fromValue(val: Long | number | string | {low: number, high: number, unsigned: boolean}, unsigned?: boolean): Long;
/**
* Returns the sum of this and the specified Long.
*/
add(addend: number | Long | string): Long;
/**
* Returns the bitwise AND of this Long and the specified.
*/
and(other: Long | number | string): Long;
/**
* Compares this Long's value with the specified's.
*/
compare(other: Long | number | string): number;
/**
* Compares this Long's value with the specified's.
*/
comp(other: Long | number | string): number;
/**
* Returns this Long divided by the specified.
*/
divide(divisor: Long | number | string): Long;
/**
* Returns this Long divided by the specified.
*/
div(divisor: Long | number | string): Long;
/**
* Tests if this Long's value equals the specified's.
*/
equals(other: Long | number | string): boolean;
/**
* Tests if this Long's value equals the specified's.
*/
eq(other: Long | number | string): boolean;
/**
* Gets the high 32 bits as a signed integer.
*/
getHighBits(): number;
/**
* Gets the high 32 bits as an unsigned integer.
*/
getHighBitsUnsigned(): number;
/**
* Gets the low 32 bits as a signed integer.
*/
getLowBits(): number;
/**
* Gets the low 32 bits as an unsigned integer.
*/
getLowBitsUnsigned(): number;
/**
* Gets the number of bits needed to represent the absolute value of this Long.
*/
getNumBitsAbs(): number;
/**
* Tests if this Long's value is greater than the specified's.
*/
greaterThan(other: Long | number | string): boolean;
/**
* Tests if this Long's value is greater than the specified's.
*/
gt(other: Long | number | string): boolean;
/**
* Tests if this Long's value is greater than or equal the specified's.
*/
greaterThanOrEqual(other: Long | number | string): boolean;
/**
* Tests if this Long's value is greater than or equal the specified's.
*/
gte(other: Long | number | string): boolean;
/**
* Tests if this Long's value is greater than or equal the specified's.
*/
ge(other: Long | number | string): boolean;
/**
* Tests if this Long's value is even.
*/
isEven(): boolean;
/**
* Tests if this Long's value is negative.
*/
isNegative(): boolean;
/**
* Tests if this Long's value is odd.
*/
isOdd(): boolean;
/**
* Tests if this Long's value is positive.
*/
isPositive(): boolean;
/**
* Tests if this Long's value equals zero.
*/
isZero(): boolean;
/**
* Tests if this Long's value equals zero.
*/
eqz(): boolean;
/**
* Tests if this Long's value is less than the specified's.
*/
lessThan(other: Long | number | string): boolean;
/**
* Tests if this Long's value is less than the specified's.
*/
lt(other: Long | number | string): boolean;
/**
* Tests if this Long's value is less than or equal the specified's.
*/
lessThanOrEqual(other: Long | number | string): boolean;
/**
* Tests if this Long's value is less than or equal the specified's.
*/
lte(other: Long | number | string): boolean;
/**
* Tests if this Long's value is less than or equal the specified's.
*/
le(other: Long | number | string): boolean;
/**
* Returns this Long modulo the specified.
*/
modulo(other: Long | number | string): Long;
/**
* Returns this Long modulo the specified.
*/
mod(other: Long | number | string): Long;
/**
* Returns this Long modulo the specified.
*/
rem(other: Long | number | string): Long;
/**
* Returns the product of this and the specified Long.
*/
multiply(multiplier: Long | number | string): Long;
/**
* Returns the product of this and the specified Long.
*/
mul(multiplier: Long | number | string): Long;
/**
* Negates this Long's value.
*/
negate(): Long;
/**
* Negates this Long's value.
*/
neg(): Long;
/**
* Returns the bitwise NOT of this Long.
*/
not(): Long;
/**
* Tests if this Long's value differs from the specified's.
*/
notEquals(other: Long | number | string): boolean;
/**
* Tests if this Long's value differs from the specified's.
*/
neq(other: Long | number | string): boolean;
/**
* Tests if this Long's value differs from the specified's.
*/
ne(other: Long | number | string): boolean;
/**
* Returns the bitwise OR of this Long and the specified.
*/
or(other: Long | number | string): Long;
/**
* Returns this Long with bits shifted to the left by the given amount.
*/
shiftLeft(numBits: number | Long): Long;
/**
* Returns this Long with bits shifted to the left by the given amount.
*/
shl(numBits: number | Long): Long;
/**
* Returns this Long with bits arithmetically shifted to the right by the given amount.
*/
shiftRight(numBits: number | Long): Long;
/**
* Returns this Long with bits arithmetically shifted to the right by the given amount.
*/
shr(numBits: number | Long): Long;
/**
* Returns this Long with bits logically shifted to the right by the given amount.
*/
shiftRightUnsigned(numBits: number | Long): Long;
/**
* Returns this Long with bits logically shifted to the right by the given amount.
*/
shru(numBits: number | Long): Long;
/**
* Returns this Long with bits logically shifted to the right by the given amount.
*/
shr_u(numBits: number | Long): Long;
/**
* Returns this Long with bits rotated to the left by the given amount.
*/
rotateLeft(numBits: number | Long): Long;
/**
* Returns this Long with bits rotated to the left by the given amount.
*/
rotl(numBits: number | Long): Long;
/**
* Returns this Long with bits rotated to the right by the given amount.
*/
rotateRight(numBits: number | Long): Long;
/**
* Returns this Long with bits rotated to the right by the given amount.
*/
rotr(numBits: number | Long): Long;
/**
* Returns the difference of this and the specified Long.
*/
subtract(subtrahend: number | Long | string): Long;
/**
* Returns the difference of this and the specified Long.
*/
sub(subtrahend: number | Long |string): Long;
/**
* Converts the Long to a 32 bit integer, assuming it is a 32 bit integer.
*/
toInt(): number;
/**
* Converts the Long to a the nearest floating-point representation of this value (double, 53 bit mantissa).
*/
toNumber(): number;
/**
* Converts this Long to its byte representation.
*/
toBytes(le?: boolean): number[];
/**
* Converts this Long to its little endian byte representation.
*/
toBytesLE(): number[];
/**
* Converts this Long to its big endian byte representation.
*/
toBytesBE(): number[];
/**
* Converts this Long to signed.
*/
toSigned(): Long;
/**
* Converts the Long to a string written in the specified radix.
*/
toString(radix?: number): string;
/**
* Converts this Long to unsigned.
*/
toUnsigned(): Long;
/**
* Returns the bitwise XOR of this Long and the given one.
*/
xor(other: Long | number | string): Long;
}

1
unified-ai-platform/node_modules/@xtuc/long/index.js generated vendored Normal file
View File

@@ -0,0 +1 @@
module.exports = require("./src/long");

View File

@@ -0,0 +1,36 @@
{
"name": "@xtuc/long",
"version": "4.2.2",
"author": "Daniel Wirtz <dcode@dcode.io>",
"description": "A Long class for representing a 64-bit two's-complement integer value.",
"main": "src/long.js",
"repository": {
"type": "git",
"url": "https://github.com/dcodeIO/long.js.git"
},
"bugs": {
"url": "https://github.com/dcodeIO/long.js/issues"
},
"keywords": [
"math"
],
"dependencies": {},
"devDependencies": {
"webpack": "^3.10.0"
},
"license": "Apache-2.0",
"scripts": {
"build": "webpack",
"test": "node tests"
},
"files": [
"index.js",
"LICENSE",
"README.md",
"src/long.js",
"dist/long.js",
"dist/long.js.map",
"index.d.ts"
],
"types": "index.d.ts"
}