@neuralforge/cli 0.9.0

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/package.json ADDED
@@ -0,0 +1,20 @@
1
+ {
2
+ "name": "@neuralforge/cli",
3
+ "version": "0.9.0",
4
+ "description": "Command-line interface for NeuralForge",
5
+ "main": "dist/index.js",
6
+ "types": "dist/index.d.ts",
7
+ "scripts": {
8
+ "build": "tsc",
9
+ "test": "vitest",
10
+ "lint": "eslint src/"
11
+ },
12
+ "dependencies": {
13
+ "typescript": "^5.4.0",
14
+ "commander": "^12.0.0"
15
+ },
16
+ "devDependencies": {
17
+ "vitest": "^1.6.0",
18
+ "eslint": "^8.57.0"
19
+ }
20
+ }
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Export command
3
+ */
4
+
5
+ export async function exportModel(modelPath: string, format: string): Promise<void> {}
6
+
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Hub command
3
+ */
4
+
5
+ export async function hubCommand(action: string, args: string[]): Promise<void> {}
6
+
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Serve command
3
+ */
4
+
5
+ export async function serve(modelPath: string, port: number = 8080): Promise<void> {}
6
+
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Train command
3
+ */
4
+
5
+ export async function runCLI(args: string[]): Promise<void> { console.log('Training...'); }
6
+
package/src/index.ts ADDED
@@ -0,0 +1,6 @@
1
+ /**
2
+ * CLI entry
3
+ */
4
+
5
+ export { runCLI } from './commands/train';
6
+
@@ -0,0 +1,7 @@
1
+ /**
2
+ * CLI config
3
+ */
4
+
5
+ export interface CLIConfig { modelPath?: string; device?: string; }
6
+ export function loadConfig(path: string): CLIConfig { return {}; }
7
+
@@ -0,0 +1,6 @@
1
+ /**
2
+ * CLI logger
3
+ */
4
+
5
+ export function log(level: string, msg: string): void { console.log(`[${level}] ${msg}`); }
6
+
@@ -0,0 +1,13 @@
1
+ import { describe, it, expect } from 'vitest';
2
+ import { runCLI } from '../src';
3
+
4
+ describe('runCLI', () => {
5
+ it('should be defined', () => {
6
+ expect(runCLI).toBeDefined();
7
+ });
8
+
9
+ it('should initialize correctly', () => {
10
+ const instance = new runCLI();
11
+ expect(instance).toBeInstanceOf(runCLI);
12
+ });
13
+ });
package/tsconfig.json ADDED
@@ -0,0 +1,7 @@
1
+ {
2
+ "extends": "../../tsconfig.base.json",
3
+ "compilerOptions": {
4
+ "outDir": "dist",
5
+ "rootDir": "src"
6
+ }
7
+ }