So, I am making a chatbot for restaurants. It actually fetches relevant data using function calling.
I have also written the prompt so work with that even explicitly told in system prompt " ALWAYS prioritize function calling to fetch information
- You will always use available functions to answer queries."
and also prevent hallucination. But it still hallucinating. So, for the restaurants product search I have a function to fetch the relevant product. but Gemini sometimes doesn’t call the function just make up product by its own. It’s giving me so much problem.
previously I was using the 1.5 flash model which was giving me the worst result ever so, I have moved to pro model which still hallucinating. Even I am only giving last two conversations as a history to less hallucinate.
So can you give me a better solution?