GenkitG
Genkitโ€ข3mo ago
military-pink

I have a design question to architect my

I have a design question to architect my solution. My app provides analysis and guidance based on user's financial data. When user enters to the app very likely they have not provided any data at all. In this case, my agent is able to prompt the user asking for minimal information and continue the conversation.

It will very useful for me to store the user provided information in my data model as well (not just in the chat history). However, I am not sure how do i really implement this part of detecting that user provided information can be used to enrich the user data model. Concrete examples:

Example 1. user ask when can i retire and agent will say to tell you that i need your desired retirement age.
User responds: 55
Now when this response comes back to the flow, i would like to be able to identify that agent asked a question for which the response can be stored permanantly in the user profile as there is a field for that.

Example 2: user asks: can i afford to spend $10000 every month?
Agent: looks that user did not provide his income. so asks: can you tell me what's your monthly income?

At this point: i as a developer know that there is a field in user finacial data to store his annual income. So, other than keeping it in the chat history it will make sense to store it in the financial data.


One way I was thinking:
is another agent that kicks after every user response and analyze agent question and user response and check against the data model to see if it can store.

I feel i might be over engineering and over relying on the capability of the agentic system. Any other ideas or recommendations to implement my use case?
Was this page helpful?