Skip to content

Commit

Permalink
fix: fix system prompt missing bug
Browse files Browse the repository at this point in the history
  • Loading branch information
zhzLuke96 committed Jul 9, 2024
1 parent 950a0cd commit d92e267
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/PromptMerger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,8 @@ export class PromptMerger {
}
}
}

system_prompt = system_prompts.join(this.options.join_string);
};

const only_first_with = (role: "user" | "assistant" | "remove") => {
Expand All @@ -173,7 +175,6 @@ export class PromptMerger {
}

if (role !== "remove") {
system_prompt = first_system.message.content;
const suffix = system_messages
.slice(1)
.map((m) => m.message.content)
Expand Down

0 comments on commit d92e267

Please sign in to comment.