Update prompter.js

Fixed a MAJOR bug in prompter.js, preventing any model besides llama3 from being used via ollama
This commit is contained in:
Sweaterdog 2025-02-23 21:13:47 -08:00 committed by GitHub
parent f313094cb5
commit e84cc60a77
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -145,10 +145,8 @@ export class Prompter {
profile.api = 'xai';
else if (profile.model.includes('deepseek'))
profile.api = 'deepseek';
else if (profile.model.includes('llama3'))
profile.api = 'ollama';
else
throw new Error('Unknown model:', profile.model);
else
profile.api = 'ollama'; // Fixed here to make it so if the model does not meet this criteria, it is an Ollama model, instead of blocking all models but llama3, which was an odd choice.
}
return profile;
}
@ -379,4 +377,4 @@ export class Prompter {
goal.quantity = parseInt(goal.quantity);
return goal;
}
}
}