RAG-Stack: Analysis of an Automated Framework for Collaborative Performance-Quality Optimization of RAG in AI Search