Negation is a quiet failure mode of language processing: a system that reads “no presenta fiebre” and extracts “fiebre” without noticing the negation gets the meaning backwards. This project detects negation in Spanish text so downstream tasks like information extraction, sentiment analysis, and question answering can account for it.
The system works in two supervised phases. First, a classifier finds negation cues, the words or expressions that signal a negation. Then a second phase works out each cue’s scope: which words in the sentence it affects.
The models are linear classifiers (scikit-learn) built on linguistic features: each word’s form, lemma, and part-of-speech tag, plus a window of context around it. Training data comes from an annotated Spanish corpus, and the pipeline covers corpus parsing, training, and evaluation.
The project ships in Docker, with a ready-to-use development environment.