Question answering is the NLP task of producing a direct answer to a question asked in natural language. What separates it from search is the shape of the output. Search returns a list of links, question answering returns the answer to the question itself.
There are two main approaches. In extractive question answering the answer appears inside a supplied document and the model only marks which span of text it is. In the generative approach the model writes the answer in its own words. A closed-book setup uses only the knowledge in the model's weights, while an open-book setup runs a retrieval step first and builds the answer from the retrieved documents. Most enterprise applications today work in that second form, through a RAG pipeline.
Evaluation goes beyond whether the answer is correct. Whether the answer is grounded in a source, whether the model says so when a question should have no answer, and unnecessary length are all measured.
A concrete case: an assistant wired to a software company's documentation is asked which plan includes a given feature. The system retrieves the relevant pricing page, builds its answer from it and shows the source. The reader can verify the claim with one click.
The most common failure is a confident answer to a question that should have had none. Being able to say "I do not know" is treated as a requirement of its own for that reason.



