Fix issues with system_message rendering

#3
by elmon - opened

When trying to pass a system_message in chat history, the template rendering fails with 'TypeError: can only concatenate str (not "list") to str'.
The underlying issue being the format of passed messages with "type" and "content" inside the contents of the message.
This case is handled correctly in user/assistant messages, inside the main loop, so I've adapted the template code from that part, assuming the system_message can be just a single text message.

Ready to merge
This branch is ready to get merged automatically.

Sign up or log in to comment