Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit 795e636

Browse files
authored
chore: fixed an issue where cortex chat reload the running models (#937)
1 parent 2dc4733 commit 795e636

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

cortex-js/src/infrastructure/commanders/chat.command.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -109,21 +109,19 @@ export class ChatCommand extends BaseCommand {
109109

110110
const preset = await this.fileService.getPreset(options.preset);
111111

112-
return this.cortex.models.start(modelId, preset).then(() =>
113-
this.chatClient.chat(
112+
return this.chatClient.chat(
114113
modelId,
115114
options.threadId,
116115
message, // Accept both message from inputs or arguments
117116
preset ? preset : {},
118-
),
119-
);
117+
)
120118
}
121119

122120
modelInquiry = async (models: Cortex.Model[]) => {
123121
const { model } = await this.inquirerService.inquirer.prompt({
124122
type: 'list',
125123
name: 'model',
126-
message: 'Select running model to chat with:',
124+
message: 'Select a model to chat with:',
127125
choices: models.map((e) => ({
128126
name: e.id,
129127
value: e.id,

cortex-js/src/infrastructure/commanders/embeddings.command.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ export class EmbeddingCommand extends BaseCommand {
7171
const { model } = await this.inquirerService.inquirer.prompt({
7272
type: 'list',
7373
name: 'model',
74-
message: 'Select running model to chat with:',
74+
message: 'Select model to chat with:',
7575
choices: models.map((e) => ({
7676
name: e.id,
7777
value: e.id,

0 commit comments

Comments
 (0)