Skip to yearly menu bar Skip to main content

Workshop: Generative AI for Education (GAIED): Advances, Opportunities, and Challenges

Paper 40: Retrieval-augmented Generation to Improve Math Question-Answering: Trade-offs Between Groundedness and Human Preference

Zachary Levonian · Chenglu Li · Wangda Zhu · Anoushka Gade · Owen Henkel · Millie-Ellen Postle · Wanli Xing · Zachary Levonian

Keywords: [ Prompt Engineering ] [ question-answering ] [ Generative AI ] [ Large language models ] [ education ] [ mathematics ] [ surveys ]


For middle-school math students, interactive question-answering (QA) with tutors is an effective way to learn. The flexibility and emergent capabilities of generative large language models (LLMs) has led to a surge of interest in automating portions of the tutoring process—including interactive QA to support conceptual discussion of mathematical concepts. However, LLM responses to math questions can be incorrect or mismatched to the educational context—such as being misaligned with a school's curriculum. One potential solution is retrieval-augmented generation (RAG), which involves incorporating a vetted external knowledge source in the LLM prompt to increase response quality. In this paper, we designed prompts that retrieve and use content from a high-quality open-source math textbook to generate responses to real student questions. We evaluate the efficacy of this RAG system for middle-school algebra and geometry QA by administering a multi-condition survey, finding that humans prefer responses generated using RAG, but not when responses are too grounded in the textbook content. We argue that while RAG is able to improve response quality, designers of math QA systems must consider trade-offs between generating responses preferred by students and responses closely matched to specific educational resources.

Chat is not available.