Merge remote-tracking branch 'origin/master' into dev
This commit is contained in:
@@ -48,15 +48,13 @@ if (
|
|||||||
|
|
||||||
const MODEL = config?.OCO_MODEL;
|
const MODEL = config?.OCO_MODEL;
|
||||||
if (provider === 'anthropic' &&
|
if (provider === 'anthropic' &&
|
||||||
!MODEL_LIST.anthropic.includes(MODEL) &&
|
MODEL.typeof !== 'string' &&
|
||||||
command !== 'config' &&
|
command !== 'config' &&
|
||||||
mode !== CONFIG_MODES.set) {
|
mode !== CONFIG_MODES.set) {
|
||||||
outro(
|
outro(
|
||||||
`${chalk.red('✖')} Unsupported model ${MODEL} for Anthropic. Supported models are: ${MODEL_LIST.anthropic.join(
|
`${chalk.red('✖')} Unsupported model ${MODEL}. The model can be any string, but the current configuration is not supported.`
|
||||||
', '
|
);
|
||||||
)}`
|
process.exit(1);
|
||||||
);
|
|
||||||
process.exit(1);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export class AnthropicAi implements AiEngine {
|
export class AnthropicAi implements AiEngine {
|
||||||
|
|||||||
@@ -54,15 +54,12 @@ if (
|
|||||||
|
|
||||||
const MODEL = config?.OCO_MODEL || 'gpt-3.5-turbo';
|
const MODEL = config?.OCO_MODEL || 'gpt-3.5-turbo';
|
||||||
if (provider === 'openai' &&
|
if (provider === 'openai' &&
|
||||||
!MODEL_LIST.openai.includes(MODEL) &&
|
MODEL.typeof !== 'string' &&
|
||||||
command !== 'config' &&
|
command !== 'config' &&
|
||||||
mode !== CONFIG_MODES.set) {
|
mode !== CONFIG_MODES.set) {
|
||||||
outro(
|
outro(
|
||||||
`${chalk.red('✖')} Unsupported model ${MODEL} for OpenAI. Supported models are: ${MODEL_LIST.openai.join(
|
`${chalk.red('✖')} Unsupported model ${MODEL}. The model can be any string, but the current configuration is not supported.`
|
||||||
', '
|
|
||||||
)}`
|
|
||||||
);
|
);
|
||||||
|
|
||||||
process.exit(1);
|
process.exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user