@infersec/conduit 1.5.1 → 1.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { fileURLToPath as __fileURLToPath } from 'url';
|
|
3
|
-
import { dirname } from 'path';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __pathDirname } from 'node:path';
|
|
4
4
|
const __filename = __fileURLToPath(import.meta.url);
|
|
5
|
-
const __dirname =
|
|
5
|
+
const __dirname = __pathDirname(__filename);
|
|
6
6
|
|
|
7
7
|
import { parseArgs } from 'node:util';
|
|
8
8
|
import 'node:crypto';
|
|
9
|
-
import { a as asError, s as startInferenceAgent } from './start-
|
|
9
|
+
import { a as asError, s as startInferenceAgent } from './start-B9UMbDDZ.js';
|
|
10
10
|
import 'argon2';
|
|
11
11
|
import 'node:child_process';
|
|
12
12
|
import 'node:stream';
|
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { fileURLToPath as __fileURLToPath } from 'url';
|
|
3
|
-
import { dirname } from 'path';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __pathDirname } from 'node:path';
|
|
4
4
|
const __filename = __fileURLToPath(import.meta.url);
|
|
5
|
-
const __dirname =
|
|
5
|
+
const __dirname = __pathDirname(__filename);
|
|
6
6
|
|
|
7
7
|
import 'node:crypto';
|
|
8
|
-
import { s as startInferenceAgent, a as asError } from './start-
|
|
8
|
+
import { s as startInferenceAgent, a as asError } from './start-B9UMbDDZ.js';
|
|
9
9
|
import 'argon2';
|
|
10
10
|
import 'node:child_process';
|
|
11
11
|
import 'node:stream';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { fileURLToPath as __fileURLToPath } from 'url';
|
|
3
|
-
import { dirname } from 'path';
|
|
2
|
+
import { fileURLToPath as __fileURLToPath } from 'node:url';
|
|
3
|
+
import { dirname as __pathDirname } from 'node:path';
|
|
4
4
|
const __filename = __fileURLToPath(import.meta.url);
|
|
5
|
-
const __dirname =
|
|
5
|
+
const __dirname = __pathDirname(__filename);
|
|
6
6
|
|
|
7
7
|
import require$$0$5 from 'os';
|
|
8
8
|
import require$$1$2, { realpathSync as realpathSync$1, readlinkSync, readdirSync, readdir as readdir$1, lstatSync } from 'fs';
|
|
@@ -31,7 +31,7 @@ import require$$1$5, { fileURLToPath } from 'node:url';
|
|
|
31
31
|
import require$$1$6 from 'node:async_hooks';
|
|
32
32
|
import require$$1$7 from 'node:console';
|
|
33
33
|
import require$$0$b, { realpath, readlink, readdir, lstat, mkdir, readFile, writeFile } from 'node:fs/promises';
|
|
34
|
-
import path$1, { win32, posix, join } from 'node:path';
|
|
34
|
+
import path$1, { win32, posix, dirname, join } from 'node:path';
|
|
35
35
|
import require$$1$8 from 'node:dns';
|
|
36
36
|
import require$$2$4 from 'node:sqlite';
|
|
37
37
|
import require$$0$c from 'path';
|
|
@@ -94911,9 +94911,13 @@ async function downloadModelViaHuggingFace({ format, huggingFaceToken, modelSlug
|
|
|
94911
94911
|
// Get all files in model
|
|
94912
94912
|
for await (const file of listFiles({
|
|
94913
94913
|
accessToken,
|
|
94914
|
+
recursive: true,
|
|
94914
94915
|
repo: modelSlug
|
|
94915
94916
|
})) {
|
|
94916
94917
|
const filePath = file.path.toLowerCase();
|
|
94918
|
+
if (format === "gguf" && filePath.endsWith(".gguf") === false) {
|
|
94919
|
+
continue;
|
|
94920
|
+
}
|
|
94917
94921
|
if (variant &&
|
|
94918
94922
|
filePath.endsWith(".gguf") &&
|
|
94919
94923
|
filePath.includes(variant.toLowerCase()) === false) {
|
|
@@ -94925,6 +94929,7 @@ async function downloadModelViaHuggingFace({ format, huggingFaceToken, modelSlug
|
|
|
94925
94929
|
continue;
|
|
94926
94930
|
}
|
|
94927
94931
|
console.log("Downloading:", file.path, file.size);
|
|
94932
|
+
await mkdir(dirname(join(targetDirectory, file.path)), { recursive: true });
|
|
94928
94933
|
const response = await downloadFile({
|
|
94929
94934
|
accessToken,
|
|
94930
94935
|
repo: modelSlug,
|