I've got a setup where a user hits a chat interface (ai sdk useChat setup). I'm using initial messags to populate the feed BUT, those messages aren't saved to memory. I generate them from an agent.generate call.
I tried to add memory to that but I don't want the prompt to land in memory, just the response from the LLM, as if it was starting the conversation.
Does anyone have a solution for this using Mastra sdk or do I need to create my own function to write to memory?