Thanks for your explanation
I’m using Chat Completions too, that’s not a dependency (in fact it may save your sanity )
In contrast, my Chatbot does not perform a search on every iteration, it only does so if invoked by the LLM. You might want to consider that, but your approach may best suit your use case already.