I think that's part of the RAG pipeline, at least to me it looks to be separate from the model output. Models are notorious for getting URLs wrong so makes sense to me to handle it separately.