feat: update chat prompt (#6639)

fix AFF-878
fix AFF-852 (maybe)
This commit is contained in:
darkskygit
2024-04-19 12:34:02 +00:00
parent 94a70a5f3a
commit 657a5250ad
6 changed files with 42 additions and 4 deletions
@@ -351,7 +351,9 @@ export class ChatSessionService {
// render system prompt
const preload = withPrompt
? prompt.finish(ret.data[0]?.params || {})
? prompt
.finish(ret.data[0]?.params || {})
.filter(({ role }) => role !== 'system')
: [];
return {