Skip to content

Commit

Permalink
Merge pull request buerokratt#1048 from 1AhmedYasser/Give-the-LLM-the…
Browse files Browse the repository at this point in the history
…-input-from-the-last-messages

Hot Fix: Content Control Characters
  • Loading branch information
varmoh authored Nov 27, 2024
2 parents 1d57d64 + 718d7c1 commit 1ac2e9c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions DSL/DMapper/hbs/prepare-llm-messages.handlebars
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
[
{
"role": "system",
"content": "{{prompt_message}}"
"content": "{{filterControlCharacters prompt_message}}"
}
{{#if messages}}
{{#each messages}}
{{#if (eq authorRole "end-user")}},
{
"role": "user",
"content": "{{content}}"
"content": "{{filterControlCharacters content}}"
}
{{else}},
{
"role": "assistant",
"content": "{{content}}"
"content": "{{filterControlCharacters content}}"
}
{{/if}}
{{/each}}
{{/if}}
{{#if new_message}},
{
"role": "user",
"content": "{{new_message}}"
"content": "{{filterControlCharacters new_message}}"
}
{{/if}}
]

0 comments on commit 1ac2e9c

Please sign in to comment.