# Wskazywanie odpowiedzi w podanym tekście (extractive QA)

EN: **Extractive question answering (reading comprehension)** · id `extractiveqa` · aliases: extractive QA, span extraction QA, pytania ekstraktywne

Path: [AI Atlas](https://aiatlasgraph.com/llms.txt) › [Język, obraz, audio](https://aiatlasgraph.com/t/modalities.md) › [Język naturalny](https://aiatlasgraph.com/t/nlp.md) › [Odpowiadanie na pytania (QA)](https://aiatlasgraph.com/t/questionanswering.md) › Wskazywanie odpowiedzi w podanym tekście (extractive QA)

## Description

- PL: Odpowiadanie na pytanie przez wskazanie spanu odpowiedzi w podanym kontekście lub stwierdzenie, że odpowiedzi w nim nie ma.
- EN: Answering a question by selecting an answer span in a given context, or stating that the context has no answer.

## In one sentence

- PL: Program dostaje tekst i pytanie, a w odpowiedzi zaznacza dokładnie ten fragment, który na nie odpowiada.
- EN: Software gets a text and a question and highlights exactly the passage that answers it.

## Problem it solves

- PL: Szukanie jednej informacji w długiej instrukcji lub regulaminie zajmuje dużo czasu, a odpowiedź trzeba potem jeszcze sprawdzić.
- EN: Finding one detail in a long manual or set of rules takes ages, and the answer still needs checking.

## What it does

- PL: Zamiast pisać własną odpowiedź, podkreśla zdanie w oryginale, więc od razu widać, skąd pochodzi.
- EN: Instead of writing its own answer it underlines words in the original, so you see at once where it came from.

## Everyday example

- PL: Pytasz o okres gwarancji, a program podświetla w umowie zdanie „gwarancja obejmuje 24 miesiące”.
- EN: You ask about the warranty period and the tool highlights the sentence in the contract stating it.

## This concerns you if you…

- PL: szukasz konkretnej informacji w długich dokumentach
- PL: potrzebujesz odpowiedzi z dokładnym cytatem
- PL: chcesz, by program przyznał, gdy odpowiedzi brak
- EN: look for specific facts in long documents
- EN: need answers with an exact quote
- EN: want software to admit when there is no answer

## Keywords

SQuAD · SQuAD 2.0 · span prediction · BERT QA · exact match · F1 score · question-answering pipeline · Natural Questions

## How it works

- PL: Pytanie i akapit trafiają razem do enkodera, który dla każdego tokenu przewiduje prawdopodobieństwo początku i końca odpowiedzi; wybiera się najlepszy span. Wersje z pytaniami bez odpowiedzi uczą model wstrzymania się, gdy żaden span nie przekracza progu.
- EN: Question and paragraph enter one encoder that predicts start and end probabilities for each token; the best span is chosen. Versions with unanswerable questions teach the model to abstain when no span passes a threshold.

## Limits

- PL: Odpowiedź musi dosłownie występować w tekście, więc pytania wymagające syntezy lub obliczeń wypadają słabo. Modele bez treningu na pytaniach bez odpowiedzi zgadują pasująco brzmiący fragment.
- EN: The answer must appear verbatim, so questions needing synthesis or calculation fare poorly. Models not trained on unanswerable questions guess a plausible-looking span.

## Key terms

- PL: **span**: Ciągły fragment tekstu wskazany jako odpowiedź.
- PL: **exact match**: Miara: czy odpowiedź jest identyczna z wzorcową.
- PL: **unanswerable question**: Pytanie, na które tekst nie odpowiada.
- EN: **span**: A continuous text fragment selected as the answer.
- EN: **exact match**: A metric: is the answer identical to the reference.
- EN: **unanswerable question**: A question the text does not answer.

## Know first

- [Transformery i attention (Transformers and attention)](https://aiatlasgraph.com/t/transformers.md)

## Related topics

Untyped, symmetric "see also" links.

- [Pytania i odpowiedzi o treść obrazu (VQA) (Visual question answering (VQA))](https://aiatlasgraph.com/t/vqa.md)

## Sources

- [SQuAD: 100,000+ Questions for Machine Comprehension of Text](<https://arxiv.org/abs/1606.05250>) `squad-2016` · by Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, Percy Liang
- [Know What You Don't Know: Unanswerable Questions for SQuAD](<https://ar5iv.labs.arxiv.org/html/1806.03822>) `rajpurkar-2018-squad2` · by Pranav Rajpurkar, Robin Jia, Percy Liang

---

AI Atlas revision 122 (2026-10-30) · HTML: https://aiatlasgraph.com/t/extractiveqa · index: https://aiatlasgraph.com/llms.txt · everything: https://aiatlasgraph.com/llms-full.txt · updated 2026-10-30
