background messaging not really background
# support
s
So background messaging in the Web ask is really in just a system msg right? My assistant responds to system messages also against what is stated in the docs. Is this a prompting trick?
v
@Sangy It sounds like you're referring to the behavior of your assistant in response to system messages within the Web SDK. The assistant should indeed respond to the messages specified at creation time in the
clientMessages
field. If your assistant is responding to system messages that you did not specify or intend for it to handle, this could be an issue with the configuration or an unexpected behavior. If you believe your assistant is not behaving as documented, it would be helpful to review the configuration you've set for
clientMessages
and ensure it aligns with your expectations. If everything seems correct on your end and the issue persists, it might be necessary to look into the specific details of your implementation or consult with support for further assistance. Would you like to review the
clientMessages
configuration or is there something specific you would like to address regarding the assistant's behavior?
You can continue this conversation by mentioning me in the message.
s
@Shubham Bajaj
s
you can use role for system, user, assistant, tool or function.
@Sangy i hope it resolves the issue if something else then please eloborate.
s
I use the system role. The docs says this is a background message so assistant should not respond but the assistant always replies back.
s
change type to assistant and it will work.
s
no that does not work as well. have you tested this before? here is how i send the background message (following https://docs.vapi.ai/assistants/background-messages) I just wnat to add to the context of the conversation and not have the assistant reply back. vapiInstance.send({ type: "add-message", message: { role: "system", content: "Waiting for the candidate to enable screen sharing.", }, });
spoke to @nikhil in OH and he said this is a quick fix. basically the assistant should treat this as a true background message and not get interrupted.