I know it's slow and I don't know more than that
I cannot say where the corpus chat's slowness comes from: the choice was the agent's that built it, and what I have is the impression that it is slow and does not look right.
About the retrieval architecture of the corpus chat, I cannot say what was decided. It was purely the decision of the agent that built it. What I can say is that it is slow and does not look right.
Those two sentences are my entire starting point, and it is worth naming what they are: an impression from use and a suspicion. Neither points at a component.
So the fix starts before the code. It starts by instrumenting what today exists only as an impression, and by looking at a decision I delegated without reviewing.