diff --git a/package.json b/package.json index 1fcbcea..47a9221 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "nodejs-whisper", - "version": "0.0.10", + "version": "0.0.8", "description": "Node bindings for OpenAI's Whisper. Optimized for CPU.", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/src/downloadModel.ts b/src/downloadModel.ts index 6fa1131..361ccb8 100644 --- a/src/downloadModel.ts +++ b/src/downloadModel.ts @@ -36,24 +36,6 @@ export default async function downloadModel() { try { shell.cd(path.join(__dirname, '..', './cpp/whisper.cpp/models')) - const args = process.argv.slice(2) - if (args.length > 0) { - const modelName = args[0] - console.log('Downloading model:', modelName) - if (!MODELS_LIST.includes(modelName)) { - throw `[Nodejs-whisper] Error: Model name not found. Check your spelling.` - } - let scriptPath = './download-ggml-model.sh' - - if (process.platform === 'win32') scriptPath = 'download-ggml-model.cmd' - shell.chmod('+x', scriptPath) - shell.exec(`${scriptPath} ${modelName}`) - console.log('[Nodejs-whisper] Attempting to compile model...\n') - shell.cd('../') - shell.exec('make') - process.exit(0) - } - let anyModelExist = [] MODELS.forEach(model => {