Reasoning in Large Language Models: RAG and Beyond